-
Notifications
You must be signed in to change notification settings - Fork 410
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
LoRaWAN channels for mask-type bands vs list-type bands #836
Comments
The whole point behind the channel span structure is to save program space when defining the regional parameters, that's it. It's based on ideas I had while reading the LoRaWAN standard as an outsider, and it shows. For example, the mapping between channel ID and allowed data rate is quite complex. So I'm more than happy to replace this approach completely if a better solution appears.
This could be addressed by saving the default channels in a structure that also includes data rates. Perhaps this structure could be populated dynamically from the spans/CFList during activation (for default channels), and then appended to when processing NewChannelReq?
As far as I can tell, the standard does not specify the maximu, at least not directly. The reason I just picked 8 and ran with it is that: a) TTN requires you to select only 8 channels and So I think this should cover most use cases. |
Thanks for the clarifications! I'm trying to summarize all my findings below. A channel plan's default parameters are defined, and set to the following:
A join-request is performed based on the channel plan's defaults:
Regarding CFList:
Regarding MAC commands:
So we should (dynamically) at least keep track of the following items (for each frequency, up to 9 may be required judging from here - although AS1 and AS2 even have 10 - and here):
One question is yet unanswered:
A final note on all these parameters and NVM:
That's manageable - if we save all of this, we can remove the CFList from the table, which would then result in 192 bytes + 90 bytes = 282 bytes. So it would use just over half of the commonly seen 512 bytes. Please - let me know if you spot a mistake, and what do you think about supporting the full 16 channels? |
@jgromes I've got this working mostly. What do you prefer - shove it into the existing PR, or make it a two-stage rocket? |
@StevenCellist sorry for being so far behind the curve on this one, I've been pretty busy lately. I don't see any issues on the high level. Just one point regarding the NVM, I would very much like to keep it under 256 bytes. Failing to do that, I don't see much difference between 9 and 16 channels in terms of used storage. Since we're alredy past that limit, 16 would be preferrable for the sake of compliance. Regarding integration to the upstream, please open a new PR for this. |
Closing this as it is fully integrated in #867 |
Hi Jan,
As I'm looking to integrate ADR into LoRaWAN, I'm investigating your use of the so-called spans. While in itself a genius idea to tackle mask-type bands such as US902-928, things go wrong for list-type bands. Some list-type bands are even declared incorrectly (looking at CN780).
For list-type bands, the regional parameters define a minimum set of required channels; let's work with EU868. There are 3 that must be implemented: 868.1, .3 and .5. But then any LNS is free to specify extra channels using a CFList. Sure, these are added to a
availableChannelsFreq
frequency, but then the default ones aren't present here. Plus, the allowed DR range is not present in this structure, which may in theory be different for each frequency after NewChannelReq command.And in case of mask-type bands, I am wondering if those bands always use fewer than or equal to 8 channels, even though there may be 72 or more defined? Because the availableChannelsFreq is just 8 channels long. But I don't have any US923 equipment, so can't check.
Maybe we can come up with a middle road that allows this efficient use of mask-type bands, but also permits irregular list-type bands.
Let's use this issue to propose ideas, and the best one will be implemented in some commit or PR in the near future :)
The text was updated successfully, but these errors were encountered: