<?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: K22 + KSDK 1.3 C90TFS/FTFx Driver, FlashVerifySection(...) method in Kinetis Software Development Kit</title>
    <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/K22-KSDK-1-3-C90TFS-FTFx-Driver-FlashVerifySection-method/m-p/615078#M6394</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Chris,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The &lt;STRONG&gt;FlashVerifySection&lt;/STRONG&gt; command makes use of the "&lt;STRONG&gt;Read 1s Section&lt;/STRONG&gt;" command from the Kinetis Flash module. For K64 you can see in the Reference Manual that the required alignment is 16 bytes (128 bits):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_2.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/7433iDFAA3CBEC2BD2710/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_2.png" alt="pastedImage_2.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With 16 x 256 = 4096 bytes you can see that the whole &lt;STRONG&gt;4 KiB&lt;/STRONG&gt; sector is verified.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the K22FN512 the alignment would be 8 bytes (1 phrase):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_3.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/7480iCB5ECA2494281274/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_3.png" alt="pastedImage_3.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then &lt;STRONG&gt;Number&lt;/STRONG&gt; is calculated as next:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Number = FTFx_PSECTOR_SIZE / FSL_FEATURE_FLASH_PFLASH_SECTION_CMD_ADDRESS_ALIGMENT;&lt;/P&gt;&lt;P&gt;Number = 2048 / 8;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Number = 256;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this clarifies.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Best Regards!,&lt;BR /&gt;Jorge Gonzalez&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 19 Apr 2017 02:30:55 GMT</pubDate>
    <dc:creator>Jorge_Gonzalez</dc:creator>
    <dc:date>2017-04-19T02:30:55Z</dc:date>
    <item>
      <title>K22 + KSDK 1.3 C90TFS/FTFx Driver, FlashVerifySection(...) method</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/K22-KSDK-1-3-C90TFS-FTFx-Driver-FlashVerifySection-method/m-p/615077#M6393</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm using a K22FN512xxx12 device (FTFA flash controller) and I am trying to make sense of the "number" parameter in the FlashVerifySection(config, dest, &lt;STRONG&gt;number&lt;/STRONG&gt;, margin, commandSeq) function. &amp;nbsp;The description for the parameter in the C90TFS/FTFx Driver User Manual states: &amp;nbsp;"&lt;EM&gt;Number of alignment unit to be verified. Refer to corresponding reference manual to get correct information of alignment constrain&lt;/EM&gt;." [sic]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Searching through the reference manual I am not able to find the relevant information (I have no idea what I am looking for). &amp;nbsp;What I do know for my&amp;nbsp;K22&amp;nbsp;device:&lt;/P&gt;&lt;P&gt;Flash size: 512 KB&lt;/P&gt;&lt;P&gt;Block size: 256 KB&lt;BR /&gt;Sector size: 2048 B&lt;/P&gt;&lt;P&gt;Program size: 4 B&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The example application (For a K64 device) has the following code:&lt;/P&gt;&lt;PRE&gt;/* Verify section for several sector of PFLASH */
 number = FTFx_PSECTOR_SIZE/FSL_FEATURE_FLASH_PFLASH_SECTION_CMD_ADDRESS_ALIGMENT;
 for(margin_read_level = 0; margin_read_level &amp;lt; 0x2; margin_read_level++)
 {
&amp;nbsp;&amp;nbsp; ret = FlashVerifySection(&amp;amp;flashSSDConfig, destination, number, margin_read_level, g_FlashLaunchCommand);
&amp;nbsp;&amp;nbsp; if (FTFx_OK != ret)
&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ErrorTrap(ret);
&amp;nbsp;&amp;nbsp; }
 }&lt;/PRE&gt;&lt;P&gt;Where 'FTFx_PSECTOR_SIZE' =&amp;nbsp;4096 (for the example K64 project) and 'FSL_FEATURE_FLASH_PFLASH_SECTION_CMD_ADDRESS_ALIGMENT' = 16 (for the example K64 project). &amp;nbsp;This means &lt;STRONG&gt;&lt;EM&gt;number&lt;/EM&gt; &lt;/STRONG&gt;= 256 (for the example K64 project) which ... doesn't make any sense to me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How am I supposed to calculate the&amp;nbsp;&lt;EM&gt;&lt;STRONG&gt;number&lt;/STRONG&gt;&lt;/EM&gt; parameter for my device (MK22FN512xxx12) and what is its meaning / purpose?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for any help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Apr 2017 23:02:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/K22-KSDK-1-3-C90TFS-FTFx-Driver-FlashVerifySection-method/m-p/615077#M6393</guid>
      <dc:creator>chriskeeser</dc:creator>
      <dc:date>2017-04-17T23:02:14Z</dc:date>
    </item>
    <item>
      <title>Re: K22 + KSDK 1.3 C90TFS/FTFx Driver, FlashVerifySection(...) method</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/K22-KSDK-1-3-C90TFS-FTFx-Driver-FlashVerifySection-method/m-p/615078#M6394</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Chris,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The &lt;STRONG&gt;FlashVerifySection&lt;/STRONG&gt; command makes use of the "&lt;STRONG&gt;Read 1s Section&lt;/STRONG&gt;" command from the Kinetis Flash module. For K64 you can see in the Reference Manual that the required alignment is 16 bytes (128 bits):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_2.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/7433iDFAA3CBEC2BD2710/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_2.png" alt="pastedImage_2.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With 16 x 256 = 4096 bytes you can see that the whole &lt;STRONG&gt;4 KiB&lt;/STRONG&gt; sector is verified.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the K22FN512 the alignment would be 8 bytes (1 phrase):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_3.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/7480iCB5ECA2494281274/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_3.png" alt="pastedImage_3.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then &lt;STRONG&gt;Number&lt;/STRONG&gt; is calculated as next:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Number = FTFx_PSECTOR_SIZE / FSL_FEATURE_FLASH_PFLASH_SECTION_CMD_ADDRESS_ALIGMENT;&lt;/P&gt;&lt;P&gt;Number = 2048 / 8;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Number = 256;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this clarifies.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Best Regards!,&lt;BR /&gt;Jorge Gonzalez&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Apr 2017 02:30:55 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/K22-KSDK-1-3-C90TFS-FTFx-Driver-FlashVerifySection-method/m-p/615078#M6394</guid>
      <dc:creator>Jorge_Gonzalez</dc:creator>
      <dc:date>2017-04-19T02:30:55Z</dc:date>
    </item>
    <item>
      <title>Re: K22 + KSDK 1.3 C90TFS/FTFx Driver, FlashVerifySection(...) method</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/K22-KSDK-1-3-C90TFS-FTFx-Driver-FlashVerifySection-method/m-p/615079#M6395</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jorge, Thank you for clearing that up.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I wish that the documentation for the driver would mention that the VerifySection() made use of the "Read 1's" command so future developers would know where to look when trying to figure out what&amp;nbsp;&lt;STRONG&gt;&lt;EM&gt;number&amp;nbsp;&lt;/EM&gt;&lt;/STRONG&gt; should be.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Apr 2017 16:59:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/K22-KSDK-1-3-C90TFS-FTFx-Driver-FlashVerifySection-method/m-p/615079#M6395</guid>
      <dc:creator>chriskeeser</dc:creator>
      <dc:date>2017-04-19T16:59:25Z</dc:date>
    </item>
  </channel>
</rss>

