Skip to content

AutoResearch: wire LPC845-BRK into bash autoresearch harness #3004

Closed

Description

@zackees

Motivation

The LPC845-BRK bring-up is functionally complete (Serial.println, FastLED log pipeline, and JSON-RPC echo round-trip all verified on hardware — see PR notes referencing FastLED/framework-arduino-lpc8xx#24–#29). The next gate is wiring this board into the bash autoresearch harness so the bring-up tests run via the same CI pipeline as ESP32/Teensy boards.

Current blocker

bash autoresearch is hardcoded to examples/AutoResearch/AutoResearch.ino (see ci/autoresearch/phases.py:594). That sketch:

  • Has an @filter requiring board: esp32s3,esp32c6,esp32p4,teensy41,teensy40 AND exclude: memory: low — LPC845 (low-memory ARM) is double-excluded.
  • Depends on RMT / PARLIO / SPI / I2S LED-protocol peripherals that LPC845 simply doesn't have.
  • Drags in FastLED.h, fl::channels::all_drivers.h, fl::RxChannel, fl::Watchdog, etc. — a 100+ KB transitive include graph that won't fit on a 64 KB-flash part.

Two viable approaches

Option A — refactor examples/AutoResearch/AutoResearch.ino to compile-out LED-protocol parts on low-memory targets (preferred)

#ifdef SKETCH_HAS_LARGE_MEMORY-gate the LED matrix testing, keep only the AutoResearchRemote/JSON-RPC infrastructure on low-memory ARM. Same sketch, same bash autoresearch <board> UX, same RPC contract. Requires:

  • Adjust @filter to admit lpc845brk (drop the memory: low exclusion or add a new low_memory_rpc_only mode).
  • Conditional-compile guards around #include <FastLED.h>, AutoResearchTest.h, all driver-specific tests.
  • Keep AutoResearchRemote.h (or a slimmed version) for the JSON-RPC echo / RPC dispatch.
  • Validate against the LPC845 RPC echo round-trip from the bring-up sketch (ci/tmp/lpc_val/lpc_val.ino in the work tree as of this issue's filing).

Option B — board-dispatched sketch (faster, less elegant)

Allow phases.py to pick a board-specific sketch directory: examples/AutoResearchLpc/ for lpc845brk, examples/AutoResearch/ for everything else. New sketch needs the FL_AGENT_ALLOW_NEW_EXAMPLE directive. Splits the CI compile matrix; means two harnesses to maintain.

Success criteria

The integration is complete when:

  1. bash autoresearch lpc845brk builds, flashes, and runs cleanly on a connected LPC845-BRK without errors.
  2. The harness verifies — via the same JSON-RPC mechanism used by other boards — that:
    • Serial.println() reaches the host
    • The FastLED log pipeline (FL_DBG/FL_WARN/fl::println) reaches the host
    • JSON-RPC echo round-trip succeeds (host sends {"jsonrpc":"2.0","method":"echo","params":[N],"id":I}\n, device responds with REMOTE: {"id":I,"result":N,"jsonrpc":"2.0"}\r\n)
  3. The sketch fits within LPC845's 64 KB flash budget (currently a tight squeeze — see fl::json: replace double with templated fixed-point variant to drop libgcc soft-FP bloat on embedded #3002 for the fl::json refactor that would give comfortable margin).
  4. CI matrix includes lpc845brk (added to whatever workflow runs the existing AutoResearch matrix).

Related

🤖 Filed via Claude Code during LPC845 bring-up. Functional bring-up is proven on hardware; this issue tracks the harness-side wire-up.
EOF
)

Activity

  1. zackees commented on Jun 14, 2026

    @zackees
    MemberAuthor

    Closing — items 1–3 of the success criteria are functionally complete via merged PRs:

    End-to-end verified on real LPC845-BRK on COM10:

    TX: {"jsonrpc":"2.0","method":"echo","params":[4242],"id":1}
    RX: b'FL_WARN: echo invoked\r\nREMOTE: {"id":1,"result":4242,"jsonrpc":"2.0"}\r\n'
    
    ✅ Serial.println — REMOTE: response received
    ✅ JSON-RPC echo — sentinel 4242 round-trip verified
    ✅ FL_WARN_LIT — FastLED warn pipeline reached host
    

    Flash footprint after #3014 + #3016: text = 62.16 KB / 64 KB (~1.8 KB headroom).

    Item 4 (CI matrix entry) is deferred. The default ci-compile.py path is PlatformIO-based and doesn't yet support LPC845 (the LPC platform is fbuild-only). Wiring a CI job that invokes fbuild against examples/AutoResearchLpc is its own piece of CI infrastructure work — separate from this issue's primary "bring up the harness against the LPC845 board" gate, which is done. If there is desire to track that CI matrix wiring, please file a dedicated issue; this one is closed because the on-host autoresearch flow against a connected LPC845 is verified working.

  2. moved this from Triage to Done in FastLED Trackeron Jun 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions