Browse Source

Arduino 20 PWM 9/10 issue fix

Peter Knight 14 years ago
parent
commit
6c38654906
1 changed files with 5 additions and 5 deletions
  1. 5 5
      optiboot/bootloaders/optiboot/optiboot.c

+ 5 - 5
optiboot/bootloaders/optiboot/optiboot.c

@@ -234,6 +234,11 @@ int main(void) {
 
   uint8_t ch;
 
+  // Adaboot no-wait mod
+  ch = MCUSR;
+  MCUSR = 0;
+  if (!(ch & _BV(EXTRF))) appStart();
+
 #if LED_START_FLASHES > 0
   // Set up Timer 1 for timeout counter
   TCCR1B = _BV(CS12) | _BV(CS10); // div 1024
@@ -252,11 +257,6 @@ int main(void) {
 #endif
 #endif
 
-  // Adaboot no-wait mod
-  ch = MCUSR;
-  MCUSR = 0;
-  if (!(ch & _BV(EXTRF))) appStart();
-
   // Set up watchdog to trigger after 500ms
   watchdogConfig(WATCHDOG_1MS);