diff options
author | Jean-François Milants <jf@codingfield.com> | 2021-10-10 16:48:45 +0200 |
---|---|---|
committer | Jean-François Milants <jf@codingfield.com> | 2021-10-10 16:48:45 +0200 |
commit | 6d0e68d6260044dcce09ebf879a48e314987f808 (patch) | |
tree | ef9f0325f56fb22f7ce4a79321b61ad5da415a46 /src/systemtask | |
parent | 92aeae73dee5bb16f669806621a9b735f2b0ce07 (diff) | |
parent | f61e88b8425f9edcd38e47027df62dcc56c83adc (diff) |
Merge branch 'update_touch_driver' of git://github.com/Riksu9000/InfiniTime into Riksu9000-update_touch_driver
# Conflicts:
# src/displayapp/Apps.h
Diffstat (limited to 'src/systemtask')
-rw-r--r-- | src/systemtask/SystemTask.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/systemtask/SystemTask.cpp b/src/systemtask/SystemTask.cpp index 12388290..f79fd8e5 100644 --- a/src/systemtask/SystemTask.cpp +++ b/src/systemtask/SystemTask.cpp @@ -23,6 +23,7 @@ #include "drivers/Hrs3300.h" #include "drivers/PinMap.h" #include "main.h" +#include "BootErrors.h" #include <memory> @@ -116,6 +117,8 @@ void SystemTask::Process(void* instance) { } void SystemTask::Work() { + BootErrors bootError = BootErrors::None; + watchdog.Setup(7); watchdog.Start(); NRF_LOG_INFO("Last reset reason : %s", Pinetime::Drivers::Watchdog::ResetReasonToString(watchdog.ResetReason())); @@ -133,7 +136,9 @@ void SystemTask::Work() { lcd.Init(); twiMaster.Init(); - touchPanel.Init(); + if (!touchPanel.Init()) { + bootError = BootErrors::TouchController; + } dateTimeController.Register(this); batteryController.Register(this); motorController.Init(); @@ -151,7 +156,7 @@ void SystemTask::Work() { settingsController.Init(); displayApp.Register(this); - displayApp.Start(); + displayApp.Start(bootError); heartRateSensor.Init(); heartRateSensor.Disable(); |