aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ui.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/ui.c b/ui.c
index 6d32031..408724f 100644
--- a/ui.c
+++ b/ui.c
@@ -257,8 +257,7 @@ static void doAlarm () {
*/
static void doInit () {
/* get initial orientation */
- h = accelGetHorizon ();
- if (h != HORIZON_NONE) {
+ if (horizonChanged && h != HORIZON_NONE) {
puts ("init->idle");
enterIdle ();