Skip to main content
David Littell
Senior II
August 20, 2018
Question

Why such an insane value for SDMMC_CMDTIMEOUT?

  • August 20, 2018
  • 2 replies
  • 671 views

Why is the value for stm32f7xx_ll_sdmmc.h's SDMMC_CMDTIMEOUT (5 seconds!) so insanely huge as compared to the Reference Manual SDMMC_STA.CTIMEOUT description and the MMC Ncr timing?

    This topic has been closed for replies.

    2 replies

    Tesla DeLorean
    Guru
    August 20, 2018

    You think that's a long time...

    #define SDMMC_DATATIMEOUT                 ((uint32_t)0xFFFFFFFFU)

    #define SDMMC_CMDTIMEOUT                  ((uint32_t)5000U)       /* Command send and response timeout */

    #define SDMMC_MAXERASETIMEOUT             ((uint32_t)63000U)      /* Max erase Timeout 63 s           */

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    David Littell
    Senior II
    August 21, 2018

    Yeah, I've seen those too. It'd be helpful if there was some commentary explaining such ludicrous values, especially in the case of SDMMC_CMDTIMEOUT, which should rightfully have a value no larger than (64 + 48 + some_small_number) * (SDMMC_CK period).

    Hello, ST? 5 seconds checking for bits that should (must!) be set in << 1 mSec?