这个就可以啊。
我就用这个的:
alias: 大门未关超过2分钟后第分钟提醒1次
description: ''
trigger:
- platform: state
entity_id: binary_sensor.smartlock_door
to: 'on'
for: '120'
condition: []
action:
- data:
message: 大门未关好,请检查!
title: 大门未关好
service: notify.mobile_app_iphone
- repeat:
while:
- condition: state
entity_id: binary_sensor.smartlock_door
state: 'on'
sequence:
- service: tts.baidu_say
data:
entity_id: media_player.{{states("input_select.shu_chu_yin_xiang")}}
message: 大门未关好,请检查!
- delay:
hours: 0
minutes: 1
seconds: 0
milliseconds: 0
mode: single
|