<?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: IAP functions sometimes return error in LPC Microcontrollers</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708222#M28554</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well thank you Carsten&amp;nbsp;&lt;/P&gt;&lt;P&gt;Actually that might be the case!&lt;/P&gt;&lt;P&gt;I do run the LPC1778 at 120MHz !&lt;/P&gt;&lt;P&gt;I didn't saw that coming !&lt;/P&gt;&lt;P&gt;So it could lead to a problem. Waw&lt;/P&gt;&lt;P&gt;What do you say I run the main code at 120MHz and when it's time to run the bootloader I reduce the clock to say 100MHz or 60MHz ?&lt;/P&gt;&lt;P&gt;So are u sure this could be the only case or is there something else I should know about ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 19 Sep 2017 17:06:02 GMT</pubDate>
    <dc:creator>mostafanfs</dc:creator>
    <dc:date>2017-09-19T17:06:02Z</dc:date>
    <item>
      <title>IAP functions sometimes return error</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708220#M28552</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="padding: 0px;"&gt;Guys I have a problem with IAP inside some of LPC1778 boards.&lt;/P&gt;&lt;P style="padding: 0px;"&gt;I'm using IAP functions to upgrade the firmware using USB memory stick.&amp;nbsp;&lt;/P&gt;&lt;P style="padding: 0px;"&gt;Why on earth would any of the IAP functions (listed below) return an error?&lt;/P&gt;&lt;P style="padding: 0px;"&gt;1-&amp;nbsp;IAP_PreSectorForReadWrite();&lt;/P&gt;&lt;P style="padding: 0px;"&gt;2-&amp;nbsp;IAP_CopyRamToFlash()&lt;/P&gt;&lt;P style="padding: 0px;"&gt;3-&amp;nbsp;IAP_Compare()&lt;/P&gt;&lt;P style="padding: 0px;"&gt;4-&amp;nbsp;IAP_EraseSector()&lt;/P&gt;&lt;P style="padding: 0px;"&gt;5-&amp;nbsp;IAP_BlankCheckSector()&lt;/P&gt;&lt;P style="padding: 0px;"&gt;There are totally 30 sector which my bootloader is located on the last sector (#29).&amp;nbsp;&lt;/P&gt;&lt;P style="padding: 0px;"&gt;Sometimes it goes and everything is good but when it gets to for example Sector #24 it returns an error after&amp;nbsp;&lt;SPAN&gt;IAP_Compare() function.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding: 0px;"&gt;&lt;SPAN&gt;What could possibly be wrong ?&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding: 0px;"&gt;&lt;SPAN&gt;This way I will loose my firmware cause I've just erased entire 28 sectors before copying new firmware onto flash and the new firmware is not installed correctly so I'm screwed !&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding: 0px;"&gt;&lt;SPAN&gt;the weird thing is that it goes well for most of the time specially the first try but it fails on the second try.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding: 0px;"&gt;&lt;SPAN&gt;How am I supposed to have a robust and reliable bootlader ?&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding: 0px;"&gt;&lt;SPAN&gt;Please help.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Sep 2017 11:04:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708220#M28552</guid>
      <dc:creator>mostafanfs</dc:creator>
      <dc:date>2017-09-19T11:04:48Z</dc:date>
    </item>
    <item>
      <title>Re: IAP functions sometimes return error</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708221#M28553</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Mosi,&lt;/P&gt;&lt;P&gt;are you aware of the errata sheet for the 177x/8x regarding the IAP ?&lt;BR /&gt;It can in some circumstances be a problem if you run the device at 120 MHz:&lt;/P&gt;&lt;P&gt;(I don't know if you do that, but something to be aware of...)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/31752i3F3CBE2401E7E92F/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Sep 2017 12:29:59 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708221#M28553</guid>
      <dc:creator>carstengroen</dc:creator>
      <dc:date>2017-09-19T12:29:59Z</dc:date>
    </item>
    <item>
      <title>Re: IAP functions sometimes return error</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708222#M28554</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well thank you Carsten&amp;nbsp;&lt;/P&gt;&lt;P&gt;Actually that might be the case!&lt;/P&gt;&lt;P&gt;I do run the LPC1778 at 120MHz !&lt;/P&gt;&lt;P&gt;I didn't saw that coming !&lt;/P&gt;&lt;P&gt;So it could lead to a problem. Waw&lt;/P&gt;&lt;P&gt;What do you say I run the main code at 120MHz and when it's time to run the bootloader I reduce the clock to say 100MHz or 60MHz ?&lt;/P&gt;&lt;P&gt;So are u sure this could be the only case or is there something else I should know about ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Sep 2017 17:06:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708222#M28554</guid>
      <dc:creator>mostafanfs</dc:creator>
      <dc:date>2017-09-19T17:06:02Z</dc:date>
    </item>
    <item>
      <title>Re: IAP functions sometimes return error</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708223#M28555</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You're welcome :smileyhappy:&lt;/P&gt;&lt;P&gt;I do exactly what you propose, I lower the clock to 60 MHz when doing the IAP, and so far that works fine :smileyhappy:&lt;/P&gt;&lt;P&gt;Also remember that the PCLK divider (for peripherals) must not be more than 4 (I have fallen into that a couple of times, things gets VERY funny if not doing this) this is also mentioned in the errata&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Sep 2017 18:38:39 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/IAP-functions-sometimes-return-error/m-p/708223#M28555</guid>
      <dc:creator>carstengroen</dc:creator>
      <dc:date>2017-09-19T18:38:39Z</dc:date>
    </item>
  </channel>
</rss>

