LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview & VISA two com write & read

Solved!
Go to solution

how to chang baund rate ?

How to write com port output
My program cannot be exported now, the problem should be the content of the program
But i don't know where the problem is

g0910353_0-1586330411505.png

 

0 Kudos
Message 1 of 4
(2,383 Views)

Hi g,

 


@g0910353 wrote:

how to chang baund rate ?

How to write com port output
My program cannot be exported now, the problem should be the content of the program
But i don't know where the problem is


To change the baudrate(s) you just have to edit those numeric constants at the left…

You already know how to use VISAWrite…

Why can't you "export" your program? Aren't you able to save the VI and attach it to your message?

Why is "the content of the program" a problem?

Which problem do you encounter? Why don't you know "where the problem is"?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 4
(2,381 Views)

I have two machines A machine is 38400 read A output
I want to change 38400 to 19200 for B to read
So it should be handled by different com ports?

0 Kudos
Message 3 of 4
(2,370 Views)
Solution
Accepted by topic author g0910353

Hi g,

 

change the "38400" constant into a control.

Now you can set the correct baudrate when you run the VI on a different computer!

 

When you want to automate thise setting: implement a configuration file handling in your (main) VI!

Read the configuration file, parse the correct baudrate from it's content and call the shown routine with the correct baudrate setting.

LabVIEW comes with a huge library of example VIs, there should be an example on how to use configuration files…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 4
(2,361 Views)