mirror of
https://github.com/esphome/esphome.git
synced 2025-09-01 10:52:19 +01:00
Add Adalight support (#956)
A component to support [Adalight](https://learn.adafruit.com/adalight-diy-ambient-tv-lighting). This allows to control addressable LEDs over UART, by pushing data right into LEDs. The most useful to use [Prismatik](https://github.com/psieg/Lightpack) to create an immersive effect on PC. Co-authored-by: Guillermo Ruffino <glm.net@gmail.com>
This commit is contained in:
@@ -128,14 +128,20 @@ spi:
|
||||
miso_pin: GPIO23
|
||||
|
||||
uart:
|
||||
tx_pin: GPIO22
|
||||
rx_pin: GPIO23
|
||||
baud_rate: 115200
|
||||
id: uart0
|
||||
parity: NONE
|
||||
data_bits: 8
|
||||
stop_bits: 1
|
||||
rx_buffer_size: 512
|
||||
- tx_pin: GPIO22
|
||||
rx_pin: GPIO23
|
||||
baud_rate: 115200
|
||||
id: uart0
|
||||
parity: NONE
|
||||
data_bits: 8
|
||||
stop_bits: 1
|
||||
rx_buffer_size: 512
|
||||
|
||||
- id: adalight_uart
|
||||
tx_pin: GPIO25
|
||||
rx_pin: GPIO26
|
||||
baud_rate: 115200
|
||||
rx_buffer_size: 1024
|
||||
|
||||
ota:
|
||||
safe_mode: True
|
||||
@@ -179,6 +185,8 @@ as3935_spi:
|
||||
cs_pin: GPIO12
|
||||
irq_pin: GPIO13
|
||||
|
||||
adalight:
|
||||
|
||||
sensor:
|
||||
- platform: adc
|
||||
pin: A0
|
||||
@@ -1177,6 +1185,8 @@ light:
|
||||
if (initial_run) {
|
||||
it[0] = current_color;
|
||||
}
|
||||
- adalight:
|
||||
uart_id: adalight_uart
|
||||
- automation:
|
||||
name: Custom Effect
|
||||
sequence:
|
||||
|
@@ -183,9 +183,13 @@ spi:
|
||||
miso_pin: GPIO14
|
||||
|
||||
uart:
|
||||
tx_pin: GPIO1
|
||||
rx_pin: GPIO3
|
||||
baud_rate: 115200
|
||||
- tx_pin: GPIO1
|
||||
rx_pin: GPIO3
|
||||
baud_rate: 115200
|
||||
|
||||
- id: adalight_uart
|
||||
rx_pin: GPIO3
|
||||
baud_rate: 115200
|
||||
|
||||
ota:
|
||||
safe_mode: True
|
||||
@@ -203,6 +207,8 @@ deep_sleep:
|
||||
run_duration: 20s
|
||||
sleep_duration: 50s
|
||||
|
||||
adalight:
|
||||
|
||||
sensor:
|
||||
- platform: apds9960
|
||||
type: proximity
|
||||
@@ -708,6 +714,8 @@ light:
|
||||
method: ESP8266_UART0
|
||||
num_leds: 100
|
||||
effects:
|
||||
- adalight:
|
||||
uart_id: adalight_uart
|
||||
- e131:
|
||||
universe: 1
|
||||
|
||||
|
Reference in New Issue
Block a user