Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

implemented external LED power control #41

Merged
merged 3 commits into from
Aug 26, 2023

Conversation

phil535
Copy link
Contributor

@phil535 phil535 commented Aug 19, 2023

Description

This enhancement implementes a mechanism to power off the LED power source using an external pin.
The mechanism is triggered 5 seconds after no serial data is received.

This feature is mainly implemented due to power saving. 60 WS2815 RGB LEDs have an idle power consumption of 0.12A on 12V. Which is ~1.5W of power when they are not in use (only 12V active).

Tested

  • ESP32-WROOM-32
  • WS281x_RGB
  • HyperHDR 19.0.0.0

Potential issues

For static color light the refresh rate has to be non zero value. Otherwise no serial data will be transmitted and the LEDs will turn off.

Is this an issue with the configuration as the readme shows a refresh rate of 0?

@awawa-dev
Copy link
Owner

Added caching for digitalWrites because they are not completely for free. For esp32 (but not esp32-S2) the "handshake" option in HyperHDR resets the board and the relay pin immediately goes low. This can be undesirable if the LED driver is turned off/on in a short time without waiting for the 5 second timeout, so for esp32 (and esp32 only) you can disable "handshake" in Adalight's HyperHDR settings. "Continues output" in the smoothing should be rather used to counter turning off relay control for static colors, because enabling additional timer directly in LED driver could lead to some side effects and should be avoided.

@awawa-dev awawa-dev merged commit 88ed3c9 into awawa-dev:master Aug 26, 2023
@phil535
Copy link
Contributor Author

phil535 commented Aug 27, 2023

Thanks for the adjustments and the merge.

It works like a charm :)

Very nice work!

@phil535 phil535 deleted the powercontrol branch August 27, 2023 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants