WS2811+ESP32 intermittent dropouts

TL;DR

Experiencing unstable behaviour - device drops out from Home Assistant, web interface is not available during the downtimes, intermittent ping. When the setup is not glitching, everything works perfectly fine - colours, brightness, animations.

Question: What should I try next to help troubleshoot the issue? My money is on the power supply and I’ll try the LED power cap next whilst I wait for the level shifter parts to arrive.

Hardware

Setup description

I converted two super cheap corner LED stands to run WLED firmware using the spare ATOMs I had lying around. This is my first project and I had a bit of fun putting it together. Worked fine “in the lab” but when I installed them in the bedroom behind the bed, I could not even load up the web interface. Blaming WiFi, I bought another access point for the bedroom. The wifi theory was supported by my better half complaining about the reception.

The new AP (Thanks Unifi!) made reception much better, the device was usable. After a week, I noticed that both of the devices would sometimes glitch out, but one more than the other. The one with more issues (Jess LED) was the one further away from the AP. And by further away I mean 2.2m as opposed to 20cm.

Worth noting that a bunch of other ESP devices in the household had no wifi issues at all, notably the in-wall Shelly relays.

I have eliminated the controller itself from being the issue by trying out 5 different ones. In fact I even flashed two controllers with ESPHome and sat them down next to the LED controllers to track their RSSI. The testers’ signal was inline with what I am seeing from the WLED devices, but much more stable. Note that the testers were running off their own power supplies.

Problem description

Basically the light is sometimes unresponsive to commands. We have everything set up in scenes in HA and controlled by Google Home. The lights sometimes fail to turn on, turn off, change colour, or respond to preset changes. During those times ping is patchy and the web interface doesn’t load, loads halfway, or fails to perform commands. I tracked the device status and RSSI in a dashboard, see screenshots. Eventually the light comes back, after 5-10 minutes of downtime.

My hypothesis

Given that the strip renders colour and effects properly, I don’t think this is a data line issue. I’ll get the level shifters anyway, but I suspect this won’t fix the stability issues. I am hoping that this is a noisy power supply issue with a cheap 12V 2A power brick that came with it and the step-down buck that I added. Given the outage frequency is correlated to the LEDs being on, my money is on power.

I am planning on tackling the following steps in order to try to get to a resolution. Thoughts?

  1. Add LED strip power line cap (1000 uF)
  2. Add a level shifter
  3. Use a different buck (which one???)
  4. Use a different 12V power supply
  5. Try a different controller? (toss up between NodeMCU and Wemos)
  6. Get a Philips Hue LED strip (j/k, never!)

Pics

WLED Web interface during an outage (when it loads).

Ping response

Last two hours of status/RSSI

Last 24 hours of status/RSSI

What HA sees during the outages

Perhaps a simple test to see if it’s power related - try to run all your LED’s at no more than 25% brightness. Should drastically reduce the load on both the 12V and buck converter.

Unfortunately if you have a power issue, it could be either or both those units. 132 LED’s means max power ~40W => 5V @ 8A. Your buck converter may be overheating under some conditions and/or the 12V brick is being overloaded as well. You might try rigging a separate 5V supply just for the MCU (make sure your grounds are common) so that the MCU is guaranteed good power.

1 Like

Thanks @divsys. I will try separate power supply for the controller. This is definitely going beyond my comfort zone of mixing power supplies. I understand the theory of joining GND and not +ve terminals, but it’s not something I’ve done before.

Given that the strip is 12V, the buck is only powering the controller, so it’s definitely not short on power. I guess I suspect it’s the power quality? If that’s even a thing.

I’ve done a bunch of other tests and changes and the results are annoyingly inconclusive.

First of all, I rewired one of the stands with a fuse and a capacitor. Plugged it in - works in the lab, not in the bedroom. Turned it off at the wall last night and turned it on this morning. It’s been stable today. I think that it’s more to do with me moving the access point though…

The ESPHome testers ran for 24 hours and haven’t skipped a bit. I reflashed them with WLED and one has been stable for more than 24 hours (on the “bad” side of the room), and the other one basically refuses to stay connected full stop. So I don’t know what to make it of :man_shrugging:

Got some NodeMCU units on the way, let’s see how that goes. At this point I don’t think I can trust the Atoms. Way too unreliable.

Also, I reviewed the install steps and I didn’t do the bootloader bit with esptool as per the instructions here - is this necessary? I just used the web flasher for all my installs.

I’ve personally had good success with the webflasher and that’s typically my first install method.

On the PS issue I missed that the LED’s are 12V so that should let the buck converter off the hook.
12V 2A is still somewhat “light” in my guesstimation for the worst case of driving that many LED’s so that might be worth an upgrade.

As far as dedicated MCU power, you could use a 2nd 12v PS just driving the MCU converter, that way the LED power draw doesn’t affect the MCU. Might be worth a try to eliminate a variable.