Having some trouble with LEDs blinking. Hoping you smart folks here can help me solve it. The blinking doesn’t happen when I just set it to one solid color. But when I set it to any animation it starts blinking.
Looks like the blinking is worse farther along the length, making me think the Data signal is getting too weak. Does that happen? I’ve had 10 strings attached to a different controller without seeing this problem. I’m using a D1 mini/ESP8266 controller for this one.
These are 12v 2811 LEDs. 7 strings of 50 LEDs, so 350 total. I’ve boosted the 12v along the length, so there is plenty of voltage for the lights. There’s no dimming toward the end.
I had this problem myself with an ESP8266. I spent some time reading the bugs on Github and found a couple of fixes. AIUI, this is related to interrupts on the ESP8266. Neither of these “fixes” below are really the right way to go about it, but they work so probably good enough.
The Easy Way:
Before the "#include “FastLED.h” line in your sketch add:
#define FASTLED_INTERRUPT_RETRY_COUNT 0
In my testing this allows wifi to still work, the watchdog didnt seem to timeout (but I didnt test this very much) and the flickering is gone.
The Harder Way:
Change the timeout settings in ~/Arduino/libraries/FastLED/platforms/esp/8266/clockless_esp8266.h
Around line 21 in that file you should see:
template <int DATA_PIN, int T1, int T2, int T3, EOrder RGB_ORDER = RGB, int XTRA0 = 0, bool FLIP = false, int WAIT_TIME = 5>
Change that WAIT_TIME to 18.
You then don’t need to use the FASTLED_INTERRUPT_RETRY_COUNT from the easy option. You do need to recompile everything in order for this change to take effect. An easy way to do this is change the board to, say, Arduino Pro Mini, and rebuild. It will fail, but that’s OK. Then change the board setting back to your ESP8266 and build again. That will force it to rebuild the libraries as well.
If you’re doing it the easy way. You should also add WiFi.setSleepMode(WIFI_NONE_SLEEP);
at the top of the setup function to prevent WDT resets and/or flakey WiFi connections.
@Justin_Aden Are you updating this via OTA or do you have any arduinoOTA implemented? I had a similar looking strands and disabling interrupts still did not fix the issue but I am using OTA firmware updates since the controller is in my attic.
@Joe_Schalk I have not been using OTA. I just got it working on a test strip. Haven’t used it on my main lights yet so I can’t comment on flickering.
Someone else told me they used a shielded wire for the data line and stopped his flickering.
Good luck.