Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Serial communication differences between rs-232 and rs-485

I'm trying to modify a VI that -- one that was not originally created by me -- to communicate with an instrument (specifically, a Eurotherm 2416 controller) via a serial connection.  The trouble is, the original connection to the device was successfully made via the RS-485 standard, and I'm using RS-232 instead.  I've taken a look at the VI and it's sub-VIs and it seems to use the standard "Bytes At Serial Port" and "Serial Port Read" VIs to communicate to serial devices.  I don't see any way to change the type of connection from RS-232 to RS-485 anywhere, though, and the VI doesn't seem to work correctly -- it just gives me an error of "no data found at serial port".

 

How do these sub-VIs know whether to communicate via RS-232 or RS-485, or is this a user-definable setting?  If so, where is it?

 

Thanks for any help in advance. 

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

main differences (may not be totaly wrong 😉 :

physical way of communication: GND ref. voltage (232) to diffential (current?) loops (so the connector might look equal, but the pinout and signals are not)

point to point vs bus (so for the 485 a more complex messaging is needed,  adresses , checksums)

 

look for a KB article , I'm shure there are some on the ni sites or at wikipedia

 

 

 

 

 

 

 

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


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

Hi,

 

The difference is the physical interface. Seen from SW it makes no difference if the link is 232, 485, 123 or whatever.

 

485 is a differential voltage interface with no direct ground reference between nodes. But is must be within a range specified by the interface circuit.

With 485 you can connect more then 1 node directly (with 232 you can do this indirectly) When you want to address more then 1 node then you need the a more complex protocol like ModBus (but there are many more)

 

So you can use a 485 point-to-point connection just like you use a 232 connection with no change needed in SW

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

Could you please share the rs485 vi with me?

0 Kudos
Message 4 of 5
(2,686 Views)

Hi,

 

You are answering to an eight year old post.

A serial VI communicates with a COM port. Whether the data is transported over RS-232, RS-485, plumbing, smoke signals, ec. does not change the VI.

So asking for a RS-485 VI ......

 

Kees

0 Kudos
Message 5 of 5
(2,684 Views)