Skip to content

chore: merge main into multicore task architecture - #210

Merged
stritti merged 27 commits into
feat/multicore-task-architecturefrom
main
Oct 1, 2026
Merged

stritti merged 27 commits into
feat/multicore-task-architecturefrom
main

Conversation

@stritti

@stritti stritti commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Temporary integration PR to update #170 (feat/multicore-task-architecture) with the current main. This PR will be merged into the feature branch and then closed automatically by the merge.

dependabot Bot and others added 27 commits August 1, 2026 21:44
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 6 to 7.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](actions/setup-python@v6...v7)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4 to 4.37.3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](github/codeql-action@v4...v4.37.3)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.37.3
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 4.37.4 to 4.37.6.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](github/codeql-action@v4.37.4...v4.37.6)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.37.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* docs: add olimex c6 local ui concept

* docs: refine olimex local ui display concept

* docs: verify olimex local ui power compatibility

* docs: make olimex display configuration flexible

* docs: add olimex local ui implementation plan

* docs: adjust olimex implementation pin defaults

* build: add olimex esp32-c6 board variant

* build: use pioarduino for olimex c6 arduino

* build: pin onewire for esp32-c6 compatibility

* build: use adafruit tft libraries for c6

* fix(build): add explicit cstdint include

* fix(build): support esp32-c6 arduino compatibility

* build: pin pioarduino platform release

* feat(ui): add local settings menu state machine

* feat(ui): add ky040 encoder input handling

* feat(ui): add olimex tft display wrapper

* fix(ui): use adafruit tft wrapper on olimex

* fix(ui): initialize olimex tft spi pins

* fix(ui): use st7789 init for olimex tft

* feat(ui): wire olimex local tft interface

* fix(ui): include olimex local ui wiring

* docs: add olimex local ui bring-up guide

* docs: clarify olimex local ui bring-up

* chore: remove sdd scratch report

* docs: add olimex board reference links

* docs: add olimex references to skills

* style: format olimex local ui sources

* fix(ui): address olimex local ui review comments

* ci: add olimex c6 platformio matrices

* fix(ui): implement local menu actions

* fix(ui): refresh olimex live pages safely

* fix(ui): show active mode and ap address
…178)

* chore(ci): optimize GitHub Actions workflows with caching and dedup

- Add composite action .github/actions/setup-platformio centralizing
  Python setup, PlatformIO install, and cache restore/save
- Use composite action in PlatformIO CI, native tests, CodeQL,
  dependency check, and release workflows (removes 6x duplicated setup)
- Merge platformio-update-check into pio-dependency-check with cache
  and working issue creation (steps.outdated.outcome instead of
  never-triggering if: failure())
- Remove unnecessary checkout from auto-merge-release (gh pr merge
  needs no repository)
- Add concurrency cancel-in-progress to MegaLinter workflow
- Drop redundant job-level permissions (already at workflow level)

* fix(ci): supply repository context to gh pr merge in auto-merge workflow

Without a checkout there is no git remote for gh to resolve the
repository. Pass --repo explicitly so auto-merge works without
re-adding the checkout step.
Bumps [oxsecurity/megalinter](https://github.com/oxsecurity/megalinter) from 9.6.0 to 10.0.0.
- [Release notes](https://github.com/oxsecurity/megalinter/releases)
- [Changelog](https://github.com/oxsecurity/megalinter/blob/main/CHANGELOG.md)
- [Commits](oxsecurity/megalinter@v9.6.0...v10.0.0)

---
updated-dependencies:
- dependency-name: oxsecurity/megalinter
  dependency-version: 10.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* feat(system): log concrete reason when entering safe mode

Safe-mode entry now logs the specific cause instead of a generic message:
boot-loop (forced), critically low free heap, or a breakdown of the
concurrent failures (WiFi, NTP, sensor). Priority mirrors evaluateLevel()
decision logic.

* style(system): fix clang-format line join in safe-mode reason log

* fix(system): gate NTP reason on wifi availability in safe-mode log

NTP loss while WiFi is down is a consequence, not an independent
failure — evaluateLevel() only counts it when WiFi is up. Mirror that
condition in the safe-mode reason breakdown so the diagnosis matches
the actual failure accounting.

Addresses PR #179 review comment.

Reviewed-by: Codex
* docs: add NORVI button calibration design spec

* docs(calibration): add implementation plan for button calibration

* feat(calibration): add CalibrationManager state machine with measurement

* test(calibration): cover threshold computation and error paths

* feat(calibration): suppress button actions during calibration

* feat(calibration): add REST endpoints for calibration wizard

* feat(calibration): add guided calibration wizard to web UI

* style(calibration): apply clang-format to CalibrationManager

* style(calibration): fix clang-format and trailing newlines for CI

* docs(calibration): fix trailing newlines for editorconfig CI

* fix(calibration): accept exact minimum gap and reject release levels

The wait-phase predicate required a reading strictly above
previousLevel + MIN_LEVEL_GAP and also accepted readings far below it.
Hardware whose adjacent button levels sit exactly 100 ADC counts apart
could therefore never advance past the wait phase, while releasing a
button (ADC dropping back toward the resting level) was mistaken for the
next button level and produced non-ascending thresholds.

Accept only readings at least MIN_LEVEL_GAP above the previous level
(inclusive), matching the validation boundary in computeThresholds().

Addresses PR #182 review comments.

* fix(calibration): space ADC samples across the intended window

The sample phase collected all 20 readings within a few loop iterations
because it had no time gate, so correlated noise or the transient right
after a button press could be averaged into a calibrated level. Gate each
sample on SAMPLE_INTERVAL_MS so the readings span the documented one-second
window.

Addresses PR #182 review comment.

* fix(calibration): preserve settings in memory when persistence fails

The new thresholds were written into the live Settings before
ConfigManager::save() ran, so a failed save left the failed values active
in memory even though calibration reported ERROR. Snapshot the previous
thresholds, commit the new ones, and restore the snapshot when save()
fails so the old thresholds stay untouched.

Addresses PR #182 review comment.

* fix(buttons): suppress callbacks until release after calibration

When calibration reaches DONE while Button 3 is still held, isActive()
immediately becomes false and the handler starts processing that same
held press, firing the S3 callback (which can toggle the pool pump)
before the UI can report completion. Arm callback suppression on the
calibration-finish transition, reset press tracking, and keep callbacks
disabled until the ADC returns to the no-press range for the debounce
interval.

Addresses PR #182 review comment.

* fix(web): hide calibration wizard on non-NORVI firmware

The LittleFS web assets are shared across all build environments, but the
/api/calibrate/* routes are compiled out unless NORVI_AE01_R is defined.
Report NORVI support in /api/status and hide the calibration button on
targets without it, so the wizard is no longer exposed with a start
request that always 404s.

Addresses PR #182 review comment.

* fix(calibration): restart sampling when the level stops matching

The sample phase accumulated all 20 readings without validating them, so
releasing the button or a large ADC transition mid-window produced a mixed
average (e.g. ten S1 readings at 3400 plus ten resting readings at 2700
yield 3050) that could pass the final checks and misclassify the real
button level. Reject any sample that leaves the stability window around
the level accepted in the wait phase and restart the measurement.

Addresses PR #182 review comment.

* fix(web): resume an already-running calibration

After a page reload or a lost start response the calibration stays active
on the device, so the start request returns 409 and the UI only alerted.
Reopen the wizard modal and resume polling on 409 so the user can watch
progress or cancel the orphaned calibration instead of being stuck with
disabled front-panel buttons.

Addresses PR #182 review comment.

* fix(web): avoid duplicate calibration polling loops

Starting the wizard twice before the first request completed created two
polling intervals, overwriting calibPollTimer and leaving an orphan loop
that kept calling loadConfig() after DONE. Clear an existing timer before
starting a new poll loop.

Addresses PR #182 review comment.

* fix(web): keep the wizard open when cancellation is rejected

When the session expired, handleAuthentication() serves the login page
with HTTP 200, so the cancel request was treated as success and the modal
closed while calibration kept running with suppressed callbacks. Verify an
actual API response (non-HTML content type) before closing and surface
re-authentication instead.

Addresses PR #182 review comment.

* fix(calibration): revalidate the averaged level before advancing

Samples may drift within the stability window and yield an average below
previousLevel + MIN_LEVEL_GAP, which later failed the sanity check in
computeThresholds() and aborted the entire wizard. Validate the averaged
level against the previous measurement before storing it; on failure the
step retries instead of advancing. The value is only written to the
status once validation passes.

Addresses PR #182 review comment.

* fix(web): reject login HTML from calibration API responses

handleAuthentication() serves the login page with HTTP 200 on session
expiry, so the start request was treated as success and the wizard opened
while the device stayed idle. Verify the response is an actual calibration
API response before opening, and stop the status poller instead of parsing
the login HTML as JSON.

Addresses PR #182 review comment.

* feat(web): guide calibration wizard through clear step-by-step flow

Make the wizard's flow obvious from the moment it opens:
- Always-visible overview line: four measurements run one after another,
  keep the button pressed until its step turns green.
- 'Next:' line under the current instruction names the upcoming step
  (hold Button 1/2/3, then auto-computed thresholds).
- Start button hint on the dashboard states the expected sequence and
  duration.
- Keep every status text readable: new messages only replace the current
  one after a 1.2 s minimum display time.
- DONE now shows a brief green success state (1.5 s) before the modal
  closes, instead of closing instantly.
- Live ADC meter bar, numbered step progress with checkmarks, and a
  color-coded waiting/measuring/retry state chip (previous iteration).
chore(main): release 5.0.0
chore(main): release 5.0.1
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@stritti
stritti merged commit f8c310a into feat/multicore-task-architecture Oct 1, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant