瀏覽代碼

Even more startup clock cycles - clear any stale card state

main
PaulStoffregen 7 年之前
父節點
當前提交
e02764de2f
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. +1
    -1
      utility/KinetisSDHC.c

+ 1
- 1
utility/KinetisSDHC.c 查看文件

@@ -310,7 +310,7 @@ static uint8_t SDHC_Init(void)
// initial clocks... SD spec says only 74 clocks are needed, but if Teensy rebooted
// while the card was in middle of an operation, thousands of clock cycles can be
// needed to get the card to complete a prior command and return to a usable state.
for (i=0; i < 50; i++) {
for (i=0; i < 500; i++) {
SDHC_SYSCTL |= SDHC_SYSCTL_INITA;
while (SDHC_SYSCTL & SDHC_SYSCTL_INITA) { };
}

Loading…
取消
儲存