LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

RS232 and LabView

Hi, I understand that RS232 is called also GPIB.

All common instrumentations use protocoll RS232 and many times the instrumentations is connected to pc with USB port: that is a serial port is connected to cable that have a usb terminal to connect to pc.

Now I have studied a RS232 protocol, I have understand how the instruments communicate each other with RS232 protocol.

 

1) When I Use LabVIEW to control instruments... I stay at level od RS232 Protocol or at higher Level?

To Explain myself: When I use Icon in Labview, for example from VISA I use an Higher "Protocol", an Higher mode to communication?

 

2) And I find on Manual a command to control device.There are 2 types of controll: 1) Remote Control via IEC Bus and 2) Remote Control via RS-232-Interface. Now there is a "List of Commands (with SCPI Conformity Information)", but where I must write this command to communicate with my device? For example: "SOURce:FREQuency:CW 1E3 = SOURce:FREQuency:FIXed 1E3". Where I must Write it? In MAX there is Interactive Control, maybe I can use it?

 

3) The device has a RS232 serial port with 9 pin for example. If I buy a cable with a serial port at side and usb port at other side... I must think that there is the same protocol to communicate? The change of port from 9 pin to usb is only a facilities? Or this induce modification in the controll device?

 

Can U respond associating your answers to number of my questions?

Thanks,
Vanny

)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(-_-)(

Sweet, Beautiful and Young Female Physicist (SBYFP)
(I speak a not very good english, so If U are Italian LabVIEW expert speak in Italian, if U speak in Eglish... please speak easy;) )
My e-mail for personal contact: vanessaricciardi@live.it_NO_SPAM_PLEASE
0 Kudos
Message 1 of 4
(4,609 Views)

Hi, I understand that RS232 is called also GPIB. NO, RS232 is a serial protocol, GPIB is parallel => They are often associated because you can communicate both with NI-VISA, a higher layer of driver. For information, GPIB is easier to drive because you need less information to configure (address is often sufficient). With serial you need more charateristics as BaudRate, number of data bit, etc... But GPIB is often more expensive and have a specific physical link. Serial is most usefull because the wire is more easy to do...

All common instrumentations use protocoll RS232 and many times the instrumentations is connected to pc with USB port: that is a serial port is connected to cable that have a usb terminal to connect to pc.

Now I have studied a RS232 protocol, I have understand how the instruments communicate each other with RS232 protocol.

 

1) When I Use LabVIEW to control instruments... I stay at level od RS232 Protocol or at higher Level?

To Explain myself: When I use Icon in Labview, for example from VISA I use an Higher "Protocol", an Higher mode to communication?

Best way is to use NI-VISA (higher level)

 

2) And I find on Manual a command to control device.There are 2 types of controll: 1) Remote Control via IEC Bus and 2) Remote Control via RS-232-Interface. Now there is a "List of Commands (with SCPI Conformity Information)", but where I must write this command to communicate with my device? For example: "SOURce:FREQuency:CW 1E3 = SOURce:FREQuency:FIXed 1E3". Where I must Write it? In MAX there is Interactive Control, maybe I can use it?

The encapsulation of NI-VISA makes that the most part of time, you don't need to know the basics of communication to use it. At first, you could use the VI Express 'Assistant i/o instruments' to implement communication and follow the main method after 'Open Front panel' to see how it's coded. 

 

3) The device has a RS232 serial port with 9 pin for example. If I buy a cable with a serial port at side and usb port at other side... I must think that there is the same protocol to communicate? The change of port from 9 pin to usb is only a facilities? Or this induce modification in the controll device?

Yes, same protocol. NI-VISA is great!!!

Message 2 of 4
(4,599 Views)

3) When you use a USB to RS232 adapter, the signals are really transformed. The usb port is only used to pass the data.

You install the "new" rs232 com port into Visa, plug it in and it works like a normal rs232 port.

 

Forget everything about usb. New situation: one side the rs232 9-pin connector, other side your blocks in LabView.

 

Problem: Not all the rs232 terminals are 100% compatible with the rs232 standard.

Also not all rs232-usb converters are full 100% compatible with that standard.

 

So it is possible that your device don't work on a rs232 port (through usb) and it works well on a native rs232 port.

Voltage levels and offset are the main cause here.

 

 

 

Message Edited by ST5 on 01-15-2010 04:56 AM
Message 3 of 4
(4,596 Views)

Sure ST5, I was a little short ;).

0 Kudos
Message 4 of 4
(4,586 Views)