comparison testavr.c @ 53:98b5a43fc748

Disable WDT in reset just in case we take too long (eg after reset when the timer is set to a short time)
author darius@Inchoate
date Wed, 29 Oct 2008 16:11:15 +1030
parents 3217e93b28a3
children 58f1ec46bff6
comparison
equal deleted inserted replaced
52:3217e93b28a3 53:98b5a43fc748
55 */ 55 */
56 void handle_mcucsr(void) 56 void handle_mcucsr(void)
57 __attribute__((section(".init3"))) 57 __attribute__((section(".init3")))
58 __attribute__((naked)); 58 __attribute__((naked));
59 void handle_mcucsr(void) { 59 void handle_mcucsr(void) {
60 wdt_disable();
60 mcucsr = MCUCSR; 61 mcucsr = MCUCSR;
61 MCUCSR = 0; 62 MCUCSR = 0;
62 } 63 }
63 64
64 int 65 int