<?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: MK22 - Fail to flash it in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770908#M46897</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Antonio Oliveira,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; If you welded the minimum components, you can use the JLINK commander find the ARM cortex M4, and can do the erase, I think your smallest system don't have big problem.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; You said, when you use the KDS download the code, it will be time out, I have a question about your KDS project, whether your KDS project is match with the MK22FN1M0VLL12.&lt;/P&gt;&lt;P&gt;&amp;nbsp; You can create a empty project for MK22FN1M0VLL12, then in the debug configuration, you need to use the JLINK, select the according SWD or JTAG interface.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; If you still have problem, you also can generate the .bin file, then try to download the file directly in the JLINK commander, with command: loadfile xxx.bin&lt;/P&gt;&lt;P&gt;&amp;nbsp; Whether you can do it correctly or not?&lt;/P&gt;&lt;P&gt;&amp;nbsp; Please try it at first.&lt;/P&gt;&lt;P&gt;&amp;nbsp; If you still have problem about it, please give me some picture about the KDS error problem, the debug log, and the JLINK commander windows information.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Wish it helps you!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Kerry&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>Sat, 24 Feb 2018 03:10:18 GMT</pubDate>
    <dc:creator>kerryzhou</dc:creator>
    <dc:date>2018-02-24T03:10:18Z</dc:date>
    <item>
      <title>MK22 - Fail to flash it</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770907#M46896</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey Guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a custom board with the MK22FN1M0VLL12 1N41K.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have pull up resistors in the reset_b and EZP_CS (10K each), and 10ohm resistor with 47mF to slow down the power startup. Other signal; VBat connected to 3V3, VREFH and VREFL connected to 3V3 and GND, all VDD and VSS connected, no cristals&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using Jlink Lite or Jlink commander I can connect the MCU, erase it, and unlock it, also can access the memory. I acn see the erase working and there are no errors at all. After the erase the reset_b goes high, but if we do a power off and a power on the saw wave in the reset_b it shows up again, it does not go away. When I try to upload (flash) a sketch through KDS I go a time out error. So I am unable to change the factory state in this MCU.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All the connections are ok and I just welded the minimum components to do the first erase and upload. I have used the same process with the MKL05, MKE06, and MK10 and everything was ok, and easy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So my questions are:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What else more can I try? I am running out of options.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Has someone successfully put the K22 in a custom board to work using a probe like Segger Jlink ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help on this issue will be very appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Antonio Oliveira&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Not answered yet...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Feb 2018 09:11:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770907#M46896</guid>
      <dc:creator>antoniooliveira</dc:creator>
      <dc:date>2018-02-23T09:11:19Z</dc:date>
    </item>
    <item>
      <title>Re: MK22 - Fail to flash it</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770908#M46897</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Antonio Oliveira,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; If you welded the minimum components, you can use the JLINK commander find the ARM cortex M4, and can do the erase, I think your smallest system don't have big problem.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; You said, when you use the KDS download the code, it will be time out, I have a question about your KDS project, whether your KDS project is match with the MK22FN1M0VLL12.&lt;/P&gt;&lt;P&gt;&amp;nbsp; You can create a empty project for MK22FN1M0VLL12, then in the debug configuration, you need to use the JLINK, select the according SWD or JTAG interface.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; If you still have problem, you also can generate the .bin file, then try to download the file directly in the JLINK commander, with command: loadfile xxx.bin&lt;/P&gt;&lt;P&gt;&amp;nbsp; Whether you can do it correctly or not?&lt;/P&gt;&lt;P&gt;&amp;nbsp; Please try it at first.&lt;/P&gt;&lt;P&gt;&amp;nbsp; If you still have problem about it, please give me some picture about the KDS error problem, the debug log, and the JLINK commander windows information.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Wish it helps you!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Kerry&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>Sat, 24 Feb 2018 03:10:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770908#M46897</guid>
      <dc:creator>kerryzhou</dc:creator>
      <dc:date>2018-02-24T03:10:18Z</dc:date>
    </item>
    <item>
      <title>Re: MK22 - Fail to flash it</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770909#M46898</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kerry,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for answering my question.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I followed your suggestion and used the loadbin in the J-Link commander and surprisingly it works. But the KDS is still being not able to connect to the MK22.&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/18789i0B76EA87DFFB1631/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;&lt;/P&gt;&lt;P&gt;In the commander the sequence is:&lt;/P&gt;&lt;P&gt;1- launch commander -&amp;gt; Jlink.exe&lt;/P&gt;&lt;P&gt;2- type -&amp;gt; device mk22fn1m0xxx12&lt;/P&gt;&lt;P&gt;3- type -&amp;gt; connect&lt;/P&gt;&lt;P&gt;4- it will ask the programmer type - SWD, and speed -&amp;gt; 100&lt;/P&gt;&lt;P&gt;5- then should connect&lt;/P&gt;&lt;P&gt;6- type -&amp;gt; erase&lt;/P&gt;&lt;P&gt;7- check if is unsecured, type - mem 40c 1 (it will show the FSEC status, it should be "FE")&lt;/P&gt;&lt;P&gt;8- if is not "FE", try erase again, and connect again.&lt;/P&gt;&lt;P&gt;9- type mem40c 1, it should show "FE"&lt;/P&gt;&lt;P&gt;10- type loadbin &amp;lt;your_file.bin&amp;gt;&amp;nbsp; &amp;nbsp;0&lt;/P&gt;&lt;P&gt;11- if everything is ok it will load the file&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you mess up the sequence, and get errors, just poer on/off the board and restart the commander.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Took me a while to figure out the right way to do the file upload because I was tricked by the IDE, it works perfectly for other MCUs, but does not work for the K22. I do not know why.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The hardware needs to include:&lt;/P&gt;&lt;P&gt;1- Resitor of 10ohm and capacitor of 47mF to slow down the power up just for the first upload, put them in a proto-board and connect a power supply set at 3V4.&amp;nbsp;&lt;/P&gt;&lt;P&gt;2- Pull up resistors (4.7K) for SWD_DIO and RESET_b&lt;/P&gt;&lt;P&gt;3- Pull up resistor in EZP_CS is not required&lt;/P&gt;&lt;P&gt;4- The 3V3 regulator requires capacitors in VIN and VOUT.&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;Resitor of 10ohm and capacitor of 47mF are not required after the first upload, I did disable the EZ port at POR by software in my sketch, so it will not come up on POR.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So, this is based on the best of my abilities, it might have other ways but this is the one that works for me.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;But I still do not know why the IDE cannot flash the board, would be nice to solve this issue, because is more practical&amp;nbsp;using the IDE alone, instead IDE + commander.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Best Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Antonio Oliveira&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Feb 2018 09:47:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770909#M46898</guid>
      <dc:creator>antoniooliveira</dc:creator>
      <dc:date>2018-02-25T09:47:40Z</dc:date>
    </item>
    <item>
      <title>Re: MK22 - Fail to flash it</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770910#M46899</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Antonio Oliveira,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Thank you for your updated information.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; If the JLINK can download the code, and the code function works, I think the problem should in the IDE configuration side.&lt;/P&gt;&lt;P&gt;&amp;nbsp; Do you follow my suggestion, just to create a empty project, then use the JLINK to download it?&lt;/P&gt;&lt;P&gt;&amp;nbsp; Please make sure the part number is the same as your chip, because the K22 has a lot of part number, different part number have different feature.&lt;/P&gt;&lt;P&gt;&amp;nbsp; After you create the KDS project, in the debug configuration, choose Segger JLINK, interface should select SWD, not JTAG, please try again.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; If you still have problem in KDS, please give me your debug configuration picture, and the KDS debug log, I need to check it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Kerry&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>Tue, 27 Feb 2018 02:23:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/MK22-Fail-to-flash-it/m-p/770910#M46899</guid>
      <dc:creator>kerryzhou</dc:creator>
      <dc:date>2018-02-27T02:23:22Z</dc:date>
    </item>
  </channel>
</rss>

