Closed n2jn closed 7 years ago
@Nicolasdejean could you resolve the conflict and document what the public API/use is of this change and what I should test?
@FokkeZB In API.md I put the use of trackAirtime in sendBytes since its a private function. Also @johanstokking shouldn't we print the airtime in the examples to let the user be aware of the 30 seconds fair policy.
If we don't debug print nor make it public it's of no use.
Yep, true. Put it in showStatus()
@johanstokking @FokkeZB It's going to change everytime we send a message so shouldn't we print it in sendBytes()
? Or in another function in void loop
?
Yes, we can too
Isn't this information users might want to calculate with? What if we make the property public so that you can read it and do whatever you like (reset every day perhaps)? We could still also include it in showStatus (total airtime) log in sendBytes (added and total airtime)
Also, don't the other commands like for join also cost air time?
I might be wrong but doesn't the 30 seconds start when we successfully joined the ttn network ?
@FokkeZB @johanstokking Should I put a limitation to sendbytes(), if the airtime reaches 30 s or if I receive 10 messages, I should stop the uplink and downlinks (I read that it was 10 messages downlink per day) ?
@FokkeZB I printed the airtime in showstatus. The formula I used in trackAirtime()
apply's to all SF, changing it will, I think, be no use to the user, and the airtime is going to reset everytime you close the workshop so think it's better to let trackAirtime()
private. What I could do is put fillAirtimeInfo()
public so that the user may change the values and may fool around with the airtime system.
@Nicolasdejean no blocking, also no fooling around by the user. It's just an indication on the node-side, as @FokkeZB said to change behavior. The tracking itself will be done in the Network Server, further upstream after the Router and Broker.
@FokkeZB can you test and merge?
I will, but the branch has conflicts and is all dirty. It should be rebased and cherry picked.
@Nicolasdejean please resolve conflicts
Replaced by #84
Added a timer in sendbytes that calculates air-time of the uplink and a function showAirTime() to show you your air-time. #30