Skip to content

Fix AP feedback/toggle, headless binding cues, gating and connect timing - #12

Merged
PSi86 merged 1 commit into
mainfrom
fix/ap-headless-connect-ux
Jun 9, 2026
Merged

PSi86 merged 1 commit into
mainfrom
fix/ap-headless-connect-ux

Conversation

@PSi86

@PSi86 PSi86 commented Jun 9, 2026

Copy link
Copy Markdown
Owner

AP mode:

  • 3-click now toggles the WiFi AP on/off (was open-only) via a shared setApMode() helper, with distinct strobe cues on each transition (IND_AP_ENABLED violet / IND_AP_DISABLED amber). OPC_CONFIG 0x04 reuses the same helper. AP is now closable without a reboot.

Indicators (overlay decoupling):

  • Remove the leftover cancelIndicator() from applyLocalScene(). With the frame-buffer overlay model serviceIndicator() does no segment restore, so a new scene can be written underneath a running overlay and revealed on expiry. This fixes the pair-confirm (slave) and cyan-enter (master) strobes being cut short by the master scene rebroadcast. The interim pendingScene/activeType deferral workaround is removed.
  • Add IND_ACTION_LOCKED: a short orange cue when a local 1-click color cycle or long-press brightness fade is gated because a master is active, instead of silently ignoring the press.

Headless promotion:

  • 5-click promotes immediately (gated by masterContactedRecently()) and sends the normal IDENTIFY_REPLY; an active master/Gateway answers with SET_GROUP and the existing handler reverts us to slave (self-abort). No probe window or jitter. Probe send machinery and HeadlessState probe fields removed.
  • Boot auto-resume is deferred until the normal startup IDENTIFY_REPLY sequence settles: if a master adopts us we stay a slave, otherwise we re-promote.

Startup connect:

  • Second startup IDENTIFY_REPLY now fires 3s after the first is actually sent (was a fixed boot+10s) and only if unanswered.
  • Skip the second attempt entirely if the button was operated since boot (operator wants standalone / headless master, not gateway+master).

AP mode:
- 3-click now toggles the WiFi AP on/off (was open-only) via a shared
  setApMode() helper, with distinct strobe cues on each transition
  (IND_AP_ENABLED violet / IND_AP_DISABLED amber). OPC_CONFIG 0x04 reuses
  the same helper. AP is now closable without a reboot.

Indicators (overlay decoupling):
- Remove the leftover cancelIndicator() from applyLocalScene(). With the
  frame-buffer overlay model serviceIndicator() does no segment restore, so
  a new scene can be written underneath a running overlay and revealed on
  expiry. This fixes the pair-confirm (slave) and cyan-enter (master)
  strobes being cut short by the master scene rebroadcast. The interim
  pendingScene/activeType deferral workaround is removed.
- Add IND_ACTION_LOCKED: a short orange cue when a local 1-click color
  cycle or long-press brightness fade is gated because a master is active,
  instead of silently ignoring the press.

Headless promotion:
- 5-click promotes immediately (gated by masterContactedRecently()) and
  sends the normal IDENTIFY_REPLY; an active master/Gateway answers with
  SET_GROUP and the existing handler reverts us to slave (self-abort). No
  probe window or jitter. Probe send machinery and HeadlessState probe
  fields removed.
- Boot auto-resume is deferred until the normal startup IDENTIFY_REPLY
  sequence settles: if a master adopts us we stay a slave, otherwise we
  re-promote.

Startup connect:
- Second startup IDENTIFY_REPLY now fires 3s after the first is actually
  sent (was a fixed boot+10s) and only if unanswered.
- Skip the second attempt entirely if the button was operated since boot
  (operator wants standalone / headless master, not gateway+master).
@PSi86
PSi86 merged commit 77f8191 into main Jun 9, 2026
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