Hi there,
I just can´t get this to work and I was hoping someone could help me.
I want to turn on the light (via button press) with a predefined effect (rainbow).
I have the following code:
esphome:
name: l-d1-laurabett
friendly_name: l-d1-laurabett
esp8266:
board: d1_mini
# Enable logging
logger:
level: DEBUG
# Enable Home Assistant API
api:
ota:
- platform: esphome
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
fast_connect: True
min_auth_mode: WPA2
binary_sensor:
- platform: gpio
pin:
number: D3
inverted: True
mode:
input: True
pullup: True
id: "button"
on_press:
then:
- logger.log: "Button pressed"
- light.toggle: strip60
# on_click:
# min_length: 500ms
# max_length: 2000ms
# then:
# - logger.log: "Button long pressed"
# - light.toggle: strip60
light:
- platform: neopixelbus
id: "strip60"
name: none
type: GRB
variant: ws2812
pin: D4
num_leds: 60
restore_mode: RESTORE_DEFAULT_OFF
on_turn_on:
then:
- light.turn_on:
id: "strip60"
brightness: 40%
effect: addressable_rainbow
effects:
- addressable_rainbow:
But if I use this, I get an error message in my logs:
[16:37:49.513][D][main:210]: Button pressed
[16:37:49.525][D][light:091]: 'l-d1-laurabett' Setting:
[16:37:49.526][D][light:104]: State: ON
[16:37:49.526][D][light:142]: Transition length: 1.0s
[16:37:49.526][W][light:523]: 'l-d1-laurabett': no such effect 'addressable_rainbow'
[16:37:49.526][D][light:091]: 'l-d1-laurabett' Setting:
[16:37:49.539][D][light:079]: Brightness: 40%
[16:37:49.539][D][light:142]: Transition length: 1.0s
[16:37:49.539][D][binary_sensor:041]: 'button': New state is ON
[16:37:49.651][D][binary_sensor:041]: 'button': New state is OFF
Does someone have a tip for me?