Add Philips Hue V2 API usermod with auto-detected TLS backend#10
Draft
Add Philips Hue V2 API usermod with auto-detected TLS backend#10
Conversation
Co-authored-by: netmindz <442066+netmindz@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add usermod for Phillips Hue V2 API
Add Philips Hue V2 API usermod
Mar 13, 2026
- Auto-detect TLS: WiFiClientSecure → NetworkClientSecure → BearSSL - Remove old usermod_hue_v2.h (duplicate of PhilipsHueV2.cpp) - Remove accidentally committed generated files (js_iro.h, js_omggif.h) - Update readme with BearSSL and official platform build instructions Co-authored-by: netmindz <442066+netmindz@users.noreply.github.com>
Copilot
AI
changed the title
Add Philips Hue V2 API usermod
Add Philips Hue V2 API usermod with auto-detected TLS backend
Mar 13, 2026
Owner
|
@copilot something has gone very wrong. The only change to const.h should be the usermod ID, but nothing else really Despite my prompts saying to confirm your base on the branch by the absence of the usermod_list.cpp your PR includes charges to this file |
Only change to const.h is the single usermod ID line. Removed all spurious changes from the MM branch that were incorrectly included. usermods_list.cpp is no longer modified. Co-authored-by: netmindz <442066+netmindz@users.noreply.github.com>
Author
Fixed in |
Add artifact upload step for firmware binaries.
This reverts commit dd26d44.
… and improve error logging
…t discovered lights, optimize memory usage, and improve connection backoff logic.
…ve TLS client management, enhance error logging, and update documentation with new features and troubleshooting steps.
…pdates, refactor JSON parsing, improve error handling, and enhance configuration management.
…mod, enhance configuration behavior, and improve status reporting.
…mod, enhance configuration behavior, and improve status reporting.
…tial timeout, adjusting idle timeout, and ensuring complete data read.
…havior, implement configurable auto-reconnect, and enhance error logging.
…racy, ensure proper scaling, and apply gamma correction.
…quivalents, deferred effect application, and updated documentation.
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.
WLED only supports Philips Hue via the deprecated V1 API. This adds a usermod that uses the CLIP V2 API (HTTPS) to poll a Hue bridge and sync on/off, brightness, and color (CIE xy + mirek CT) to WLED.
Core implementation
usermods/PhilipsHueV2/PhilipsHueV2.cpp— polls a single light resource, applies state viacolorUpdated(), supports link-button auth flow that persists the API key to configUSERMOD_ID_PHILIPS_HUE_V2(57) inwled00/const.h— single line addition, no other changes to the fileREGISTER_USERMODTLS backend auto-detection
The V2 API requires HTTPS. The Tasmota-based platform used by WLED strips
WiFiClientSecure, so the usermod detects available TLS at compile time via__has_include:NetworkClientSecure(arduino-esp32 v3.x)WiFiClientSecure(officialespressif32platform)ArduinoBearSSL(any platform, smaller than native mbedTLS)Build
BearSSL alternative for Tasmota platform:
Cleanup
usermod_hue_v2.h(was a duplicate of the.cpp)js_iro.h,js_omggif.h)wled00/const.hto match upstream main exactly (only the usermod ID line added)wled00/usermods_list.cppto original state (no modifications)Original prompt
📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.
Summary by cubic
Adds a Philips Hue V2 usermod that syncs WLED with a Hue bridge over HTTPS with auto-detected TLS, with optional plain HTTP. Adds real-time SSE updates, mDNS bridge discovery, link-button auth, light discovery/selection, and Hue effect mapping to WLED FX.
New Features
/clip/v2/resource/light, saved to/hue_lights.json(up to 16); settings dropdown and selected light name in Info.NetworkClientSecure/WiFiClientSecureorArduinoBearSSL; opt-in plain HTTP by prefixinghttp://; link-button auth to obtain an app key with polling fallback.Refactors
WiFiClienttransport and heap-allocated TLS clients with timeouts, reduced buffers, non-blocking reads, better error logging/backoff to reduce socket errors.USERMOD_ID_PHILIPS_HUE_V2added), and fixed Create usermod for Phillips Hue V2 API #9.Written for commit 0d25264. Summary will update on new commits.