M5Stamp LED Test Not Working Well
-
I’m working with an M5Stamp Fly drone running an ESP32-S3, trying to verify that my custom firmware properly controls the onboard WS2812 LED. I’ve written minimal FastLED code to blink the LED red and blue repeatedly. After flashing and erasing the flash completely, the LED blinks correctly for a short time, including across battery power cycles. However, after some minutes or power cycles, the LED stops responding and stays off, although the blue status LED remains on. This suggests the firmware runs initially but then stops updating the LED, possibly due to resets, watchdog triggers, or power instability. I could use some guidance on diagnosing why my minimal code works only briefly after flashing and then stops, and whether there are common pitfalls on the M5Stamp Fly or ESP32-S3 that could cause this intermittent behavior.
#include <FastLED.h> #define PIN_LED_ESP 21 CRGB leds[1]; void setup(){ FastLED.addLeds<WS2812, PIN_LED_ESP, GRB>(leds, 1); FastLED.setBrightness(50); } void loop(){ delay(3000); leds[0] = CRGB::Red; FastLED.show(); delay(500); leds[0] = CRGB::Blue; FastLED.show(); delay(500); } -
Correction: The LED doesn't blink, it stays on continuously.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login