Skip to content

intermittech/ESPHOME-WS2805

 
 

Repository files navigation

💡 ESPHome WS2805 External Component

Latest Release Status ESPHome ESP-IDF Ready Arduino Ready License: CC BY-NC-SA 4.0

🌍 Lies dies auf Deutsch

This is an external component for ESPHome that provides support for WS2805 5-channel (RGB + Warm White + Cold White) LED strips.

ESPHome's built-in AddressableLight primarily maps to a maximum of 4 channels (RGBW). Since WS2805 requires 5 channels (40 bits per pixel) for RGBCCT support, this component operates as an AddressableLight for RGB effects, while maintaining global control over the W1 and W2 channels.

This maps perfectly to the Home Assistant UI, providing correct Addressable RGB effects and global CCT (Color Temperature) control without jumping sliders.

🔥 What can it DO?

  • Addressable RGB Effects: Since the component inherits from AddressableLight, you can add and use all Addressable light effects such as addressable_rainbow, addressable_scan, etc.
  • Global CCT Control: The Warm White and Cold White channels are globally set across the entire strip according to your CCT sliders in Home Assistant. This is exactly how tools like WLED manage RGBCCT setups.
  • Multi-Strip Support (Native RMT): Uses ESPHome's highly optimized, native esp32_rmt_led_strip architecture instead of NeoPixelBus. This safely manages RMT channels, interrupt flags, and SRAM, allowing up to 8 parallel instances without ESP_ERR_INVALID_STATE limits on modern chips like the ESP32-S3.
  • Brightness Scaling: Proper mapping and scaling of the 5 channels relative to overall brightness.

🛠️ Usage in ESPHome

To use this component, you can include it directly from GitHub using the external_components block. You can define multiple zones/strips running in parallel on the ESP32 (e.g., ESP32-S3) without RMT crashes.

esp32:
  board: esp32-s3-devkitc-1
  framework:
    type: esp-idf # Also compatible with arduino

external_components:
  - source:
      type: git
      url: https://github.com/babeinlovexd/ESPHOME-WS2805
      ref: main
    components: [ ws2805 ]

light:
  - platform: ws2805
    id: ws2805_zone_1
    name: "My WS2805 Strip - Zone 1"
    pin: GPIO4 # The GPIO pin your data line is connected to
    num_leds: 100 # Total number of LEDs on the strip
    color_interlock: false
    cold_white_color_temperature: 153 mireds
    warm_white_color_temperature: 500 mireds
    gamma_correct: 2.2
    effects:
      - addressable_rainbow:

  - platform: ws2805
    id: ws2805_zone_2
    name: "My WS2805 Strip - Zone 2"
    pin: GPIO5
    num_leds: 100

  - platform: ws2805
    id: ws2805_zone_3
    name: "My WS2805 Strip - Zone 3"
    pin: GPIO6
    num_leds: 100

⚙️ Configuration Variables

You can use all standard ESPHome variables (like name, id, gamma_correct, effects), plus the following WS2805-specific arguments:

  • pin (Required): The GPIO pin your data line is connected to.
  • num_leds (Required): Total number of LEDs on the strip.
  • color_interlock (Optional, boolean): Prevents white LEDs and RGB LEDs from being at full brightness simultaneously (useful for power supply management or thermal limits). Defaults to false.
  • cold_white_color_temperature (Optional): The color temperature of your cold white LEDs in mireds. Default value is 153 mireds (~6500K).
  • warm_white_color_temperature (Optional): The color temperature of your warm white LEDs in mireds. Default value is 500 mireds (~2000K).

☕ Support this Project

If you like this ESPHome component and want to support my work, I'd be absolutely thrilled about a virtual coffee!

Donate with PayPal

👨‍💻 Developed by


Christopher

About

esph-ws2805: A stable ESPHome external component for 5-channel (RGBCCT) WS2805 LED strips. Features addressable RGB, global CCT control, and native ESP32 RMT support for perfect Home Assistant UI integration.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

  • C++ 66.2%
  • Python 30.3%
  • C 3.3%
  • HTML 0.2%