Hello!
So I have my xiaomi roborock working with voice commands with google home mini activating scripts to zoneclean different rooms. Next project is to do the same with “ikea trådfri” lights.
The gateway is setup and integrated, remote connecten to it, and lamps connected to the remote. I se both lamps in overview.
Now I want to make a script that, when activated, turns a lamp on with 10 % dim. I just dont know how to write the scripts. I´ve tried this:
Turn_lights_on_bedroom:
alias: "Turn the lights on in bedroom"
sequence:
- service: light.turn_on
data:
entity_id: light.kitchen_counter
brightness_pct: 30
- service: light.turn_on
data:
entity_id: light.kitchen_main
brightness_pct: 90
But I end upp getting error when “checking config”:
Invalid config for [script]: invalid slug Turn_lights_on_bedroom (try turn_lights_on_bedroom) for dictionary value @ data[‘script’]. Got OrderedDict([(‘vacuum_kitchen’, OrderedDict([(‘alias’, ‘Vacuum the kitchen’), (‘sequence’, [OrderedDict([(‘service’, ‘vacuum.send_command’), (‘data’, OrderedDict([(‘entity_id’, ‘vacuum.Bellman’), (‘command’, ‘app_zoned_clean’), (‘params’, [[25500, 25500, 25500, 27000, 1], [25300, 29300, 28800, 30000, 1]])]))])])])), (‘vacuum_kitchen_fast’, OrderedDict([(‘alias’, ‘Vacuum by the sink’), (‘sequence’, [OrderedDict([(‘service’, ‘vacuum.send_command’), (‘data’, OrderedDict([(‘entity_id’, 'vacuum.Be… (See /config/configuration.yaml, line 39). Please check the docs at Scripts - Home Assistant
How should one write a correct script 4 this?