09-13-2016 01:00 PM
I don't think the problem is that the VI isn't working, the problem is that you're using an equals comparison on a time stamp variable to trigger using it. Time stamps may look like hours/minutes/seconds and nothing else, but under the surface they're floating point numbers. Comparing floating points for equality in LabVIEW is a bad idea (well, it's a bad idea in all languages...)
The easy way to fix your code would be to change it to a "greater than" node instead.
I'd also add a time delay in there too. Since you're only measuring once an hour there's no need to check it millions of times a second. Add a .1 or 1 second timer in there.
09-13-2016 01:27 PM
Thank you! Checking the floats for equality was indeed a problem, the code was never entering the "True" case. But I am still not seeing an output from the "Meas Voltage Output VI".
On another note, the bottom while loop doesn't execute until I halt the top while loop and I am having trouble understanding why. Is this because of the flat sequence structure in the top loop?
09-13-2016 01:37 PM
Yeah, I wasn't looking at that earlier, but the error chain and time stamp inputs won't let the bottom loop run because they both pass through the top loop.
You need to either fork the error wire before it enters the loop and move the "Get date/time in seconds" out of the loop, or move the bottom loop so that it's completely inside the top loop. Not sure which (or both) would accomplish your goal.
09-13-2016 02:19 PM
The former fixed it. Took off the error wire from the bottom loop and moved the "get date/time in sec" outside the loop. Thanks so much.
Additional question. If I wanted to turn off the power supply after X amount of hours (gradually decrease the voltage down to zero), do you have an idea of what driver I could use to accomplish this?