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

Option to set persistent LinkADR settings when using Custom ADR option #3820

Closed
i3mSuperMan opened this issue Feb 17, 2021 · 4 comments · Fixed by #5353
Closed

Option to set persistent LinkADR settings when using Custom ADR option #3820

i3mSuperMan opened this issue Feb 17, 2021 · 4 comments · Fixed by #5353
Assignees
Labels
c/network server This is related to the Network Server in progress We're working on it
Milestone

Comments

@i3mSuperMan
Copy link

Summary

The custom ADR option allows to set the ADR parameter values, and NS communicates them to the device via LinkADRReq. But these values are not persistent and lost on reset of MAC State during re-join, thus requiring re-configuration every time device joins the network.

Why do we need this?

To make the parameters' values persistent and communicate to the device in case of MAC State reset after Join, to avoid manual intervention to set them with every re-join of the device.

What is already there? What do you see now?

The custom ADR option currently allows configuring the adr-data-rate-index, adr-tx-power-index & adr-nb-trans values using the below flags. These values reset when the MAC State of the device reset on re-join and not communicated to the device.

ttn-lw-cli end-devices set <app-id> <dev-id> --mac-state.desired-parameters.adr-data-rate-index
ttn-lw-cli end-devices set <app-id> <dev-id> --mac-state.desired-parameters.adr-tx-power-index
ttn-lw-cli end-devices set <app-id> <dev-id> --mac-state.desired-parameters.adr-nb-trans

What is missing? What do you want to see?

An option to make the changes to adr-data-rate-index, adr-tx-power-index & adr-nb-trans parameters persistent.

Environment

TTES V3.10.9 CH

How do you propose to implement this?

Add relevant mac-settings flags at the NS end.

How do you propose to test this?

...

Can you do this yourself and submit a Pull Request?

No. @rvolosatovs

@rvolosatovs rvolosatovs self-assigned this Feb 17, 2021
@rvolosatovs rvolosatovs added the c/network server This is related to the Network Server label Feb 17, 2021
@rvolosatovs rvolosatovs added this to the Next Up milestone Feb 17, 2021
@rvolosatovs
Copy link
Contributor

Good to note that this is mostly relevant for pre-1.1 devices in US915-like bands

@rvolosatovs
Copy link
Contributor

Also, these fields should be mutually exclusive with enable_adr

@baranisrc
Copy link

baranisrc commented Feb 25, 2021

If NS sets the DataRate=0 respectful of Desired ADR settings for each device when sending the USA linkADRreq "channel_mask", it will cause devices with an 11 byte or larger payload to exceed allowed payload size and some modems may reset, thus sending them into an endless reset and rejoin cycle, since the maximum application payload length in the absence of the OPTIONAL FOpt MAC control field (N) is 11 bytes. A single data frame may contain any sequence of MAC commands piggybacked in the FOpts field. Piggybacked MAC commands are always sent without encryption and MUST NOT exceed 15 octets. Alternatively, MAC commands may be sent as FRMPayload and MUST NOT exceed the maximum FRMPayload length.
ref: RP002-1.0.2 LoRaWAN® Regional Parameters: 2.5.6 US902-928 Maximum payload size

@rvolosatovs
Copy link
Contributor

rvolosatovs commented Mar 9, 2021

If NS sets the DataRate=0 respectful of Desired ADR settings for each device when sending the USA linkADRreq "channel_mask", it will cause devices with an 11 byte or larger payload to exceed allowed payload size and some modems may reset, thus sending them into an endless reset and rejoin cycle, since the maximum application payload length in the absence of the OPTIONAL FOpt MAC control field (N) is 11 bytes. A single data frame may contain any sequence of MAC commands piggybacked in the FOpts field. Piggybacked MAC commands are always sent without encryption and MUST NOT exceed 15 octets. Alternatively, MAC commands may be sent as FRMPayload and MUST NOT exceed the maximum FRMPayload length.
ref: RP002-1.0.2 LoRaWAN® Regional Parameters: 2.5.6 US902-928 Maximum payload size

This should be fixed by #3901 - NS will probably send the uplink data rate index in the first LinkADRReq.

@htdvisser htdvisser added the needs/triage We still need to triage this label Jun 3, 2021
@nejraselimovic nejraselimovic modified the milestones: Next Up, v3.14.0 Jun 7, 2021
@nejraselimovic nejraselimovic removed the needs/triage We still need to triage this label Jun 7, 2021
@adriansmares adriansmares modified the milestones: v3.14.0, v3.14.1 Jul 2, 2021
@NicolasMrad NicolasMrad modified the milestones: v3.14.1, v3.14.2 Jul 26, 2021
@NicolasMrad NicolasMrad modified the milestones: v3.14.2, v3.15.0 Aug 24, 2021
@NicolasMrad NicolasMrad modified the milestones: v3.15.0, 2021 Q3 Sep 7, 2021
@NicolasMrad NicolasMrad modified the milestones: 2021 Q3, 2022 Conference Sep 16, 2021
@NicolasMrad NicolasMrad modified the milestones: 2021 Q4, 2022 Q1 Dec 21, 2021
@adriansmares adriansmares modified the milestones: 2022 Q1, v3.18.1 Feb 18, 2022
@adriansmares adriansmares added the in progress We're working on it label Feb 22, 2022
@adriansmares adriansmares modified the milestones: v3.18.1, v3.18.2 Mar 3, 2022
@adriansmares adriansmares removed the in progress We're working on it label Mar 8, 2022
@adriansmares adriansmares mentioned this issue Mar 21, 2022
5 tasks
@adriansmares adriansmares modified the milestones: v3.18.2, v3.19.0 Mar 23, 2022
@adriansmares adriansmares added the in progress We're working on it label Mar 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c/network server This is related to the Network Server in progress We're working on it
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants