always reset mac counters even if lora package could not been sent
fixes #76
This commit is contained in:
parent
28f0396185
commit
4fce10b03e
@ -153,6 +153,7 @@ void do_send(osjob_t *j) {
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
end:
|
||||||
// clear counter if not in cumulative counter mode
|
// clear counter if not in cumulative counter mode
|
||||||
if (cfg.countermode != 1) {
|
if (cfg.countermode != 1) {
|
||||||
reset_counters(); // clear macs container and reset all counters
|
reset_counters(); // clear macs container and reset all counters
|
||||||
@ -161,7 +162,6 @@ void do_send(osjob_t *j) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Schedule next transmission
|
// Schedule next transmission
|
||||||
end:
|
|
||||||
os_setTimedCallback(&sendjob, os_getTime() + sec2osticks(cfg.sendcycle * 2),
|
os_setTimedCallback(&sendjob, os_getTime() + sec2osticks(cfg.sendcycle * 2),
|
||||||
do_send);
|
do_send);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user