Digital Inputs
Digital inputs are on/off signals such as buttons, switches, magnetic reed switches, beam breaks, and sensor contacts.
Add a digital input
- Open Configuration.
- Go to Connections.
- Expand Inputs, Outputs, and Modules.
- Add an input.
- Choose a digital input type.
- Set the input ID (friendly name).
- Select the physical pin, expander pin, or module channel.
- Set active behavior if the sensor is high or low trigger and enable/disable the input pullup.
- Apply I/O Changes and let the controller reboot if required.
- Confirm the input changes in Live Monitor or on the Operator page.
Digital input controls
| Control | What it does |
|---|---|
| ID | Friendly name used by behavior rules and operator status |
| Type | Defines the kind of digital source, such as button, switch, latch, knock, or custom input |
| Pin/channel | Physical controller pin or module channel |
| Pullup | For dry contacts the simplest configuration is pullup enabled with a low active |
| Active state | Determines whether high or low means active |
Use in behavior
- Go to Configuration > Behavior.
- Add an Action Trigger or Logic Rule.
- Choose the digital input as the source.
- Select the state or value, such as active, inactive, pressed, or released.
- Choose the action to run.
Gestures and Debounce
On the Definitions page there are 2 sections that can apply to Digital Inputs, the Default Debounce and Input Gestures. A debounce determines how long an input needs to be in a state before it registers as a trigger and can also determine how fast subsequent triggers can happen. Switches a default of 40ms can usually help ensure clean signals but in noisy environments it’s not uncommon to have debounce of up to 500ms. Too much can make a prop feel sluggish but the longer the debounce the more reliable the reading.
For buttons, setting up an Input Gesture can allow you to have things long short press, long press, double press and press/hold. You can configure the timings individually but the defaults are usually a good starting point.
Troubleshooting
| Symptom | What to check |
|---|---|
| Input never changes | Pin/channel, ground, active state, module power |
| Input reads backward | Active state or wiring type |
| Input fires repeatedly | Debounce, loose wiring, floating input |
| Behavior does not run | Source ID, required state guard, and action target |