08-12-2013 12:59 PM - last edited on 08-13-2013 10:16 AM by JordanG
Hello,
I want to control my shutter using LabView. I have got a program for it from which I can see that shutter is being controlled. But I don't know how should i incorporate this conditional opening and closing of shutter. For example, I would like shutter to be close for first "t1' sec and open for next "t2" sec and again close for "t1" and this repeated over unless stopped.
I am attaching the file also, Can somebody explain me how I can do it?
Thanks and regards.
Solved! Go to Solution.
08-12-2013 02:03 PM
Hi
What you need is two arrays with in the first the on times and in the second the off times.
Then in a for loop switch on, wait element on, switch off wait element off.
Use autoindexing and make sure that both arrays have the same length otherwise the shortest array will determine the last steps.
08-12-2013 02:30 PM
I'm thinking this would be a good application for a State Machine.
08-12-2013 03:59 PM
I have managed to find the solution. thank you for help
08-13-2013 12:13 AM
I completely agree with the statemachine proprosal.
Especially the sequence structure used now is really not necessary (two empty frames and everything is already connected by error wires)
Instead of the old sequence structure please use the new flat structure.
The only extra comment I would make is to connect all error wires instead of starting again in a frame.