<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: fsl_sd.c issue in MCUXpresso SDK</title>
    <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892753#M1485</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;SPAN class=""&gt;Mike Spenard &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Using the correct clock source for the module, then the driver would take that clock and div and multiply it for the needed clock speed. The Reference MAnual Mentioned that the uSDHC module only supports:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;SPAN class=""&gt; &lt;SPAN class=""&gt;SD/SDIO UHS-I mode(up to 208 MHz in SDR mode, up to 50 MHz in DDR mode)&lt;/SPAN&gt; &lt;BR style="font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" /&gt; &lt;/SPAN&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Best regards&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Jorge Alcala&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 10 May 2019 21:48:41 GMT</pubDate>
    <dc:creator>jorge_a_vazquez</dc:creator>
    <dc:date>2019-05-10T21:48:41Z</dc:date>
    <item>
      <title>fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892746#M1478</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;I'm trying to incorporate SD-card support, based on the SDK's fatfs example, into my own project.&lt;/P&gt;&lt;P&gt;I have the pins and clock plumbed without conflict. And card detection works. However, whenever I try and format the card ( using f_mkfs() ), or do any write operation really, things get hung up.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;f_mkfs() calls SD_Write() in fsl_sd.c which then goes to check status but never returns. What would cause this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;EM&gt; /* Wait for the card's buffer to be not full to write to improve the write performance. */&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; while ((GET_SDMMCHOST_STATUS(card-&amp;gt;host.base) &amp;amp; CARD_DATA0_STATUS_MASK) != CARD_DATA0_NOT_BUSY)&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; {&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; }&lt;/EM&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 28 Apr 2019 02:21:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892746#M1478</guid>
      <dc:creator>mspenard603</dc:creator>
      <dc:date>2019-04-28T02:21:06Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892747#M1479</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;/P&gt;&lt;P&gt;Please let us know your chip part number. Thus we can have the right engineer to check your issue. Thanks.&lt;/P&gt;&lt;P&gt;Jun Zhang&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Apr 2019 06:00:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892747#M1479</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2019-04-29T06:00:47Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892748#M1480</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;iMXRT1062.&lt;/P&gt;&lt;P&gt;I tracked it down. Despite having pin_mux and clock .c files setup right the clocking was still off. This is because in the SDK example there's a #define in board.c that sets the PFD source.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Defaults:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;//#define BOARD_USDHC1_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_&lt;STRONG&gt;Pfd0&lt;/STRONG&gt;) / (CLOCK_GetDiv(kCLOCK_Usdhc1Div) + 1U))&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;//#define BOARD_USDHC2_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_&lt;STRONG&gt;Pfd0&lt;/STRONG&gt;) / (CLOCK_GetDiv(kCLOCK_Usdhc2Div) + 1U))&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;SDK example requires:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;#define BOARD_USDHC1_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_&lt;STRONG&gt;Pfd2&lt;/STRONG&gt;) / (CLOCK_GetDiv(kCLOCK_Usdhc1Div) + 1U)) // mls from SDK example&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;#define BOARD_USDHC2_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_&lt;STRONG&gt;Pfd2&lt;/STRONG&gt;) / (CLOCK_GetDiv(kCLOCK_Usdhc2Div) + 1U)) // mls from SDK example&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is very confusing because the main example source sets it up with pdf0 and yet even there it is commented as pdf2 !?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;void BOARD_InitSDcardClock(void)&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;{&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; /*configure system pll &lt;STRONG&gt;PFD2&lt;/STRONG&gt; fractional divider to 18*/&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; CLOCK_InitSysPfd(kCLOCK_&lt;STRONG&gt;Pfd0&lt;/STRONG&gt;, 0x12U);&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; /* Configure USDHC clock source and divider */&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; CLOCK_SetDiv(kCLOCK_Usdhc1Div, 0U);&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt; CLOCK_SetMux(kCLOCK_Usdhc1Mux, 1U);&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;}&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What is going on here?!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Apr 2019 14:20:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892748#M1480</guid>
      <dc:creator>mspenard603</dc:creator>
      <dc:date>2019-04-29T14:20:05Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892749#M1481</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks. Our iMXRT support will check your issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Apr 2019 15:01:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892749#M1481</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2019-04-29T15:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892750#M1482</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN class=""&gt;Hi Mike Spenard &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Sorry for the late response, this is an error in the example code and the configuration used for the board file. Please check the following post:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;A _jive_internal="true" class="jive_macro_thread jive_macro link-titled" data-orig-content="About Max Frequency of USDHC" href="https://community.nxp.com/thread/485686" title="About Max Frequency of USDHC"&gt;About Max Frequency of USDHC&lt;/A&gt; &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;TIC&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-------------------------------------------------------------------------------&lt;BR /&gt;Note:&lt;BR /&gt;- If this post answers your question, please click the "Mark Correct" button. Thank you!&lt;BR /&gt;-------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 May 2019 22:40:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892750#M1482</guid>
      <dc:creator>jorge_a_vazquez</dc:creator>
      <dc:date>2019-05-03T22:40:32Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892751#M1483</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Jorge for that link. I've set my project up as the link suggested:&lt;/P&gt;&lt;UL style="color: #51626f; background-color: #ffffff; border: 0px; padding: 0px 0px 0px 30px;"&gt;&lt;LI style="border: 0px; font-weight: inherit; margin: 0.5ex 0px;"&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro" style="border-width: 0px 0px 0px 2px; border-style: initial initial initial solid; border-color: initial initial initial #cccccc; font-weight: inherit; margin: 10px 0px; padding: 10px 20px;"&gt;&lt;P style="border: 0px; font-weight: inherit;"&gt;/* Init System pfd0. */&lt;/P&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;CLOCK_InitSysPfd(kCLOCK_Pfd0, 16);&lt;/DIV&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;/* Set USDHC1_PODF. */&lt;/DIV&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;CLOCK_SetDiv(kCLOCK_Usdhc1Div, 2);&lt;/DIV&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;/* Set Usdhc1 clock source. */&lt;/DIV&gt;&lt;DIV style="border: 0px; font-weight: inherit;"&gt;CLOCK_SetMux(kCLOCK_Usdhc1Mux, 1);&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;&lt;/LI&gt;&lt;LI style="border: 0px; font-weight: inherit; margin: 0.5ex 0px;"&gt;Change the definition of BOARD_SD_HOST_SUPPORT_SDR 104 _ FREQ on board.h as follows.&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro" style="border-width: 0px 0px 0px 2px; border-style: initial initial initial solid; border-color: initial initial initial #cccccc; font-weight: inherit; margin: 10px 0px; padding: 10px 20px;"&gt;&lt;P style="border: 0px; font-weight: inherit;"&gt;&lt;SPAN style="background-color: #f6f6f6; border: 0px; text-decoration: none;"&gt;#define BOARD_SD_HOST_SUPPORT_SDR104_FREQ (198000000U)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, I'm still getting erratic behavior from the SDcard bus. Reads go crazy with high ascii garbage occasionally. And sometimes with parts of a file going missing. ChaN FatFS isnt returning any errors, so I has to be getting garbage to start with.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Am I still suppose to be setting up board.h with the following?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;#define BOARD_USDHC1_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_Pfd2) / (CLOCK_GetDiv(kCLOCK_Usdhc1Div) + 1U)) // mls from SDK example&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;#define BOARD_USDHC2_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_Pfd2) / (CLOCK_GetDiv(kCLOCK_Usdhc2Div) + 1U)) // mls from SDK example&lt;/EM&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 May 2019 17:56:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892751#M1483</guid>
      <dc:creator>mspenard603</dc:creator>
      <dc:date>2019-05-09T17:56:35Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892752#M1484</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oh, just noticed my card, while it is a SDHC is not a UHS-I. Is there a way to configure the clocking to work with any available SDHC?!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 May 2019 19:08:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892752#M1484</guid>
      <dc:creator>mspenard603</dc:creator>
      <dc:date>2019-05-09T19:08:33Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892753#M1485</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;SPAN class=""&gt;Mike Spenard &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Using the correct clock source for the module, then the driver would take that clock and div and multiply it for the needed clock speed. The Reference MAnual Mentioned that the uSDHC module only supports:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;SPAN class=""&gt; &lt;SPAN class=""&gt;SD/SDIO UHS-I mode(up to 208 MHz in SDR mode, up to 50 MHz in DDR mode)&lt;/SPAN&gt; &lt;BR style="font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px;" /&gt; &lt;/SPAN&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Best regards&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Jorge Alcala&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 May 2019 21:48:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892753#M1485</guid>
      <dc:creator>jorge_a_vazquez</dc:creator>
      <dc:date>2019-05-10T21:48:41Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892754#M1486</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well the correct clock sourcing is not clear to me which is why I ask.The example code in board.c uses &lt;EM&gt;Pfd0&lt;/EM&gt; "&lt;SPAN style="color: #51626f; background-color: #f6f6f6;"&gt;CLOCK_InitSysPfd(kCLOCK_&lt;STRONG&gt;Pfd0&lt;/STRONG&gt;, 16);" while the board.h uses &lt;EM&gt;Pdf2&lt;/EM&gt; "#define BOARD_USDHC1_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_&lt;STRONG&gt;Pfd2&lt;/STRONG&gt;) / (CLOCK_GetDiv(kCLOCK_Usdhc1Div) + 1U))&amp;nbsp;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This doesn't make sense to me and seems incorrect.What are the correct settings for board.c and board.h?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;&amp;nbsp;/ms&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 May 2019 17:05:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892754#M1486</guid>
      <dc:creator>mspenard603</dc:creator>
      <dc:date>2019-05-11T17:05:42Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892755#M1487</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mike&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, as you mentioned, there is an error in the example code, it is incorrect to select Pfd0 clock and actually get the clock of the fdp2 to config the module. you could use the settings used by the example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="language-c line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;static&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;void&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;BOARD_USDHCClockConfiguration&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;void&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
    &lt;SPAN class="comment token"&gt;/*configure system pll PFD0 fractional divider to 18 pfd0 = 528MHz */&lt;/SPAN&gt;
    &lt;SPAN class="token function"&gt;CLOCK_InitSysPfd&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;kCLOCK_Pfd0&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;18U&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
    &lt;SPAN class="comment token"&gt;/* Configure USDHC clock source and divider 528 / 1 = 528MHz */&lt;/SPAN&gt;
    &lt;SPAN class="token function"&gt;CLOCK_SetDiv&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;kCLOCK_Usdhc1Div&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;0U&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
    &lt;SPAN class="token function"&gt;CLOCK_SetMux&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;kCLOCK_Usdhc1Mux&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;1U&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and change the line in the board.h file as:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="language-c line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="property macro token"&gt;#define BOARD_USDHC1_CLK_FREQ (CLOCK_GetSysPfdFreq(kCLOCK_Pfd0) / (CLOCK_GetDiv(kCLOCK_Usdhc1Div) + 1U))‍&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this could help you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Jorge Alcala&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2019 18:04:54 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892755#M1487</guid>
      <dc:creator>jorge_a_vazquez</dc:creator>
      <dc:date>2019-05-14T18:04:54Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892756#M1488</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you. The SDcard is detected and I can mount FatFS. But only if I press the reset button. If I do a flash or enter debug mode the SD card is detected but FatFS is unable to mount. For some reason it seems to need a cold power cycle. Any thoughts on how to fix this so I can run debug mode?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2019 20:19:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892756#M1488</guid>
      <dc:creator>mspenard603</dc:creator>
      <dc:date>2019-05-14T20:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892757#M1489</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN class=""&gt;Hi Mike Spenard &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Sorry for the late response, but I'm not able to reproduce the issue that you are seeing. I'm using an 8GB HC 1 memory. Your issue could be related to a big deviation of the clock from the ideal clock that you need, as you know, depending on the sd card technology you need a frequency, and you may have a big deviation with the card that you use.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;A class="link-titled" href="https://www.sdcard.org/press/past_evens/pdf/SD_Standards_and_Technology_GWTaipei_Oct2014.pdf" title="https://www.sdcard.org/press/past_evens/pdf/SD_Standards_and_Technology_GWTaipei_Oct2014.pdf"&gt;https://www.sdcard.org/press/past_evens/pdf/SD_Standards_and_Technology_GWTaipei_Oct2014.pdf&lt;/A&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Regards&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 May 2019 16:22:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892757#M1489</guid>
      <dc:creator>jorge_a_vazquez</dc:creator>
      <dc:date>2019-05-21T16:22:50Z</dc:date>
    </item>
    <item>
      <title>Re: fsl_sd.c issue</title>
      <link>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892758#M1490</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No worries,&lt;SPAN style="color: #4a4a4d; background-color: #ffffff; font-size: 16px;"&gt;&lt;SPAN&gt;&amp;nbsp;I&amp;nbsp;&lt;/SPAN&gt;traced the f_mount() issue down to a difference between NXP's eval board and EmbeddedArtists'. I was unaware that SD_Reset is on a different pin with EmbArt's RT1062 board. What is confusing is getting this sd_reset pin mapping wrong presents itself as a check_fs() FAT signature-block mismatch error within f_mount().&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 May 2019 11:45:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MCUXpresso-SDK/fsl-sd-c-issue/m-p/892758#M1490</guid>
      <dc:creator>mspenard603</dc:creator>
      <dc:date>2019-05-22T11:45:42Z</dc:date>
    </item>
  </channel>
</rss>

