badge/ui/event: Beim Warten pmuSleep().
authorWintermate <wintermute@hannover.ccc.de>
Fri, 25 Oct 2013 00:30:56 +0000 (02:30 +0200)
committerWintermate <wintermute@hannover.ccc.de>
Fri, 25 Oct 2013 00:30:56 +0000 (02:30 +0200)
badge/ui/event.c

index 157c8c9..c705a0e 100644 (file)
@@ -1,6 +1,7 @@
 #include "event.h"
 
 #include <core/gpio/gpio.h>
+#include <core/pmu/pmu.h>
 #include <core/timer32/timer32.h>
 
 #ifdef R0KET
@@ -68,8 +69,9 @@ void badge_event_irq(void) {
 }
 
 badge_event_t badge_event_wait(void) {
-  while(!event_flag)
-    ;
+  while(!event_flag) {
+    pmuSleep();
+  }
 
   // User input takes precedence.
   if(event_flag & BADGE_EVENT_FLAG_INPUT) {
This page took 0.03001 seconds and 4 git commands to generate.