Commit 9323ad6
[NXP] Add BLE pairing and bonding after commissioning (project-chip#40704)
* [nxp][platform][common][ble] Temporary fix for multiple ble connections.
* this bug was introduced in the initial multiple ble connections PR,
blekw_stop_advertising should be called only when there was no successful
connection. When a connection is made, advertising is stoped by the lib.
If called in this case, it will cause an error which doesn't any effect,
it just shows in the logs.
* this will work only for the first connection, if multiple connections are
made, the function will be called on successful connection showing the error.
A rework of this feature is needed.
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][platform][common][ble] Add ble pairing and bonding changes
* allow device to use random ble address when matter commissioning
and public ble address in extra ble connections, this is needed
for pairing and bonding. This is a workaround. Setting of ble
advertising data at runtime is needed in the future.
* don't send Gap_RejectPairing when pairing enabled, the pairing
request will be acceped from the ble host code.
* add DisconnectAndUnbond to allow disconnecting and removing ble bonding
data when factory resetting.
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][examples][platform][common] Add FactoryReset in BLEApplicationManager
* feature can be used by each application to implement its factory reset mechanism
in BLEApplicationManager (e.g. erasing ble bonding data)
* add dummy FactoryReset implementation in BLEApplicationManagerEmpty
* add dummy FactoryReset implementation in BleZephyrManagerApp
* call FactoryReset BLEApplicationManager in AppTaskBase::FactoryResetHandler
* call FactoryResetHandler in ButtonBle to align with matter cli
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][examples][platform][mcxw] BLEApplicationManager changes
* add FactoryReset function to disconnect and erase bounding data for all ble
connections
* move BLEApplicationManager.cpp to NXPHostBLEApplicationManager.cpp
in common/app_ble/source directory
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][gn][examples][lock-app][mcxw71] BLE changes
* use ble bonding nvm functions (App_NvmRead, App_NvmWrite, App_NvmErase)
implementation
* align extra gatt macros with cmake kconfigs
* use common NXPHostBLEApplicationManager.cpp
(originating from mcxw71 BLEApplicationManager.cpp)
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][cmake][config] Add multiple ble connections kconfig
* add kconfigs for ble pairing and bonding
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][cmake][examples][platform][common] Rework CHIP_APP_BLE_MANAGER_SELECTION & add kconfigs
* change CHIP_APP_BLE_MANAGER_CUSTOM to CHIP_APP_BLE_MANAGER_CUSTOM_BLE_ZEPHYR
* add CHIP_APP_BLE_MANAGER_CUSTOM_NXP_BLE_HOST which currently depends on
CHIP_NXP_MULTIPLE_BLE_CONNECTIONS and not on CHIP_CUSTOM_BLE_ADV_DATA
as it doesn't yet have custom ble adv data
* use common app_ble/source/NXPHostBLEApplicationManager.cpp when
CHIP_APP_BLE_MANAGER_CUSTOM_NXP_BLE_HOST
* add kconfigs for extra gatt db header and gatt uuid header
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][common] Update nxp_matter_support repo
Signed-off-by: Andrei Menzopol <[email protected]>
* Restyled by whitespace
* Restyled by clang-format
* Restyled by gn
* [nxp][cmake][examples][platform][common] Fix typo
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][examples][all-clusters-app][zephyr] Add BLE application manager
Signed-off-by: Andrei Menzopol <[email protected]>
* [nxp][examples][laundry-washer-app][zephyr] Add BLE application manager
Signed-off-by: Andrei Menzopol <[email protected]>
---------
Signed-off-by: Andrei Menzopol <[email protected]>
Co-authored-by: Restyled.io <[email protected]>1 parent 2ed6d78 commit 9323ad6
File tree
16 files changed
+146
-15
lines changed- config/nxp
- chip-cmake-freertos
- cmake
- examples
- all-clusters-app/nxp/zephyr
- laundry-washer-app/nxp/zephyr
- lock-app/nxp/mcxw71
- platform/nxp/common
- app_ble
- include
- source
- app_task/source
- matter_button/source
- src/platform/nxp/common/ble
- third_party/nxp
16 files changed
+146
-15
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| 55 | + | |
55 | 56 | | |
56 | 57 | | |
57 | 58 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
272 | 272 | | |
273 | 273 | | |
274 | 274 | | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
275 | 293 | | |
276 | 294 | | |
277 | 295 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
54 | 55 | | |
55 | 56 | | |
56 | 57 | | |
| |||
67 | 68 | | |
68 | 69 | | |
69 | 70 | | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
70 | 81 | | |
71 | 82 | | |
72 | 83 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| 56 | + | |
56 | 57 | | |
57 | 58 | | |
58 | 59 | | |
| |||
69 | 70 | | |
70 | 71 | | |
71 | 72 | | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
72 | 83 | | |
73 | 84 | | |
74 | 85 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
96 | | - | |
97 | | - | |
| 96 | + | |
| 97 | + | |
98 | 98 | | |
| 99 | + | |
99 | 100 | | |
100 | 101 | | |
101 | 102 | | |
| |||
199 | 200 | | |
200 | 201 | | |
201 | 202 | | |
202 | | - | |
203 | | - | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
204 | 206 | | |
205 | 207 | | |
206 | 208 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
52 | | - | |
53 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
54 | 54 | | |
55 | 55 | | |
56 | | - | |
| 56 | + | |
57 | 57 | | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
58 | 64 | | |
59 | 65 | | |
60 | 66 | | |
61 | 67 | | |
62 | 68 | | |
63 | 69 | | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
64 | 85 | | |
65 | 86 | | |
66 | 87 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
36 | 37 | | |
37 | 38 | | |
38 | 39 | | |
| |||
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
30 | 33 | | |
31 | 34 | | |
32 | 35 | | |
| |||
63 | 66 | | |
64 | 67 | | |
65 | 68 | | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
66 | 73 | | |
67 | 74 | | |
68 | 75 | | |
| |||
92 | 99 | | |
93 | 100 | | |
94 | 101 | | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
0 commit comments