Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Need to control a serial device with LabView using a GPIB-RS232CT converter

Solved!
Go to solution

Thank you all for taking the time to answer this question.

I am trying to control an Omega CNi32 series temperature controller with Rs232 serial communication enabled using Labview 2009SP1 through a GPIB-RS232CT NI converter

The connection is as follows:

1. From the PC to GPIB-RS232CT NI converter using a USB to GPIB cable

2.  From GPIB-RS232CT NI converter to temperature controller using a DB9 cable

 

I can successfully control the temperature controller directly from the PC using a serial connection through the DB9 cable, but I need to use the GPIB-RS232 converter module for my application.

GPIB-RS232CT NI converter configuration: G mode with the address set, I can detect the GPIB address but couldn't communicate with the serial device.

 

The temperature controller is programmed to continuously transmit data and I tried using Visa Read and GPIB Read to get the bytes from the device, but no success.

 

I have attached the Omega temperature controller and GPIB-RS232CT NI converter manual for reference

 

 

Download All
0 Kudos
Message 1 of 6
(1,831 Views)

@Hariram96 wrote:

The connection is as follows:

1. From the PC to GPIB-RS232CT NI converter using a USB to GPIB cable

2.  From GPIB-RS232CT NI converter to temperature controller using a DB9 cable


Why?  Just use a USB-RS232 adapter.  Removing parts often simplifies the issues.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 6
(1,815 Views)

@crossrulz wrote:


Why?  Just use a USB-RS232 adapter.  Removing parts often simplifies the issues.



You are right. However, my application demands the use of the serial to GPIB converter.

Info about my specific use case: 

I am building a setup with multiple instruments that communicate with a PC using GPIB

The design is to use a single USB port in the PC and connect all the Instruments through GPIB to GPIB cables and one GPIB to USB cable to the PC.

I do understand I can use Mutilport UBS extenders to solve my issue. but I cannot use it for my design. I have to convert the serial device into a GPIB

0 Kudos
Message 3 of 6
(1,809 Views)
Solution
Accepted by topic author Hariram96

I got it to work.

  • I tried to communicate with the instrument(the 2nd address indicating the serial device) using Ni max initially but was getting a timeout error message on the read command.
  • The reason for the time-out error was due to the byte length I was trying to read
  • By default it reads 1028 bytes which were not available and hence the time-out error
  • Once I changed the byte size to the desired length I was able to communicate with the instrument without any issue 
  • Finally, I used the Visa read-write function to create a Labview Vi
0 Kudos
Message 4 of 6
(1,726 Views)

@Hariram96 wrote:

I got it to work.

  • I tried to communicate with the instrument(the 2nd address indicating the serial device) using Ni max initially but was getting a timeout error message on the read command.
  • The reason for the time-out error was due to the byte length I was trying to read
  • By default it reads 1028 bytes which were not available and hence the time-out error
  • Once I changed the byte size to the desired length I was able to communicate with the instrument without any issue 
  • Finally, I used the Visa read-write function to create a Labview Vi

Depending on the temperature chamber, you likely just needed to enable the Termination Character and then VISA Read would stop reading when it is read.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 5 of 6
(1,716 Views)

@crossrulz wrote:

Depending on the temperature chamber, you likely just needed to enable the Termination Character and then VISA Read would stop reading when it is read.


That makes sense, Now I understand. Thanks

0 Kudos
Message 6 of 6
(1,710 Views)