LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Control a network device on a comopactRIO using PyVISA?

The PyVISA library supports TCP/IP connections see:

 

TCPIP INSTR TCPIP[board]::host address[::LAN device name][::INSTR]
TCPIP SOCKET TCPIP[board]::host address:: port:: SOCKET

 

If I am able to establish a TCP/IP connection between Python and the cRIO would I be able to use PyVISA on my network device? My network device is a VISA TCP/IP resource on the cRIO (I think). It shows up under network devices in NI-Max and it has a 5 different labels

  1. Product
  2. Name
  3. Hostname
  4. IP Addresss (this is the same as the cRIO's)
  5. Serial Number

Has anyone ever tried to use this library like this or knows if its even possible?

0 Kudos
Message 1 of 5
(3,248 Views)

There is this whitepaper that shows different uses of Python and LabVIEW that I have found helpful, but it doesn't say anything about if the PyVISA library can be used with a cRIO or not

0 Kudos
Message 2 of 5
(3,172 Views)

Smurf,

What do you mean by "establish a TCP/IP connection between Python and the cRIO"? What hardware are you trying to communicate with? The cRIO is itself a network device, are you saying you have a separate network device and it has the same IP address as the cRIO?

Regards,

TyVo

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

I have an Ethernet camera attached to my cRIO that takes visa commands, it shows up in NI-Max as a network device on my remote system (cRIO)

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

I personally am not familiar with the PyVISA library. You should be able to use the LabVIEW VISA API to control the camera from the cRIO.

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