LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Teststand & LabWindows/CVI Datatypes mismatch

Hello,
I didn't know where I should post my problem but I decided to place it to the LabWindows/CVI forum. I have a problem using an ivi driver in Teststand with the Labwindows/CVI Adapter. When I'm compiling my ivi specific driver (or generating a class driver) the parameter datatypes are not correctly recognized by Teststand. When I load a module and select a function in the Testand Sequence Editor some datatypes are mismatched.

I have a High Level Function in my driver which looks like this one:

ViStatus _VI_FUNC Prefix_read_XXX (ViSession vi, uint8_t *result, uint8_t length, uint16_t errorCode)

the Datatypes are defined in a Headerfile (stdint.h, included in prefix.h):

#ifndef __STDINT_H
#define __STDINT_H

typedef char int8_t;
typedef unsigned char uint8_t;

typedef signed short int int16_t;
typedef unsigned short int uint16_t;

typedef signed long int int32_t;
typedef unsigned long int uint32_t;

#endif /* __STDINT_H */

Teststand always recognizes a long for ViSession (should be unsigned long) and a short for uint16_t (should be uint16_t = unsigned short). Sometimes, if i disable the type library, or use the __stdcall convention in the Build Options it works (sometimes I have also to enable the Default Base Library Name in the target settings options) ... the datatypes are correctly defined in the function panel (Options > Datatypes...).. I also tried to specify the "intrinsic datatypes" but this doesn't work... options > ivi&vxi plug&play style is enabled... does anyone have an idea?
0 Kudos
Message 1 of 3
(3,949 Views)
I used LabWindows/CVI 8.1 and everything worked fine until I updated to 8.5. The problem occurs now with both versions. I have also reinstalled the IVI Compliance Package to be able to use the IVI Library in LabWindows 8.5. There is also another problem with the session manager which I posted in another thread (here) some weeks ago. Could there be any relationships between this problems and the update?
0 Kudos
Message 2 of 3
(3,905 Views)

Hi 7even,

 

could you please add your teststand and CVI Programm, so we can have a look at it? If you do so, please minimize (cut) the code as much as possible.Just enough to rebuild the problem.

 

Thanks and Regards,

 

Matteo

 

 

0 Kudos
Message 3 of 3
(3,864 Views)