想写一个状态持续不更新超过5分钟就重启设备的自动化,看到官方有下面这种方式和我的需求刚好契合
In this example, the trigger fires if the state value of the entity remains the same for for the time specified, regardless of the current state value.
automation:
trigger:
platform: state
entity_id: media_player.kitchen
# The media player remained in its current state for 1 hour
for: "01:00:00"
可是编译检查的时候,缺有错误提示:
Invalid config for [automation]: expected str for dictionary value @ data['trigger'][0]['from']. Got None. (See /config/configuration.yaml, line 63).