summaryrefslogtreecommitdiff
path: root/daemon/sensorPlugins/stepCounter.h
diff options
context:
space:
mode:
authorArseniy-Movshev <dodoradio@outlook.com>2023-06-10 00:29:19 +0100
committerArseniy-Movshev <dodoradio@outlook.com>2023-06-20 00:05:28 +0100
commit451388685a13669561b778e5719379db39164d47 (patch)
tree2b8e36bece5d78e2c528c6f2dcb9cdd47aa3736b /daemon/sensorPlugins/stepCounter.h
parent79184000729be9c1615d3a07449d1244dcacd887 (diff)
Compensate for steps when daemon starts up and when date changes
This is a radical new approach where we just scrap all steps that have happened outside of the current day. Theoretically, this should be more robust. Remains to be seen whether it actually does work any better.
Diffstat (limited to 'daemon/sensorPlugins/stepCounter.h')
-rw-r--r--daemon/sensorPlugins/stepCounter.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/daemon/sensorPlugins/stepCounter.h b/daemon/sensorPlugins/stepCounter.h
index cb6a7e4..ad8d8d6 100644
--- a/daemon/sensorPlugins/stepCounter.h
+++ b/daemon/sensorPlugins/stepCounter.h
@@ -35,7 +35,7 @@ private:
int interval;
QTimer *recordIntervalTimer;
QStepCounterSensor *stepcounterSensor;
- int m_stepsOffset;
+ int m_stepsOffset = 0;
QSettings *m_settings;
const QString sensorPathPrefix = "stepCounter";