11-27-2012 11:08 AM
Why are you confused? If you are trying to detect that an instrument is not connected, you are supposed to get an error. You will also get an error if the instrument does not support the *IDN? command that you are sending. Are you sure it's supported? Is it listed in its manual or are you just making something up to send?
11-27-2012 11:28 AM
Thank you for reply ...
That I have to check;i though *IDN? is commen command...
but any ways i will check it tomorrow and will let you know.
Thanks again...
11-27-2012 10:38 PM
The "*IDN?" query is "common" only for devices that conform to the IEEE488 standard.
Do you have a programmer's reference manual for the Light Guard Basic device? If not, I would call the vendor and ask for one. My point is that you need to find a query that you can send that will return some known response from the device. No response and you can assume (with some risk) that the device is not connected. I myself assume that this is what you are basically trying to do.
11-28-2012 05:19 AM
Hi,
I have checked manual I didn't find any command regarding to communication with device with PC and will you please let me know if my device is not standardize by IEEE488 then what I have to do in order to communicate.
Thank you very much.
11-28-2012 07:41 AM
12-03-2012 01:16 AM
Hello,
I asked to my professor who have design this device and he told me that we don't have such *IDN? Or any other types command for communicate with device,that's why we are dealing with Modbus library and in our Light guard software we have to set all com port ,baud rate ,data bits etc in order to communicate with RS232 cable,if suppose we don't have given correct configuration then its seem error in that software so my professor told me that it might be same functionality having in Labview when device is not IEEE488 standardize.
Will you please guide me in such case how to design the Vi for RS232 cable detection...
Thank you very much.
12-03-2012 01:45 AM
The device being IEEE488 compliant or not makes no difference in the actual sending/receiving of data over RS232. Normally, you will send a valid "command" to the device, and it will respond, if applicable, with some data. I don't know how your device operates, but if you don't get a response after sending a command, or you are reading and not getting data when you expect it, you can assume the communication link is broken (for one of many different reasons). It seems very simple to turn on an LED in that case.
12-03-2012 02:02 AM
Thank for reply,
Even I Tryed with by changing the cable also but its give same result.
I am using Modbus in order to communicate with my device.
12-03-2012 02:26 AM
Yes and it sounds like Modbus RTU over RS232. However, I do not see any way to get status from the serial port through LabVIEW (for example, DTR). So if the cable is not connected, there is no way for you to tell except to try and send a request to a slave device and declare a communication problem if no response is received.
12-03-2012 02:50 AM
Thank for reply...
It means there is no any way to measure the connectivity test of RS232 in Labview when we are dealing with Modbus.??
Because we have developed the software Regarding to testing the light guard device in which we can measure and set the data of GSM, GPS, Ambient light sensor etc....which are impliment in Light guard device ,that we can measure through that software and in that software there is one connect option in order to connect with device and for connection we are using RS232 and RS485 cable.