 
 void setup()
 {  
-//  pinMode(LED, OUTPUT);
+  //  pinMode(LED, OUTPUT);
 
   attachInterrupt(interupt, BtnDownCB, FALLING );
 
   // Call the function to enable low power consumption
-  #if !NORMALPOW
-    ble_low_power();
-  #else 
-   Serial.begin(9600);
-  #endif
+#if !NORMALPOW
+  ble_low_power();
+#else 
+  Serial.begin(9600);
+#endif
   time =1; // init the time to 1, to make it different from 0
   // If you are using the Blend, uncomment below
   ble_set_pins(6, 7);
-   ble_set_name("Stroller");
+  ble_set_name("Stroller");
 
   // Init. and start BLE library.
   ble_begin();
 
   // prepare SD data logging!
-//
+  //
   if (!SD.begin(10, 11, 12, 13)) { // important: this is custom code for the leonardo, see https://learn.adafruit.com/adafruit-data-logger-shield/for-the-mega-and-leonardo
 
   } 

{   
  PRR0 = 0x00;  // Power Reduction Register: open timer
  PRR1 = 0x00;
  #if DEBUG
  digitalWrite(LED,HIGH);
    #endif
  hadRound = 1;
}





    // Open up the file we're going to log to!
    dataFile = SD.open("datalog.txt", FILE_WRITE);
    runs=SD.open("run.txt",FILE_WRITE);
  }


  //  setSyncProvider(RTC.get);
}


ISR(WDT_vect)
{
#if DEBUG
  if (ble_connected()) {
    ble_write_bytes((unsigned char *)"wakelock",8);

  }
#endif
  time = time +8;

}


void stroller_ble_print() {
#if NORMALPOW
  Serial.println("printing distance");
#endif
  if (ble_connected()) {
    char output[26];
    // length of output should be: 5 fixed, 10 time, 10 distance, but must be one longer?!?
    sprintf(output,"D:%10lu:%10lu\n\n",time,curDistance);

    ble_write_bytes((unsigned char *)output,26);
  }
}

