-
Notifications
You must be signed in to change notification settings - Fork 3k
BLE: Cordio port #5060
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BLE: Cordio port #5060
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Why
TARGET_CORDIO
? - Why
TARGET_CORTEX
? - Why not
TARGTE_CORTEX_{M0,M0PLUS,M3,M4}
- Trying to build this will result in a link error with duplicate symbols x4 for each and every cordio function in the static lib.
Also, what does an example look like? |
This is BLE implementation based on the Cordio stack, do you have another suggestion for the name ? AFAIR there is no concept of implementation usable in the build system so we have to rely on the target concept.
That's a mistake, that I need to fix. Binary came out that way from the build machine since a long time and I never had a single error with any of the compiler we support (ARM, GCC_ARM, IAR). I suppose the linker doesn't consider objects files compiled for a different cpu that the one specified in command line.
I will add one based on BLE examples. |
You could then have an {
"target_overrides" :{
"*" : {
"target.features_add": ["BLE"]
}
}
} This has a few benefits:
|
👍 |
Huh. Let's not depend on it. |
Why would it be more appropriate to use From my perspective targets are exclusive from one another not inclusive like features can be and that's what we want in that precise case. But I might be completely wrong. We also use |
Well, that's simply not true. |
Probably that nested features do not work/are not allowed. |
The reason that I'm suggesting a feature, is that this (mbed_app.json) might be better:
than this (mbed_app.json):
I think that they will both work, and I think that |
Thanks for pointing that out. If nested features are not allowed then I'm not sure to understand why That also means security and hci features fo the cordio stack should go inside targets. |
@pan- I think you missed/I incorrectly worded that I'm advocating for NOT putting |
@pan- I don't like calling anything but a vendor, family, mcu, module or board a "target". I don't want to use |
@theotherjimmy Library path has been fixed and examples can be run with the Cordio port here. @sg- Should I put the Cordio stack in a feature as suggested by Jimmy ? I have no particular opinion about this change however it disrupt current practices. As an example, the ST Blue NRG library was always imported as a target, not a feature. I also want to point out that if the Cordio stack is packaged as a feature, it's very likely to experience errors if the feature is enabled on targets which already provide an implementation of BLE API (Nordic, Maxim, Beetle). |
How is this any different than of it was packaged as a target? A user could just do |
This is the default stack therefore would expect its enabled by default, not requiring any configuration (same goes for BLE). Maybe this isn't quite ready yet. |
And then you would do
Which would be nice, agreed. |
Given this is early access and just needs to land to master we can iterate how it is used or not used. |
Approved with the understanding that we can bikeshed about directory structure later. |
As my understanding, to fix jenkins CI, we need https://github.com/ARMmbed/mbed-os-cliapp/pull/307, should be in soon |
The fix is in, restarted CI |
/morph test |
@pan- The failure from the latest test does not seem to be related to this patch
If you can confirm that we should restart CI, we will do it right away |
The issue seen in CI is caused by the use of the the non throwing version of the new operator which is used in GenericGattClient.cpp. I submitted another PR to overcome that issue: #5165 . |
/morph test |
Result: ABORTEDYour command has finished executing! Here's what you wrote!
|
…inationCallbackParams_t
Also fix wrong usage of designed initializer in CPP files.
This changes introduce a platform adaptation over ATT/GATT that can be implemented by porter. Unlike the GattClient interface, the ATT/GATT adaptation is simple, follow closely the Bluetooth specification and won't change over time. Implementation of the GattClient interface is realized by the class GenericGattClient which accept in input a pal::GattClient. This change will also free design space once adopted by partners, addition to the GattClient interface won't require partner support.
It allows mbed users to enable BLE on targets with an external BLE module.
@0xc0170 Apologies, I didn't rebase the PR. It is done now. |
/morph test |
Result: SUCCESSYour command has finished executing! Here's what you wrote!
OutputAll builds and test passed! |
@tommikas Please restart CI job |
Description
Add a BLE port based on the ARM Cordio stack into mbed OS.
It allows mbed OS users to exploit BLE API on any targets which is connected to an HCI compatible module.
Status
READY
Migrations
NO