fix(heltec-v3): powerOff() arms user button + LoRa-DIO1 wake mask#2595
Open
akkerkid wants to merge 1 commit into
Open
fix(heltec-v3): powerOff() arms user button + LoRa-DIO1 wake mask#2595akkerkid wants to merge 1 commit into
akkerkid wants to merge 1 commit into
Conversation
HeltecV3Board::powerOff() called enterDeepSleep(0) with the default pin_wake_btn = -1, so the wake mask armed only LoRa-DIO1. The user button (PIN_USER_BTN) was never armed despite typical long-hold-button- to-hibernate UX prompts expecting it to wake. Mirrors the same fix landed for HeltecV4Board in May 2026 in the downstream meshomatic-conduit-firmware fork (akkerkid/meshomatic-conduit-firmware fix/hibernate-button-only-wake), where this bug shipped to ~80 conduit units before discovery. V3 in upstream carries the identical bug shape today. One-line fix: pass PIN_USER_BTN explicitly. No API changes; the default-arg signature stays. Affected use case: any board class user that calls `powerOff()` expecting both LoRa packets AND the user button to wake the device (the OLED prompt "Tap button to wake" reads that way). Signed-off-by: AkkerKid <akkerkid@meshomatic.net>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
HeltecV3Board::powerOff() calls enterDeepSleep(0) which falls through to the default
pin_wake_btn = -1. The wake mask thus arms only LoRa-DIO1 -- the user button is never armed despite typical long-hold-button-to-hibernate UX (the OLED prompt commonly says "Tap button to wake").Discovery context: the identical bug shape on HeltecV4Board bit our downstream conduit firmware fork (
akkerkid/meshomatic-conduit-firmware) in May 2026 and shipped to ~80 conduit units before we caught it. While porting our conduit feature work to V3 in May 2026 we found V3 carrying the same bug -- mirroring the V4 fix is one line.Fix
variants/heltec_v3/HeltecV3Board.h:Pre-fix:
Scope
enterDeepSleep's existingint pin_wake_btn = -1default stays for any other caller that genuinely wants radio-only wake.variants/heltec_v3/platformio.inivia-D PIN_USER_BTN=0build flag; the symbol is already in scope in HeltecV3Board.h. Verified locally withbuild.sh build-firmware Heltec_v3_repeater-- SUCCESS, 20.78s.Happy to address review feedback. Filed with DCO sign-off.