08-18-2014 11:33 AM
I'm trying to create a vi that will control (actuate and release) several relays using a USB 6501 DAQ. This should be a relativily easy task but I keep getting flumoxed by errors. I've tried using the examples but I keep getting an error telling me that I need to use 1 sample (On Demand) generation mode. Please help
Solved! Go to Solution.
08-18-2014 11:39 AM
08-18-2014 11:54 AM
I need to be able to be able to actuate the relay for about 10 Sec and then releas for about 10 sec while running the vi. Can I do that with a single sample?
08-18-2014 12:03 PM
@bfort wrote:
I need to be able to be able to actuate the relay for about 10 Sec and then releas for about 10 sec while running the vi. Can I do that with a single sample?
Sure, what is the precision you need? Windows timing (or software timing) is sorta arbitrary. If your relay was on for 10.001 seconds is that okay? What about 10.01 seconds? What about 10.1? How consistent it is will rely on how many other things Windows is doing, and how good of a computer it is.
But generally if you have your code running in a while loop, doing nothing else, you can probably expect <10ms of variation.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
08-18-2014 12:07 PM
How do I control the timing?
08-18-2014 12:10 PM
08-18-2014 12:10 PM
There's the Wait (ms) function.
08-18-2014 12:10 PM
@bfort wrote:
How do I control the timing?
With a While Loop and probably the Elapsed Timer VI. You can wire to it a constant, and it will tell you if that amount of time has elapsed or not. When it has do something using a case structure.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord