03-31-2009 01:58 PM
If I have a simple program consisting of a DAQ assistant inside a while loop with its data output in volts is there anyway to program in the following formula?
Acceleration= {((Vout1/125)/0.5)-((Vout2/125)/0.5)}/(T2-T1)
so if I start the program Vout1 will be the first data output and T1 will be the time in sec (0 sec) and Vout2 will be the second data output at time T2. Essentially I am trying to convert the voltage output from my device into acceleration as the program runs. Thanks.
03-31-2009 02:02 PM
Yes. You want a shift register. Feed the voltage into a shift register on the right hand side. The left hand side of the shift register will be the value from the previous iteration of the loop.
03-31-2009 02:07 PM
03-31-2009 02:09 PM - edited 03-31-2009 02:10 PM
This should be what youre looking for, replacing the random rnumbers with DAQ Assist:
Also, that 500 ms wait was just for a quick glance making sure I wired everything correctly, you wouldn't need that per se.
03-31-2009 02:52 PM
03-31-2009 02:55 PM