LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to continue timer from prevous state?

Hi guys,

 

I have some question regarding on the timer. I doing a project called car washing system. Basically every selection will have limited function.

Example: $2 wash: Heavy Wash (10 sec) -> Air Dry (15 sec )-> Exit
Example: $5 wash: Main Wash (10sec) -> Soap(10sec) -> Heavy Wash (10sec) -> Air Dry (15 sec) -> Exit

 

So for every state the timer run until it reach the timing, the timer will pause and next state the timer will continue. I'm using toggle switch so when i toggle up the timer, it will start running until it reach the stage and pause for next toggle switch up to continue. But currently there is some error which i toggle up the timer get reset.

 

subvi.png

timer.png

0 Kudos
Message 1 of 5
(2,873 Views)

Ah, CLD practice exams. 🙂

You might want to rethink your use of locals.

 

This is also one of those rare cases where I think the Express VI works well. The Elapsed Time Express VI should have all of the pieces you need.

The tricky part is that you'll probably want to put the timer in its own state in your state machine.

0 Kudos
Message 2 of 5
(2,852 Views)

I'm still a beginner. How can express VI work?

0 Kudos
Message 3 of 5
(2,841 Views)

Look at the LabVIEW help for this one:

Elapsed Time.png

 

0 Kudos
Message 4 of 5
(2,825 Views)

You may also want to post questions over on the Certification forum.

 

http://forums.ni.com/t5/Certification/bd-p/Certification

 

I'd also recommend checking out the elapsed timer express VI.  It doesn't have a pause/resume feature but it doesn't take much to add it.  I started from the express VI and just added this functionality.

0 Kudos
Message 5 of 5
(2,820 Views)