diff options
Diffstat (limited to 'lock/scan.c')
| -rw-r--r-- | lock/scan.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lock/scan.c b/lock/scan.c index e375111..6784e9a 100644 --- a/lock/scan.c +++ b/lock/scan.c @@ -4,6 +4,7 @@ #include <stdlib.h> #include <avr/interrupt.h> +#include <avr/wdt.h> #include <util/delay.h> #include "nrfm.h" @@ -22,6 +23,7 @@ int main(void) TCCR1B |= (1 << WGM13) | (1 << CS11); ICR1 = 20000; + wdt_init(); uart_init(); radio_init(rxaddr); radio_print_config(); @@ -29,6 +31,8 @@ int main(void) sei(); for (;;) { + wdt_reset(); + _delay_ms(2000); } return 0; |
