summaryrefslogtreecommitdiff
path: root/src/components/settings/Settings.h
diff options
context:
space:
mode:
authorTim Keller <geekboy1011@gmail.com>2021-09-27 02:52:02 (GMT)
committerTim Keller <geekboy1011@gmail.com>2022-01-04 01:59:01 (GMT)
commit3ebf002f9db75513d036c0eaa0863e75882b3a40 (patch)
treec9e78252084716e797b56793c8b7f1cbd51188be /src/components/settings/Settings.h
parentad42cdf120ddd835331be6c1d1ee86e8e14a4479 (diff)
Add start of settings app for senstivity.
really just debugging. I want to make it more configurable then high med low. Position of setting needs a new location...dynamicly adding it currently at the end. Which honestly im fine with.
Diffstat (limited to 'src/components/settings/Settings.h')
-rw-r--r--src/components/settings/Settings.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/components/settings/Settings.h b/src/components/settings/Settings.h
index 928d04c..a414573 100644
--- a/src/components/settings/Settings.h
+++ b/src/components/settings/Settings.h
@@ -109,10 +109,19 @@ namespace Pinetime {
}
settings.screenTimeOut = timeout;
};
+
uint32_t GetScreenTimeOut() const {
return settings.screenTimeOut;
};
+ void SetShakeThreshold(uint16_t thresh){
+ settings.shakeWakeThreshold = thresh;
+ }
+
+ int16_t GetShakeThreshold() const{
+ return settings.shakeWakeThreshold;
+ }
+
void setWakeUpMode(WakeUpMode wakeUp, bool enabled) {
if (enabled != isWakeUpModeOn(wakeUp)) {
settingsChanged = true;
@@ -164,7 +173,7 @@ namespace Pinetime {
private:
Pinetime::Controllers::FS& fs;
- static constexpr uint32_t settingsVersion = 0x0003;
+ static constexpr uint32_t settingsVersion = 0x0004;
struct SettingsData {
uint32_t version = settingsVersion;
uint32_t stepsGoal = 10000;
@@ -178,7 +187,7 @@ namespace Pinetime {
PineTimeStyle PTS;
std::bitset<4> wakeUpMode {0};
-
+ uint16_t shakeWakeThreshold = 300;
Controllers::BrightnessController::Levels brightLevel = Controllers::BrightnessController::Levels::Medium;
};