| 32232aba |
client: Proxy calls to ReadValue and WriteValue
This uses the proxies created by clone command to forward the requests
to the cloned services. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +141, -0 |
| 183d47c1 |
client: Add gatt.clone command
This adds clone command to gatt submenu which can be use to clone
services as follow:
Clone all services from the connected device:
> gatt.clone
Clone a given service
> gatt.select-attribute <attribute/uuid>
> gatt.clone
In either case there is a prompt to confirm since this may add a lot of
service the user must confim before proceding.
Then finally:
> gatt.register-application |
Luiz Augusto von Dentz |
6 years ago |
3 files, +253, -0 |
| 6d410a0e |
gatt: Fix not allowing 'extended-properties' as flags
Allows 'extended-propeties' as flags. |
Luiz Augusto von Dentz |
6 years ago |
2 files, +3, -0 |
| 54a67a1c |
shared/gatt-db: Fix crash if next_handle is 0
If the database is reseted all the services shall be ignored and no
hash shall be generated. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +3, -0 |
| 8d8066d8 |
mesh: Save newly added or updated net key to config file
This separates mesh_db_net_key_add() into distinct functions:
mesh_db_net_key_add() and mesh_db_net_key_update() which will be called
based on whether a network key was newly added or updated. |
Inga Stotland |
6 years ago |
6 files, +80, -82 |
| 9fe6a99f |
mesh: Save key refresh phase state to node config file
This adds implementation for saving the key refresh phase to
a node configuration file in JSON format. When the key refresh
procedure is finished, the old network keys are remove from the
configuration file. |
Inga Stotland |
6 years ago |
5 files, +72, -1 |
| 8c4c46e5 |
mesh: Declare internal functions as static
This renames mesh_net_key_refresh_finish() to key_refresh_finish() and
mesh_net_key_phase_two() to key_refresh_phase_wo() and changes the
function declaration to static since they are called only within net.c |
Inga Stotland |
6 years ago |
2 files, +73, -75 |
| d69e29af |
mesh: Add function to restore net key state from storage
This creates subnet state based on saved network key state:
current keys and, if present, updated keys.
Secure network beacon is generated according to key refresh phase. |
Inga Stotland |
6 years ago |
3 files, +82, -16 |
| c1551f20 |
mesh: Separate functions for net key add and update
This splits mesh_net_key_add() into two separate functions:
mesh_net_key_add() and mesh_net_key_update().
mesh_net_key_update() essentially replaces mesh_net_kr_phase_one()
since switching to Key Refresh phase one can only be triggered
by successful network key update. |
Inga Stotland |
6 years ago |
5 files, +24, -25 |
| db15160d |
client: Add type to write command
This enables setting the write type as optional third parameter:
write <data=xx xx ...> [offset] [type]
The type can be used to force a specific procedure to be used, for
example to force reliable writes one can enter:
> write 00 0 reliable |
Luiz Augusto von Dentz |
6 years ago |
2 files, +53, -73 |
| aa9f9b19 |
gatt: Implement "type" option for Characteristic.WriteValue
This implements the "type" option as documented. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +19, -8 |
| fa9473bc |
doc/gatt-api: Add "type" option to Characteristic.WriteValue
The option "type" can be used to force a certain procedure to be used:
- "command": Use Write Without Response procedure
- "request": Use (Long) Write With Response procedure
- "reliable"" Use Reliable Write procedure |
Luiz Augusto von Dentz |
6 years ago |
1 file, +6, -0 |
| 750a26cd |
TODO: Fix complexity level for Bluetooth mesh items |
Inga Stotland |
6 years ago |
1 file, +3, -3 |
| ccdfe1e1 |
device: Store Database Hash on storage
This stores the hash on the storage so it can be reloaded when the
daemon/system restarts. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +77, -9 |
| 55b0d66a |
shared/gatt-client: Write Client Features
This writes the supported client features setting Robust Caching bit. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +23, -0 |
| 0f67d5e2 |
shared/gatt-client: Read database hash if available
This reads the database hash if available and compares to the existing
value, if it matches consider the discovery is completed. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +152, -25 |
| 9eb2bf9f |
gatt: Implement Robust Caching handling for server
This detects when a client becomes change-unware returning
DB Out of Sync error when that happens. |
Luiz Augusto von Dentz |
6 years ago |
3 files, +74, -7 |
| 291e9a0d |
shared/gatt-server: Add bt_gatt_server_set_authorize
bt_gatt_server_set_authorize can be used to set the callback to
authorize attribute operations which is required in order to send
out of sync error as that has to happen even in case the handle is
not valid. |
Luiz Augusto von Dentz |
6 years ago |
2 files, +41, -0 |
| 59df8b8c |
shared/gatt-db: Add gatt_db_set_authorize
gatt_db_set_authorize can be used to set the callback to authorize
attribute operations. |
Luiz Augusto von Dentz |
6 years ago |
2 files, +47, -0 |
| 97937bcb |
gatt: Add caching support for server
This registers both Client Features and Database Hash Characteristics
which are mandatory for the server. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +102, -1 |
| 3a427d1a |
shared/gatt-db: Generate database hash
This use bt_crypto_hash (AES-CMAC) to generate a database hash
using the content of the attribute:
In ascending order of attribute handles, starting with the first handle,
concatenate the fields Attribute Handle, Attribute Type, and Attribute
Value if the attribute has one of the following types:
«Primary Service», «Secondary Service», «Included Service»,
«Characteristic», or «Characteristic Extended Properties», concatenate
the fields Attribute Handle and Attribute Type if the attribute has one
of the following types: «Characteristic User Description»,
«Client Characteristic Configuration»,
«Server Characteristic Configuration», «Characteristic Format», or
«Characteristic Aggregate Format», and ignore the attribute if it has
any other type (such attributes are not part of the concatenation). |
Luiz Augusto von Dentz |
6 years ago |
1 file, +66, -2 |
| 64c2b5a7 |
shared/gatt-db: Introduce Database Hash
This introduces a database hash which is generate whenever the database
changes. |
Luiz Augusto von Dentz |
6 years ago |
2 files, +37, -0 |
| 3a035b07 |
monitor: Decode GATT Caching errors
This enables decoding of Database Out of Sync and Value Not Allowed
ATT errors introduced with GATT Caching improvements. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +6, -0 |
| 81a87401 |
shared/att-types: Add errors introduced by GATT caching
This adds Database Out of Sync and Value Not Allowed errors. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +5, -0 |
| 03332ce6 |
shared/util: Add decoding support for GATT caching attributes
This adds support to decode Client Supported Features and Database
Hash. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +2, -0 |
| a85fe5d4 |
lib/uuid: Introduce definition for GATT caching attributes
This introduces UUIDs for Client Features and Database Hash
characteristics. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +4, -0 |
| 810d8ff3 |
unit/test-crypto: Add test for bt_crypto_gatt_hash
This adds test case base on the example given in the spec. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +66, -0 |
| 8474ad9f |
shared/crypto: Add bt_crypto_gatt_hash
The bt_crypto_gatt_hash uses AES-CCM to create a hash with the contents
stored in the iovec.
Note: The spec disregards the byte order so both the key, msg and res
are not swapped. |
Luiz Augusto von Dentz |
6 years ago |
2 files, +34, -0 |
| 64441a32 |
mesh: Add D-Bus policy for Bluetooth mesh daemon
This adds new D-Bus policy file bluetooth-mesh.conf |
Inga Stotland |
6 years ago |
2 files, +28, -0 |
| 314f340a |
mesh: Rename mesh daemon executable to bluetooth-meshd |
Inga Stotland |
6 years ago |
1 file, +4, -4 |
| 73ffcdc6 |
TODO: Add Bluetooth mesh items |
Inga Stotland |
6 years ago |
1 file, +51, -0 |
| d8e2e394 |
mesh: Remove unnecessary variable initialization |
Inga Stotland |
6 years ago |
1 file, +1, -1 |
| c953e1c7 |
mesh: Add README file
This file contains instructions for Bluetooth mesh daemon
configuration and description of the persistent storage. |
Inga Stotland |
6 years ago |
1 file, +50, -0 |
| 6f0b95a2 |
mesh: Add MGMT bypass when specifying controller
If Daemon is started with an explicit controller specified, the
MGMT search for an unused shared controller is bypassed, and
the controller is opened directly. |
Brian Gix |
6 years ago |
1 file, +13, -7 |
| b52543ae |
client: Don't expose pointer value in attribute path
Instead use the position in the list to create a unique path:
[bluetooth]# register-service 0x1820
[NEW] Primary Service (Handle 0x0000)
/org/bluez/app/service0
0x1820
Internet Protocol Support |
Luiz Augusto von Dentz |
6 years ago |
1 file, +6, -3 |
| d5cb29ce |
client: Enable list-attributes to print local attributes
This enable passing "local" to list-attributes to print the attributes
registered locally:
> list-attributes local
Primary Service (Handle 0x0400)
/org/bluez/app/service0x74ccb0
0x1820
Internet Protocol Support |
Luiz Augusto von Dentz |
6 years ago |
2 files, +54, -3 |
| 918f6f93 |
client: Enable setting attribute handles
This emulates application setting their attribute handles. |
Luiz Augusto von Dentz |
6 years ago |
3 files, +36, -12 |
| ae63206f |
client: Enable Handle property for GATT attributes
This enable bluetoothd to write back the actual value of attribute
handles. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +124, -16 |
| 3882e127 |
gatt: Write back the handle to Handle property
If the application has set an attribute with Handle set to 0 inform the
allocated handle by writting the Handle property. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +27, -0 |
| 98f13d47 |
gatt: Implement Handle property
This parses the Handle property and if it exists attempt to insert
attributes in their locations. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +43, -4 |
| 872c3928 |
shared/gatt-db: Allow passing 0 as handle to gatt_db_insert_*
Handle 0 should be allocate on the next handle just as any of
gatt_db_add_* functions. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +7, -5 |
| 0c81f373 |
doc/gatt-api: Add Handle property
When acting as server it is useful to select where to allocate the
handle for an attribute so it can be restored in the same position when
restarting the daemon or rebooting the system.
In order to do that the application also needs to know in which handle
the attribute is allocated the very first time it is registered, this
also allows for a better integration with PTS and tools like auto-pts
which needs to know the handles where the attributes have been
allocated. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +24, -0 |
| 61244c0c |
a2dp-codecs: Fix SBC_MAX_BITPOOL and add SBC quality modes
According to A2DP specification; section SBC; Codec Specific Information
Elements; Minimum / Maximum Bitpool Value, range for Bitpool value is from
2 to 250.
A2DP specification also defines bitpool values for two SBC modes: Middle
Quality and High Quality. They depends on channel mode and frequency. So
add definitions for them into a2dp-codecs file too.
File android/hal-audio-sbc.c was updated to use High Quality mode for
chosen frequency. |
Pali Rohár |
6 years ago |
2 files, +18, -4 |
| 97801670 |
avinfo: Fix parsing capabilities
Function print_caps() expects capabilities buffer without AVDTP header.
Previously avinfo somehow worked, because AVDTP header looks like
capability header with unknown category which was skipped. |
Pali Rohár |
6 years ago |
1 file, +1, -1 |
| 5d2aa427 |
avinfo: Dump unknown codecs and unknown categories |
Pali Rohár |
6 years ago |
1 file, +14, -1 |
| e655b64f |
a2dp-codecs & avinfo: Simplify defintions and parsing of aptX family
Reuse whole a2dp_aptx_t structure and defines as they are same for aptX Low
Latency and aptX HD. |
Pali Rohár |
6 years ago |
2 files, +22, -77 |
| 06a3310b |
lib: Add version number for Bluetooth 5.1 |
Johan Hedberg |
6 years ago |
1 file, +1, -0 |
| 94e62dd3 |
monitor: Add Bluetooth 5.1 features and version information |
Johan Hedberg |
6 years ago |
1 file, +14, -0 |
| 01c3b5f3 |
monitor: Reformat LE features table
Bluetooth 5.1 has many features with long names, so reformat the table
before adding any new ones. |
Johan Hedberg |
6 years ago |
1 file, +17, -17 |
| 02877c5e |
a2dp: Add reverse discovery
Now that remote endpoints are exposed there is a chance that a
configured device will reconnect and initiate SetConfiguration skipping
the discovery phase which is now required in order to be able to switch
endpoints, so this introduces the reverse discovery logic in order to
find out about remote endpoints capabilities if they have not been
found yet. |
Luiz Augusto von Dentz |
6 years ago |
1 file, +13, -1 |