<?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: MKL04Z8XXX4 Custom board lock/brick in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MKL04Z8XXX4-Custom-board-lock-brick/m-p/907645#M53239</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not sure what was the right reason (noise? sync issue? to short timeout constraint even at lower speed I've been using?), but it was the long wires (even some more then 1m long with no extra shielding whatsoever) that trigger this behaviour: when I shortened the wires to ~20cm everything goes flawlessly.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 25 May 2019 19:41:20 GMT</pubDate>
    <dc:creator>tomazlov</dc:creator>
    <dc:date>2019-05-25T19:41:20Z</dc:date>
    <item>
      <title>MKL04Z8XXX4 Custom board lock/brick</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MKL04Z8XXX4-Custom-board-lock-brick/m-p/907643#M53237</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have custom&amp;nbsp;MKL04Z8XXX4 board and suddenly can not connect to the board using my standard routine. Based on some references I have read (&lt;A _jive_internal="true" href="https://community.nxp.com/thread/357035"&gt;How to unlock bricked MCU with J-Link?&lt;/A&gt;, &lt;A href="https://mcuoneclipse.com/2012/10/26/unsecuring-the-kl25z-freedom-board/"&gt;Unsecuring the KL25Z Freedom Board&lt;/A&gt;,&amp;nbsp;&lt;A href="https://forum.segger.com/index.php/Thread/4614-SOLVED-Bricked-Eval-Board-after-erase-NXP-Kinetis-MK20/"&gt;Bricked Eval Board after "erase" (NXP Kinetis MK20)&lt;/A&gt;, &lt;A href="https://mcuoneclipse.com/2014/10/05/unlocking-and-erasing-flash-with-segger-j-link/"&gt;Unlocking and Erasing FLASH with Segger J-Link&lt;/A&gt;, etc.) there seems to be locking or bricking issue. Using Jlink commander v6.40 none of the suggestions ("unlock kinetis", manually selecting CPU, setting lower SWD speed, e.g. 4kHz: im using ~1m SWD wires!) were useful; below is copy-paste of the sequence:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;SEGGER J-Link Commander V6.40 (Compiled Oct 26 2018 15:06:29)&lt;BR /&gt;DLL version V6.40, compiled Oct 26 2018 15:06:02&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Connecting to J-Link via USB...O.K.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;VTref=2.982V&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Type "connect" to establish a target connection, '?' for help&lt;BR /&gt;J-Link&amp;gt;&lt;STRONG style="color: #ff0000; "&gt;connect&lt;/STRONG&gt;&lt;BR /&gt;Please specify device / core. &amp;lt;Default&amp;gt;: MKL04Z8XXX4&lt;BR /&gt;Type '?' for selection dialog&lt;BR /&gt;Device&amp;gt;&lt;BR /&gt;Please specify target interface:&lt;BR /&gt; J) JTAG (Default)&lt;BR /&gt; S) SWD&lt;BR /&gt; T) cJTAG&lt;BR /&gt;TIF&amp;gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;S&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;BR /&gt;Specify target interface speed [kHz]. &amp;lt;Default&amp;gt;: 4000 kHz&lt;BR /&gt;Speed&amp;gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;4&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;BR /&gt;Device "MKL04Z8XXX4" selected.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Connecting to target via SWD&lt;BR /&gt;InitTarget()&lt;BR /&gt;Device will be unsecured now.&lt;BR /&gt;Timeout while unsecuring device. Erase never starts.&lt;BR /&gt;Found SW-DP with ID 0x0BC11477&lt;BR /&gt;Scanning AP map to find all available APs&lt;BR /&gt;AP[2]: Stopped AP scan as end of AP map has been reached&lt;BR /&gt;AP[0]: AHB-AP (IDR: 0x04770031)&lt;BR /&gt;AP[1]: JTAG-AP (IDR: 0x001C0020)&lt;BR /&gt;Iterating through AP map to find AHB-AP to use&lt;BR /&gt;AP[0]: Skipped. Invalid implementer code read from CPUIDVal[31:24] = 0x00&lt;BR /&gt;AP[1]: Skipped. Not an AHB-AP&lt;BR /&gt;InitTarget()&lt;BR /&gt;Device will be unsecured now.&lt;BR /&gt;Timeout while unsecuring device. Erase never starts.&lt;BR /&gt;Found SW-DP with ID 0x0BC11477&lt;BR /&gt;Scanning AP map to find all available APs&lt;BR /&gt;AP[2]: Stopped AP scan as end of AP map has been reached&lt;BR /&gt;AP[0]: AHB-AP (IDR: 0x04770031)&lt;BR /&gt;AP[1]: JTAG-AP (IDR: 0x001C0020)&lt;BR /&gt;Iterating through AP map to find AHB-AP to use&lt;BR /&gt;AP[0]: Skipped. Invalid implementer code read from CPUIDVal[31:24] = 0x00&lt;BR /&gt;AP[1]: Skipped. Not an AHB-AP&lt;/P&gt;&lt;P&gt;****** Error: Could not find core in Coresight setup&lt;BR /&gt;InitTarget()&lt;BR /&gt;Device will be unsecured now.&lt;BR /&gt;Timeout while unsecuring device. Erase never starts.&lt;BR /&gt;Found SW-DP with ID 0x0BC11477&lt;BR /&gt;Scanning AP map to find all available APs&lt;BR /&gt;AP[2]: Stopped AP scan as end of AP map has been reached&lt;BR /&gt;AP[0]: AHB-AP (IDR: 0x04770031)&lt;BR /&gt;AP[1]: JTAG-AP (IDR: 0x001C0020)&lt;BR /&gt;Iterating through AP map to find AHB-AP to use&lt;BR /&gt;AP[0]: Skipped. Invalid implementer code read from CPUIDVal[31:24] = 0x00&lt;BR /&gt;AP[1]: Skipped. Not an AHB-AP&lt;BR /&gt;InitTarget()&lt;BR /&gt;Device will be unsecured now.&lt;BR /&gt;Timeout while unsecuring device. Erase never starts.&lt;BR /&gt;Found SW-DP with ID 0x0BC11477&lt;BR /&gt;Scanning AP map to find all available APs&lt;BR /&gt;AP[2]: Stopped AP scan as end of AP map has been reached&lt;BR /&gt;AP[0]: AHB-AP (IDR: 0x04770031)&lt;BR /&gt;AP[1]: JTAG-AP (IDR: 0x001C0020)&lt;BR /&gt;Iterating through AP map to find AHB-AP to use&lt;BR /&gt;AP[0]: Skipped. Invalid implementer code read from CPUIDVal[31:24] = 0x00&lt;BR /&gt;AP[1]: Skipped. Not an AHB-AP&lt;BR /&gt;Cannot connect to target.&lt;BR /&gt;J-Link&amp;gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;unlock Kinetis&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;BR /&gt;Found SWD-DP with ID 0x0BC11477&lt;BR /&gt;Unlocking device...Timeout while unlocking device.&lt;BR /&gt;J-Link&amp;gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;device MKL04Z8XXX4&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;BR /&gt;J-Link&amp;gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;unlock kinetis&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;BR /&gt;Found SWD-DP with ID 0x0BC11477&lt;BR /&gt;Unlocking device...Timeout while unlocking device.&lt;BR /&gt;J-Link&amp;gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;erase&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;BR /&gt;Target connection not established yet but required for command.&lt;BR /&gt;Device "MKL04Z8XXX4" selected.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;1) Is my board bricked? If YES: is there any other way to&amp;nbsp;unbrick the IC (using other dedicated HW or interface)?&lt;/P&gt;&lt;P&gt;2) Since I am always working from MCU Expresso IDE (v10.2.0) is there some settings (flags/operation/flash overwrite on specific addresses?) to be careful about during programing/erasing to avoid this situation?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Apr 2019 08:57:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/MKL04Z8XXX4-Custom-board-lock-brick/m-p/907643#M53237</guid>
      <dc:creator>tomazlov</dc:creator>
      <dc:date>2019-04-24T08:57:56Z</dc:date>
    </item>
    <item>
      <title>Re: MKL04Z8XXX4 Custom board lock/brick</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MKL04Z8XXX4-Custom-board-lock-brick/m-p/907644#M53238</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Hello,&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;1.-&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;If you did set the&amp;nbsp;disable mass erase bit and the protection bit at the same time in the flash security register, if you did unfortunately there is no way to unlock it.&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;2.-&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Yes it is please take a look to this application note [&lt;A href="https://www.nxp.com/docs/en/application-note/AN4835.pdf"&gt;AN4835&lt;/A&gt;], also you can check this out to know more about the protection and security bits&amp;nbsp;&lt;A href="https://mcuoneclipse.com/2012/11/04/how-not-to-secure-my-microcontroller/"&gt;https://mcuoneclipse.com/2012/11/04/how-not-to-secure-my-microcontroller/&lt;/A&gt;&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Hope this helps,&lt;/P&gt;&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Regards,&lt;BR /&gt; Aldo.&lt;/P&gt;&lt;P&gt;&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&gt;&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>Thu, 25 Apr 2019 16:45:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/MKL04Z8XXX4-Custom-board-lock-brick/m-p/907644#M53238</guid>
      <dc:creator>AldoG</dc:creator>
      <dc:date>2019-04-25T16:45:43Z</dc:date>
    </item>
    <item>
      <title>Re: MKL04Z8XXX4 Custom board lock/brick</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MKL04Z8XXX4-Custom-board-lock-brick/m-p/907645#M53239</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not sure what was the right reason (noise? sync issue? to short timeout constraint even at lower speed I've been using?), but it was the long wires (even some more then 1m long with no extra shielding whatsoever) that trigger this behaviour: when I shortened the wires to ~20cm everything goes flawlessly.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 25 May 2019 19:41:20 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/MKL04Z8XXX4-Custom-board-lock-brick/m-p/907645#M53239</guid>
      <dc:creator>tomazlov</dc:creator>
      <dc:date>2019-05-25T19:41:20Z</dc:date>
    </item>
  </channel>
</rss>

