summaryrefslogtreecommitdiff
path: root/src/binwatch
diff options
context:
space:
mode:
Diffstat (limited to 'src/binwatch')
-rw-r--r--src/binwatch/Makefile4
-rw-r--r--src/binwatch/binwatch.c2
-rw-r--r--src/binwatch/counter.c2
3 files changed, 6 insertions, 2 deletions
diff --git a/src/binwatch/Makefile b/src/binwatch/Makefile
index e123a2c..dd7404b 100644
--- a/src/binwatch/Makefile
+++ b/src/binwatch/Makefile
@@ -1,7 +1,7 @@
BASE = $b/digital/avr
AVR_PROGS = counter binwatch
-counter_SOURCES = counter.c led.c button.c
-binwatch_SOURCES = binwatch.c led.c rtc.c button.c
+counter_SOURCES = counter.c led.c button.c power.c
+binwatch_SOURCES = binwatch.c led.c rtc.c button.c power.c
MODULES = utils
binwatch_MODULES = utils twi
CONFIGFILE = avrconfig.h
diff --git a/src/binwatch/binwatch.c b/src/binwatch/binwatch.c
index de48181..99283f3 100644
--- a/src/binwatch/binwatch.c
+++ b/src/binwatch/binwatch.c
@@ -25,6 +25,7 @@
#include "common/led.h"
#include "common/rtc.h"
#include "common/button.h"
+#include "common/power.h"
/** Get time in leds format. */
static uint16_t
@@ -42,6 +43,7 @@ int
main (void)
{
/* Initialise hardware. */
+ power_init ();
led_init ();
button_init ();
/* Initialise RTC. */
diff --git a/src/binwatch/counter.c b/src/binwatch/counter.c
index 71f9ba5..ff72c0d 100644
--- a/src/binwatch/counter.c
+++ b/src/binwatch/counter.c
@@ -24,10 +24,12 @@
#include "common.h"
#include "common/led.h"
#include "common/button.h"
+#include "common/power.h"
int
main (void)
{
+ power_init ();
led_init ();
button_init ();
uint16_t i;