LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Interface dll function with struct in LabVIEW

Solved!
Go to solution

Thanks for the help.

 

I found another good example of using the CLN: http://zone.ni.com/devzone/cda/epd/p/id/3720 I didn't know that we could call these kernel functions directly.

 

In addition I have been playing with the dll import tool and that seems to be a good way of learning how to match prototypes. By creating different functions in a h file you can see how LabVIEW creates CLNs for different datatypes.

 

Also, it may have been mentioned but to get an array (if you know the max size of the array beforehand) into a struct, i.e. a string you can string to bytesarray->array to cluster but of course you'd have to set the size of the array to cluster beforehand.

In addition, if you need a typedef for such a cluster instead of manually adding hundreds of numeric constants you could probably use something like this vi to create a constant that you can embed into your typedef.

0 Kudos
Message 41 of 41
(964 Views)