io_get(alias)
Unified I/O. Introduced at SW 10.15 and 5.26. This script is backward compatible with all previous SW and HW versions.
Returns the state of one selected input or output pin.
See also I/O labels and io_set(alias, value).
Parameters
alias: The symbolic name of the pin (string). It can represent a digital input, digital output, analog input, or analog output.
Return Value
For digital I/O, the return type is boolean. For analog I/O, it is a floating-point number.
Example command: sensor1 = io_get("CB_CI3")
- Example Parameters:
- Read control box configurable digital input 3:
sensor1 = io_get("CB_CI3") - Read control box analog output 0:
conveyor_speed = io_get("CB_AO0") - Read Smart Panel button 1:
button1 = io_get("T1_DI0")
- Read control box configurable digital input 3:
Replaces: get_analog_in, get_analog_out, get_standard_analog_in, get_standard_analog_out, get_tool_analog_in, get_configurable_digital_in, get_configurable_digital_out, get_digital_in, get_digital_out, get_standard_digital_in, get_standard_digital_out, get_tool_digital_in, get_tool_digital_out.