Update MQTT platforms that now support availablity (#4293)

To accompany changes from:
https://github.com/home-assistant/home-assistant/pull/11336

Updated platforms:
- Switch (previously supported)
- Binary sensor (previously supported)
- Cover (previously supported)
- Light
- JSON light
- Template light
- Sensor
- Alarm control panel
- Lock
- HVAC
- Fan
- Vacuum
This commit is contained in:
Dan Nixon 2018-01-02 02:33:19 +00:00 committed by Paulus Schoutsen
parent 943b2e3119
commit 5d321e66f7
12 changed files with 1024 additions and 229 deletions

View file

@ -35,14 +35,56 @@ alarm_control_panel:
command_topic: "home/alarm/set"
```
Configuration variables:
- **state_topic** (*Required*): The MQTT topic subscribed to receive state updates.
- **command_topic** (*Required*): The MQTT topic to publish commands to change the alarm state.
- **name** (*Optional*): The name of the alarm. Default is 'MQTT Alarm'.
- **qos** (*Optional*): The maximum QoS level of the state topic. Default is 0. This QoS will also be used to publishing messages.
- **payload_disarm** (*Optional*): The payload to disarm your Alarm Panel. Default is "DISARM".
- **payload_arm_home** (*Optional*): The payload to set armed-home mode on your Alarm Panel. Default is "ARM_HOME".
- **payload_arm_away** (*Optional*): The payload to set armed-away mode on your Alarm Panel. Default is "ARM_AWAY".
- **code** (*Optional*): If defined, specifies a code to enable or disable the alarm in the frontend.
{% configuration %}
name:
description: The name of the alarm.
required: false
type: string
default: MQTT Alarm
state_topic:
description: The MQTT topic subscribed to receive state updates.
required: true
type: string
command_topic:
description: The MQTT topic to publish commands to change the alarm state.
required: true
type: string
qos:
description: The maximum QoS level of the state topic.
required: false
type: integer
default: 0
payload_disarm:
description: The payload to disarm your Alarm Panel.
required: false
type: string
default: DISARM
payload_arm_home:
description: The payload to set armed-home mode on your Alarm Panel.
required: false
type: string
default: ARM_HOME
payload_arm_away:
description: The payload to set armed-away mode on your Alarm Panel.
required: false
type: string
default: ARM_AWAY
code:
description: If defined, specifies a code to enable or disable the alarm in the frontend.
required: false
type: string
availability_topic:
description: The MQTT topic subscribed to receive availability (online/offline) updates.
required: false
type: string
payload_available:
description: The payload that represents the available state.
required: false
type: string
default: online
payload_not_available:
description: The payload that represents the unavailable state.
required: false
type: string
default: offline
{% endconfiguration %}