Rename sensor_class to device_class
This commit is contained in:
parent
4b6358c12b
commit
b83f3855ee
8 changed files with 19 additions and 19 deletions
|
|
@ -32,7 +32,7 @@ Configuration variables:
|
|||
- **qos** (*Optional*): The maximum QoS level of the state topic. Default is 0.
|
||||
- **payload_on** (*Optional*): The payload that represents on state. Default is "ON".
|
||||
- **payload_off** (*Optional*): The payload that represents state. Default is "OFF".
|
||||
- **sensor_class** (*Optional*): The [type/class](/components/binary_sensor/) of the sensor to set the icon in the frontend.
|
||||
- **device_class** (*Optional*): The [type/class](/components/binary_sensor/) of the sensor to set the icon in the frontend.
|
||||
- **value_template** (*Optional*): Defines a [template](/topics/templating/) to extract a value from the payload.
|
||||
|
||||
For a quick check you can use the commandline tools shipped with `mosquitto` to send MQTT messages. Set the state of a sensor manually:
|
||||
|
|
@ -52,7 +52,7 @@ binary_sensor:
|
|||
qos: 0
|
||||
payload_on: "1"
|
||||
payload_off: "0"
|
||||
sensor_class: opening
|
||||
device_class: opening
|
||||
value_template: '{% raw %}{{ value.x }}{% endraw %}'
|
||||
```
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue