-
Notifications
You must be signed in to change notification settings - Fork 376
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 1.1 registration #418
LWM2M 1.1 registration #418
Conversation
Signed-off-by: Scott Bertin <sbertin@telular.com>
Client reports 1.1 or 1.0 based on the build. Server recognizes and accepts only versions it is built for. Example server prints out client version. Signed-off-by: Scott Bertin <sbertin@telular.com>
lwm2m_binding_t is now a bit mask of the supported binding modes. Parsing of the binding mode is more permissive for an LWM2M 1.1 server. Queue mode is still tracked internally as part of the binding mode, but is sent seperately by LWM2M 1.1 clients. Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Also resolves eclipse-wakaama#404 Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Missing return in utils_convertMediaType timeout used uninitialized in transaction_send Various type mismatches between char * and uint8_t * Return of void result in lwm2m_free Mismatch int vs size_t in send_data fprintf. Signed-off-by: Scott Bertin <sbertin@telular.com>
Some tests were not even being run. Cmake's CTest doesn't work properly with cunit so was removed. Fix many compiler warnings. convert_numbers_test.c expanded and check conversion both ways for the same values. Added uint tests. tlv_tests.c added uint tests. Signed-off-by: Scott Bertin <sbertin@telular.com>
LWM2M_SECURITY_SHORT_SERVER_ID and LWM2M_SECURITY_HOLD_OFF_ID were assumed to always exist. LWM2M_SECURITY_HOLD_OFF_ID is only requied for bootstrap servers and LWM2M_SECURITY_SHORT_SERVER_ID should not exist for bootstrap servers. If one didn't exist the entire read would fail. This only reads them under the conditions where they are required. Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Add support for optional resources controlling the client registration procedure. Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Signed-off-by: Scott Bertin <sbertin@telular.com>
Thank you for all this work. I'm still reviewing it. |
I'm having second thoughts about adding the Corelnk type. I don't think it would actually be used as a type for a resource. What do you think, should I revert cc55289? I realize this is a large chunk of changes, but some of it didn't make sense unless put in context. I'll try to keep future changes smaller and more focused. I should have more ready to go in the next day or so, but they build on some of this so I'll wait for this pull request to complete before creating additional pull requests. |
Hi, Why having second thoughts ? CoreLnk type is a possibility in 1.1 so it is better to be able to handle it in wakaama. It looks fine for me. |
This updates the registration procedure for LWM2M 1.1. Several changes were needed to make this happen.
First, the build needed to be updated to supply which version of the LWM2M spec to build for.
The new data types for LWM2M 1.1 (Unsigned Integer and Corelnk) are added. This wasn't made specific to the LWM2M 1.1 build because it is only internal and not exposed through the protocol.
Transaction callbacks were changed to pass the context. It is only used here for the registration procedure, but may have additional uses.
The tests were updated to actually run all the tests and to test unsigned integer conversions. Existing number conversion tests were expanded and made to test conversion of the same numbers both ways.
The example client and bootstrap server had some of the new optional Server object resources added to facilitate testing.
Several minor bugs were fixed and minor changes made to reduce compiler warnings and improve logging output.