Skip to content

feat(autoresearch): trigger-time input-mux snapshots in the edge probe (#3586) - #3595

Merged
zackees merged 1 commit into
masterfrom
feat/edgeprobe-mux-snapshot-3586
Jul 2, 2026
Merged

zackees merged 1 commit into
masterfrom
feat/edgeprobe-mux-snapshot-3586

Conversation

@zackees

@zackees zackees commented Jul 2, 2026 •

Copy link
Copy Markdown
Member

Extends the edge probe's trigger-time register snapshot with the real RX channel CONF1 (0x1C — the earlier 0x24 read was CH3's reset default) and the FUNC71/72_IN_SEL input-mux routing, captured at the instant the TX waveform is live.

Findings recorded on #3586 with this tooling: input mux, filter, divider, and idle threshold are byte-identical between working and deaf captures at waveform-live time; and WS2811-400 timing (625 ns low gaps) still merges into a single envelope symbol while UART's 490 ns gaps capture fine — the deafness follows the TX driver, not the waveform shape, eliminating electrical/low-pass models.

Host tests + lint clean; C6 compile clean.

Refs #3586.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Bug Fixes
    • Expanded edge-probe RMT live data returned by the remote control API, so callers can now see more live register information.
    • Improved the ESP32C6 edge-probe snapshot to capture additional live register sources, providing more complete diagnostic output.

#3586)

Extend the edge probe's trigger-time register snapshot with the real
RX channel CONF1 (0x1C, not the CH3 default at 0x24) and the
FUNC71/72_IN_SEL input-mux routing, read at the instant the TX
waveform is live on the wire.

Findings recorded on #3586 with this tooling: input mux, filter,
divider and idle threshold are byte-identical between working and
deaf captures at waveform-live time; and WS2811-400 timing (625 ns low
gaps) still merges into a single envelope symbol while UART's 490 ns
gaps capture fine — the deafness follows the TX DRIVER, not the
waveform shape, eliminating electrical/low-pass models.

Co-Authored-By: Claude Fable 5 <[email protected]>
@coderabbitai

coderabbitai Bot commented Jul 2, 2026 •

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The g_rmt_live array in AutoResearchEdgeProbe.cpp was expanded from 6 to 8 entries, with updated register addresses including a new CH2CONF1 source and two additional FUNC signal input registers on ESP32C6. AutoResearchRemoteSystemMethods.cpp was updated to copy 8 entries instead of 6 into the RPC response.

Changes

RMT Live Register Expansion

Layer / File(s) Summary
Expand live RMT register array and captures
examples/AutoResearch/AutoResearchEdgeProbe.cpp
g_rmt_live grows from 6 to 8 volatile entries; ESP32C6 snapshot updates the CH2CONF1 source for index 3 and adds captures for indices 6 and 7 from FUNC signal input registers.
Update RPC read loop to consume 8 entries
examples/AutoResearch/AutoResearchRemoteSystemMethods.cpp
The edgeProbeRead RPC loop now appends 8 rmtLive entries instead of 6.

Estimated code review effort: 2 (Simple) | ~10 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the main change: adding trigger-time input-mux snapshots in the AutoResearch edge probe.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/edgeprobe-mux-snapshot-3586

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@zackees
zackees merged commit 0383419 into master Jul 2, 2026
7 checks passed
@fastled-project-sync fastled-project-sync Bot moved this from Triage to Done in FastLED Tracker Jul 2, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
examples/AutoResearch/AutoResearchEdgeProbe.cpp (1)

29-29: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Consider exposing the snapshot length to avoid a hard-coded cross-file 8.

edgeProbeRmtLive() returns a bare pointer with no length, so consumers must hard-code the element count. AutoResearchRemoteSystemMethods.cpp:364 now iterates k < 8 to match this array — the two literals must be kept in sync manually, and a future size bump that misses one site will either truncate the payload or read past the array. Exposing a compile-time count (or an accessor) keeps both sides in lockstep.

♻️ Sketch: shared count
-volatile fl::u32 g_rmt_live[8] = {0};
+constexpr fl::u32 kRmtLiveCount = 8;
+volatile fl::u32 g_rmt_live[kRmtLiveCount] = {0};

Expose it via the header (e.g. fl::u32 edgeProbeRmtLiveCount();) and use it in the RPC loop instead of the literal 8.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@examples/AutoResearch/AutoResearchEdgeProbe.cpp` at line 29, The edge probe
snapshot size is duplicated as a hard-coded 8, which requires manual syncing
between the array definition and consumers. Expose the snapshot length through a
shared symbol in AutoResearchEdgeProbe (for example, a count accessor or
constexpr) and update edgeProbeRmtLive and the RPC loop in
AutoResearchRemoteSystemMethods to use that shared count instead of the literal.
This keeps the snapshot array and its iteration logic aligned if the size
changes later.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@examples/AutoResearch/AutoResearchEdgeProbe.cpp`:
- Line 29: The edge probe snapshot size is duplicated as a hard-coded 8, which
requires manual syncing between the array definition and consumers. Expose the
snapshot length through a shared symbol in AutoResearchEdgeProbe (for example, a
count accessor or constexpr) and update edgeProbeRmtLive and the RPC loop in
AutoResearchRemoteSystemMethods to use that shared count instead of the literal.
This keeps the snapshot array and its iteration logic aligned if the size
changes later.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: ea9f5b5a-2505-4559-bd59-db6e11b4e5a4

📥 Commits

Reviewing files that changed from the base of the PR and between b852acf and 4d77b29.

📒 Files selected for processing (2)
  • examples/AutoResearch/AutoResearchEdgeProbe.cpp
  • examples/AutoResearch/AutoResearchRemoteSystemMethods.cpp

@zackees
zackees deleted the feat/edgeprobe-mux-snapshot-3586 branch August 21, 2026 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant