Updates MQTT switch to add state_ configurations (#5776)

This commit is contained in:
Ryan Davies 2018-07-21 09:05:02 +12:00 committed by Fabian Affolter
parent 04eaee0089
commit d483e549a3

View File

@ -46,6 +46,16 @@ state_topic:
description: The MQTT topic subscribed to receive state updates. description: The MQTT topic subscribed to receive state updates.
required: false required: false
type: string type: string
state_on:
description: The payload that represents the on state.
required: false
type: string
default: ON
state_off:
description: The payload that represents the off state.
required: false
type: string
default: OFF
command_topic: command_topic:
description: The MQTT topic to publish commands to change the switch state. description: The MQTT topic to publish commands to change the switch state.
required: false required: false
@ -117,6 +127,8 @@ switch:
availability_topic: "home/bedroom/switch1/available" availability_topic: "home/bedroom/switch1/available"
payload_on: "ON" payload_on: "ON"
payload_off: "OFF" payload_off: "OFF"
state_on: "ON"
state_off: "OFF"
optimistic: false optimistic: false
qos: 0 qos: 0
retain: true retain: true