Using:
- 6x10 RGB MATRIX for XIAO
- XIAO ESP32C3
- Home Assistant + ESPHome
I am trying to setup my XiaoC3+LED Matrix for control with ESPHome. I am able to talk to the LED matrix just fine using Arduino firmware. However, I have gotten nothing working with the ESPHome firmware–no progress after too many hours. Sad face. I do see my debug “.” being logged so the lambda routine is running but showing nothing.
My ESPHome YAML is below. Can anyone help me figure out how to the LED matrix working with ESPHome?
esphome:
name: "led-matrix"
friendly_name: LED Matrix
platformio_options:
board_build.flash_mode: dio
esp32:
board: seeed_xiao_esp32c3
variant: esp32c3
framework:
type: arduino
platform_version: 5.4.0
logger:
level: DEBUG
#hardware_uart: UART0 # this causes firmware to fail to boot, pin overlap?
api:
encryption:
key: !secret api_key
ota:
password: !secret ota_key
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
ap:
ssid: "led-matrix-fallback"
password: !secret ap_key
captive_portal:
color:
- id: YELLOW
red_int: 6
green_int: 3
blue_int: 0
- id: AMBER
red_int: 6
green_int: 2
blue_int: 0
- id: ORANGE
red_int: 6
green_int: 1
blue_int: 0
light:
- platform: neopixelbus
name: "LED Matrix Light"
id: led_matrix_light
variant: WS2812X #WS2812 doesn't work either
type: GRB
num_leds: 60
pin: 2 # pin 0 doesn't work either
#method:
#type: bit_bang #sp32_rmt
#channel: 0
# - platform: fastled_clockless # doesn't build, might be issue/bug
# name: "LED Matrix Light"
# id: led_matrix_light
# chipset: WS2812B
# rgb_order: GRB
# num_leds: 60
# pin: GPIO2
# - platform: esp32_rmt_led_strip
# name: "LED Matrix Light"
# id: led_matrix_light
# chipset: ws2812
# rgb_order: GRB
# num_leds: 60
# pin: GPIO2
# rmt_channel: 0
display:
- platform: addressable_light
id: led_matrix_display
addressable_light_id: led_matrix_light
width: 6
height: 10
rotation: 0°
update_interval: 500ms
lambda: |-
ESP_LOGD("custom", ".");
Color yellow = Color(0x060300);
Color amber = Color(0x060200);
Color orange = Color(0x060100);
// try these colors
it.draw_pixel_at(0, 0, yellow);
it.draw_pixel_at(1, 1, amber);
it.draw_pixel_at(2, 2, orange);
// try these colors too
it.draw_pixel_at(3, 3, YELLOW);
it.draw_pixel_at(4, 4, AMBER);
it.draw_pixel_at(5, 5, ORANGE);