<?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 LPC802 reset and ISP pin in LPC Microcontrollers</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC802-reset-and-ISP-pin/m-p/1078338#M41485</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using LPC802M001JDH20 in my project and have two questions regarding pins: PIO012 and nRESET/PIO0_5.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;I want to use these pins as I/O and do not want neither reset nor ISP functionality.&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;1. In my hardware design my nRESET pin is connected to GND and stays connected as the power is applied to the MCU. As far as I know from the datasheet, nRESET functionality can be disabled by writing to appropriate registers, but the question is; until the appropriate register is written, how will the MCU know I want the nRESET pin to be disabled?&lt;/P&gt;&lt;P&gt;I need a way to tell the programmer (or linker?) to put some special values at specific addresses during the programming phase.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also explicitly write the code below besides the one created by config tools to make sure nRESET function is disabled but as a said it is too late since the CPU does not even reach that point.&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;"SWM_SetFixedPinSelect(SWM0, kSWM_RESETN, false);"&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;As MCU starts when nRESET pin is connected to VDD,&amp;nbsp;it executes code as I want but when it is powered up whilst the nRESET pin is&amp;nbsp;connected to GND, MCU does not work as the same (same with&amp;nbsp;when connected to&amp;nbsp;VDD).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. I do not want any kind of ISP functionality, but MCU goes into ISP mode as MCU starts if PIO0_12 pin is connected to GND. My hardware also connects this pin to GND. I also want to disable this feature.&lt;/P&gt;&lt;P&gt;" A LOW level on this pin during reset starts the ISP command handler."&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/97720i7853CEB7D06C4EAE/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;P&gt;So to disable this feature I do the following at the beginning of the program:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;int main(void)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;{&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;/* Init board hardware. */&lt;/SPAN&gt;&lt;BR /&gt; &lt;SPAN style="font-size: 11px;"&gt;BOARD_InitBootPins();&lt;/SPAN&gt;&lt;BR /&gt; &lt;SPAN style="font-size: 11px;"&gt;BOARD_InitBootClocks();&lt;/SPAN&gt;&lt;BR /&gt; &lt;SPAN style="font-size: 11px;"&gt;BOARD_InitBootPeripherals();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;uint32_t volatile * const crp&amp;nbsp;= (uint32_t *)(0x000002FC) ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;*crp= 0x4E697370;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;After CPU executes (or attempts to execute idk) the write operation (*crp...), it goes to:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;void HardFault_Handler(void)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;{ while(1) {}&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Overall,&lt;/P&gt;&lt;P&gt;I need a way to tell the linker/programmer to put a specific data at a specific address inside flash. How do I do that with McuXpresso?&lt;/P&gt;&lt;P&gt;My hardware connects both of these pins to GND.&lt;/P&gt;&lt;P&gt;Through Config Tools, PIO0_12 (ISP) pin is configured as digital input and nRESET pin as digital output.&lt;/P&gt;&lt;P&gt;I do&amp;nbsp;&lt;SPAN style="text-decoration: underline;"&gt;not&lt;/SPAN&gt; want &lt;SPAN style="text-decoration: underline;"&gt;any&lt;/SPAN&gt; of reset and ISP features.&lt;/P&gt;&lt;P&gt;What should I do in this case to make sure reset and ISP functionality is disabled and MCU starts and treats these pins as simple I/O?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 25 Apr 2020 08:59:43 GMT</pubDate>
    <dc:creator>arda_otuz</dc:creator>
    <dc:date>2020-04-25T08:59:43Z</dc:date>
    <item>
      <title>LPC802 reset and ISP pin</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC802-reset-and-ISP-pin/m-p/1078338#M41485</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using LPC802M001JDH20 in my project and have two questions regarding pins: PIO012 and nRESET/PIO0_5.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;I want to use these pins as I/O and do not want neither reset nor ISP functionality.&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;1. In my hardware design my nRESET pin is connected to GND and stays connected as the power is applied to the MCU. As far as I know from the datasheet, nRESET functionality can be disabled by writing to appropriate registers, but the question is; until the appropriate register is written, how will the MCU know I want the nRESET pin to be disabled?&lt;/P&gt;&lt;P&gt;I need a way to tell the programmer (or linker?) to put some special values at specific addresses during the programming phase.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I also explicitly write the code below besides the one created by config tools to make sure nRESET function is disabled but as a said it is too late since the CPU does not even reach that point.&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;"SWM_SetFixedPinSelect(SWM0, kSWM_RESETN, false);"&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;As MCU starts when nRESET pin is connected to VDD,&amp;nbsp;it executes code as I want but when it is powered up whilst the nRESET pin is&amp;nbsp;connected to GND, MCU does not work as the same (same with&amp;nbsp;when connected to&amp;nbsp;VDD).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. I do not want any kind of ISP functionality, but MCU goes into ISP mode as MCU starts if PIO0_12 pin is connected to GND. My hardware also connects this pin to GND. I also want to disable this feature.&lt;/P&gt;&lt;P&gt;" A LOW level on this pin during reset starts the ISP command handler."&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/97720i7853CEB7D06C4EAE/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;P&gt;So to disable this feature I do the following at the beginning of the program:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;int main(void)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;{&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;/* Init board hardware. */&lt;/SPAN&gt;&lt;BR /&gt; &lt;SPAN style="font-size: 11px;"&gt;BOARD_InitBootPins();&lt;/SPAN&gt;&lt;BR /&gt; &lt;SPAN style="font-size: 11px;"&gt;BOARD_InitBootClocks();&lt;/SPAN&gt;&lt;BR /&gt; &lt;SPAN style="font-size: 11px;"&gt;BOARD_InitBootPeripherals();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;uint32_t volatile * const crp&amp;nbsp;= (uint32_t *)(0x000002FC) ;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;*crp= 0x4E697370;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;After CPU executes (or attempts to execute idk) the write operation (*crp...), it goes to:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;&lt;SPAN style="font-size: 11px;"&gt;void HardFault_Handler(void)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;{ while(1) {}&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-size: 11px;"&gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Overall,&lt;/P&gt;&lt;P&gt;I need a way to tell the linker/programmer to put a specific data at a specific address inside flash. How do I do that with McuXpresso?&lt;/P&gt;&lt;P&gt;My hardware connects both of these pins to GND.&lt;/P&gt;&lt;P&gt;Through Config Tools, PIO0_12 (ISP) pin is configured as digital input and nRESET pin as digital output.&lt;/P&gt;&lt;P&gt;I do&amp;nbsp;&lt;SPAN style="text-decoration: underline;"&gt;not&lt;/SPAN&gt; want &lt;SPAN style="text-decoration: underline;"&gt;any&lt;/SPAN&gt; of reset and ISP features.&lt;/P&gt;&lt;P&gt;What should I do in this case to make sure reset and ISP functionality is disabled and MCU starts and treats these pins as simple I/O?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 25 Apr 2020 08:59:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC802-reset-and-ISP-pin/m-p/1078338#M41485</guid>
      <dc:creator>arda_otuz</dc:creator>
      <dc:date>2020-04-25T08:59:43Z</dc:date>
    </item>
    <item>
      <title>Re: LPC802 reset and ISP pin</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC802-reset-and-ISP-pin/m-p/1078339#M41486</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;A _jive_internal="true" data-content-finding="Community" data-userid="357230" data-username="arda.otuz@eecelectronics.com.tr" href="https://community.nxp.com/people/arda.otuz@eecelectronics.com.tr"&gt;Arda Otuz&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;Thank you for your interest in NXP Semiconductor products and &lt;BR /&gt;for the opportunity to serve you.&lt;BR /&gt;1) I'm afraid it's impossible to disable the reset pin function prior to boot up.&lt;BR /&gt;2) Please refer to the &lt;A href="https://www.nxp.com/docs/en/application-note/AN11581.zip"&gt;application&lt;/A&gt; to implement the code read protection feature.&lt;/P&gt;&lt;P&gt;Have a great day,&lt;BR /&gt;TIC&lt;/P&gt;&lt;P style="min- padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;-------------------------------------------------------------------------------&lt;BR /&gt;Note:&lt;BR /&gt;- If this post answers your question, please click the "Mark Correct" button. Thank you!&lt;/P&gt;&lt;P style="min- padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;- We are following threads for 7 weeks after the last post, later replies are ignored&lt;BR /&gt; Please open a new thread and refer to the closed one, if you have a related question at a later point in time.&lt;BR /&gt;-------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Apr 2020 06:43:04 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC802-reset-and-ISP-pin/m-p/1078339#M41486</guid>
      <dc:creator>jeremyzhou</dc:creator>
      <dc:date>2020-04-27T06:43:04Z</dc:date>
    </item>
  </channel>
</rss>

