LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Reading garbage on serial port

Hello,

Could someone please tell me why i get this garbage on serial port: *198#?!
I should get only the following as response: *0#DL7ZN

When i use RealTerm to communicate through serial port i get no garbage like *198#?!

Kind Regards,
serial.jpgBalázs

0 Kudos
Message 1 of 5
(3,116 Views)
  1. One or more of your serial parameters is incorrect (bits, baud, parity, stop bit, flow control, etc)
  2. You are expecting ASCII data but are receiving binary data
  3. You are using "Bytes at Port" and that rarely works 
========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 2 of 5
(3,108 Views)

@RTSLVU wrote:
  1. One or more of your serial parameters is incorrect (bits, baud, parity, stop bit, flow control, etc)
  2. You are expecting ASCII data but are receiving binary data
  3. You are using "Bytes at Port" and that rarely works 

I vote for #2 with a sprinkling of #3 for good measure.  😉

 

To the OP:
I believe that the second line is NOT garbage, but is, in fact, some additional information that is being sent.  I would make sure what you are SENDING is the same thing as you are sending "manually".

 

Did you check the programmer's guide to see if that is a valid response?

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 3 of 5
(3,093 Views)

I also forgot, the data itself may need post processing. That is the device may be sending data in "Two's Complement" or some other form that is not "human readable" unless you decode it.

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 4 of 5
(3,076 Views)

Instead of using RealTerm to communicate with your device, use MAX.  You can open a Test Panel for the VISA Port you are using, configure the Interface (so you know what settings you are using), and you can write to and read from the buffers, seeing just what comes back.  It seems curious to me that the picture you show seems to show a response to a Command sending back a two-line response, the second line of which is the "garbage" response in your Title -- was the first line meaningful?

 

Let us know what you learn using MAX.  Do you know how to avoid "Bytes at Port"?  [It depends on whether your device uses a Termination Character, typically <LF> = 0xA].

 

Bob Schor

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