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: 

python and labview

I need help in automation process.

where i will send serial configuration data from python like baud rate, parity, data bits, stop bits to the labview via tcp/ip so it automatically should the change the values in VISA configure serial port.
can someone help?? how i can store data in labview sent from python and process it to change the visa configurations.

0 Kudos
Message 1 of 6
(1,023 Views)

@Anup130901 wrote:

I need help in automation process.

where i will send serial configuration data from python like baud rate, parity, data bits, stop bits to the labview via tcp/ip so it automatically should the change the values in VISA configure serial port.
can someone help?? how i can store data in labview sent from python and process it to change the visa configurations.


No problem all those tasks are relatively easy. Have you written any code yet? 

______________________________________________________________
Have a pleasant day and be sure to learn Python for success and prosperity.
0 Kudos
Message 2 of 6
(986 Views)

i have written the python code, but im facing issues in labview code can someone tell hwo should i implement the labview code?

0 Kudos
Message 3 of 6
(948 Views)

text_file_labview_SS.pngtext_data_format.png

 

 

i tried and its working i have attached image also, but now i want to read data from the same file after writing data, but it is reading data first. and i want to split that data and automatically configure the "visa serial configure port" block.

0 Kudos
Message 4 of 6
(936 Views)

Hi Anup,

 


@Anup130901 wrote:

now i want to read data from the same file after writing data, but it is reading data first.

and i want to split that data and automatically configure the "visa serial configure port" block.


So you need to parse the received string!

There is a full palette of string functions you could use for your task…

 

What have you tried so far, where are you stuck?

Best regards,
GerdW


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

Here is a basic way using Spreadsheet String to Array since you have a comma-separated string.

NIquist_0-1734462708145.png

NIquist_1-1734462733120.png

There are many other ways to do this of course, but this should get you started... 

 

 

LabVIEW Pro Dev & Measurement Studio Pro (VS Pro) 2019
Message 6 of 6
(895 Views)