From 1c1a227b53bb417e4f73fd7e8e912955d93b7ce7 Mon Sep 17 00:00:00 2001 From: Florent Duchon Date: Wed, 16 May 2012 22:57:03 +0200 Subject: digital/beacon: start & stop codewheel timer task according to the motor state --- digital/beacon/src/motor.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/digital/beacon/src/motor.c b/digital/beacon/src/motor.c index 56682b48..b6453190 100644 --- a/digital/beacon/src/motor.c +++ b/digital/beacon/src/motor.c @@ -50,13 +50,14 @@ void motor_init(void) void motor_start(void) { OCR0A = 115; - + start_codewheel_timer_task(); } /* This function stops the motor rotation */ void motor_stop(void) { OCR0A = 0; + stop_codewheel_timer_task(); } /* This function returns the motor state */ -- cgit v1.2.3