Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BLE: Add GapPairingNone support #3596

Merged
merged 3 commits into from
Apr 18, 2024
Merged

Conversation

Willy-JL
Copy link
Contributor

@Willy-JL Willy-JL commented Apr 17, 2024

What's new

  • Previously, GapPairingNone did not do any setup, so it kept the config from previous configured pairing mode
  • Having a pairing mode in API that doesn't do anything and doesn't really work is also confusing to the user, since now BLE Profiles can set custom GapPairing values
  • This adds support for GapPairingNone, in the sense that it will try to show a simple Yes/No prompt (with no PIN code shown), or fall back to basic PIN code confirm
  • This is supported on iOS (gotta love iOS' "security"), it will show simply '"Device Name" would like to pair with your iPhone' 'Cancel' 'Pair', the Flipper will not show any on-screen prompt
  • Android and basically everything else that doesn't accept "Just works" pairing will fall back to showing a PIN code and asking to confirm Yes/No if it matches the one on Flipper
  • This code and idea was originally from @yocvito, I ported it to the new BLE API and did some further testing

Verification

  • No example app available for OFW yet, can test by modifying any BLE app to use GapPairingNone mode
  • Test pairing on iOS, should show simply "Pair" or "Cancel", without any PIN code (tested on iOS 14.4.2, should work on newer too)
  • Test pairing on Android and other devices, should fall back to PIN code Yes/No

Checklist (For Reviewer)

  • PR has description of feature/bug or link to Confluence/Jira task
  • Description contains actions to verify feature/bugfix
  • I've built this code, uploaded it to the device and verified feature/bugfix

@skotopes skotopes merged commit 12112e7 into flipperdevices:dev Apr 18, 2024
11 checks passed
@Willy-JL Willy-JL deleted the gap-pairing-none branch April 18, 2024 01:35
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.

2 participants