1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-17 13:25:20 +03:00

SD timeouts increased [Horus]

This commit is contained in:
Damjan Adamic 2016-09-19 20:44:26 +02:00
parent 3fddb28c4f
commit 3b10c28b66
2 changed files with 4 additions and 4 deletions

View file

@ -166,7 +166,7 @@ DRESULT __disk_read(
if (Status == SD_OK) {
SDTransferState State;
Status = SD_WaitReadOperation(100*count); // Check if the Transfer is finished
Status = SD_WaitReadOperation(200*count); // Check if the Transfer is finished
while ((State = SD_GetStatus()) == SD_TRANSFER_BUSY); // BUSY, OK (DONE), ERROR (FAIL)

View file

@ -70,7 +70,7 @@
#define SD_SINGLE_BUS_SUPPORT ((uint32_t)0x00010000)
#define SD_CARD_LOCKED ((uint32_t)0x02000000)
#define SD_DATATIMEOUT ((uint32_t)100000)
#define SD_DATATIMEOUT ((uint32_t)1000000)
#define SD_0TO7BITS ((uint32_t)0x000000FF)
#define SD_8TO15BITS ((uint32_t)0x0000FF00)
#define SD_16TO23BITS ((uint32_t)0x00FF0000)
@ -1385,7 +1385,7 @@ OPTIMIZE("O0") SD_Error SD_WaitReadOperation(uint32_t timeout)
DMAEndOfTransfer = 0;
timeout = 10;
timeout = 100;
while(((SDIO->STA & SDIO_FLAG_RXACT)) && (timeout > 0))
{
@ -1622,7 +1622,7 @@ OPTIMIZE("O0") SD_Error SD_WaitWriteOperation(uint32_t timeout)
DMAEndOfTransfer = 0;
timeout = 10;
timeout = 100;
while(((SDIO->STA & SDIO_FLAG_TXACT)) && (timeout > 0))
{