aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars-Dominik Braun <lars@6xq.net>2014-12-15 13:00:48 +0100
committerLars-Dominik Braun <lars@6xq.net>2014-12-15 13:00:48 +0100
commitbaff9933bb21440df0cd78dbf65d794e793d7e4b (patch)
tree7f5c7725dbf4fc7d355395504c9fab5837aebcfd
parente3fab7cf4072aa7792b1bb371377bc2fd208ede0 (diff)
downloadhourglass-baff9933bb21440df0cd78dbf65d794e793d7e4b.tar.gz
hourglass-baff9933bb21440df0cd78dbf65d794e793d7e4b.tar.bz2
hourglass-baff9933bb21440df0cd78dbf65d794e793d7e4b.zip
ui: Reduce required shake count to 1
Gesture detection has been fixed with commit 254fb0c490c62c0e29518cab2d8b5c90a30b378c, one shake now actually sets the counter to one.
-rw-r--r--ui.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ui.c b/ui.c
index a387c17..b08ee41 100644
--- a/ui.c
+++ b/ui.c
@@ -128,7 +128,7 @@ static void setFine (const int8_t value) {
/* Coarse timer setting, selects from 0 to 60 minutes, in 10 min steps
*/
static void doSelectCoarse () {
- if (accelGetShakeCount () >= 2) {
+ if (accelGetShakeCount () >= 1) {
/* selection */
accelResetShakeCount ();
mode = UIMODE_SELECT_FINE;
@@ -158,7 +158,7 @@ static void doSelectCoarse () {
/* Fine timer setting, selects from -5 to 5 minutes, in 1 min steps
*/
static void doSelectFine () {
- if (accelGetShakeCount () >= 2) {
+ if (accelGetShakeCount () >= 1) {
/* stop selection */
accelResetShakeCount ();
speakerStart (SPEAKER_BEEP);
@@ -205,7 +205,7 @@ static void doIdle () {
timerStart (brightnessStep);
puts ("idle->run");
speakerStart (SPEAKER_BEEP);
- } else if (accelGetShakeCount () >= 2) {
+ } else if (accelGetShakeCount () >= 1) {
/* set timer */
accelResetShakeCount ();
gyroStart ();