LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

plotting a realtime graph in labview

I have taken data from arduino mega ADK board to LabVIEW and I am able read it.But if I donot include delay I get timeout error in READ (VISA) and I need the data to be read as a single array one after the other.And please help me to plot the data in realtime.

Download All
0 Kudos
Message 1 of 3
(1,996 Views)

Hi saik,

 

why do you need 2 case structures depending on the very same button? Why not use just one case structure?

Why do you need to close the very same COM port 3 times even when you open that port only once?

Why is there an unlabelled control?

Why do you need to output a string containing "0" in case you don't want to read the COM port? Why do you need to clear that "0" later on???

How do you handle the TermChar you enabled with your ConfigureSerialPort function call? Do you know what it means to enable that TermChar???

Are you sure you need to read exactly 9 bytes from the port?

Do you really need to wait nearly 10s for an answer from your device? (You don't need to wait at all when you use a TermChar!)

Why do you print a "0" in your Arduino code as a line termination? Why not get rid of that last "Serial.println(0)" and use "Serial.println(analoguev)" before?

Why don't you attach your Arduino code as simple text file?

After reading this code I would increase the 9 to 99 as "bytes to read"…

 

check.png

Why don't you cleanup your VI to something like this?

Best regards,
GerdW


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

thank you for the reply.

0 Kudos
Message 3 of 3
(1,983 Views)