Calling convention of the functions in Labview.dll
Posted: Fri Jan 11, 2008 5:40 pm
Hi!
I am writing an interface in C to get directly the data from the ActiveTwo system. I can load the dll, load the function addresses and I am able to initialize the system (I can get the green LED). I haven't try to call READ_POINTER function yet.
However:
-the return value of READ_MULTIPLE_SWEEPS is always 0 (I have used a ring buffer of 32*1024*1024 bytes)
-If I call READ_MULTIPLE_SWEEPS function, I have a problem when I call CLOSE_DRIVER_ASYNC (Windows tell me that it encounters a problem). If I don't call READ_MULTIPLE_SWEEPS, I don't have any problem when I call CLOSE_DRIVER_ASYNC.
I suspect that this problem is because I don't use the correct calling convention when I call the functions of the DLL (I use the C calling convention (__cdecl)). That is why I would like to know which calling convention we should use.
If you think that my problem is caused by something else, please give me your suggestions...
Thanks
Nicolas BOURDAUD
I am writing an interface in C to get directly the data from the ActiveTwo system. I can load the dll, load the function addresses and I am able to initialize the system (I can get the green LED). I haven't try to call READ_POINTER function yet.
However:
-the return value of READ_MULTIPLE_SWEEPS is always 0 (I have used a ring buffer of 32*1024*1024 bytes)
-If I call READ_MULTIPLE_SWEEPS function, I have a problem when I call CLOSE_DRIVER_ASYNC (Windows tell me that it encounters a problem). If I don't call READ_MULTIPLE_SWEEPS, I don't have any problem when I call CLOSE_DRIVER_ASYNC.
I suspect that this problem is because I don't use the correct calling convention when I call the functions of the DLL (I use the C calling convention (__cdecl)). That is why I would like to know which calling convention we should use.
If you think that my problem is caused by something else, please give me your suggestions...
Thanks
Nicolas BOURDAUD