GPIO Inputs used in input board. For switch mode mqtt message is send for actions single, double and long presses. For sensor mode mqtt message is send for actions pressed, released.
input:
- id: IN_29
pin: P8_36
actions:
single:
- action: output
pin: light
action_output: toggle
- id: IN_30
pin: P8_35
kind: sensor
actions:
pressed:
- action: mqtt
topic: boneiohome2/cmd/cover/kitchen/set
action_mqtt_msg: 'ON'
released:
- action: cover
pin: kitchen
action_cover: stop
{pin}
) - ID to use to name this device in MQTT and Home Assistant.P9_33
.gpio
, allowed_values: ['gpio', 'gpio_pu', 'gpio_pd', 'gpio_input']
) - How to run this gpio. gpio means default gpio mode. gpio_pu = gpio pull up, gpio_pd = gpio pull down, gpio_input - to be checked.['switch', 'sensor']
) - Type of device to send to Home Assistant. This kind indicate actions you can use.['mqtt', 'output', 'cover']
) - action type. Output and cover means that command is send directly to output relay or cover. This mode doesn’t need network to work. Mqtt mean that there is extra action send to mqtt. For example you can directly control second boneIO!output
or cover
.mqtt
action is chosen['toggle', 'open', 'close', 'stop', 'toggle_open', 'toggle_close']
) - action to perform on cover
type action. toggle
is actions between open/close. toggle_open
means actions between open/stop, toggle_close
means actions between close/stop.['toggle', 'on', 'off']
) - action to perform on output
type action.mqtt
.