Repository navigation
feat(read-pico): add MindReset Read Pico support - #10
Conversation
List Read Pico in the firmware and protocol references, correct its font subset record, describe the diagnostic views directly, and document the board and view interfaces. Drop pending-verification remarks from the Bridge, Mosaico and ePaper notes.
Add MindReset Read Pico to the Target Registry without a web flasher entry, and list it in the device, firmware and release references.
|
@codex review |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1e7cb6291c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| read_pico_sd_info_t sd{}; | ||
| v.sd = read_pico_sd_get_info(&sd) == ESP_OK && sd.mounted; |
There was a problem hiding this comment.
Re-probe the SD card after media changes
When the device boots without a card, the one startup probe leaves the SD driver in its completed/unmounted state, and this polling path only calls read_pico_sd_get_info(), which never starts another mount. Likewise, removing a mounted card permanently sets the driver's media_invalidated flag until read_pico_sd_remount() is called. Consequently, inserting or reinserting a FAT card while the firmware is running never enables trend persistence; detect the presence transition here and trigger the remount/probe path.
Useful? React with 👍 / 👎.
| 滚动仅处理图标范围内的纵向事件,触控板惯性滚动不触发翻页,连续操作最多每 200 ms 翻一页。 | ||
|
|
||
| 菜单按已添加的设备显示固件更新项,包含新版提示、等待设备确认、传输百分比和重连状态。点击后下载并校验固件,在桌面确认设备、来源、版本和摘要,再通过蓝牙更新;设备仍需逐次物理确认。下载与桌面确认不占独占连接,期间继续同步用量。macOS OTA 软件流程已接入,实机升级、重连和数据恢复仍待验收。 | ||
| 菜单按已添加的设备显示固件更新项,包含新版提示、等待设备确认、传输百分比和重连状态。点击后下载并校验固件,在桌面确认设备、来源、版本和摘要,再通过蓝牙更新;设备仍需逐次物理确认。下载与桌面确认不占独占连接,期间继续同步用量。 |
There was a problem hiding this comment.
Restore the macOS OTA verification caveat
This deletion removes the only nearby distinction between the implemented macOS OTA software flow and hardware validation, while docs/verification.md still states that macOS OTA for every target remains pending. The remaining paragraph now presents transfer, confirmation, and reconnection as an unqualified supported workflow, so release readers can mistake unverified device behavior and recovery for completed validation; restore the caveat unless corresponding hardware acceptance evidence is added.
AGENTS.md reference: AGENTS.md:L7-L7
Useful? React with 👍 / 👎.
| req->code = code; | ||
| req->payload_length = plen; | ||
| req->session_id = s_snap.boot_id; | ||
| if (payload != NULL && plen > 0) memcpy(req->payload, payload, plen); |
There was a problem hiding this comment.
Reject oversized PMU command payloads
If any caller passes plen > PMU_FRAME_PAYLOAD_SIZE (44), this memcpy writes past pmu_frame_t::payload and corrupts the request's trailing CRC and adjacent stack data before the frame is transmitted. read_pico_pmu_cmd() is a public component API and accepts an unrestricted uint8_t length, so it should reject oversized payloads—and nonzero lengths with a null payload—before calling fill_req().
Useful? React with 👍 / 👎.
356d458 to
1e7cb62
Compare
The SD driver probes once at boot and latches removal until an explicit remount, so a card inserted or reinserted later never enabled trend storage. Request a remount when the card-detect input reports a new card.
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: cd40500f9c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| uint8_t ident[PMU_IDENTITY_SIZE]; | ||
| err = pmu_read_reg(PMU_REG_IDENTITY, ident, sizeof(ident)); | ||
| if (err == ESP_OK) { | ||
| parse_identity(ident); |
There was a problem hiding this comment.
Preserve the successful PMU identity result
s_snap is zeroed at initialization, but the successful identity read discards parse_identity()'s return value, and recover_seq() does the same. Consequently s_snap.identity_ok remains false, s_ready is false at the later readiness check, and every otherwise healthy CW32 is deinitialized as an invalid response; the board then loses factory VCOM, RTC, battery/charging data, and OTA power authorization.
Useful? React with 👍 / 👎.
| ota_partition_bytes=4 * 1024 * 1024, | ||
| ), |
There was a problem hiding this comment.
Add Read Pico to the browser flasher registry
This target leaves web_flash at its None default, so both scripts/export_web_devices.py and scripts/assemble_web_flasher.py explicitly filter Read Pico out of the website device list and firmware manifests. Users following the newly updated Quick Start therefore cannot select this supported model in the advertised web flasher; provide its WebFlashDefinition and asset, or qualify the installation documentation.
Useful? React with 👍 / 👎.
| static bool loaded = false; | ||
| if (!loaded) { | ||
| loaded = true; |
There was a problem hiding this comment.
Reload trend history after an SD-card replacement
After a mounted card is removed and another card is inserted, the remount path restores v.sd, but this process-lifetime loaded flag remains true. The new card's trend.bin is therefore never read; instead the old card's in-memory history is displayed and then written onto the replacement card at the next half-hour sample. Reset or key the loaded state when media changes.
Useful? React with 👍 / 👎.
| used monochrome refreshes: a full refresh on entry and after 20 partial | ||
| updates, with partial refreshes for progress updates; power-loss recovery and rollback | ||
| remain unverified. | ||
| updates, with partial refreshes for progress updates. |
There was a problem hiding this comment.
Restore the ePaper OTA recovery caveat
This verification paragraph only records a normal OTA run, while docs/verification.md still says power interruption, failed-start rollback, and related failure paths remain outstanding for maintained targets. Removing the only target-specific caveat makes those untested device behaviors appear covered by the successful transfer; retain the recovery limitation alongside the observed result.
AGENTS.md reference: AGENTS.md:L7-L7
Useful? React with 👍 / 👎.
| for (int i = 0; i < CST836U_MAX_POINTS; i++) { | ||
| const uint8_t* src = &data[3 + i * 6]; |
There was a problem hiding this comment.
Parse only the touch contacts reported by the controller
When the CST836U reports fewer than two contacts, this loop still decodes both coordinate slots instead of stopping at touch->count. An unused or stale slot whose bytes encode event 0/2 and ID 0/1 is counted as active, so a zero-contact packet can leave touch.touched true and Board::input() never observes the release needed to emit taps or capacitive-key presses; restrict parsing and primary-point selection to the reported active contacts.
Useful? React with 👍 / 👎.
| if (ui.ready()) | ||
| ble.verify_boot(); |
There was a problem hiding this comment.
Do not confirm OTA when panel power-up failed
When a pending image boots but sy7636a_power_on() fails or PGOOD times out, board_poweron() returns without enabling the panel rails, while the subsequent epdiy transfer can still return EPD_DRAW_SUCCESS; ui.ready() then becomes true and this call permanently marks the image valid even though no frame reached the display. Include the rail/PGOOD state in display readiness before calling verify_boot() so a firmware-caused panel power regression can still roll back.
Useful? React with 👍 / 👎.
epdiy reports a successful update when the SY7636A rails failed to power up, which let a pending OTA image be marked valid without a displayed frame. Treat a refresh without rails as failed. Reload the trend history when a card is mounted again so history from a previous card is not written onto its replacement, and note in the Quick Start that Read Pico installs from the release image.
Summary
Add MindReset Read Pico (ESP32-S3, 684 × 1216 sixteen-gray e-paper) as a maintained target.
firmware/targets/mindreset_read_pico(applicationmr_read_pico): Home with both services, alarm states and a 24-hour trend; clock; landscape Home; pairing; OTA progress and confirmation; Display settings; offline state. Usage publication, time synchronization and OTA reuse the shared BLE protocol.MindReset/read_pico_firmwareat28cde68; provenance, licenses and local changes are recorded incomponents/UPSTREAM.mdandTHIRD_PARTY_LICENSES.md.mindreset-read-pico-ota-and-full-images. It has no web flasher entry yet.tools/read_pico/preview/renders the views with the firmware drawing code and checks the touch targets.Validation
idf.py buildformindreset_read_picowith ESP-IDF v6.1 succeeds without changingdependencies.lock.tools/read_pico/preview/run.shbuilds and passes on the host.