<?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: FTFL FTFE Flash controller behaviour in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/FTFL-FTFE-Flash-controller-behaviour/m-p/394917#M21660</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Lovro Oreskovic:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the FTFE case the programming operations must always point to a 64-bit aligned address and always provide the whole 8 bytes, disregarding if you don use them all. If you look at the &lt;STRONG&gt;Program Phrase&lt;/STRONG&gt; parameters in the Reference Manual it may help you:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_0.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/22211i96DA203B1E740281/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_0.png" alt="pastedImage_0.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So the command expects 8 bytes to be written at a 64-bit aligned address. You can decide to program as many bytes as you want from those 8 bytes (1 in your case), but the next time you want to update the same phrase then an erase must be launched first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this clarifies.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards!&lt;/P&gt;&lt;P&gt;Jorge Gonzalez&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 14 Oct 2015 15:26:45 GMT</pubDate>
    <dc:creator>Jorge_Gonzalez</dc:creator>
    <dc:date>2015-10-14T15:26:45Z</dc:date>
    <item>
      <title>FTFL FTFE Flash controller behaviour</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/FTFL-FTFE-Flash-controller-behaviour/m-p/394916#M21659</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have looked around quite a bit and I can't seem to figure out a definite answer to my question. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So the FTFL controller writes to flash in longword ie 32bit chunks, and FTFL writes in phrases ie 64 bit chunks. And when writing to a flash location once, you should erase the sector before writing again to the same location, because it can cause damage to the flash area.&lt;/P&gt;&lt;P&gt;If you write to the same location it will possibly cause a hardfault error when reading from that location (that is how I got to this whole question in the first place, by porting my bootloader from a FTFL device to a FTFE device).&lt;/P&gt;&lt;P&gt;My question is can you write just one byte to a sector (32bit or 64 bit depending on the controller) and if you don't write to it later before erasing. Or do you need to always write in 32/64bit chunks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So let's say we have a 64 bit chunk starting at 0x1000 and ending at 0x1008. &lt;/P&gt;&lt;P&gt;Do I have to start writing at 0x1000 location or can I start with let's say 0x1001?&lt;/P&gt;&lt;P&gt;Do I have to write 0x10FFFFFFFFFFFFFF starting at 0x1000 with length of 8 bytes, or can I write 0x10 starting at 0x1000 with length of 1 byte?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Lovro Oreskovic&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Oct 2015 14:13:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/FTFL-FTFE-Flash-controller-behaviour/m-p/394916#M21659</guid>
      <dc:creator>lovro</dc:creator>
      <dc:date>2015-10-14T14:13:12Z</dc:date>
    </item>
    <item>
      <title>Re: FTFL FTFE Flash controller behaviour</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/FTFL-FTFE-Flash-controller-behaviour/m-p/394917#M21660</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Lovro Oreskovic:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For the FTFE case the programming operations must always point to a 64-bit aligned address and always provide the whole 8 bytes, disregarding if you don use them all. If you look at the &lt;STRONG&gt;Program Phrase&lt;/STRONG&gt; parameters in the Reference Manual it may help you:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_0.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/22211i96DA203B1E740281/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_0.png" alt="pastedImage_0.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So the command expects 8 bytes to be written at a 64-bit aligned address. You can decide to program as many bytes as you want from those 8 bytes (1 in your case), but the next time you want to update the same phrase then an erase must be launched first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this clarifies.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards!&lt;/P&gt;&lt;P&gt;Jorge Gonzalez&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Oct 2015 15:26:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/FTFL-FTFE-Flash-controller-behaviour/m-p/394917#M21660</guid>
      <dc:creator>Jorge_Gonzalez</dc:creator>
      <dc:date>2015-10-14T15:26:45Z</dc:date>
    </item>
  </channel>
</rss>

