Skip to content

Commit b762d30

Browse files
committed
feat: add sleeptracking controller
Related infinitime PR: InfiniTimeOrg/InfiniTime#2304
1 parent 56ed755 commit b762d30

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,8 @@ target_sources(infinisim PUBLIC
205205
${InfiniTime_DIR}/src/components/ble/NotificationManager.cpp
206206
${InfiniTime_DIR}/src/components/ble/SimpleWeatherService.h
207207
${InfiniTime_DIR}/src/components/ble/SimpleWeatherService.cpp
208+
${InfiniTime_DIR}/src/components/sleeptracking/SleepTrackingController.h
209+
${InfiniTime_DIR}/src/components/sleeptracking/SleepTrackingController.cpp
208210
${InfiniTime_DIR}/src/components/fs/FS.h
209211
${InfiniTime_DIR}/src/components/fs/FS.cpp
210212
${InfiniTime_DIR}/src/components/motion/MotionController.h

main.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
#include "components/motor/MotorController.h"
3939
#include "components/datetime/DateTimeController.h"
4040
#include "components/heartrate/HeartRateController.h"
41+
#include "components/sleeptracking/SleepTrackingController.h"
4142
#include "components/fs/FS.h"
4243
#include "drivers/Spi.h"
4344
#include "drivers/SpiMaster.h"
@@ -370,6 +371,11 @@ Pinetime::Controllers::AlarmController alarmController {dateTimeController};
370371
Pinetime::Controllers::TouchHandler touchHandler;
371372
Pinetime::Controllers::ButtonHandler buttonHandler;
372373
Pinetime::Controllers::BrightnessController brightnessController {};
374+
Pinetime::Controllers::SleepTrackingController sleeptrackingController {fs,
375+
dateTimeController,
376+
motionSensor,
377+
heartRateController,
378+
motorController};
373379

374380
Pinetime::Applications::DisplayApp displayApp(lcd,
375381
touchPanel,
@@ -387,6 +393,7 @@ Pinetime::Applications::DisplayApp displayApp(lcd,
387393
#endif
388394
alarmController,
389395
brightnessController,
396+
sleeptrackingController,
390397
touchHandler,
391398
fs,
392399
spiNorFlash);
@@ -402,6 +409,7 @@ Pinetime::System::SystemTask systemTask(spi,
402409
timerController,
403410
#endif
404411
alarmController,
412+
sleeptrackingController,
405413
watchdog,
406414
notificationManager,
407415
heartRateSensor,

0 commit comments

Comments
 (0)