UT_TOGGLE — Push-on / push-off
UT_TOGGLE — Push-on / push-off
One pushbutton turns something on, the next press turns it off.
Pins
| Pin | Type | Default | What to wire | |
|---|---|---|---|---|
| in | In |
BOOL | FALSE | Pushbutton. Each press (rising edge) flips Q |
| in | Reset |
BOOL | FALSE | Forces Q off while held (wins over everything) |
| in | ForceOn |
BOOL | FALSE | Forces Q on while held (Set is avoided as a name) |
| out | Q |
BOOL |
How it works
- Only a press counts: holding the button does nothing more, and releasing it does nothing.
Resetwins overForceOn, and both win over the button. A press while either is held is ignored, and releasing them with the button still held doesn't count as a press.ForceOnleavesQon when it releases.- Power cut: nothing is kept.
Qstarts off. - Like the standard
R_TRIG, a button already held on the first scan after start counts as a press.
Last updated 2 hours ago
Was this helpful?