LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

ASCII mode using VISA

hai...
Is anyone know how to read data for ASCII mode using VISA?
 
Thanks 
0 Kudos
Message 1 of 13
(3,791 Views)
Hai..
Is anyone know how to read data for ASCII serial parameter mode using VISA?
0 Kudos
Message 2 of 13
(3,790 Views)
Hi gdah,

the standard VISA read results in an ASCII string... So what exactly is your problem?
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 3 of 13
(3,778 Views)
Hi GerdW,
I used Labview 8.2.I want to read data from device using serial connection. My serial setting are mode=ASCII, flow control=none, Baud rate=19200, parity=even. The problem is I can't reveice any query frame from the com port using VISA. Can I change the mode serial setting from RTU to ASCII using the VISA configure serial port??Or you have any idea to solve my problem??Currently I try to use modbus library.But unfortunately I still can't reveice the query frame
 
Thanks  
0 Kudos
Message 4 of 13
(3,764 Views)
Hi gdah,

when I set up a VISA serial communication I don't have any "mode=ASCII" setting... I also don't have any "RTU" setting. Where do you find this?

That's my (standard) VISA Serial Config.vi:



Message Edited by GerdW on 02-15-2008 04:17 PM
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 13
(3,753 Views)

Hi GerdW,

Yes, you are correct. There is no setting to change serial mode when using VISA.That why I'm asking you either I can change the mode setup or not. Because I also not sure either I can change the serial mode. I ask you if there any option so that I can change the serial mode. But in the modbus library there is the function of serial mode setup.The problem is I can't receive the query frame and I have no idea what wrong with my program..Do you have any suggestion for me??

Thanks

0 Kudos
Message 6 of 13
(3,741 Views)
Hi gdah,

in VISA serial there is no "mode" - so you can't change it...

Could you attach your program (important vi, stripped down to show the relevant part)? Then we may decide what's "wrong"!
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 13
(3,737 Views)
ASCII and RTU are different protocols used by Modbus. They do not have anything to do with the VISA itself.
First make sure your settings are correct. (same for both sides)
You can use windows hyperterminal , as a first step to see if you receiveing any bytes.
Then you can use Labview VISA  ,simply read the COM, to make sure you receive bytes.
Then try to use Modbus vis
0 Kudos
Message 8 of 13
(3,734 Views)

To the serial port, it is all just ones and zeroes transmitted as bytes. It is up to the labview program to convert the bytes into ASCII or RTU format.

Download portmon from the web and use it to watch the data being transmitted out the serial port. You can also watch the received data.

 http://www.microsoft.com/technet/sysinternals/processesandthreads/portmon.mspx

Try the llb file that I put in this thread. It originally used RTU mode, but you should be able to change it to ASCII. It just transmits more bytes in ASCII mode.


Message Edited by unclebump on 02-15-2008 09:55 AM
0 Kudos
Message 9 of 13
(3,732 Views)
Hi unclebump
 
I have try your program of modbus library. But the result is same.I can't receive any quey frame from the port. I didn't do any changes in the modbus library. Please help me..
 
Thanks
Download All
0 Kudos
Message 10 of 13
(3,706 Views)