Skip to content

F-39: NVS writes on the LVGL task #42

Open

Description

@bazauto

Severity: LOW · Effort: Small · Batch: 5 · Status: Code done in #21 (29b54d2), awaiting bench verification

Found in the second full review of the firmware. Recorded with the rest of the pass (F-19…F-44) in docs/REVIEW_REMEDIATION_PLAN_2.md, which is where its status is kept.

JmriConfigScreen::saveSettings, the orchestrator screen's save and saveSpeedSteps still
write NVS from event handlers, against F-05's rule.

Progress: the JMRI settings are now saved by JmriConnectionController on its own task
(batch 3, F-34). Batch 5 moved the rest.

Acceptance Criteria

  • SettingsWriter — one task, settings_writer, and a queue — carries out every NVS
    write the UI asks for, in order: speed steps, the transport choice, the orchestrator
    settings, WiFi Forget, and the JMRI settings under the orchestrator (replacing the
    one-shot jmri_save task).
  • The orch read-modify-writes happen on the writer, so a transport change and an
    orchestrator Save moments apart cannot overwrite each other with stale copies (the
    transport choice's own save was a fourth NVS write on the LVGL task, not listed above).
  • The orchestrator screen's Connect posts the supervisor's wake-up behind its save, so
    the login reads what was just typed.
  • Bench: change speed steps and leave the screen at once; the new value applies. Save
    orchestrator settings, then Connect; the login uses them. Forget WiFi.
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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions