|
楼主 |
发表于 2019-10-26 16:13:09
|
显示全部楼层
- data_template:
cache: false
entity_id: media_player.eaemx4
message: >
欢迎回家,现在室内温度{{states('sensor.temperature_158d00044abb74')}}度, 湿度{{states('sensor.humidity_158d00044abb74')}}度
当前空调状态为
{% if states.climate.aqara_air_conditioning_companion_2.state == 'fan_only' %}
送风模式,空调设定温度为{{states.climate.aqara_air_conditioning_companion_2.attributes.temperature}}度
{% elif states.climate.aqara_air_conditioning_companion_2.state == 'heat' %}
制热模式,空调设定温度为{{states.climate.aqara_air_conditioning_companion_2.attributes.temperature}}度
{% elif states.climate.aqara_air_conditioning_companion_2.state == 'cool' %}
制冷模式,空调设定温度为{{states.climate.aqara_air_conditioning_companion_2.attributes.temperature}}度
{% elif states.climate.aqara_air_conditioning_companion_2.state == 'auto' %}
自动模式,空调设定温度为{{states.climate.aqara_air_conditioning_companion_2.attributes.temperature}}度
{% elif states.climate.aqara_air_conditioning_companion_2.state == 'dry' %}
抽湿模式,空调设定温度为{{states.climate.aqara_air_conditioning_companion_2.attributes.temperature}}度
{% elif states.climate.aqara_air_conditioning_companion_2.state == 'off' %}
关闭状态
{% endif %}
service: tts.baidu_say
搜索一晚论坛学会了写这种if 判断的了 |
|