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

Feature request: add setters for uplink and downlink counters #41

Closed
romansoft opened this issue Sep 27, 2018 · 7 comments
Closed

Feature request: add setters for uplink and downlink counters #41

romansoft opened this issue Sep 27, 2018 · 7 comments

Comments

@romansoft
Copy link

I'd like you to consider adding setters for uplink and downlink counters to help with testing the system at corner conditions when the counters roll over. Without these, it will take a very looong time to reach those conditions.

Also, could you please clarify these comments from another issue?
#27 (comment)
#27 (comment)

Will version 1.0.2 work correctly with 32-bit counter rollover, or should the network rejoin happen just before 16-bit counter expiry, as @SloMusti advises?

When the counter rolls over, does the application code need to do anything special (eg. force re-join)? Is there an error generated from send functions?

@GrumpyOldPizza
Copy link
Owner

User modifications of uplinj/downlink counters are pointless. For testing a system those had to be injected at a way lower level (i.e. syntheic test case).

There are no known rollover issues in 1.0.2. There is not rejoin required as pointed out in the other issue. The problem was observed with ST's code, which is derived off a LoRaMac-node 4.4.2 develop branch.

@romansoft
Copy link
Author

@GrumpyOldPizza, when I say system testing, I mean interaction between a node and a network server., not just testing the module and firmware (although it's good to hear you had it covered).
The network server implementations are all over the place with profiles for different lorawan versions. You would be surprised how many issues there are in corner cases and misconfigurations, even in commercial products.
I, as any serious developer, would like to test these corner cases for the final system configuration before launching products into field. The alternative is to learn about issues later, the hard way.

@GrumpyOldPizza
Copy link
Owner

Please show me a real use case (not just an abstract one) where this makes sense, and would actually do the right thing.

@GrumpyOldPizza
Copy link
Owner

I'll add a "::setUpLinkCounter()". Not sure about the value, but easy enough to do. A "::setDownLinkCounter()" does not make sense, and this counter is driven by the gateway.

@romansoft
Copy link
Author

As I said before, this is not be used in mission mode, but only during the system integration testing. Not having this is not a show stopper, but makes such testing harder than it should be. If this is a low effort add on (which I expected to be), it would be useful to have in the toolbox.

setDownLinkCounter() is OK to be skipped.

@GrumpyOldPizza
Copy link
Owner

Ok. setUpLinkCounter() is not implementable right now. The backing EEPROM code enforces a strict increasing order. Applying all sorts of trickery does not seem to be worth it at this point of time. Perhaps when the stack will be upgraded to 1.0.3 or 1.1.

@romansoft
Copy link
Author

Sounds reasonable. Thanks for trying.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants