Skip to content
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

LwM2M: make transport agnostic #41313

Open
rerickson1 opened this issue Dec 17, 2021 · 5 comments
Open

LwM2M: make transport agnostic #41313

rerickson1 opened this issue Dec 17, 2021 · 5 comments
Assignees
Labels
area: LWM2M Enhancement Changes/Updates/Additions to existing features

Comments

@rerickson1
Copy link
Member

Is your enhancement proposal related to a problem? Please describe.
Currently the LwM2M engine is tightly coupled to sending/receiving data with sockets.
There's no reason this can't be decouple to allow sending over other transports therefore removing the dependency on the networking stack.

Describe the solution you'd like
Decouple the LwM2M engine from networking and sockets.

  1. Decouple the engine from sockets and add a Kconfig option to use the socket implementation by default
  2. If Kconfig option for using sockets is turned off, callbacks for LwM2M send/receive can be implemented by the user app.

This would allow a user to tunnel LwM2M over a BLE connection for instance.

@rerickson1 rerickson1 added the Enhancement Changes/Updates/Additions to existing features label Dec 17, 2021
@rerickson1
Copy link
Member Author

@rlubos curious if you have any thoughts or further input on this.

@rlubos
Copy link
Contributor

rlubos commented Dec 20, 2021

We have something like this in MQTT, where we implement multiple transports, and user can select which one to use when initializing client (https://github.com/zephyrproject-rtos/zephyr/blob/main/subsys/net/lib/mqtt/mqtt_transport.h) - I think we could implement something similar for LwM2M as well.

Or were you rather thinking about being able to disable LwM2M thread entirely, and handle the communication on the application side? The LwM2M would then need an API to feed the data into the stack and to trigger send.

@rerickson1
Copy link
Member Author

Thanks for pointing out that feature of MQTT, I was not aware of it. I think I would like to start with an approach similar to that for LwM2M.

@0Grit
Copy link

0Grit commented Dec 22, 2021

Recommend reading the LWM2M transport spec

http://www.openmobilealliance.org/release/LightweightM2M/V1_2-20201110-A/OMA-TS-LightweightM2M_Transport-V1_2-20201110-A.pdf

@rerickson1
Copy link
Member Author

@ahedin25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: LWM2M Enhancement Changes/Updates/Additions to existing features
Projects
None yet
Development

No branches or pull requests

4 participants