Payment terminal TIMAPI.DLL
Moderator: Rathinagiri
Payment terminal TIMAPI.DLL
Hello everyone
I would need to integrate the program's cooperation with the payment terminal. These are WORLDLine terminals. There is a TIMAPI SDK for this with libraries for Java, .NET, Swift, JavaScript, C
more at the link
https://six-tim.github.io/timapi/doc/c/guide.html#setup
Has anyone solved it?
Thanks for help
Best regards, Georg
I would need to integrate the program's cooperation with the payment terminal. These are WORLDLine terminals. There is a TIMAPI SDK for this with libraries for Java, .NET, Swift, JavaScript, C
more at the link
https://six-tim.github.io/timapi/doc/c/guide.html#setup
Has anyone solved it?
Thanks for help
Best regards, Georg
Re: Payment terminal TIMAPI.DLL
Hello everyone
As far as I can see, no one has implemented payment terminals yet.
So please help with the C library.
In the attachment there is a complete SDK in C with source code.
I have a problem with the declaration of variables and reading the return values
source code in C language
I created a function that calls parts from the DLL library
after calling my function the program freezes
when I call the function that returns the current version of the API, everything goes fine
I know that the problem is in the declaration of objects and their subsequent reading.
my knowledge of C is weak and I cannot adapt it to the needs of HMG
Thank you for your help
As far as I can see, no one has implemented payment terminals yet.
So please help with the C library.
In the attachment there is a complete SDK in C with source code.
I have a problem with the declaration of variables and reading the return values
source code in C language
Code: Select all
ta_object_t terminal = ta_object_invalid;
ta_object_t settings = ta_object_invalid;
// create terminal settings instance
ta_terminal_settings_create(&settings);
// add wanted guides (with bitwise or)
ta_terminal_settings_set_guides(settings, ta_c_guide_retail | ta_c_guide_dialog);
// create terminal
ta_terminal_create(&terminal, settings);
// release terminal settings
ta_object_release(settings);
Code: Select all
function a_timcres
local vr:=''
if file(cesta1+'timapi.dll')
vr:=HMG_CallDLL ( 'timapi.dll', , 'ta_terminal_settings_create','&settings')
//ta_terminal_settings_create(&settings);
endif
msgbox(vr,'a_timcres')
return(vr)
when I call the function that returns the current version of the API, everything goes fine
Code: Select all
ltim_ver:='TIMapi: '+HB_VALTOSTR(HMG_CallDLL ( 'timapi.dll', , 'ta_terminal_get_tim_api_version'))
my knowledge of C is weak and I cannot adapt it to the needs of HMG
Thank you for your help
- Attachments
-
- timsdk_C.ZIP
- (21.62 MiB) Downloaded 831 times
-
- tim_toolsTools.zip
- (19.85 MiB) Downloaded 783 times
- serge_girard
- Posts: 3309
- Joined: Sun Nov 25, 2012 2:44 pm
- DBs Used: 1 MySQL - MariaDB
2 DBF - Location: Belgium
- Contact:
Re: Payment terminal TIMAPI.DLL
Perhaps Edward can help?
There's nothing you can do that can't be done...
Re: Payment terminal TIMAPI.DLL
I was hoping that KDJ would help, but he was last here a year ago
- AUGE_OHR
- Posts: 2093
- Joined: Sun Aug 25, 2019 3:12 pm
- DBs Used: DBF, PostgreSQL, MySQL, SQLite
- Location: Hamburg, Germany
Re: Payment terminal TIMAPI.DLL
hi,
i have look into your Upload and found that *.DLL also have a LIB in same Folder
---
when use a *.DLL 1st, Step is to "loadLibrary"
when got a handle you must use it for all HMG_CallDLL()
---
other Way is to use a "Import" LIB. those LIB in ZIP Files seem to be for it
when have a "Import" LIB you can use all Function like usual without "call" it
but you need it for MinGW / HMG
there is a Tool called LIB2A which you can try to "convert" *-LIB to *.A
please search here in Forum
---
i´m NOT a "C" User so i can´t help with "C" Code
i have look into your Upload and found that *.DLL also have a LIB in same Folder
---
when use a *.DLL 1st, Step is to "loadLibrary"
Code: Select all
nDLL := HMG_CallDLL( "Kernel32.dll",, "LoadLibrary", "Everything32.dll" )
IF nDLL > 0
Code: Select all
nRet := DllCall( nDLL,, "Everything_SetRequestFlags", hb_BitOr
( EVERYTHING_REQUEST_PATH, EVERYTHING_REQUEST_FILE_NAME, EVERYTHING_REQUEST_SIZE ) )
other Way is to use a "Import" LIB. those LIB in ZIP Files seem to be for it
when have a "Import" LIB you can use all Function like usual without "call" it
but you need it for MinGW / HMG
there is a Tool called LIB2A which you can try to "convert" *-LIB to *.A
please search here in Forum
---
i´m NOT a "C" User so i can´t help with "C" Code
have fun
Jimmy
Jimmy
Re: Payment terminal TIMAPI.DLL
Thanks for help
I'll try and let you know how.
I also think that creating lib.a would be the easiest.
Best regards, Georg
I'll try and let you know how.
I also think that creating lib.a would be the easiest.
Best regards, Georg
Re: Payment terminal TIMAPI.DLL
Hello everyone
My next attempts
1)
I found a library of type a in the supplied SDK
\C\TimApi\Libraries\Unix\32bit-Static\libtimapi.a
I copied it to the HMG344\lib directory
I added the mentioned library to the IDE-configuration
for the test I call the function
msgbox(ta_terminal_get_tim_api_version())
it gives me an error message during compilation
undefined reference to `HB_FUN_TA_TERMINAL_GET_TIM_API_VERSION'
2)
I tried to create library type .a from DLL
I used utilities from MINIGW
gendef timapi.dll <-- generates timapi.def
dlltool.exe -d timapi.def -D timapi.dll -l libtimapi.a
but the created file has zero size
3)
the conversion using LIB2A ends when the DEF file is created
.\bin\reimp.exe: out of memory
Best regards, Georg
My next attempts
1)
I found a library of type a in the supplied SDK
\C\TimApi\Libraries\Unix\32bit-Static\libtimapi.a
I copied it to the HMG344\lib directory
I added the mentioned library to the IDE-configuration
Code: Select all
libs=timapi
msgbox(ta_terminal_get_tim_api_version())
it gives me an error message during compilation
undefined reference to `HB_FUN_TA_TERMINAL_GET_TIM_API_VERSION'
2)
I tried to create library type .a from DLL
I used utilities from MINIGW
gendef timapi.dll <-- generates timapi.def
dlltool.exe -d timapi.def -D timapi.dll -l libtimapi.a
but the created file has zero size
3)
the conversion using LIB2A ends when the DEF file is created
.\bin\reimp.exe: out of memory
Best regards, Georg
- AUGE_OHR
- Posts: 2093
- Joined: Sun Aug 25, 2019 3:12 pm
- DBs Used: DBF, PostgreSQL, MySQL, SQLite
- Location: Hamburg, Germany
Re: Payment terminal TIMAPI.DLL
hi,
it seems not to display help file
---
are those LIB for "C++" or "C"
you can´t use a UNIX LIB for Windows
where you got the Syntax of dlltool.exe

it seems not to display help file
---
are those LIB for "C++" or "C"

have fun
Jimmy
Jimmy
- danielmaximiliano
- Posts: 2625
- Joined: Fri Apr 09, 2010 4:53 pm
- Location: Argentina
- Contact:
Re: Payment terminal TIMAPI.DLL
hola, yo uso la sintaxis https://sourceware.org/binutils/docs/bi ... ltool.html
ver las funciones dentro del .dll https://www.alternate-tools.com/pages/c_dllanalyzer.php
Code: Select all
dlltool --dllname timapi.dll --def timapi.def --output-lib libtimapi.a
*´¨)
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
.·`. Harbour/HMG : It's magic !
(¸.·``··*
Saludos / Regards
DaNiElMaXiMiLiAnO
Whatsapp. := +54901169026142
Telegram Name := DaNiElMaXiMiLiAnO
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
.·`. Harbour/HMG : It's magic !
(¸.·``··*
Saludos / Regards
DaNiElMaXiMiLiAnO
Whatsapp. := +54901169026142
Telegram Name := DaNiElMaXiMiLiAnO
Re: Payment terminal TIMAPI.DLL
Hi daniel
I also tried your command syntax, I think they work the same way, but the "a" type library is not created
could someone try to create the given library if someone has another tool for that
Best regards, Georg
I also tried your command syntax, I think they work the same way, but the "a" type library is not created
could someone try to create the given library if someone has another tool for that
Best regards, Georg
- Attachments
-
- timapi32bit.zip
- (2.67 MiB) Downloaded 837 times