PXI

cancel
Showing results for 
Search instead for 
Did you mean: 

Help: cross over cable TCP trouble

Hello,
 
I am using a PXI 1002 chasis with a PXI-8176 controller, and PXI 6052E acquisition board. I'm using the last release of LabView 7.1 (available Aug 2005) before version 8.
 
I am running an experiment where the WindowsXP computer requests a real-time acquisition from the PXI, which performs the acquisition, and then returns the data. In this set-up, the PXI is first listening for a TCP connection from Windows, and then Windows listens for a TCP connection from the PXI.
 
I am having some bizarre trouble with my TCP connection between the PXI and Windows computer. When both are connected to each other through standard network cables to a switch, which is itself connected to the broader network, the program works flawlessly. <b>Once it has done at least one trial, I can disconnect the broader network and everything continues to work fine.</b>
 
If however, I start the whole process without a connection to the broader network, or if I use a cross over cable to directly connect Windows and the PXI, a problem occurs. The Windows to PXI transaction works fine, but then the PXI to Windows transaction times out. The PXI's "TCP Open Connection" works fine, but the "TCP Send Receive" times out with error code 56.
 
This is suddenly an issue for me because I need to take the whole set-up on the road, and therefore need to use a cross over cable to directly control the PXI from my notebook. The NI Measurement & Automation Explorer is able to talk with the PXI in either case, so the cabling itself is not the problem. I've read previous posts about slow access times using a cross over cable, but my problem is slightly more general as evidenced by the weird "need to connect to the Net once through the network switch" behavior.
 
I've attached stripped down VIs of the TCP code on my Windows and PXI machines.
I would be very grateful for any help!
 
Thanks in advance, and Best Regards,
Frenk
Download All
0 Kudos
Message 1 of 5
(3,469 Views)
> If however, I start the whole process without a connection to the broader
> network, or if I use a cross over cable to directly connect Windows and
> the PXI, a problem occurs. The Windows to PXI transaction works fine, but
> then the PXI to Windows transaction times out. The PXI's "TCP Open
> Connection" works fine, but the "TCP Send Receive" times out with error
> code 56.

I recommend trying leaving the TCP connection from the notebook to the PXI
open and use that to send back the data. You might also try using private
IP addresses when not connected to the network. These are in the ranges:

10.0.0.0 - 10.255.255.255
172.16.0.0 - 172.31.255.255
192.168.0.0 - 192.168.255.255

See here for more info: http://duxcw.com/faq/network/privip.htm I use the
last range without any problems.


0 Kudos
Message 2 of 5
(3,459 Views)
Hello,
 
Thank you for your response.
 
I haven't left the TCP connection open because the real-time data acquisition can be several seconds. Conceptually I had thought it was "wrong" to leave it open that long without using it. Do you see any problems leaving it idle while the time-critical acquisition takes place?
 
I have used the 192.168.#.# range, and unfortunately the problem persisted.
 
Thanks again,
Frenk
0 Kudos
Message 3 of 5
(3,455 Views)
> Conceptually I had&nbsp;thought it was "wrong" to leave it open that long
> without using it.

There is no problem with leaving the connection open. I leave connections
open for months. These connections are self healing in that if they detect
an error they close and reconnect. The listener side has to send a message
back every so often so the server knows the client is still alive. Not that
you need that level of complexity for your task.

Conceptually, it is probably actually worse to continuously open and close
connections. You leave yourself open to any memory leak bugs and require
the system to continuously setup and destroy the connection.



0 Kudos
Message 4 of 5
(3,452 Views)

Ok Thanks. I'll try leaving it open.

Best Regards,

Frenk

0 Kudos
Message 5 of 5
(3,438 Views)