From d6228f3605bc814a4e90a7d9597a7ab78e9dd915 Mon Sep 17 00:00:00 2001 From: Frederic Date: Mon, 13 Apr 2020 11:54:00 +0200 Subject: [PATCH] add LED String --- ledstring.yml | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 ledstring.yml diff --git a/ledstring.yml b/ledstring.yml new file mode 100644 index 0000000..e1ceaf8 --- /dev/null +++ b/ledstring.yml @@ -0,0 +1,78 @@ +<<: !include secrets.yml + +esphome: + name: ledstring + platform: ESP8266 + board: d1_mini + +wifi: + ssid: $wifi_ssid + password: $wifi_password + ap: + ssid: "LED String Fallback Hotspot" + password: $wifi_ap_password + +captive_portal: + +logger: + +api: + +ota: + password: $ota_password + +web_server: + +binary_sensor: + - platform: gpio + id: button + pin: + number: D1 + mode: INPUT_PULLUP + inverted: True + name: "Button" + on_click: + then: + - switch.toggle: + id: ledstring_switch + +switch: + - platform: template + optimistic: True + id: ledstring_switch + name: "LED String Switch" + turn_on_action: + - light.turn_on: + id: ledstring + brightness: 70% + effect: rainbow + turn_off_action: + - light.turn_off: + id: ledstring + +light: + - platform: neopixelbus + id: ledstring + name: "LED String" + type: RGB + variant: WS2812 + method: ESP8266_DMA + pin: GPIO3 + num_leds: 26 + effects: + - addressable_twinkle: + name: twinkle + twinkle_probability: 5% + progress_interval: 4ms + - addressable_random_twinkle: + name: randomtwinkle + twinkle_probability: 5% + progress_interval: 32ms + - addressable_rainbow: + name: rainbow + speed: 10 + width: 50 + - addressable_flicker: + name: flicker + update_interval: 50ms + intensity: 5%