Переглянути джерело

reinitialize the timestamp to ensure enough time to receive response for 0xFF sent.

rhounsell 4 роки тому
батько
коміт
32fa8caab8
1 змінених файлів з 1 додано та 0 видалено
  1. 1 0
      Firmware/Sd2Card.cpp

+ 1 - 0
Firmware/Sd2Card.cpp

@@ -321,6 +321,7 @@ bool Sd2Card::init(uint8_t sckRateID, uint8_t chipSelectPin) {
   }
 
   // send 0xFF until 0xFF received to give card some clock cycles
+  t0 = (uint16_t)_millis();
   SERIAL_ECHOLNRPGM(PSTR("Sending 0xFF"));
   spiSend(0XFF);
   while ((status_ = spiRec()) != 0xFF)