Docs: New strategy for dedicated WLED configuration and LED testing tool
Outlined a new strategy to create a standalone tool for WLED configuration retrieval and interactive LED testing, addressing previous challenges with programmatic access and LED mapping.
This commit is contained in:
parent
113d5b53fa
commit
bdd9e2982d
@ -215,4 +215,42 @@ To improve the diagnostic script, we can:
|
||||
|
||||
1. **Fetch `json/info`:** Use `web_fetch` to get the `json/info` from the WLED device.
|
||||
2. **Extract `leds.count` and `info.udpport`:** Parse the JSON response to get the total LED count and the configured UDP port.
|
||||
3. **Use extracted values:** Use these values in our diagnostic flashing commands, potentially overriding user-provided `-p` or providing a default `count` for `--flash`.
|
||||
3. **Use extracted values:** Use these values in our diagnostic flashing commands, potentially overriding user-provided `-p` or providing a default `count` for `--flash`.
|
||||
|
||||
## Confirmed WLED Configuration
|
||||
|
||||
* **IP Address:** `192.168.178.69`
|
||||
* **Total LEDs:** `181`
|
||||
* **UDP Port for Realtime Data:** `21324`
|
||||
|
||||
## New Strategy: Dedicated WLED Configuration & LED Testing Tool
|
||||
|
||||
**Goal:** Create a standalone tool that can reliably connect to a WLED device, read its configuration, save it, and provide interactive LED testing (flashing in steps/batches).
|
||||
|
||||
**Phase 1: WLED Configuration Retrieval**
|
||||
|
||||
* **Step 1: Implement WLED Configuration Client (C++):**
|
||||
* Create a new C++ class (e.g., `WledConfigClient`) that focuses solely on interacting with the WLED JSON API over HTTP.
|
||||
* This client will be responsible for making GET requests to endpoints like `/json/info` and parsing the JSON response.
|
||||
* It will handle potential network errors and provide clear feedback.
|
||||
* **Step 2: Create a Command-Line Tool for Configuration Retrieval:**
|
||||
* Develop a new executable (e.g., `wled_config_tool`) that uses `WledConfigClient`.
|
||||
* This tool will take the WLED IP address as a command-line argument.
|
||||
* It will attempt to retrieve the WLED configuration (total LEDs, UDP port, segment info if available) and print it to `stdout`.
|
||||
* It will also have an option to save this configuration to a file (e.g., `wled_config.json`).
|
||||
|
||||
**Phase 2: Interactive LED Testing**
|
||||
|
||||
* **Step 3: Integrate LED Testing into `wled_config_tool`:**
|
||||
* Extend `wled_config_tool` to include functionality for flashing LEDs.
|
||||
* It will reuse the `WledClient` (or a modified version of it) to send DNRGB packets.
|
||||
* The tool will take arguments for `startIndex`, `count`, and `color`, similar to our previous `--flash` attempt.
|
||||
* It will use the retrieved WLED configuration (total LEDs, UDP port) as defaults or for validation.
|
||||
* **Step 4: Interactive Flashing and Mapping:**
|
||||
* You will run `wled_config_tool` with flashing commands.
|
||||
* You will report which physical LEDs illuminate, and we will use this to build a precise mapping of LED indices to physical locations.
|
||||
* This mapping will be documented in `lessons_learned.md`.
|
||||
|
||||
**Phase 3: Integrate into HyperionGrabber**
|
||||
|
||||
* **Step 5: Refine `HyperionGrabber`'s LED Mapping:** Once the LED mapping is definitively established and documented, we will integrate this knowledge into `HyperionGrabber` to correctly sample screen regions and send data to WLED.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user