This function block will give a pulse on one to four outputs depending on the length of the press on the input.
When an input is pressed when connected to the Tr input on the long click block the duration of the press is measured. Depending on how long the pulse is, an adjustable pulse will occur on one of the digital outputs Q1 to Q4. The duration of the output pulse can be defined using the parameter T.
The analogue value that is output can also be changed using the parameters V1 to V4.
Four different scenarios can occur with this block depending on how long the input is pressed for:
Output Q1 and Q2 sequentially active
The first press on input Tr is a pulse longer than parameter Ti but shorter than 2x Ti (a short press). Output Q2 is active with a pulse of parameter T duration. Also the value of parameter V2 is output at AQ. By default this is 2.
Then a quicker press happens on input Tr. Therefore output Q1 is active with a pulse of parameter T duration. The value of parameter V1 is also output at AQ. By default this is 1.
You could use the long click block to have multiple functions inbuilt into one switch for example a short press will raise the blinds by a small amount whereas a long press will raise them fully.
Q4 output active
The press on input Tr is a pulse 3 times longer than parameter Ti. Output Q4 is active with a pulse of parameter T duration. Also the value of parameter V4 is output at AQ. By default this is 4.