aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2016-09-12 20:23:53 +0200
committerMatthias P. Braendli <matthias.braendli@mpb.li>2016-09-12 20:23:53 +0200
commit1178a81fd9ad7d02d0207eb3d5a7279e88ec52b0 (patch)
tree56cae8b25d61a4e07698e576cb2334ab19452dac
parent6e450da36c51d49478dd529e3ab77da571210f7e (diff)
downloadglutte-o-matic-1178a81fd9ad7d02d0207eb3d5a7279e88ec52b0.tar.gz
glutte-o-matic-1178a81fd9ad7d02d0207eb3d5a7279e88ec52b0.tar.bz2
glutte-o-matic-1178a81fd9ad7d02d0207eb3d5a7279e88ec52b0.zip
Minor short beacon counter simplification
-rw-r--r--src/common/src/Core/fsm.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/common/src/Core/fsm.c b/src/common/src/Core/fsm.c
index 7fabb55..db1f05c 100644
--- a/src/common/src/Core/fsm.c
+++ b/src/common/src/Core/fsm.c
@@ -189,11 +189,9 @@ void fsm_update() {
}
// Increment the SHORT_BEACON counter based on time spent in the state
- if (short_beacon_counter_s < SHORT_BEACON_MAX) {
- while(short_beacon_counter_s < SHORT_BEACON_MAX && (fsm_current_state_time_s() - short_beacon_counter_last_update > 1)) {
- short_beacon_counter_last_update++;
- short_beacon_counter_s++;
- }
+ while(short_beacon_counter_s < SHORT_BEACON_MAX && (fsm_current_state_time_s() - short_beacon_counter_last_update > 1)) {
+ short_beacon_counter_last_update++;
+ short_beacon_counter_s++;
}
if (fsm_in.tone_1750) {