LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Continuous data restart issues

The attached script is to interface and record continuous data between two MCC DAQ devices. The problem that I am having is that when I run the script, the timer is running before I press the start new scan button. When I press the Start new scan button, the goal is that the X-data starts at zero and not at however long I started running the script. 

I have messed around with case structures and restart triggers, but not much as been working out. 

 

Can't wait to hear from ya'll!

Evan Goodson

 

 

0 Kudos
Message 1 of 2
(2,236 Views)

Hi Evan,

 

in LabVIEW we create VIs, scripts are used inside of formula nodes or similar text-based constructs…

 


@EvanGoodson wrote:

The problem that I am having is that when I run the script, the timer is running before I press the start new scan button. When I press the Start new scan button, the goal is that the X-data starts at zero and not at however long I started running the script.


The "timer is running" because you get the start time before the main loop. When the "timer should start" with the "scan button press" then you need to read the start time in a different way…

Your VI is a little bit "complicated": right now you can read data several times (each time you enable "Scan") before you stop the main loop. This will give you non-continuous data in your (mostly non-initialized!?) arrays: is this required/expected?

 

You really should clean up your VI, atleast there should be more straight wires…

Best regards,
GerdW


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