Motion Control and Motor Drives

cancel
Showing results for 
Search instead for 
Did you mean: 

how to read data over tcp/ip using labview

Hi,

 

I have a network enabled force transducer (6-axis load cell). I know its IP addr. and the data format it is sending the data out (7 32-bit DWORD, One status and 6 axis force data) . I have been playing around with the simple data client.vi example program. 

 

When I executed the program using the devices IP addr. I used to get error 63: TCP/IP connection open. Then I ran the program using localhost in IP addr field, the program executes now indefinetly at one block only. I am attaching the screenshot for ref. 

 

Thanks.


Sasi.

0 Kudos
Message 1 of 6
(5,806 Views)

Hello,

 

Using localhost refers back to your computer and thus you would not be reading from your transducer. Specifying the network IP address of the transducer is the correct method. Have you made sure that the port you are communicating on is open in your firewall?

 

-Zach

0 Kudos
Message 2 of 6
(5,791 Views)

Yes, the firewall is disabled and I have also added the device's IP addr. in VI: Server options. Still no use. Where do you think I am going wrong?

 

Sasi.

0 Kudos
Message 3 of 6
(5,788 Views)

Hello,

 

Have you been able to verify that you can receive data from the transducer on the computer without using LabVIEW? Does it have any software that came with it that you can test? The next thing would be to verify that you can use the TCP/IP Server and Client examples between two different computers on your network.

 

-Zach

0 Kudos
Message 4 of 6
(5,786 Views)

Thanks for the prompt reply Zach.

 

Yeah, the NetFT does come with a JAVA applet through which I am able to read the data from the sensor and save to a file as well. 

 

I did not try though to communicate between 2 PC's, shall do that and let you know. 

 

What I feel is that the data being sent from sensor is 7 DWORDS of 32-bit. Do you feel that the problem might lie here. 

 

Also I kind of called up NI and asked the support guys if they have any module for NetFT. NI had one for DAQFT. If that be the case then it would really ease the job.

 

Thanks.

 

Sasi.

0 Kudos
Message 5 of 6
(5,783 Views)

Hello,

 

I'm wondering if you can create a rather simple VI that just tries to open and close a TCP connecting to your transducer. All you would need is a TCP Open and a TCP Close wired together with the proper IP address etc. Does this run? I did look to see if there was any NetFT information and I could not find anything. I feel that the problem lies in the communication protocol between your transducer. Another place to see if you can connect to it would be to try hyperterminal. You can access this in Windows XP by clicking Start»All Programs»Accessories»Communications»HypeTermina. Using this, you can try and connect to your instrument with TCP/IP outside of LabVIEW. You might also want to get in contact with the manufacturer to verify that third-party software can indeed communicate with it. There may be a specific set of instructions that need to be sent to the transducer in order to initiate the connection and then read from it. These may be in the form of serial commands that would need to be sent over TCP. What is the make and model of your transducer?

 

-Zach

0 Kudos
Message 6 of 6
(5,773 Views)