07-05-2019 08:36 AM
Hi all,
I'm grabbing ECG data from an NI 6009 USB device and plotting it on a waveform chart.
In the attached VI below, once DAQ acquisition starts it updates the waveform chart in each loop. I want the chart to scroll time markers from right to left on each iteration, which it does to some extent. I'm not sure if there's an easier/better way to implement this (i'm sure there will be).
1) Is there a way to turn off the markers at the very far right and left of the chart? I'd like to disable those so the markers move seamlessly from left to right?
2) Slightly related, but more of a general question about communicating between while loops: Is it possible to change control properties using local variables? Such that I can implement an event handler to change the control appearance in a separate loop?
Thanks again
07-05-2019 02:03 PM - edited 07-05-2019 02:05 PM
There are many ways to manipulate LV charts and graphs. I'm sure there's a way to present the data how you want it. Take a look at the examples: Help > Find Examples... Building User Interfaces > Displaying Data > Graphs and Charts.
Although you can use locals there are many better ways. Between loops you don't need anything. Just put your property node in the other loop and wire your control directly.
BTW, like almost everyone else here, I'm not using LV2019 yet so can't open your VI. Do a Save for Previous Version... and make it LV2015 or something and re-post it.
07-06-2019 02:14 PM
I'm attaching the DAQmx example saved in LabVIEW 2016 (my oldest version readily available).
This VI has a curious property. When I opened it in LabVIEW 2019, I was worried because the Front Panel loaded "in pieces" (it looked like a part of a Chart/Graph came visible, then nothing happened for a minute). I aborted, tried again, and everything loaded in (I'm guessing now) 2 minutes. The code doesn't look remarkable (not huge), so I chalked it up to a weird 2019 thing (it is extremely difficult to load "on top of" earlier versions, probably thanks to NIPM -- I still have not accomplished it despite several attempts on my work PC).
I saved it in LabVIEW 2016, then opened it in LabVIEW 2016. Same thing -- partial load of Front Panel, then after a minute or so, the "grid background" of the Front Panel loads and you can open the VI. No idea why this is happening -- "It's a Feature ...".
Bob Schor
07-07-2019 02:16 PM
Opens instantly in LabVIEW 2019 here.
(... but OTOH I don't have DAQmx installed. Could it be that one of the subVIs is hogging the UI thread? What is their original version?)
07-07-2019 05:31 PM
Front Panel opens instantly in 2018, block diagram blank for a few seconds, then fills in.
mcduff
07-08-2019 12:39 AM