This module is used to describe the input button. This is about a Gpio configured as an input.
Int — not used yet
gpio PIN number for this input
pinMode — can be INPUT_PULLUP INPUT_PULLDOWN INPUT
debounceDelay — bounce processing time
execLevel — trigger level High or Low
fixState-input behavior, triggered at the transition or when the level is fixed (trigger mode)
To understand the dependence of the input behavior on the execLevel and fixState states, we present a table built after the fact:
Customization | at input 1 | input 0 |
---|---|---|
execLevel 0 | High | |
fixState 0 | Low | |
execLevel 1 | High | |
fixState 0 | Low | |
execLevel 1 | High TM | |
fixState 1 | High TM | |
execLevel 0 | Low TM | |
fixState 1 | Low TM |
Explanations to the table, High TM is a mode where 1 and 0 are fixed by a high level, but to change the state, you must first switch to a low level. The next high level will change state again. This mode is also sometimes referred to as high edge state switching.
Low TM is a low edge state switch.