Skip to content

MEM button paints optimistically while the model waits for the radio echo #5545

Description

@Ozy311

Summary

The MEM button in the TX applet is a checkable QPushButton, so Qt paints it checked the
instant it is clicked, while the model waits for the radio to echo the change back. If
that echo never arrives, MEM reads lit while memoriesEnabled() is still false.

src/gui/TxApplet.cpp:447-450:

connect(m_memBtn, &QPushButton::toggled, this, [this](bool on) {
    if (!m_updatingFromModel && m_model)
        m_model->setAtuMemories(on);
});

TransmitModel::setAtuMemories() (:440) only emits atu set memories_enabled=N and
latches nothing, which is correct under Principle II. The one thing that re-syncs the
button is syncAtuIndicators() (:679-684), and that runs on atuStateChanged(), i.e.
only when the radio actually reports back.

Why it matters

This is the same optimistic-paint shape #5292 corrected for the sibling ATU button. Its
summary says so directly:

Makes ATU checked state authoritative from model readback rather than the button's
optimistic click toggle.

That change landed for ATU and left MEM as it was.

The practical consequence showed up in #5510: the natural diagnostic question is "is the
MEM button lit?", and on a radio that does not echo, the answer is a misleading yes. The
operator sees a lit MEM and a dead Pre-tune entry, which is unexplainable from the UI.

Status

Latent, not currently biting. Verified on a FLEX-6700 running 26.9.2: the radio
echoes atu status both on sub atu all and on change, so the button and the model
agree there. It would bite on any radio or firmware that does not echo.

Filing it because it is cheap to fix, there is an in-repo precedent to copy, and its
main cost today is making a diagnostic question untrustworthy.


73, Ozy K6OZY - model: claude-opus-5

Activity

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

    GUIUser interfacebugSomething isn't workinggood first issueGood for newcomersmaintainer-reviewRequires maintainer review before any action is takenpriority: lowLow priority

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions