Hello to all .Hi I need to flash a led.
I created this script:
lampeggio:
alias: lampeggio
sequence:
- service: switch.turn_on
data: {}
entity_id: switch.ledtt
- delay:
hours: 0
minutes: 0
seconds: 0
milliseconds: 500
- service: switch.turn_off
data: {}
entity_id: switch.ledtt
This way I only have one flash.
Now I thought about creating a second script that repeats the blinking until a certain condition is true
ripetere:
alias: ripetere lampeggio
sequence:
- repeat:
while:
- condition: state
entity_id: switch.led_goccia
state: 'on'
sequence:
- service: script.lampeggio
Unfortunately nothing happens.