  ***************************************************/
 ISR(WDT_vect)
 {
-  Serial.print(millis());
-  Serial.println(" Watchdog overrun");
+//  Serial.print(millis());
+//  Serial.println(" Watchdog overrun");
+  Serial.println(" ");
+  Serial.print("Distance: ");
+  Serial.println(distanceToDate);
 }
 
 

  
  /* Setup the pin direction. */
  pinMode(pin2, INPUT);
   
  /* Clear the reset flag. */
  MCUSR &= ~(1<<WDRF);
  

 ***************************************************/
void enterSleep(void)
{
//      Serial.println("Going to sleep");
  
  /* Setup pin2 as an interrupt and attach handler. */
   if (digitalRead(2)==HIGH){
  sleep_enable();

  attachInterrupt(0, countRPM, LOW);
    set_sleep_mode(SLEEP_MODE_PWR_DOWN);
//  delay(100);
//  cli();
//  sleep_bod_disable();
//sei();
  

  
  
  sleep_cpu();
  
  /* The program will continue from here. */
  
  /* First thing to do is disable sleep. */
  sleep_disable(); 
   } else {
//     Serial.println("not yet going to sleep"); 
   }
}


