Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I gather info from a serial port that sending multi-channel data?

I'm trying to get information from a serial port (COM1).  I keep getting an error message, but it says that I have the correct VISA address.  On top of that, I'm trying to get data from it but it's coming from a controller that sending out 5 channels of information (0-4). I have the latest Labview software, which is different from later versions.  This version has functions to intialize a VISA and an array.  Do you have to initialize them before you start using them because this wasn't the case on earlier versions of Labview? How do I set the VISA up correctly? How can I put this data into an array after getting the data?  Examples would be helpful.  Thanks.
0 Kudos
Message 1 of 5
(3,285 Views)
JBandon,

your Qs are rather basic ones. I suggest you study the examples that are installed together with LabVIEW. Go to /Help/search_examples!
For the serial initialisation I found the 'Basic Serial Write and Read.vi' This should enable you to setup the transmission part of your Q.
To decode the data coming from the external controller you need info about the transfer protocol the controller is using.  Otherwise it might be hard to get the required data. There are soo many possibilities to transfer multiport data, either as plain data or compressed or the channels being interleaved or not. Than one can send binary data or ASCII or BCD or whatever. Experienced users might have a chnace to decipher simpler transfer protocols, but ...
You might refine your Q with the transfer protocol info to get more specific hints!
Greetings from Germany!<br>-- <br>Uwe
0 Kudos
Message 2 of 5
(3,277 Views)
It's a straight thru serial cable (no pins swapped).  No parity, baud rate = 9600, stop bit = 1.  I've tried looking at the examples, I went through the full tutorial guide and they aren't helping me.  I keep getting an error at the VISA read.  Any and all help is appreciated.
0 Kudos
Message 3 of 5
(3,264 Views)
What error do you get? error code?

0 Kudos
Message 4 of 5
(3,250 Views)
Hi JBadon,
Make sure your serial port is not tied up by another process. Can you communicate with the instrument through hyperterminal? Like Lul said, please post the exact error you receive. It'll be a lot easier to figure out what's going on.
Thanks.
Ebele O.
National Instruments
0 Kudos
Message 5 of 5
(3,238 Views)