Open Fitski opened 2 years ago
try to add a method with different channels, it helped me
try to add a method with different channels, it helped me
Hi @maik1607, thanks for your reply. Can you elaborate on what you mean by "adding a method with different channels"? Perhaps you could share your configuration. Thank you in advance!
Sorry for the short reply. Here is part of my configuration:
light:
- platform: neopixelbus
type: RGB
variant: WS2811
method:
type: esp32_rmt
channel: 0
pin: ${neopix_room1}
num_leds: 20
id: nxroom1
internal: true
- platform: neopixelbus
type: RGB
variant: WS2811
method:
type: esp32_rmt
channel: 1
pin: ${neopix_room2}
num_leds: 20
id: nxroom2
internal: true
Thank you @maik1607, This workaround works for me as well!
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
can confirm this behavior still occurs in 2022.9.1. Configuring two light's with neopixelbus with different pins controls always the first defined light. And the workaround with the channels also still works.
2022.10.2 seeing the same behaviour. Wondering if this is something wrong with neopixelbus and not ESPHome.
This fix works for me as well with HA and ESPHome 2022.12.
light:
- platform: neopixelbus
type: GRBW
variant: SK6812
pin: GPIO22
method:
type: esp32_rmt
channel: 0
num_leds: 84
name: "Light 1"
- platform: neopixelbus
type: GRBW
variant: SK6812
pin: GPIO23
method:
type: esp32_rmt
channel: 1
num_leds: 54
name: "Light 2"
I can confirm both the issue and workaround (pins GPIO5 and GPIO32 on ESP32)
For those using the NeoPixelBus directly, the following change is required to support multiple busses:
original code:
NeoPixelBus<NeoRgbFeature, Neo800KbpsMethod> pixels(CAR_LIGHTS_COUNT, CAR_LIGHTS_PIN);
updated code:
NeoPixelBus<NeoRgbFeature, NeoEsp32Rmt0800KbpsMethod> carPixels(CAR_LIGHTS_COUNT, CAR_LIGHTS_PIN);
NeoPixelBus<NeoRgbFeature, NeoEsp32Rmt1800KbpsMethod> riverPixels(RIVER_LIGHTS_COUNT, RIVER_LIGHTS_PIN)
For supporting multiple busses, make sure to have separate methods for each instance (the number after Rmt
):
NeoEsp32Rmt0800KbpsMethod
NeoEsp32Rmt1800KbpsMethod
Please keep in mind the feature (Rgb
, Rgbw
, etc.) and method (800Kbps
, 400Kbps
, etc.) must match your neo pixel type.
If it's an ESP32, you're better off using the RMT component instead.
Thank you @maik1607, This workaround works for me as well! using Lolin S3mini Home assistant and ESPHome 2023.12.9
The problem
In my kitchen, I want led strips (SK6812) on top of the kitchen cupboards, as well underneath them to shine on the counter. For this situation, I intend to use a single ESP32E configured with two NeoPixelBus platforms each having different GPIO output for each led strip. Unfortunately, I am not getting the desired behavior.
In HA, when I turn on "Kitchen Light Counter" (GPIO13).
The same thing happens when I turn on "Kitchen Light Up" which is, in this case, a good thing since that is the desired strip tied to that entity. After some troubleshooting such as: replacing ESP32 boards and using different GPIO pins, I tried the following scenario:
Instead of making two NeoPixelBus light components, I made just one. In this case, I only used "Kitchen Light Counter" (GPIO13) since it never lighted up in the previous scenario. To my surprise:
While there was technically one GPIO output configured, both led strips on different GPIO pins were turning on.
Finally, I tried to use the FastLed platform to see if the problem persists, but this worked like a charm (however, here I cannot use the white-led channel on the SK6812). Each led strip was controllable per HA entity.
At this point, ssieb (member on discord who helped me with most of the troubleshooting steps) stated that there might be an issue with the NeoPixelBus.
(these are one of my first filed issues on GitHub, feedback welcome)
Which version of ESPHome has the issue?
2021.12.1
What type of installation are you using?
Home Assistant Add-on
Which version of Home Assistant has the issue?
2021.12.5
What platform are you using?
ESP32-IDF
Board
espressif ESP32E development board.
Component causing the issue
NeoPixelBus Light
Example YAML snippet
Anything in the logs that might be useful for us?
No response
Additional information
No response