fix(ios): wire Wi-Fi config characteristic + actually push creds on Confirm#27
Open
Flo5k5 wants to merge 1 commit intom5stack:mainfrom
Open
fix(ios): wire Wi-Fi config characteristic + actually push creds on Confirm#27Flo5k5 wants to merge 1 commit intom5stack:mainfrom
Flo5k5 wants to merge 1 commit intom5stack:mainfrom
Conversation
…onfirm
Two stub-level gaps in the open-source app prevented the pairing from
ever completing:
1. AppState.swift never maps the E2E5E5E3 (Config) characteristic to
BlufiUtil.writeWifiSetCharacteristic. Without the mapping, any
attempt to sendWifiSetData() early-returns with "No writable
characteristic".
2. BindingDevice.confirmWifi() only flipped the pairingStatus to
DistributionNetwork and then ChangeTheName after a 1s delay,
without ever writing anything over BLE. The firmware never
received the Wi-Fi credentials, the StackChan stayed offline.
Fix:
- Assign writeWifiSetCharacteristic when the E2E5E5E3 characteristic
is discovered during the GATT service scan.
- Serialise {"ssid":..., "password":...} as JSON in confirmWifi and
send it via BlufiUtil.sendWifiSetData before animating the UI
progression. The firmware handler (hal_ble.cpp:
_handle_ble_config_write) parses this exact shape.
Both fixes live on self-host for now; they should also land upstream.
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.
Two stub-level gaps in the open-source app prevented the pairing from
ever completing:
AppState.swift never maps the E2E5E5E3 (Config) characteristic to
BlufiUtil.writeWifiSetCharacteristic. Without the mapping, any
attempt to sendWifiSetData() early-returns with "No writable
characteristic".
BindingDevice.confirmWifi() only flipped the pairingStatus to
DistributionNetwork and then ChangeTheName after a 1s delay,
without ever writing anything over BLE. The firmware never
received the Wi-Fi credentials, the StackChan stayed offline.
Fix:
is discovered during the GATT service scan.
send it via BlufiUtil.sendWifiSetData before animating the UI
progression. The firmware handler (hal_ble.cpp:
_handle_ble_config_write) parses this exact shape.
Both fixes live on self-host for now; they should also land upstream.