Gilles Boccon-Gibod
49b2c13e69
only use 1M parameters by default
2023-04-09 17:57:11 -07:00
Gilles Boccon-Gibod
2c2f512180
add comment to explain the initial role choice
2023-04-07 12:19:28 -07:00
Gilles Boccon-Gibod
859aea5a99
fix role state for classic connections
2023-04-07 10:24:26 -07:00
Alan Rosenthal
0f737244b5
Merge pull request #169 from AlanRosenthal/alan/remote-values
...
Add `show remote-values`
2023-04-05 09:00:48 -04:00
Alan Rosenthal
a258ba383a
Add show remote-values
...
`gatt_client` caches values read/notifications/indications and displays the most recent value to the user
2023-04-04 18:15:42 +00:00
Gilles Boccon-Gibod
620c135ac4
only instantiate keystore if not already set
2023-04-03 17:52:51 -07:00
Gilles Boccon-Gibod
fca73a49a3
use device public or static address for keystore namespace
2023-04-03 12:39:22 -07:00
Alan Rosenthal
fb49a87494
Create Characteristic.Property
...
Move all Characteristic properties into its own `enum.IntFlag` class
2023-03-31 16:09:24 -04:00
Lucas Abel
5c59b6ca6d
Merge pull request #158 from benquike/main
...
Fix HCI_PIN_Code_Reply_Command
2023-03-27 17:37:54 -07:00
Hui Peng
dcd66743f6
Use delegate.get_string to get pin code
2023-03-27 17:08:26 -07:00
Lucas Abel
7e62d4a81a
Merge pull request #150 from zxzxwu/roleswitch
...
Support BR/EDR role switch & change events
2023-03-27 11:41:29 -07:00
Josh Wu
9e1358536b
Add switch_role
2023-03-25 15:17:50 +08:00
Hui Peng
a8e61673d0
Fix HCI_PIN_Code_Reply_Command in Device.on_pin_code_request
2023-03-25 03:48:56 +00:00
Alan Rosenthal
dfb6734324
Fix typo when parsing device-config's gatt server
...
* 'permission' instead of 'permissions'
* Also added a more user friendly error message when Attribute.string_to_permissions fails
```
TypeError: Attribute::permissions error:
Expected a string containing any of the keys, seperated by commas: READABLE,WRITEABLE,READ_REQUIRES_ENCRYPTION,WRITE_REQUIRES_ENCRYPTION,READ_REQUIRES_AUTHENTICATION,WRITE_REQUIRES_AUTHENTICATION,READ_REQUIRES_AUTHORIZATION,WRITE_REQUIRES_AUTHORIZATION
Got: 1
```
```
Exception: Error parsing Device Config's GATT Services. The key 'permission' must be renamed to 'permissions'
```
2023-03-24 16:11:18 -04:00
Josh Wu
4fc13585cc
Handle BR/EDR connection roles
2023-03-24 15:13:48 +08:00
Lucas Abel
4c6320f98a
Merge pull request #142 from AlanRosenthal/main
...
Fix small bug with services set via --device-config
2023-03-23 12:47:14 -07:00
Lucas Abel
1cd13dfc19
Merge pull request #153 from benquike/main
...
Add 1 bug fix and a few features in bumble
2023-03-23 10:31:02 -07:00
Hui Peng
afe8765508
Add on_pin_code_request to support legacy BT classic pairing
2023-03-23 10:14:56 -07:00
Hui Peng
b70ebdef73
Allow Device.enable_classic to be configurable
2023-03-23 08:56:32 -07:00
Gilles Boccon-Gibod
6e719ca9fd
Merge pull request #147 from google/gbg/btbench
...
add benchmark tool and doc
2023-03-22 21:13:24 -07:00
Alan Rosenthal
fda00dcb28
Used pytype to find some missing types
...
```
pytype --pythonpath . ./bumble/device.py
```
2023-03-22 14:46:41 +00:00
Gilles Boccon-Gibod
bc29f327ef
address PR comments, take 2.
2023-03-21 15:33:34 -07:00
Gilles Boccon-Gibod
1894b96de4
address PR comments
2023-03-21 15:01:46 -07:00
Gilles Boccon-Gibod
1efa2e9d44
add benchmark tool and doc
2023-03-20 18:25:21 -07:00
Alan Rosenthal
c34c5fdf17
Fix small bug with services set via --device-config
...
before:
```
File "/home/alanrosenthal/code/fitbit/bumble/bumble/gatt.py", line 572, in __str__
f'Descriptor(handle=0x{self.handle:04X}, '
File "/home/alanrosenthal/code/fitbit/bumble/bumble/att.py", line 756, in read_value
self.permissions & self.READ_REQUIRES_ENCRYPTION
TypeError: unsupported operand type(s) for &: 'str' and 'int'
```
2023-03-14 18:16:46 -04:00
Gilles Boccon-Gibod
97a0e115ae
two small hotfixes
2023-03-05 20:24:16 -08:00
uael
d21da78aa3
overall: host a minimal copy of ainsicolors
2023-02-23 20:53:06 +00:00
uael
ad27de7717
device: remove "feature" which enable accept to return the same connection has connect
2023-02-14 21:04:39 +00:00
uael
b731f6f556
overall: add types hints to the small subset used by avatar
2023-02-02 19:37:55 +00:00
Gilles Boccon-Gibod
99758e4b7d
add basic support for mypy type checking
2023-01-20 00:20:50 -08:00
Gilles Boccon-Gibod
0a22f2f7c7
use HCI_LE_Rand
2023-01-13 16:59:34 -08:00
Gilles Boccon-Gibod
422b05ad51
don't set a random address when it is 00:00:00:00:00:00
2023-01-13 13:22:27 -08:00
Gilles Boccon-Gibod
7e854efbbb
support more commands in controller.py
2023-01-06 21:51:47 -08:00
Abel Lucas
ea0a7e2347
device: commit LE connection **before** reading it's PHY
2022-12-20 19:25:43 +00:00
Abel Lucas
ce049865a4
device: always prefer R2 for remote name request
2022-12-20 01:48:08 +00:00
Gilles Boccon-Gibod
c2959dadb4
formatting and linting automation
...
Squashed commits:
[cd479ba] formatting and linting automation
[7fbfabb] formatting and linting automation
[c4f9505] fix after rebase
[f506ad4] rename job
[441d517] update doc (+7 squashed commits)
[2e1b416] fix invoke and github action
[6ae5bb4] doc for git blame
[44b5461] add GitHub action
[b07474f] add docs
[4cd9a6f] more linter fixes
[db71901] wip
[540dc88] wip
2022-12-15 23:07:17 -08:00
Abel Lucas
f580ffcbc3
device: set as Secure Connection when encrypted with AES
2022-12-15 17:02:21 +00:00
Abel Lucas
5178c866ac
classic: add to .encrypt the possibilty to disable encryption
2022-12-15 17:02:21 +00:00
Abel Lucas
441933bd64
reverted: 662704e "classic: complete authentication when being the .authenticate acceptor"
2022-12-15 17:02:21 +00:00
Abel Lucas
287df94090
host: spawn each asynchronous task with the right aliveness
2022-12-15 17:02:21 +00:00
Gilles Boccon-Gibod
135df0dcc0
format with Black
2022-12-10 09:40:12 -08:00
Alan Rosenthal
a8eff737e6
Add Device::add_default_services()
...
This will allow a test to:
a: add services to a device
b: reset services via `Server()`
c: add the default services back
2022-12-01 17:02:54 +00:00
Abel Lucas
ab4859bd94
device: fix typos
2022-11-29 16:33:12 +00:00
Lucas Abel
0d70cbde64
Merge pull request #75 from google/uael/fixes
...
Pairing: device/host fixes & improvements
2022-11-28 21:42:43 -08:00
Abel Lucas
662704e551
classic: complete authentication when being the .authenticate acceptor
2022-11-29 00:28:39 +00:00
Abel Lucas
02a474c44e
smp: emit enough information on pairing complete to deduce security level
2022-11-29 00:28:38 +00:00
Abel Lucas
a1c7aec492
device: fix .find_connection_by_bd_addr
2022-11-29 00:28:38 +00:00
Abel Lucas
6112f00049
device: introduce BR/EDR pending connections
...
This commit enable the BR/EDR pairing to run asynchronously to
the connection being established.
When in security mode 3, a controller shall start authentication as
part of the connection, which result in HCI events being sent on a BD
address without a completed connection (ie. no connection handle).
2022-11-29 00:28:38 +00:00
Alan Rosenthal
f56ac14f2c
Add bumble-console --device-config support for gatt services
...
This PR adds support for bumble-console to be preloaded with gatt services via `--device-config`.
This PR also adds some type annotations
2022-11-28 14:11:27 -05:00
Abel Lucas
5f1d57fcb0
device: simplify and fixes remote name request
2022-11-22 21:20:56 +00:00