<?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: LPC1837 - several firmwares and proprietary bootloader in LPC Microcontrollers</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1837-several-firmwares-and-proprietary-bootloader/m-p/534560#M10846</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roman,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Times New Roman',serif; font-size: 16px; font-weight: normal; text-align: left; text-indent: 0px;"&gt;Thank you for your interest in NXP Semiconductor products and the opportunity to serve you.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;First of all, thanks for your sharing, then I was wondering if you can upload the whole code.&lt;BR /&gt;Have a great day,&lt;BR /&gt;Ping&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>Mon, 18 Jul 2016 01:14:34 GMT</pubDate>
    <dc:creator>jeremyzhou</dc:creator>
    <dc:date>2016-07-18T01:14:34Z</dc:date>
    <item>
      <title>LPC1837 - several firmwares and proprietary bootloader</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1837-several-firmwares-and-proprietary-bootloader/m-p/534559#M10845</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello everybody! Happy to write my first post in this blog.&lt;/P&gt;&lt;P&gt;Would like to share my results: i reach my finally goal - wrote an application which is select the working firmaware on chip.&lt;/P&gt;&lt;P&gt;For example: we have several firmwares and would like to switch beetween them during working. uC LPC1837 have 512 kBytes of Flash. Thus mean that we could download several specific firmwares and switch from one to another by setting vector table offset (SCB-&amp;gt;VTOR).&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The main application placed in address 0x00. And have size about 2 kBytes. This application go to EEPROM of uC and get the offset of application, which will begin to work now. Then create an entry point to reset_handler of application and jump into it.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This high weigth application in flash, placed from address 0x2000. And it can use EEPROM to setup the next application what should runing after reset. Also it ca&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This can be used for updating one of them, leave previous version without changings &lt;SPAN aria-label="Happy" class="emoticon_happy emoticon-inline" style="height:16px;width:16px;"&gt;&lt;/SPAN&gt; Like doubled buffered.&lt;/P&gt;&lt;P&gt;Here i place main function of the booter program:&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;void go_to_app(uint32_t addr)&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // addr - addres of main application(e.g. 0x2000)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;{&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; void (*app)(void);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // create an Reset_Handler of app&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; uint32_t *p = (uint32_t *)addr;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // get a pointer to app&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; __disable_irq();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; SCB-&amp;gt;VTOR = addr;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // offset the vector table&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; __set_MSP(*p++);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // set main stack pointer to app&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; app = (void (*)(void))(*p);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // app now is entry point&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; app();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt; &lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Jul 2016 19:37:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1837-several-firmwares-and-proprietary-bootloader/m-p/534559#M10845</guid>
      <dc:creator>romanleonov</dc:creator>
      <dc:date>2016-07-03T19:37:50Z</dc:date>
    </item>
    <item>
      <title>Re: LPC1837 - several firmwares and proprietary bootloader</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1837-several-firmwares-and-proprietary-bootloader/m-p/534560#M10846</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roman,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Times New Roman',serif; font-size: 16px; font-weight: normal; text-align: left; text-indent: 0px;"&gt;Thank you for your interest in NXP Semiconductor products and the opportunity to serve you.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;First of all, thanks for your sharing, then I was wondering if you can upload the whole code.&lt;BR /&gt;Have a great day,&lt;BR /&gt;Ping&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>Mon, 18 Jul 2016 01:14:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC1837-several-firmwares-and-proprietary-bootloader/m-p/534560#M10846</guid>
      <dc:creator>jeremyzhou</dc:creator>
      <dc:date>2016-07-18T01:14:34Z</dc:date>
    </item>
  </channel>
</rss>

