LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

i need to create a cvi dll that will read/write tcp and return struct to labview

i am trying to write a dll using labwindows that allow me to create a TCP connection, write a command, read a structure back then be able to return the structure so that it can be used in labview.
my C coding is limited and i have never written a dll.
how do i set up the dll so that i can return a structure?
0 Kudos
Message 1 of 2
(3,031 Views)

Hello

The simplest thing to do would be to pass the parameters individually into LV from the dll. 

The reason why I am recommending this is because this is the easiest way to do it. To be able to pass clusters, you would have to use the LabVIEW memory manager functions what would allocate the memory from the struct so that labview can handle it.

For more information about how the memory manager functions work, check out the Using External Code in LabVIEW

I hope this helps.

Bilal Durrani
NI

Bilal Durrani
NI
0 Kudos
Message 2 of 2
(3,031 Views)