LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Boolean counter

Hi Guys,

 

 

I need your help in fixing my boolean counter. In the attachments, I have attached a file which shows boolean counter implementation. The counter is stopped only on front panel when button is pressed and it does not stop in background.

 

 

Thanks

0 Kudos
Message 1 of 6
(4,554 Views)

Fix what? You have not described what you want it to do. I don't understand 'it does not stop in background' and you have two buttons on the front panel and I don't know which one you are referring to.

 

And why don't you just use a numeric indicator for time?

0 Kudos
Message 2 of 6
(4,550 Views)

Hi Dennis,

 

I have uploaded the file again.

 

1)Press the start button in vi to start the timer.

2)Timer is paused on pressing the start button again.

3)Press the same button again after 5 sec and you will see jump of 5sec in timer which is a problem.

 

The problem is that, although timer is paused on front panel but it is still running in background.I dont know why is it still running in background.

 

 

0 Kudos
Message 3 of 6
(4,540 Views)
Nothing is still running in the background except time  itself. Since all that you are doing is subtracting a start time from the current time, you are not pausing anything. Why don't you try doing a search for 'elapsed time pause' and see what you can come up with.
0 Kudos
Message 4 of 6
(4,533 Views)

Hi Mimran,

 

I wrote an 'Pausable Elapsed Timer' vi a while ago. have attached below:

 

Pausable elapsed timer vi snippet.png

 

Elapsed timer with pause snippet.png

 

If you just want the timer to constantly count time and not stop when reached a set time, input the infinity constant into the target time input, as shown.

 

Rgs,

 

Lucither

 

------------------------------------------------------------------------------------------------------
"Everything should be made as simple as possible but no simpler"
0 Kudos
Message 5 of 6
(4,504 Views)

Hi Again,

 

Looking at that old vi made me realise that i should update it to include an 'Auto Reset' input, so i did:

 

Elapsed timer with pause snippet.png

 

Elapsed timer with pause and Auto reset snippet.png

 

If you set the 'Auto Reset' to false this will give you what you are after.

 

Rgs,

 

Lucither

------------------------------------------------------------------------------------------------------
"Everything should be made as simple as possible but no simpler"
Message 6 of 6
(4,500 Views)