   // Otherwise it is an illegal key. Flash led for 5 seconds
   trace << dev << PSTR(":ILLEGAL KEY") << endl;
   for (uint8_t i = 0; i < 10; i++) {
-    ledPin.on();
+    redLed.on();
     MSLEEP(250);
-    ledPin.off();
+    redLed.off();
     MSLEEP(250);
   }
 }

  uart.begin(9600);
  trace.begin(&uart, PSTR("CosaDS1990A: started"));

  // Initiate the watchdog for sleep
  Watchdog::begin();
}


  for (uint8_t i = 0; i < sizeof(KEY); i += OWI::ROM_MAX) {
    if (!memcmp_P(rom, &KEY[i], OWI::ROM_MAX)) {
      trace << dev << PSTR(":AUTHORIZED KEY") << endl;
      greenLed.on();
      SLEEP(5);
      greenLed.off();
      return;
    }
  }
