<?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: write byte by byte in program flash (S32K144) in S32K</title>
    <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777414#M2393</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to write in pflash. Target is : possible to write single byte into pflash. I am first erase sector and try to write data like this(on this same address):&lt;BR /&gt;- &amp;nbsp;0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF&lt;BR /&gt;- &amp;nbsp;0xFF, 0x02, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF&lt;BR /&gt;- &amp;nbsp;0xFF, 0xFF, 0x03, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF&lt;/P&gt;&lt;P&gt;somethimes it works, and i am read data correctrly:&lt;BR /&gt;(for this example i am read: 0x01, 0x02, 0x03, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF)&lt;BR /&gt;but somethimes i am read some incorrect data like:&lt;BR /&gt;0x02, 0x02, 0x04, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF&lt;BR /&gt;and somethimes memory is crash and when i am read memory at this adrress then HardFault occur and CFSR have set bits: PRECISERR and BFARVALID.&lt;/P&gt;&lt;P&gt;for each case FTFC-&amp;gt;FSTAT is set to 0x81(without first write). In summary writing to Pflash using my method is very unstable.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 12 Jan 2018 12:24:58 GMT</pubDate>
    <dc:creator>tomgt</dc:creator>
    <dc:date>2018-01-12T12:24:58Z</dc:date>
    <item>
      <title>write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777409#M2388</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;it is possible to write byte by byte in program flash? (S32K144).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Jan 2018 06:45:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777409#M2388</guid>
      <dc:creator>tomgt</dc:creator>
      <dc:date>2018-01-10T06:45:56Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777410#M2389</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;The smallest portion of Flash that can be written is one phrase (8 previously erased bytes) using Program Phrase command.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Daniel&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Jan 2018 08:49:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777410#M2389</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2018-01-10T08:49:37Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777411#M2390</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;is there any other way or trick to write byte per byte?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Jan 2018 11:38:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777411#M2390</guid>
      <dc:creator>tomgt</dc:creator>
      <dc:date>2018-01-10T11:38:15Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777412#M2391</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There is no other way due to ECC.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;During the programming of the Flash, ECC checksum is generated.&lt;/P&gt;&lt;P&gt;The programming operation of the Flash and the checksum is unidirectional, it can only move bits from the '1' state (erased) to the '0' state (programmed).&lt;/P&gt;&lt;P&gt;So once the ECC checksum&amp;nbsp;has been generated, its bits cannot be changed from 0 to 1 again without an erase operation.&amp;nbsp;Therefore, after a subsequent write to the same phrase, the ECC checksum will not match the stored data and this&amp;nbsp;causes ECC errors.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Jan 2018 14:50:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777412#M2391</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2018-01-10T14:50:05Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777413#M2392</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you need store something like "calibration data/runtime data" - you can use FlexNVM configured as an EEEROM. On S32K144 is up to 4kB EEEROM available. EEEROM usage is part of S32DS Example - flash_partitioning_s32k144.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyway - what is your use case for writing data byte by byte into pflash?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jiri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Jan 2018 13:13:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777413#M2392</guid>
      <dc:creator>jiri_kral</dc:creator>
      <dc:date>2018-01-11T13:13:09Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777414#M2393</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to write in pflash. Target is : possible to write single byte into pflash. I am first erase sector and try to write data like this(on this same address):&lt;BR /&gt;- &amp;nbsp;0x01, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF&lt;BR /&gt;- &amp;nbsp;0xFF, 0x02, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF&lt;BR /&gt;- &amp;nbsp;0xFF, 0xFF, 0x03, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF&lt;/P&gt;&lt;P&gt;somethimes it works, and i am read data correctrly:&lt;BR /&gt;(for this example i am read: 0x01, 0x02, 0x03, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF)&lt;BR /&gt;but somethimes i am read some incorrect data like:&lt;BR /&gt;0x02, 0x02, 0x04, 0xFE, 0xFF, 0xFF, 0xFF, 0xFF&lt;BR /&gt;and somethimes memory is crash and when i am read memory at this adrress then HardFault occur and CFSR have set bits: PRECISERR and BFARVALID.&lt;/P&gt;&lt;P&gt;for each case FTFC-&amp;gt;FSTAT is set to 0x81(without first write). In summary writing to Pflash using my method is very unstable.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 12:24:58 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777414#M2393</guid>
      <dc:creator>tomgt</dc:creator>
      <dc:date>2018-01-12T12:24:58Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777415#M2394</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in this case - you need to read sector with byte you are interested in into RAM,&amp;nbsp; modify particular byte of the sector in the RAM, delete sector in pflash, write modified sector from RAM back to its place. Also - don't forget disable all interrupts during flash operation.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;to be honest - the request write byte by byte into pflash is very odd - I can't imagine any meaningful user case for that.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jiri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 17:13:54 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777415#M2394</guid>
      <dc:creator>jiri_kral</dc:creator>
      <dc:date>2018-01-12T17:13:54Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777416#M2395</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The results are expected. Because after the second write the data do not match the ECC checksum.&lt;/P&gt;&lt;P&gt;The incorrect data that you read mean “corrected” single-bit ECC errors.&lt;/P&gt;&lt;P&gt;The crash means an uncorrectable double-bit error.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 15 Jan 2018 09:07:17 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777416#M2395</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2018-01-15T09:07:17Z</dc:date>
    </item>
    <item>
      <title>Re: write byte by byte in program flash (S32K144)</title>
      <link>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777417#M2396</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks for the help.&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Jan 2018 15:30:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/write-byte-by-byte-in-program-flash-S32K144/m-p/777417#M2396</guid>
      <dc:creator>tomgt</dc:creator>
      <dc:date>2018-01-19T15:30:43Z</dc:date>
    </item>
  </channel>
</rss>

