LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to get status of an rs232 connection

Hi,
 
I am trying to read out the status of on RS232 connection.
How can I do this?
 
Moreover would it be great to make the handshake visible! Is there a way that I can do that?
 
I would like to make a program something like where I can push a button "connect", get the status that i am connected and then make it possible to send some data....
 
I would really thank you if you can help me.
 
Sincerely Tim
0 Kudos
Message 1 of 7
(4,336 Views)

You can check the status using hyperterminal,If you are not sure of whther port is not properly configured.

 

While handshaking you can compare the incoing data with what you expect (Like a hexa decimal character).You can use an LED as status indicator.

0 Kudos
Message 2 of 7
(4,328 Views)
Providing you know the settings to communicate with your RS232 device you can use VISA to easily communicate via RS232. The handshaking can be monitored by echoing the strings sent and received to the device to a string indicator.

You can find examples under Help-> Find examples, and search for 'serial read write'
_____________________________
- Cheers, Ed
Message 3 of 7
(4,316 Views)
I meant something like this
0 Kudos
Message 4 of 7
(4,307 Views)

Those said are right.

I just want to add that (i think) there is no direct way to read the status of your connection.

If your Port is not free, you will receive an error if you try to initialize it, or send data.

Message 5 of 7
(4,285 Views)

I just want to add that (i think) there is no direct way to read the status of your connection.


I think so too
0 Kudos
Message 6 of 7
(4,279 Views)
The more fundamental problem is that except for an indication of whether or not it has been initialized and perhaps the number of bytes in the port buffer, a serial port doesn't have any sort of real status. RS232 communications simply isn't that sophisticated. For what it's worth, unless the device you are working with is very old, monitoring the handshake lines probibly won't tell you anything because most modern serial device don't use any handshaking.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
Message 7 of 7
(4,251 Views)