FB: Enable/Disable Button - v2.0
This function block manages an enable/disable toggle state driven by a physical button, HMI button, or internal IT signals.
Use Cases
Section titled “Use Cases”- Physical pushbutton that toggles an output (e.g., conveyor enable).
- Allowing both panel button and HMI screen to enable/disable a function.
- IT-triggered forced enable or disable from program logic.
Dependencies
Section titled “Dependencies”| Type | Name | Version |
|---|---|---|
data type | escOutput | v2.2 |
Parameters
Section titled “Parameters”Function
Section titled “Function”| Parameter | Declaration | Type | Init. value | Description |
|---|---|---|---|---|
DI_button | Input | Bool | — | IR: Physical button — toggles enabled on positive edge |
IT_enable | Input | Bool | — | IR: Positive edge sets enabled := 1 |
IT_disable | Input | Bool | — | IR: Positive edge sets enabled := 0 |
HMI_button | Input | Bool | — | IR: HMI button — toggles enabled on positive edge |
DO_enableLamp | Output | Bool | — | OR: 1= Enable lamp on |
DO_disableLamp | Output | Bool | — | OR: 1= Disable lamp on |
enabledPulseOn | Output | Bool | — | OR: Positive edge pulse when enabled transitions to 1 |
disabledPulseOn | Output | Bool | — | OR: Positive edge pulse when enabled transitions to 0 |
enabled | In/Out | Bool | — | IOX: Current enable/disable state: 0= Disabled; 1= Enabled |
esc | In/Out | escOutput | — | IOX: Emergency Stop Circuit output data |
clock | In/Out | Byte | — | IOX: System clock byte |