LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

timed button

Hi,

 

My application is to give the Operator a visual indication of time elased after pressing one of a number of buttons.

 

To give an idea of what I am after, the sample vi attached has this working for the top 2 buttons with a timing of 5 seconds. I've placed the buttons on top of the slide indicators, and made the button's true state transparent. I know this could be displayed many ways - a digital or analog clock, an LED - but how it is displayed is not the problem.

 

My intention is to extend this to (at least) 24 buttons, with a timing of 2 hours. I could just extend the page downwards and include all 24 buttons with their own references, shift registers and event cases and make the sub-vi reentrant but I'm sure that's not the way to do this.

 

So, how can I achieve this neatly and make it scalable to include any number of buttons?

 

 

Thanks.

 

 

Front Panel.png

 

 

Timer.png

Download All
0 Kudos
Message 1 of 2
(2,870 Views)

Hi sebster,

 

whenever you need to do the same operation on more than one element, you should use arrays.

Whenever you need to bundle different datatype (button and slide) you need to use clusters.

 

So in conclusion you should use an array of clusters!

And hey: it's scalable to the number of buttons needed!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 2
(2,840 Views)