ARMmbed / mbed-os-example-ble

BLE demos using mbed OS and mbed cli
Apache License 2.0
134 stars 118 forks source link

Fix deprecated Gap type usages #289

Closed LDong-Arm closed 4 years ago

LDong-Arm commented 4 years ago

This PR replaces usages of deprecated types in Gap:: that are not warned by the compiler but will not be available anymore once https://github.com/ARMmbed/mbed-os/pull/12730 is merged. (Note: This does not depend on that PR.)

Types replaced:

The legacy types exist in the legacy Gap class only which will be removed from mbed-os. The current Gap APIs only use the new types.

LDong-Arm commented 4 years ago

Hi @ARMmbed/mbed-os-pan, @evedon, this PR makes sure examples continue to work after https://github.com/ARMmbed/mbed-os/pull/12730 is merged. The example updates are trivial and there's no dependency on the mbed-os PR though.

LDong-Arm commented 4 years ago

Changes look good but could you add more details in the PR description on the migration actions?

Thanks for the review, I've updated the description.

LDong-Arm commented 4 years ago

@jamesbeyond It looks like the CI result is not reported back to GitHub? @pan- Can we get this in?

Thanks

jamesbeyond commented 4 years ago

@jamesbeyond It looks like the CI result is not reported back to GitHub? @pan- Can we get this in?

Thanks

@LDong-Arm Can you rebase? then the new CI will kicks in

jamesbeyond commented 4 years ago

now CI works 😉

LDong-Arm commented 4 years ago

@jamesbeyond Thanks!

LDong-Arm commented 4 years ago

@pan- @evedon In addition to this, I'll make another example update PR to match device address related API changes. That will have a two-way dependency with the mbed-os Gap PR and they'll need to get in at the same time.

0xc0170 commented 4 years ago

This is now causing PRs failing (master Mbed OS)

./source/main.cpp:411:14: error: no type named 'central_privacy_configuration_t' in namespace 'ble'; did you mean 'central_privay_configuration_t'?
LDong-Arm commented 4 years ago

The mbed-os master branch has long had a typo central_privay_configuration_t (should be privacy). I corrected the spelling both here which caused mbed-os CI to fail...