diff --git a/CMakeLists.txt b/CMakeLists.txt index 6923efa..e520d34 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -245,6 +245,14 @@ add_library(littlefs STATIC target_include_directories(littlefs PUBLIC "${InfiniTime_DIR}/src/libs/littlefs") target_link_libraries(infinisim PRIVATE littlefs) +# sunset +add_library(sunset STATIC + ${InfiniTime_DIR}/src/libs/sunset/src/sunset.h + ${InfiniTime_DIR}/src/libs/sunset/src/sunset.cpp +) +target_include_directories(sunset PUBLIC "${InfiniTime_DIR}/src/libs/sunset") +target_link_libraries(infinisim PRIVATE sunset) + # QCBOR add_library(QCBOR STATIC ${InfiniTime_DIR}/src/libs/QCBOR/src/ieee754.c diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..0c2200c --- /dev/null +++ b/build.sh @@ -0,0 +1,3 @@ +cmake -S . -B build -DInfiniTime_DIR=/home/wbradley/apps/infinitime \ + -DENABLE_USERAPPS="Apps::Navigation, Apps::StopWatch, Apps::Timer, Apps::Alarm, Apps::Steps, Apps::HeartRate, Apps::Music, Apps::Twos" +cmake --build build && build/infinisim \ No newline at end of file diff --git a/main.cpp b/main.cpp index 3e57a1b..1050978 100644 --- a/main.cpp +++ b/main.cpp @@ -852,14 +852,10 @@ public: void switch_to_screen(uint8_t screen_idx) { if (screen_idx == 1) { - settingsController.SetWatchFace(Pinetime::Applications::WatchFace::Digital); - displayApp.StartApp(Pinetime::Applications::Apps::Clock, Pinetime::Applications::DisplayApp::FullRefreshDirections::None); - } - else if (screen_idx == 2) { settingsController.SetWatchFace(Pinetime::Applications::WatchFace::Analog); displayApp.StartApp(Pinetime::Applications::Apps::Clock, Pinetime::Applications::DisplayApp::FullRefreshDirections::None); } - else if (screen_idx == 3) { + else if (screen_idx == 2) { settingsController.SetWatchFace(Pinetime::Applications::WatchFace::PineTimeStyle); displayApp.StartApp(Pinetime::Applications::Apps::Clock, Pinetime::Applications::DisplayApp::FullRefreshDirections::None); }