<?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>S12 / MagniV MicrocontrollersのトピックFlash is secured after writing</title>
    <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/Flash-is-secured-after-writing/m-p/660294#M13953</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear sir,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #51626f; background-color: #ffffff;"&gt;I am using &lt;/SPAN&gt;&lt;SPAN style="color: black; background-color: #ffffff; border: 0px; font-size: 10pt;"&gt;ms9c12xdp512 16 bit mcu. After i writing to flash, the BDM prompt an dialog "Communications with target failed: The target MCU has no clock or wrong BDM clock speed is used to derivateve is secured" and can not debug the project. I must "unsecure" the flash, then i can use BDM to debug. I am sure my hardware and BDM are good. Which software issue can make this happen?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 Mar 2017 07:54:30 GMT</pubDate>
    <dc:creator>liuweiwei</dc:creator>
    <dc:date>2017-03-17T07:54:30Z</dc:date>
    <item>
      <title>Flash is secured after writing</title>
      <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/Flash-is-secured-after-writing/m-p/660294#M13953</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear sir,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #51626f; background-color: #ffffff;"&gt;I am using &lt;/SPAN&gt;&lt;SPAN style="color: black; background-color: #ffffff; border: 0px; font-size: 10pt;"&gt;ms9c12xdp512 16 bit mcu. After i writing to flash, the BDM prompt an dialog "Communications with target failed: The target MCU has no clock or wrong BDM clock speed is used to derivateve is secured" and can not debug the project. I must "unsecure" the flash, then i can use BDM to debug. I am sure my hardware and BDM are good. Which software issue can make this happen?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Mar 2017 07:54:30 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/Flash-is-secured-after-writing/m-p/660294#M13953</guid>
      <dc:creator>liuweiwei</dc:creator>
      <dc:date>2017-03-17T07:54:30Z</dc:date>
    </item>
    <item>
      <title>Re: Flash is secured after writing</title>
      <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/Flash-is-secured-after-writing/m-p/660295#M13954</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt;"&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt;"&gt;The &lt;STRONG&gt;MCU&lt;/STRONG&gt; is &lt;STRONG&gt;secured&lt;/STRONG&gt; only if the SEC bits in &lt;STRONG&gt;flash&lt;/STRONG&gt; security byte at address 0xFF0F (global address 0x7F_FF0F) are different from value 0b10. Recommended value of &lt;STRONG&gt;flash&lt;/STRONG&gt; security byte for unsecured state is 0xFE.&lt;BR /&gt; So, there must be something in your code that changes this byte to &lt;STRONG&gt;secured&lt;/STRONG&gt; state. Please check the content of address 0xFF0F &lt;STRONG&gt;after&lt;/STRONG&gt; first download of firmware. Then run the code for certain time and check it again. What is the result?&lt;BR /&gt; Notice that the &lt;STRONG&gt;flash&lt;/STRONG&gt; data are not refreshed in memory window by default: in debugger in main menu choose “MultilinkCyclonePro -&amp;gt; Debugging memory map” if you use P&amp;amp;E BDM multilink. New window will appear. Select appropriate block of memory in the list (it should be „flash C000“) and choose Modify/Details button. Enable the item “refresh memory when halting”.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt;"&gt;Some more info. ERASE function in PROG12Z always forces address $FF0F to $FE to allow BDM access. V&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt;"&gt;In CodeWarrior and its Hiwave debugger we can turn off the reprogramming of flash security byte to $FE by command FLASH NOUNSECURE which cases MCU is secured and BDM is disabled after programming and reset.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Unsecuring the MCU:&lt;/P&gt;&lt;P&gt;1) By application SW, the unsecuring feature or backdoor key must by implemented in user’s application.&lt;/P&gt;&lt;P&gt;2) Another way how to unsecure the device is to use unsecure command from CodeWarrior debugger or unsecure program from &lt;A href="http://www.pemicro.com/"&gt;www.pemicro.com&lt;/A&gt; pages.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you use USB multilink you have to use unsecure Option MultilinkCyclonePro-&amp;gt;Unsecure in the CodeWarrior Hiwave Debugger.&lt;/P&gt;&lt;P&gt;or you can use external usecure program which can be downloaded from pemicro pages.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unsecure_12&lt;SPAN style="font-size: 7.5pt;"&gt;: &lt;/SPAN&gt;Utility which unsecures HCS12 devices via P&amp;amp;E's BDM Interfaces such as Cyclone-PRO, USB-ML-12, and BDM-Multilink. This version supports the new Rev B Multilink.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.pemicro.com/downloads/download_file.cfm?download_id=16"&gt;http://www.pemicro.com/downloads/download_file.cfm?download_id=16&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unsecure_12 Help Files:&lt;SPAN style="font-size: 7.5pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;This .hlp file describes the use and operationg of the Unsecure_12 program which is used with P&amp;amp;E's interface devices to unsecure proeviously secured HCS12 microcontrollers.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.pemicro.com/downloads/download_file.cfm?download_id=14"&gt;http://www.pemicro.com/downloads/download_file.cfm?download_id=14&lt;/A&gt;&lt;/P&gt;&lt;P&gt;(These links I have stored in my PC…I wanted to check them but pemicro pages do not respond today)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards, Ladislav&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Mar 2017 11:34:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/Flash-is-secured-after-writing/m-p/660295#M13954</guid>
      <dc:creator>lama</dc:creator>
      <dc:date>2017-03-17T11:34:03Z</dc:date>
    </item>
  </channel>
</rss>

