Add backlight toggling to Home Assistant
This commit is contained in:
@@ -19,3 +19,6 @@ sensor:
|
|||||||
value_template: '{{ states.sensor.weather_sensor.attributes["pressure"] | round(2)}}'
|
value_template: '{{ states.sensor.weather_sensor.attributes["pressure"] | round(2)}}'
|
||||||
friendly_name: Pressure soba
|
friendly_name: Pressure soba
|
||||||
unit_of_measurement: "hPa"
|
unit_of_measurement: "hPa"
|
||||||
|
|
||||||
|
shell_command:
|
||||||
|
toggle_backlight: /bin/bash -c "echo -n -e 'T' >> /dev/ttyV0"
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
show_name: true
|
||||||
|
show_icon: true
|
||||||
|
type: button
|
||||||
|
tap_action:
|
||||||
|
action: call-service
|
||||||
|
service: shell_command.toggle_backlight
|
||||||
|
entity: sensor.weather_sensor
|
||||||
|
name: Toggle backlight
|
||||||
|
show_state: false
|
||||||
|
hold_action:
|
||||||
|
action: more-info
|
||||||
|
icon: mdi:lightbulb
|
||||||
Reference in New Issue
Block a user