<?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>LPC MicrocontrollersのトピックRe: LPC2368 Flash Memory IAP read / erase -&amp;gt; longer programming time and longer erase time</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1243007#M44211</link>
    <description>&lt;P&gt;Hi Carsten,&lt;/P&gt;&lt;P&gt;Thank you for your input. I will review my code to take the ideas you put forward into account.&lt;/P&gt;&lt;P&gt;Dani&lt;/P&gt;</description>
    <pubDate>Wed, 10 Mar 2021 07:04:01 GMT</pubDate>
    <dc:creator>danielgull</dc:creator>
    <dc:date>2021-03-10T07:04:01Z</dc:date>
    <item>
      <title>LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239127#M44112</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;I am working with the NXP microcontroller LPC2368.&lt;/P&gt;&lt;P&gt;In the User Manual UM102011 (&lt;A href="https://www.nxp.com/documents/user_manual/UM10211.pdf" target="_blank"&gt;https://www.nxp.com/documents/user_manual/UM10211.pdf&lt;/A&gt;&lt;LI-EMOJI id="lia_disappointed-face" title=":disappointed_face:"&gt;&lt;/LI-EMOJI&gt;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;in chapter 29.8.2 "Copy RAM to flash" there&amp;nbsp; is an iap command description for the command "Copy RAM to flash" with the "Command code: 5110". The "&lt;STRONG&gt;Param3: System Clock Frequency (CCLK) in kHz&lt;/STRONG&gt;" is of interest for the discussion in this email.&lt;/LI&gt;&lt;LI&gt;In chapter 29.8.3 "Erase Sector(s)" there&amp;nbsp; is an iap command description for the command " IAP Erase Sector(s) command" with the "Command code: 5210". The "&lt;STRONG&gt;Param2: System Clock Frequency (CCLK) in kHz&lt;/STRONG&gt;" is of interest for the discussion in this email.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Can I use these two parameters (&lt;STRONG&gt;Param3&lt;/STRONG&gt; and &lt;STRONG&gt;Param2&lt;/STRONG&gt;) to modify the &lt;STRONG&gt;programming time&lt;/STRONG&gt; or the &lt;STRONG&gt;erase time&lt;/STRONG&gt; of the internal flash memory transistors?&lt;/P&gt;&lt;P&gt;Normally I apply here the System Clock frequency (CCLK) in kHz that is used for the core. However evidence seems to indicate that the internal flash memory may not be erased reliably and not be programmed reliably for some devices.&lt;/P&gt;&lt;P&gt;I would like to &lt;STRONG&gt;increase reliability&lt;/STRONG&gt; of the &lt;STRONG&gt;erased transistors&lt;/STRONG&gt; on the silicon as well as &lt;STRONG&gt;increase reliability&lt;/STRONG&gt; of the &lt;STRONG&gt;programmed transistors&lt;/STRONG&gt; on the silicon by &lt;STRONG&gt;increasing the erase time&lt;/STRONG&gt; and &lt;STRONG&gt;increasing the programming time&lt;/STRONG&gt;. In order to prolong the &lt;STRONG&gt;programming time&lt;/STRONG&gt; or the &lt;STRONG&gt;erase time&lt;/STRONG&gt; can I &lt;STRONG&gt;&lt;EM&gt;&lt;U&gt;decrease&lt;/U&gt;&lt;/EM&gt;&lt;/STRONG&gt; these two parameters (&lt;STRONG&gt;Param3&lt;/STRONG&gt; and &lt;STRONG&gt;Param2&lt;/STRONG&gt;) in their value to achieve &lt;STRONG&gt;&lt;EM&gt;&lt;U&gt;longer&lt;/U&gt;&lt;/EM&gt;&lt;/STRONG&gt; &lt;STRONG&gt;programming time&lt;/STRONG&gt; and &lt;STRONG&gt;&lt;EM&gt;&lt;U&gt;longer&lt;/U&gt;&lt;/EM&gt; erase&lt;/STRONG&gt; &lt;STRONG&gt;time&lt;/STRONG&gt;?&lt;/P&gt;&lt;P&gt;The idea is that by telling the IAP control block that we have a slower frequency than physically available we force the IAP control block to increase the programming and the erase time.&lt;/P&gt;&lt;P&gt;Do you have any recommendation as to how these two parameters can or should be modified to increase reliability of the erased or programmed transistors in the internal flash or do you have a different approach how I can achieve a higher degree of reliability of the erase and programming quality of the internal flash transistors?&lt;/P&gt;&lt;P&gt;Many thanks for your support on this matter.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 06:34:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239127#M44112</guid>
      <dc:creator>danielgull</dc:creator>
      <dc:date>2021-03-03T06:34:53Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239217#M44114</link>
      <description>&lt;P&gt;Let me add my unqualified opinion here ...&lt;/P&gt;&lt;P&gt;In my experience, clock frequency has no impact on erase/program reliability. The issue is, I think, that core clock frequencies on most MCU devices can be set far beyond the speed capabilities of Flash, so defining a clock frequency will&amp;nbsp;determine the waitstate settings.&lt;/P&gt;&lt;P&gt;Flash erasing/programming is a repetitive process, were charges are "fired" repeatedly onto an isolated gate (using an increased voltage) until a threshold for proper differentiation is reached. AFAIK it is electro migration that reduces the efficiency and eventually destroys the cell (i.e. making it unusable).&lt;/P&gt;&lt;P&gt;The number of achievable erase/program cycle is very much related to temperature. Numbers given in the specs usually refer to the worst case, i.e. maximal temprature (95 ... 125°C). One can expect an increase of one order in magnitude for each 10°C less. So, a device with 10.000 guaranteed cycles might reach tens of millions at room temperature.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 08:38:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239217#M44114</guid>
      <dc:creator>frank_m</dc:creator>
      <dc:date>2021-03-03T08:38:56Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239242#M44115</link>
      <description>&lt;P&gt;Hi Frank&lt;/P&gt;&lt;P&gt;Thank you for the quick response.&lt;/P&gt;&lt;P&gt;So there is an internal on chip analog comparator that compares the charge reached on the isolated gate and this threshold is defined internally on the device and the programming and or erase time increase will not be able to change that threshold. So there is no possibility to influence the reliability of the programming or the erase of the cells due to this analog comparator on chip implementation.&lt;/P&gt;&lt;P&gt;Many thanks for this clarification.&lt;/P&gt;&lt;P&gt;You mentioned that you are not 100% sure (your and I quote "unqualified opinion") about your understanding how this works internally. Can you get a confirmation internally within NXP to get a confirmation on your understanding.&lt;/P&gt;&lt;P&gt;Dani&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 09:12:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239242#M44115</guid>
      <dc:creator>danielgull</dc:creator>
      <dc:date>2021-03-03T09:12:24Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239290#M44116</link>
      <description>&lt;P&gt;Seems my latest response was swallowed by the system ...&lt;/P&gt;&lt;P&gt;Anyway, I am not affiliated with NXP, just a normal user like you.&lt;/P&gt;&lt;P&gt;Just having quite a bit of experience with other Flash-based devices, and projects relying on Flash as frequent storage.&lt;/P&gt;&lt;P&gt;Many manufacturers do not share specific implementatio details on public fora, so you might need to open a support ticket or approach an official distributor. But NXP engineers are quite active here, so give it some time.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 10:16:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239290#M44116</guid>
      <dc:creator>frank_m</dc:creator>
      <dc:date>2021-03-03T10:16:02Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239295#M44117</link>
      <description>Hi Frank Thank you for taking the time to read my post and respond to it. Very much appreciated :-). I have opened a support ticket with NXP, but no response so far, so I thought I would post the contents of that ticket here in the NXP community to see if I get a better response time - and sure enough - Frank took some time to read and respond. Many thanks once again. Dani</description>
      <pubDate>Wed, 03 Mar 2021 10:26:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239295#M44117</guid>
      <dc:creator>danielgull</dc:creator>
      <dc:date>2021-03-03T10:26:56Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239324#M44118</link>
      <description>&lt;P&gt;Perhaps you can push the ticket a bit in the direction of your specific requirements.&lt;/P&gt;&lt;P&gt;Critical point in regards to Flash are, as fas a I'm aware of, the following:&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;permanent repetition (many cycles, wear-out)&lt;/LI&gt;&lt;LI&gt;high temperatures&lt;/LI&gt;&lt;LI&gt;cosmic radiation (alpha particles at elevated hights)&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Wed, 03 Mar 2021 11:22:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239324#M44118</guid>
      <dc:creator>frank_m</dc:creator>
      <dc:date>2021-03-03T11:22:50Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239348#M44119</link>
      <description>&lt;P&gt;Reliability of programming is 100% via IAP, provided you follow the rules. Frank has done a good job of explaining some of this. However, if you are experiencing some apparent unreliability, I would be prepared to wager that you have a power supply problem. Programming flash takes vastly more power than reading it. I would take a look at your circuit and look to see if the voltage drops while you are programming.&amp;nbsp;&lt;/P&gt;&lt;P&gt;p.s. I am also just a regular user, but with over 10 years of experience using LPC, starting with LPC2000.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 11:49:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239348#M44119</guid>
      <dc:creator>converse</dc:creator>
      <dc:date>2021-03-03T11:49:46Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239358#M44120</link>
      <description>&lt;P&gt;That's correct, erase/program involves an increased current consumption. Due to the underlying physical process, a voltage of 9..12V is required, which is usually created by a switched-capacitor converter implemented on the silicon. Which is usually the reason why the affected block cannot be accessed for normal read at that time.&lt;/P&gt;&lt;P&gt;I was involved in projects which required Flash erase/program after a mains-off was detected, with the board living from the remaining electrolytic capacitor storage. For the small 8-bit MCU involved, current consumption doubled in that case. And&amp;nbsp;electrolytic capacitors age realtively fast, i.e. loosing capacity ...&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 12:06:16 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239358#M44120</guid>
      <dc:creator>frank_m</dc:creator>
      <dc:date>2021-03-03T12:06:16Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239419#M44123</link>
      <description>&lt;P&gt;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/165257"&gt;@danielgull&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;I know this is not the same chip, but I would guess they are close...&lt;/P&gt;&lt;P&gt;we have currently more than 50.000 devices with LPC2458 running in the wild, they do once in a while get updated "over the air", and I have yet to see a single one of them fail (timespan more than 8 years) during this process. The only device I'm aware of that I use with a problem, is the LPC1788 where the errata says not to run above 100 MHz (if I remember correctly) if IAP is to remain without faults. The LPC1788 can&amp;nbsp; run at 120 MHz, but I keep it at 100 MHz just because of the errata.&lt;/P&gt;&lt;P&gt;I would also look somewhere else, is the IAP procedure followed 100%, power supply etc etc.&lt;/P&gt;&lt;P&gt;Good luck!&lt;/P&gt;&lt;P&gt;Carsten&lt;/P&gt;</description>
      <pubDate>Wed, 03 Mar 2021 14:12:04 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239419#M44123</guid>
      <dc:creator>carstengroen</dc:creator>
      <dc:date>2021-03-03T14:12:04Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239875#M44127</link>
      <description>&lt;P&gt;Hi, all,&lt;/P&gt;
&lt;P&gt;As far as I know that the flash erasing/programming operation requires a "flash-driving constant low frequency clock", the "flash-driving constant low frequency clock" is a divided clock from system clock. The api function with erasing/programing&amp;nbsp; command requires the parameter "System clock frequency (CCLK) in kHz", which can tells the api function to figure out the corresponding divider so that "flash-driving constant low frequency clock" frequency is fixed and constant.&lt;/P&gt;
&lt;P&gt;Hope it can help you&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Thu, 04 Mar 2021 03:05:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1239875#M44127</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-03-04T03:05:48Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1242178#M44189</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There are two threads in internal community.&lt;/P&gt;
&lt;P&gt;My reponse to original thread:&lt;/P&gt;
&lt;P&gt;Magicoe's answer as below&lt;/P&gt;
&lt;P&gt;Customer can not use those two param to set the FLASH speed/clock. Those two parameters is help ROM code to operate flash correctly, so you must follow the document information and set correct system clock to ROM code.&lt;/P&gt;
&lt;P&gt;Set Flash at low speed would not help flash operate safety.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My response to the 2nd thread:&lt;/P&gt;
&lt;P&gt;is that possible running CQC first?&lt;/P&gt;
&lt;P&gt;for Flash IAP, please take below attenstion:&lt;/P&gt;
&lt;P&gt;1. Errata:&amp;nbsp;3.10 Flash.1: Operating speed out of on-chip flash is restricted&lt;/P&gt;
&lt;P&gt;2. Errata:&amp;nbsp;3.12 MAM.1: Under certain conditions in MAM Mode 2 code execution out of internal flash can fail&lt;/P&gt;
&lt;P&gt;3. Suggestion: please kindly allocate IAP function code to RAM area.&lt;/P&gt;
&lt;P&gt;4. Suggestion: please make sure interrupt is disabled before IAP operation.&lt;/P&gt;
&lt;P&gt;5. Suggestion: please kindly keep the top 32bytes of RAM for IAP ROM code use.&lt;/P&gt;
&lt;P&gt;. Flash programming commands use the&lt;BR /&gt;top 32 bytes of on-chip RAM. The stack is located at RAM top - 32. The maximum stack&lt;BR /&gt;usage is 256 bytes and it grows downwards.&lt;/P&gt;</description>
      <pubDate>Tue, 09 Mar 2021 04:02:31 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1242178#M44189</guid>
      <dc:creator>magicoe_niu</dc:creator>
      <dc:date>2021-03-09T04:02:31Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1243007#M44211</link>
      <description>&lt;P&gt;Hi Carsten,&lt;/P&gt;&lt;P&gt;Thank you for your input. I will review my code to take the ideas you put forward into account.&lt;/P&gt;&lt;P&gt;Dani&lt;/P&gt;</description>
      <pubDate>Wed, 10 Mar 2021 07:04:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1243007#M44211</guid>
      <dc:creator>danielgull</dc:creator>
      <dc:date>2021-03-10T07:04:01Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1243011#M44213</link>
      <description>&lt;P&gt;Hi Frank&lt;/P&gt;&lt;P&gt;Thank you once again for your valuable input. I think that we should verify our power supply integrity during flash programming and flash erase directly on the hardware. We may have some weakness on the hardware side. I will follow this path to be able to confidently rule this out or find solutions on the hardware side if the power supply deteriorates during flash programming and flash erase.&lt;/P&gt;&lt;P&gt;Dani&lt;/P&gt;</description>
      <pubDate>Wed, 10 Mar 2021 07:09:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1243011#M44213</guid>
      <dc:creator>danielgull</dc:creator>
      <dc:date>2021-03-10T07:09:03Z</dc:date>
    </item>
    <item>
      <title>Re: LPC2368 Flash Memory IAP read / erase -&gt; longer programming time and longer erase time</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1243017#M44214</link>
      <description>&lt;P&gt;Hi XiandJun&lt;/P&gt;&lt;P&gt;Yes that was my guess at first as well and my idea was to reduce this parameter to force longer flash programming time and longer flash erase time.&lt;/P&gt;&lt;P&gt;What I gather so far from the feedback I received is that I cannot influence the flash programming time nor the flash erase time with this parameter.&lt;/P&gt;&lt;P&gt;The chip internally handles the voltage thresholds of programmed cells or erased cells independent from this parameter.&lt;/P&gt;&lt;P&gt;The clockspeed parameter is only there as a reference clock to drive the state machine used inside the flash to program and erase. The determination however if a cell is erased or programmed sufficiently is determined by analog circuitry that is independent of the clock speed.&lt;/P&gt;&lt;P&gt;Dani&lt;/P&gt;</description>
      <pubDate>Wed, 10 Mar 2021 07:18:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC2368-Flash-Memory-IAP-read-erase-gt-longer-programming-time/m-p/1243017#M44214</guid>
      <dc:creator>danielgull</dc:creator>
      <dc:date>2021-03-10T07:18:29Z</dc:date>
    </item>
  </channel>
</rss>

