Skip to content

extmod/modbluetooth: Add gap_indicate_service_changed. #8027

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

andrewleech
Copy link
Contributor

@andrewleech andrewleech commented Nov 24, 2021

This function triggers an indication on the GATT service changed characteristic.
The matching change in aioble can be found micropython/micropython-lib#467

Requires extra nimble feature at this stage: apache/mynewt-nimble#1112

I've added some extra notes to the docs to cover some idiosynchacies seen in phone (iOS / android) usage of this feature:

    Note: with an iOS client it's been seen that if this function is called greater than ~100ms 
    after a new connection is established the connection can be dropped, or the characteristics
    covered by the declared range will lock up and be no longer readable, so it's important to 
    send this command within the first few ms after a connection is made.

    Alternatively, it appears that if the start and end handles are both set to ``0x0000``, 
    the lock-up doesn't occur regardless of when the call is made. Android clients appear to 
    accept the null handles as a re-discover all, though the BLE spec makes no mention of this.

@andrewleech andrewleech force-pushed the bluetooth_service_changed branch from 81fa207 to 7444b7a Compare November 24, 2021 23:03
@codecov-commenter
Copy link

codecov-commenter commented Nov 24, 2021

Codecov Report

Merging #8027 (2f11cb3) into master (30b6ce8) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #8027   +/-   ##
=======================================
  Coverage   98.47%   98.47%           
=======================================
  Files         153      153           
  Lines       20145    20145           
=======================================
  Hits        19838    19838           
  Misses        307      307           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 30b6ce8...2f11cb3. Read the comment docs.

@andrewleech andrewleech force-pushed the bluetooth_service_changed branch 2 times, most recently from 59572d9 to d4dcd95 Compare November 25, 2021 06:31
@dpgeorge dpgeorge added the extmod Relates to extmod/ directory in source label Nov 29, 2021
@andrewleech andrewleech force-pushed the bluetooth_service_changed branch from d4dcd95 to 2f11cb3 Compare January 24, 2022 00:41
@andrewleech andrewleech force-pushed the bluetooth_service_changed branch from 2f11cb3 to c0adf9e Compare August 24, 2022 09:08
This function triggers an indication on the GATT service
changed characteristic.
@projectgus
Copy link
Contributor

This is an automated heads-up that we've just merged a Pull Request
that removes the STATIC macro from MicroPython's C API.

See #13763

A search suggests this PR might apply the STATIC macro to some C code. If it
does, then next time you rebase the PR (or merge from master) then you should
please replace all the STATIC keywords with static.

Although this is an automated message, feel free to @-reply to me directly if
you have any questions about this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
extmod Relates to extmod/ directory in source
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants