-
-
Notifications
You must be signed in to change notification settings - Fork 83
Introduce L2CAP infrastructure. #324
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
Conversation
|
Hmm… it fails to compile with ESP-IDF 4.4, probably due to the older C++ standard: How are we going to fix this correctly? |
h2zero
left a comment
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.
Looks good and thank you for updating this, couple little things to clean up the build.
|
Thanks @mickeyl, something weird is happening with this PR, it's not triggering the CI or showing the update. Could you squash these commits and force push? Hopefully that triggers the CI. |
|
@h2zero For some versions it still fails – this time because of some bogus use of |
h2zero
left a comment
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.
Looks good, just missed one.
L2CAP is the underlying technology powering GATT. BLE 5 exposes L2CAP COC (Connection Oriented Channels) allowing a streaming API that leads to much higher throughputs than you can achieve with updating GATT characteristics. The patch follows the established infrastructure very closely. The main components are: - `NimBLEL2CAPChannel`, encapsulating an L2CAP COC. - `NimBLEL2CAPServer`, encapsulating the L2CAP service. - `Examples/L2CAP`, containing a client and a server application. Apart from these, only minor adjustments to the existing code was necessary.
|
Awesome, thanks @mickeyl |
|
@h2zero Excellent, glad that this pull request made it. I can now reduce the diff and concentrate on stabilizing the code and probably exposing the (suspected) bugs in the Nimble l2cap infrastructure. Thanks for maintaining this package, I really appreciate that. Expect further pull requests for the l2cap infrastructure coming over the course of this year. |
|
Awesome, thank you @mickeyl, looking forward to future PR's 😄 |
L2CAP is the underlying technology powering GATT.
BLE 5 exposes L2CAP COC (Connection Oriented Channels) allowing a streaming API that leads to much higher throughputs than you can achieve with updating GATT characteristics.
The patch follows the established infrastructure very closely. The main components are:
NimBLEL2CAPChannel, encapsulating an L2CAP COC.NimBLEL2CAPServer, encapsulating the L2CAP service.Examples/L2CAP, containing a client and a server application.Apart from these, only minor adjustments to the existing code was necessary.
NOTE: The example programs point out a potential problem in the l2cap stack, probably deep inside Nimble, but we have to investigate that. If you are sending too many data, the stack silently drops it.
NOTE2: I forked the repository over two years ago and unfortunately didn't sync afterwards, so I had to do more merge work than expected to catch up with your changes. I hope everything is correct, but in order to reduce coming diffs, it's probably a good idea to pull this now.
This obsoletes #116