Repository navigation
OpenEPaperLink Phase 1: owner-controlled tag push via the AP's local API - #4
Merged
Merged
Conversation
…cal API
TagTinker gains an OpenEPaperLink (OEPL) module that shapes the AP's
documented POST /imgupload request and manages the owner's config and tag
allow-list. This is the FAP-side, fully-testable core; it transmits nothing.
Live push needs the Phase 2 ESP32-bridge frame and a real access point.
Safety model:
- Only tags on APP_DATA/oepl_tags.txt can be targeted; every request build is
gated by tagtinker_oepl_is_allowed().
- No proprietary retail-ESL protocol, no radio, no pairing, no discovery
probing. The owner names their AP and lists their own tags.
- No secrets compiled in: AP host/port and an optional token live in
APP_DATA/oepl.conf, read at runtime, never logged.
Contents:
- oepl/tagtinker_oepl.{c,h}: config loader, owned-tag allow-list, MAC
normalizer, and the /imgupload multipart request builder (pure, testable).
- scenes/tagtinker_scene_oepl.c: read-only status screen with a dry-run
request preview for the first owned tag (no transmission). Reuses the
existing text_box view.
- Wiring: application.fam sources, scene table + enum, a main-menu entry.
- docs/oepl-integration-plan.md: the 6-point plan and the Phase 1/2 split.
Additive only; existing behaviour unchanged. ufbt build passes (Target 7,
API 87.1). Pure logic validated by a host reference test (21/21). The
/imgupload fields (mac, dither, file) are confirmed against the OEPL wiki;
the tag-DB endpoint path stays configurable.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The repo had no unit harness (the earlier tests/ was removed in f144730). This adds one that compiles the REAL oepl/tagtinker_oepl.c off-device against stub furi/storage headers, so it needs no Flipper SDK or hardware and runs in CI. - test/oepl_test.c: 24 checks over MAC normalization, config + owned-tag allow-list loading (from test/fixtures/), the allow-list safety gate, and the exact POST /imgupload bytes + Content-Length. - test/stubs/{furi.h,storage/storage.h}: minimal stubs; storage is backed by stdio with APP_DATA_PATH rooted at $OEPL_TEST_ROOT so the loaders read fixture files. - test/run_oepl_test.sh: cc/clang/gcc runner (exit 0 = pass). - test/fixtures/, test/README.md. Not part of the FAP build (application.fam lists sources explicitly). The tests transmit nothing and touch no network or radio. Verified: all 24 pass; ufbt build unaffected (Target 7, API 87.1). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Adds .github/workflows/oepl-test.yml — a standalone GitHub Actions workflow that compiles the real oepl/tagtinker_oepl.c against the test/stubs headers and runs test/run_oepl_test.sh on ubuntu-latest (gcc, ~seconds, no SDK). Standalone because the test/ harness and the existing build.yml currently live on different branches; once they share a branch the job can be lifted into build.yml verbatim. Verified locally: the exact CI command exits 0 (24/24). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
Adds owner-controlled OpenEPaperLink (OEPL) support to TagTinker, rebased onto
local-all-fixes. Three commits: the module, its host unit test, and a CI job.What this does
A self-contained
oeplmodule that shapes the OEPL access point's documentedPOST /imguploadrequest and manages the owner's config + tag allow-list, plus a read-only status/preview scene. It transmits nothing — the Flipper has no IP stack, so live push needs the Phase 2 ESP32-bridge frame and a real AP. This is the fully-testable FAP-side core.The AP does all radio and rendering; the Flipper is a UI/controller. No proprietary retail-ESL protocol, no pairing, no radio, no discovery probing.
Safety model
APP_DATA/oepl_tags.txt) can be targeted — every request build is gated bytagtinker_oepl_is_allowed().APP_DATA/oepl.conf, read at runtime, never logged.Contents
oepl/tagtinker_oepl.{c,h}— config loader, owned-tag allow-list, MAC normalizer,/imguploadmultipart request builder (pure, testable).scenes/tagtinker_scene_oepl.c— status screen + dry-run request preview (no send); reuses the existingtext_boxview.application.fam, the scene table/enum, a main-menu entry.test/— a host unit test that compiles the real module against stubfuri/storageheaders (no SDK/hardware)../test/run_oepl_test.sh→ 24/24..github/workflows/oepl-test.yml— runs that test on every PR (ubuntu, gcc, seconds). The repo's first host test; closes the "no test harness" gap.docs/oepl-integration-plan.md— the 6-point plan and Phase 1/2 split.Verification
ufbt buildpasses on the rebased tree (includescustom-size+ OEPL): Target 7, API 87.1, no warnings./imguploadbytes +Content-Length)./imguploadfields (mac,dither,file) confirmed against the OEPL wiki; the tag-DB endpoint path stays configurable.Not in this PR
Additive only; existing behaviour unchanged.
🤖 Generated with Claude Code