-
Notifications
You must be signed in to change notification settings - Fork 3k
LoRaWAN: Fixing incorrect NetID causing ABP Failures #7641
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
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.
After reviewing ABP code more, there is some more fixes needed, so please attach them to this PR. At least net_id is handled incorrectly.
83322eb
to
4293b8b
Compare
The issue rose up when using ARMC6. A test case didn't initialize NetID parameter for ABP while using connect(params) API. NetID is the first 7 bits of the Device Address. It makes sense to actually remove the net-id parameter from ABP settings as the stack can deduce it from device address. However, the ABP structure is exposed in public APIs, so we can't really do that at the moment. Simpler fix is to move the mask that helps us to extract first 7 bits of the device address is exposed in lorawan_types.h and the user can use it to deduce correct net-id.
4293b8b
to
31aaea6
Compare
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.
/morph build |
Build : SUCCESSBuild number : 2696 Triggering tests/morph test |
Exporter Build : SUCCESSBuild number : 2326 |
Test : SUCCESSBuild number : 2427 |
LoRaWAN: Fixing incorrect NetID causing ABP Failures
Description
The issue rose up when using ARMC6. A test case didn't initialize NetID
parameter for ABP while using connect(params) API. NetID is the first 7 bits
of the Device Address. It makes sense to actually remove the net-id parameter
from ABP settings as the stack can deduce it from device address. However, the ABP
structure is exposed in public APIs, so we can't really do that at the moment.
Simpler fix is to move the mask that helps us to extract first 7 bits of the device address
is exposed in lorawan_types.h and the user can use it to deduce correct net-id.
Pull request type