Repository navigation
NanoC6 / NanoH2: switch the RGB LED power on when the LEDs are first used - #389
Merged
Merged
Conversation
…used The RGB LED on these boards is powered through a switch controlled by a GPIO (NanoC6: GPIO19, NanoH2: GPIO10). The LED driver only configured the data pin, so M5.Led never lit anything. The switch pin is a new field of the RMT bus config (pin_power) and is driven high in the bus init, which runs on the first LED access, so a sketch that does not use the LEDs keeps them unpowered. A frame sent right after switching the supply on is lost (0 ms fails, 1 ms works on both boards), so the init waits 5 ms once. release() turns the supply off again.
ainyan03
force-pushed
the
nano_rgb_power
branch
from
October 5, 2026 13:47
101a42c to
94af3dc
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On NanoC6 and NanoH2 the RGB LED is powered through a switch controlled by a GPIO (NanoC6: GPIO19, NanoH2: GPIO10, documented in the PinMap of each board).
M5.Ledonly configured the WS2812 data pin, so the LED never lit on these boards.The switch pin is a new field of the RMT bus config (
pin_power). It is driven high in the bus init, which runs on the first LED access, so a sketch that does not use the LEDs keeps them unpowered (the WS2812 draws a quiescent current even when dark).release()turns the supply off again.A frame sent right after switching the supply on is lost — measured on both boards: 0 ms between the switch and the first frame fails, 1 ms works — so the init waits 5 ms once.
Verification:
M5.Ledas expected, starting from the first frame.