From 3b6c9119eb3593d9a3af8474d7186541f08d849e Mon Sep 17 00:00:00 2001 From: Damien George Date: Fri, 8 May 2020 13:54:10 +1000 Subject: extmod/modbluetooth: Add support for changing the GAP device name. This commit allows the user to set/get the GAP device name used by service 0x1800, characteristic 0x2a00. The usage is: BLE.config(gap_name="myname") print(BLE.config("gap_name")) As part of this change the compile-time setting MICROPY_PY_BLUETOOTH_DEFAULT_NAME is renamed to MICROPY_PY_BLUETOOTH_DEFAULT_GAP_NAME to emphasise its link to GAP and this new "gap_name" config value. And the default value of this for the NimBLE bindings is changed from "PYBD" to "MPY NIMBLE" to be more generic. --- docs/library/ubluetooth.rst | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'docs') diff --git a/docs/library/ubluetooth.rst b/docs/library/ubluetooth.rst index 2609ac01b..fd2efe87d 100644 --- a/docs/library/ubluetooth.rst +++ b/docs/library/ubluetooth.rst @@ -51,6 +51,10 @@ Configuration Note: on some ports, accessing this value requires that the interface is active (so that the MAC address can be queried from the controller). + - ``'gap_name'``: Get/set the GAP device name used by service 0x1800, + characteristic 0x2a00. This can be set at any time and changed multiple + times. + - ``'rxbuf'``: Get/set the size in bytes of the internal buffer used to store incoming events. This buffer is global to the entire BLE driver and so handles incoming data for all events, including all characteristics. -- cgit v1.2.3