Commit Graph

12 Commits

Author SHA1 Message Date
Dan Halbert
0e30dd8bcc merge from upstream; working; includes debug_out code for debugging via Saleae for posterity 2020-08-20 20:29:57 -04:00
Dan Halbert
1c8e11b2cb bug in char get_value; raise NotImpl; better arg validation 2020-08-14 23:38:58 -04:00
Taku Fukada
56c898da80 Modify some Python stubs 2020-08-07 01:01:28 +09:00
Taku Fukada
d356581651 Fix several type hints 2020-07-27 18:05:13 +09:00
dherrada
d0d949cd24 Made every init return None 2020-07-03 14:23:34 -04:00
dherrada
9b4ffc0571 Changed unions to ReadableBuffer and WriteableBuffer 2020-07-02 17:47:52 -04:00
dherrada
26f1fd0071 Added type hints to _bleio 2020-07-02 14:11:25 -04:00
Scott Shawcroft
4e8de3c554
Swap sphinx to autoapi and the inline stubs 2020-05-12 17:28:24 -07:00
dherrada
0e465e63b9
Did audiopwmio, bitbangio, and _bleio 2020-05-01 18:23:27 -04:00
Scott Shawcroft
5e857fdb67
Use BluetoothError in _bleio
This better differentiates errors than using OSError everywhere.
2019-11-20 14:02:15 -08:00
Scott Shawcroft
ae30a1e5aa
Refine _bleio
This PR refines the _bleio API. It was originally motivated by
the addition of a new CircuitPython service that enables reading
and modifying files on the device. Moving the BLE lifecycle outside
of the VM motivated a number of changes to remove heap allocations
in some APIs.

It also motivated unifying connection initiation to the Adapter class
rather than the Central and Peripheral classes which have been removed.
Adapter now handles the GAP portion of BLE including advertising, which
has moved but is largely unchanged, and scanning, which has been enhanced
to return an iterator of filtered results.

Once a connection is created (either by us (aka Central) or a remote
device (aka Peripheral)) it is represented by a new Connection class.
This class knows the current connection state and can discover and
instantiate remote Services along with their Characteristics and
Descriptors.

Relates to #586
2019-10-21 18:57:03 -07:00
Dan Halbert
7a64af9280 rename bleio module to _bleio 2019-08-29 18:44:27 -04:00