ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

serial monitor

I don't sure about baud rate and everything for gcviewer.exe.....How can i check?
Is it possible to check Baud rate, data bits, parity, stop bits, flow control from device?
I put    Baud rate 9600
           Data bits 8
           Parity None
           Stop bits 1
           Flow control None
Please give me some advise...
Thanks!
0 Kudos
Message 1 of 9
(3,817 Views)

Hi Melikyan,

you can set it at start up of your vi. Can you upload your vi??

Please reply to this post, and don´t start everytime a new one. Smiley Happy

Use the "reply button"

 

Mike

0 Kudos
Message 2 of 9
(3,816 Views)
Hi Melikyan,
for more information see the provided example. "basic serial read and write" or "advanced serial read and write"
 
Mike
0 Kudos
Message 3 of 9
(3,810 Views)
Dear Mike. I attached the Vi. I use Labview 8.0.
Thanks for your kindly attention.
0 Kudos
Message 4 of 9
(3,801 Views)

Hi Melikyan,

it looks good. What error did you get? Could it be that you have to send "CRLF" at the end of your string? I don´t know what your device expected.

Mike



Message Edited by MikeS81 on 04-19-2008 11:01 AM
0 Kudos
Message 5 of 9
(3,791 Views)

Dear Mike actually the exe work like this....First time i Push "connect", second time "Load current"...and after that i get the data...

But Labview i use only 1 time Run button....

I attached 2 xls docs. I run by .exe and labview....and here i saved by serial monitor...Data is very big...But if for u not difficult could you show my mistake?

Thanks...

Best regards

Harut!

Download All
0 Kudos
Message 6 of 9
(3,787 Views)

Hi Melikyan,

where are your problems now? Does the communication work now? If you send a command from LabView to your device (only one at the moment), do you get the expected response?

Mike



Message Edited by MikeS81 on 04-19-2008 11:14 AM
0 Kudos
Message 7 of 9
(3,782 Views)

The problem is i can't read any bytes....Byte count equal 0.

And now i can't check where come from the problem...

I used serial monitor program to check whole process.....Labview command request, but can't read...

I try compare commands from serial, if you can see the xls files Row 42 the write commands go to device different, i compare 2 files...Main part are same, but some parts are different....And everytime i push run, everytime codes changed.....Main hexacodes are fixed, everytime fixed and stable...But some are not fixed and after every run changes.....What is the problem?

Do you have any idea?

0 Kudos
Message 8 of 9
(3,774 Views)
Howdy Melikyan,

Your LabVIEW code looks fine. If the instrument doesn't respond as you expect, one (or more) things could be the culprit:
  • Improperly terminating the command string sent to the instrument (most-likely case)
  • Sending an invalid command to the instrument
  • Improperly configuring the port settings for the instrument
Regarding the first possibility - at the end of each command you send to the instrument, you must verify that you have the proper termination character. Typically a \n will do the trick. Other termination characters include \r, \r\n, and \f. I'd be willing to bet that adding a termination character to the end of your command will get a valid response from the instrument.

If the instrument doesn't reply after adding a termination character, you might want to consult its manual for a simple command that you can send to test communication. For example, some instruments will have a reset command that you can send that will cycle the instrument's lights just to kind of verify that communication to the instrument works properly.

I hope this helps!

Warm regards,

pBerg
0 Kudos
Message 9 of 9
(3,714 Views)