From 6e92b73b935fced594ffe5dc7545639225c99b06 Mon Sep 17 00:00:00 2001 From: Arseniy-Movshev Date: Mon, 5 Jun 2023 18:19:49 +0100 Subject: Add a log message to debug failing step counter resets --- daemon/sensorPlugins/stepCounter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'daemon') diff --git a/daemon/sensorPlugins/stepCounter.cpp b/daemon/sensorPlugins/stepCounter.cpp index 1ab09eb..a01c0b9 100644 --- a/daemon/sensorPlugins/stepCounter.cpp +++ b/daemon/sensorPlugins/stepCounter.cpp @@ -68,7 +68,7 @@ void StepCounterPlugin::triggerRecording() int steps = stepcounterSensor->reading()->steps(); fileAddRecord(sensorPathPrefix, QString::number(steps), QDateTime(QDate::currentDate().addDays(-1), QTime(23, 59, 59))); // this writes the current step count to the last second of the previous day stepcounterSensor->reading()->setSteps(0); // and then we reset the step counter - qDebug() << "date change detected; recorded " << steps << " to previous day and reset step counter hw"; + qDebug() << "date change detected; recorded " << steps << " to previous day and reset step counter hw. Step counter now holds " << stepcounterSensor->reading()->steps() << " steps"; } else { int steps = stepcounterSensor->reading()->steps(); qDebug() << QDateTime::currentDateTime().toString("hh:mm:ss") << " : " << steps << stepcounterSensor->isActive(); -- cgit v1.2.3-54-g00ecf