LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Reset a slide bar without losing the amount of fluid pumped

Solved!
Go to solution

Hi there,

 

I am trying to sum up the total amount of fluid my pump will pump into my rig. I also need a slide bar that would show me that amount of fluid pumped, knowing that I need to sample every 15mL injected (so the slide bar is set from 0 to 15). 

 

I was thinking that my VI could work, but for some reason I ignore it doesn't behave properly. I can't really reset the bar to zero, and if I do, it won't fill anymore.

 

would you please help me setting a VI that could permit me to see the progression on the bar, and when it's full, leaving me the opportunity to reset it to zero (in order for it to start filling again) by clicking on a button ?

 

Cheers,

Flo

0 Kudos
Message 1 of 8
(3,451 Views)

1) delete 60 sec delay!!!
2) store slide bar in shift register
3) if you want reset only slide bar, but not total fluid injected, then you need 2 shift registers

slide.png

0 Kudos
Message 2 of 8
(3,383 Views)

The problem is Ineed the 60s delay as I am sampling my variable every 60s 😞

 

 

0 Kudos
Message 3 of 8
(3,354 Views)

if you set 60s delay, your UI will react once in minute.
You can add timer and when time elapsed, ask new sample, another case take 0 as FR CP

0 Kudos
Message 4 of 8
(3,344 Views)

It seems to me that you got what the problem was. But I don't precesly understand your point. 

 

Could you please be more specific? 

 

I am close to solve that, thank you very much for you help 🙂

 

Flo

0 Kudos
Message 5 of 8
(3,338 Views)
Solution
Accepted by topic author Flo-w

Basically, in the example above, set the value going into the Event structure timeout input from 1000 to 60000, this will cause the Event Structure to fire off the 'Timeout' Event once every 60000 ms (60s), you would then put your sampling code inside the 'Timeout' event.  Copy the image below to a block diagram for example.

 

SlideIncrease.png 

Edit: Fixed image to show 60000 ms delay.

Jon D
Certified LabVIEW Developer.
Message 6 of 8
(3,318 Views)

A modified version of your VI works perfectly fine !

 

I'll double check that tomorrow but for now it looks like it works !

 

Thank you!

 

Flo

0 Kudos
Message 7 of 8
(3,303 Views)

Good to hear.

Jon D
Certified LabVIEW Developer.
0 Kudos
Message 8 of 8
(3,290 Views)