<?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>Kinetis MicrocontrollersのトピックRe: Any update fro AN4379 MSD device bootloader?</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248839#M6871</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kai,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;I have contacted to AN4379’s author and he said me that there aren’t plans of updating the application note for supporting KL25 devices.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;However, Kinetis L devices are supported on the last version of USB Stack; so, you could use the MSD stack example for KL25 as base, and adding the Bootloader support from the application note similar to the current implementations. If you have troubles with the Flash routines, you could use the C90TFS Flash driver. On the following link you can find an example for KL25 device:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-94593"&gt;https://community.freescale.com/docs/DOC-94593&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;Hope this will be useful for you.&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;Best regards!&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;/Carlos &lt;/P&gt;&lt;P&gt;&lt;SPAN class="mce_paste_marker"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 11 Jul 2013 22:34:38 GMT</pubDate>
    <dc:creator>CarlosCasillas</dc:creator>
    <dc:date>2013-07-11T22:34:38Z</dc:date>
    <item>
      <title>Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248838#M6870</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;FSL has a great application note AN4379 regarding MSD device bootloader for Kirin3/Flexis JM/Kinetis K60 w/ CW, written by Derek Snell.&lt;/P&gt;&lt;P&gt;Additionally FSL also offers USB source for MSD device for emulated RAM and external SD card (via SPI bus) for multiple platforms.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am looking for MSD device bootloader for KL25Z for IAR toolchain. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Is there any update for AN4379?&lt;/STRONG&gt; I just want to make sure I am not going to re-invent the wheel on bootloader, ‘cause application development is my focus.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Jul 2013 09:52:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248838#M6870</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-07-01T09:52:13Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248839#M6871</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kai,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;I have contacted to AN4379’s author and he said me that there aren’t plans of updating the application note for supporting KL25 devices.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;However, Kinetis L devices are supported on the last version of USB Stack; so, you could use the MSD stack example for KL25 as base, and adding the Bootloader support from the application note similar to the current implementations. If you have troubles with the Flash routines, you could use the C90TFS Flash driver. On the following link you can find an example for KL25 device:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-94593"&gt;https://community.freescale.com/docs/DOC-94593&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;Hope this will be useful for you.&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;Best regards!&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;/Carlos &lt;/P&gt;&lt;P&gt;&lt;SPAN class="mce_paste_marker"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Jul 2013 22:34:38 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248839#M6871</guid>
      <dc:creator>CarlosCasillas</dc:creator>
      <dc:date>2013-07-11T22:34:38Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248840#M6872</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, Carlos.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will share my work, anyway.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Jul 2013 22:51:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248840#M6872</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-07-11T22:51:48Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248841#M6873</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kai,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any update on your work? Curious to know...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Bala&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Aug 2013 19:17:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248841#M6873</guid>
      <dc:creator>bala_aadhav</dc:creator>
      <dc:date>2013-08-06T19:17:10Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248842#M6874</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Carlos,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've found AN4379 is a great tool not only for bootloading easily but also a great template for modifying to get another funcionalities. For example, I'm developing an application which will store some sensor data into the own MCF51JM128's flash memory and the goal is to present this few bytes as a plain text file to the PC.&amp;nbsp;&amp;nbsp; With the help of FAT16 documentation I've learned how to "create" directories, files, give attributes, etc...It is all to be defined in the &lt;STRONG&gt;FAT16_RootDirSector &lt;/STRONG&gt;variable. So here comes my question: how can I get to "write" the content of the file, for example some simple ascii characters inside some example.txt file and when the PC open file the content can in effect be retrieved and copied to local drive ???&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do I have to look for FAT16 cluster write methods?, And, what could be the structure inside AN4379's FAT16.c source file and SCSI functions?.&amp;nbsp; Of course I understand the given source files are not intented for a complete file system, but for emulation purposes that helps one's application and that's just great :smileyhappy:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Really appreciating your valuable comments and guidance,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pablo B.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Aug 2013 13:46:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248842#M6874</guid>
      <dc:creator>PabloBaena</dc:creator>
      <dc:date>2013-08-08T13:46:12Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248843#M6875</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Pablo.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You could refer to application note AN4115, which implements the FAT file system from DEMOFLEXISJMSD board on MM/JE Flexis devices, and create/modify files stored on a SD card. This document is available at the following link:&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.freescale.com/files/microcontrollers/doc/app_note/AN4115.pdf"&gt;www.freescale.com/files/microcontrollers/doc/app_note/AN4115.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;Hope this will be useful for you.&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;Best regards!&lt;/P&gt;&lt;P style="padding: 0px 0px 1pt;"&gt;/Carlos&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Aug 2013 19:51:58 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248843#M6875</guid>
      <dc:creator>CarlosCasillas</dc:creator>
      <dc:date>2013-08-08T19:51:58Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248844#M6876</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nope, sorry.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Aug 2013 02:41:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248844#M6876</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-08-09T02:41:10Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248845#M6877</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Carlos,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Very useful AN...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Muchas gracias!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Aug 2013 22:08:55 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248845#M6877</guid>
      <dc:creator>PabloBaena</dc:creator>
      <dc:date>2013-08-09T22:08:55Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248846#M6878</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 managed to modify AN4379 code in order to respond to SCSI commands such as sector read, and understand the strategy corresponding to the AN's own code. Now I can generate my own plain and image files for custom applications...Very useful for low memory requirements and fast implementations not relying on additional SD Card! Just be careful with cluster and sector definitions according to FAT16 specification.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If anyone should find it useful or needs help on this, just leave me a message and will be glad to help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pablo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Aug 2013 21:02:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248846#M6878</guid>
      <dc:creator>PabloBaena</dc:creator>
      <dc:date>2013-08-23T21:02:47Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248847#M6879</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kai,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What's the current status of MSD bootloader porting?&amp;nbsp; Did you make it?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Sep 2013 00:37:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248847#M6879</guid>
      <dc:creator>hemingzhang</dc:creator>
      <dc:date>2013-09-05T00:37:41Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248848#M6880</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Pablo,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is great if you can share any resources like source code/library or even binary release.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Because my project is too urgent to wait for AN4379, and MSD bootloader has a big ass (about 22KB) to fit into my board. I use AN2295 bootloader from FSL so far.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, the original design has not been tested on FRDM-KL25Z. As a result, I changed some code and release my own tool, and my paper is here: &lt;A _jive_internal="true" href="https://community.nxp.com/docs/DOC-95429"&gt;https://community.freescale.com/docs/DOC-95429&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Alternatively, &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/BlackNight"&gt;BlackNight&lt;/A&gt; has published serial bootloader on github. &lt;A href="https://github.com/ErichStyger/mcuoneclipse/tree/master/Examples/FRDM-KL25Z/FRDM_Bootloader" title="https://github.com/ErichStyger/mcuoneclipse/tree/master/Examples/FRDM-KL25Z/FRDM_Bootloader"&gt;mcuoneclipse/Examples/FRDM-KL25Z/FRDM_Bootloader at master · ErichStyger/mcuoneclipse · GitHub&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/hemingzhang"&gt;hemingzhang&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Sep 2013 03:12:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248848#M6880</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-09-05T03:12:46Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248849#M6881</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kai, surely I will gladly post my results once I get my code very debugged, structured and documented for you colleagues to use it at best.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your feedback.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pablo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Sep 2013 16:06:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248849#M6881</guid>
      <dc:creator>PabloBaena</dc:creator>
      <dc:date>2013-09-05T16:06:01Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248850#M6882</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I spent one day to port this MSC/MSD bootloader to KL25Z with IAR. It is not finished yet.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I found that it is easy to port from CW to IAR. Porting from K60 to KL25Z takes more time. They have differences in many ways, including registers in GPIO/SIM/FTFA ......&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It only matters on time to delivery. It is not so difficult since we can cut and past some sources from AN2295, and it is working for KL25Z anyway.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, my porting path is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Based upon AN4379, setup a new project with IAR&lt;/LI&gt;&lt;LI&gt;Reuse AN4379 for USB MSC, bootloader parser and other high level modules.&lt;/LI&gt;&lt;LI&gt;Using conditional build with macro definition (MCU_MKL25Z4), will support KL24/26/45/46 in future.&lt;/LI&gt;&lt;LI&gt;Reuse flash drivers from AN2295.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The source code is messy. Too many macros are used.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Keep tuned.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Oct 2013 09:52:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248850#M6882</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-18T09:52:41Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248851#M6883</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE 1&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The firmware have been merged based upon original CW for K60 to IAR for KL25Z. Also I reuse code from AN2295 for its flash driver and simple drivers for timer, watchdog and etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The source code is built successfully. I attach my very first version here. However,&lt;STRONG&gt; it is not a working bootloader&lt;/STRONG&gt;. &lt;STRONG&gt;I have not made it working on FRDM yet.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I put it here just in case someone who need it urgently and want to debug by himself. And don't freak out if you find the source is too messy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will release my final code with FSL community. It will be a very simple version without verification, authentication, personalization and other features.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However I have to say. FSL should help us to develop and verify all the bootloaders, including AN2295 serial bootloader, AN4370 USB DFU bootloader, AN4379 USB MSC bootloader, as well as other bootloader including USB&amp;nbsp; host MSC bootloader, SD Card bootloader, Ethernet bootloader, CAN bootloader, I2C/SPI bootloader.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At least, FSL should align a standard driver for bootloaders, including drivers for K/KL flash memories, USB interface, serial com, file parser, FAT File system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yours sincerely&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Allan K Liu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 19 Oct 2013 02:12:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248851#M6883</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-19T02:12:40Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248852#M6884</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE 2&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here comes a update version. This version has famous issue "Unrecognized devices" in Windows XP. Yep, it must have bugs in USB communication. Still not a working version, available for debug only.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We are approaching our target, anyway.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Allan K Liu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 19 Oct 2013 12:18:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248852#M6884</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-19T12:18:35Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248853#M6885</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE 3&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The previous version fails on USB enumeration. I gave up on debugging low-level USB driver. So I re-create project on USB stack v4.0.3 with bootloader file. Now we can see BOOTLOADER driver now, but downloading firmware with wrong content.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyone who is interested on &lt;STRONG&gt;AN4379 on FRDM-KL25Z with IAR&lt;/STRONG&gt;?&lt;/P&gt;&lt;P&gt;Please download and help us to remove the bugs together.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The zip file should unzipped into USB stack source tree, in following path:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;X:\Freescale\Freescale USB Stack v4.0.3\Source\Device\app\&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Oct 2013 02:50:39 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248853#M6885</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-23T02:50:39Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248854#M6886</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE 04 with more questions/bugs&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/CarlosCasillas"&gt;CarlosCasillas&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/PabloBaena"&gt;PabloBaena&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/dereksnell"&gt;dereksnell&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dear all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I list you guys on my help list, 'cause I think you are experienced on this topic and can help me on AN4379 USB MSC/MSD bootloader porting to FRDM-KL25Z.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The current code base is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;I reuse code from USB MSD example from FSL USB stack v4.0.3 as new baseline, and I migrate AN4379 code by Derek to v4.0.3 for its FAT16/disk driver.&lt;/LI&gt;&lt;LI&gt;I also reuse code from AN2295 bootloader for flash routines, since I have verified that code already.&lt;/LI&gt;&lt;LI&gt;I reuse image project image from AN4370 DFU bootloader for downloading, S19, (0xA000~0xCA20)&lt;/LI&gt;&lt;LI&gt;The serial port driver has been added for debug purpose.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Current performance:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;USB enumeration works&lt;/LI&gt;&lt;LI&gt;Serial port via FRDM-KL25Z works.&lt;/LI&gt;&lt;LI&gt;S-Record identified.&lt;/LI&gt;&lt;LI&gt;All S-Record stored in buffer is dumped on a terminal window&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bugs:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;STRONG&gt;The erasing routine erase_flash() will be called twice inside the MSD_Event_Callback(), the second time will read file from very beginning even the file has not been transferred completely. (&lt;SPAN style="color: #0000ff;"&gt;Follow-up: By disabling printf(), the OS only writes once.&lt;/SPAN&gt;)&lt;/STRONG&gt;&lt;/LI&gt;&lt;LI&gt;The buffer dumping sometimes missed some records. Different dumping, different result. I doubt it has something to do with USB interrupt. &lt;STRONG&gt;I will try to inspect internal flash memory, instead of printing out its content&lt;/STRONG&gt;. (&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Follow-up: By disabling printf(), then I found the content have been programmed from 0xA000 to 0xCA4F, longer than our expectation, and only first 16 bytes are corret&lt;/STRONG&gt;&lt;/SPAN&gt;)&lt;/LI&gt;&lt;LI&gt;The content has not been programmed into desired address (0xA000). Before migrating code, I do find content inside flash memory, however only first 128B is correct.(&lt;SPAN style="color: #0000ff;"&gt;&lt;STRONG&gt;Follow-up: its performance changes every time&lt;/STRONG&gt;&lt;/SPAN&gt;)&lt;/LI&gt;&lt;LI&gt;I am confused about disk.c USB_MSC_DEVICE_WRITE_REQUEST for its lba_data_ptr-&amp;gt;offset&amp;gt;&amp;gt;9 judgement. &lt;A class="jx-jive-macro-user" href="https://community.nxp.com/people/dereksnell"&gt;dereksnell&lt;/A&gt;, could you offer some background information about it? Thanks (&lt;STRONG style="color: #0000ff;"&gt;I can figure out the purpose of the code, I just want to know the meaning of right shift 9 times, do you have any document support that?&lt;/STRONG&gt;)&lt;/LI&gt;&lt;LI&gt;I saw may write_request to this virtual FAT16 disk. What kind of write requests are filtered out?&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Attached file:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;demo image S19 file (usb_device_tower_.s19, starts from 0xA000, we need an image file starts from 0x8000)&lt;/LI&gt;&lt;LI&gt;terminal dump files (x2)&lt;/LI&gt;&lt;LI&gt;project zip file, (should be copied into FSL USB stack v4.0.3)&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;FSL USB stack is hard to share a single project, I have to zip them all.&lt;STRONG&gt; Please using compare tools carefully to avoid replacing your own version. Especially the common sources have been revised slightly.&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Oct 2013 03:50:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248854#M6886</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-24T03:50:09Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248855#M6887</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE 05&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are no code update. Just sharing my latest experiences.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I move &lt;STRONG&gt;printf( )&lt;/STRONG&gt; before running low-level flash programming routines (FCCOB). The buffer dumping seems correct. From very beginning to end.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So far I have collected references manuals for K20/KL25, and I found they are not sharing same code base. There are many parallel releases from FSL teams.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Compare to K20 FTFL and K60 FTFE, KL25 has a simpler flash module called FTFA without RAM based sector programming and some other features.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But most of the basic FCCOB is same. No idea why programming failed anyway.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Oct 2013 09:34:23 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248855#M6887</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-25T09:34:23Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248856#M6888</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE 06&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Now code is working and verified. :smileyhappy: Finally !&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is a bug in low-level flash programming for long word. The control loop is controlled by size, which is Nr of byte. So the size = size - 4, rather than -1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;LWord FLASH_ProgramSectionByLongs(LWord destination, LWord* pSource, LWord size)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;{&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp; //dumpBuf((unsigned char*)pSource,size,0);&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp; //while(size--)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp; while(size)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp; {&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if(FLASH_ProgramLongWord(destination, *pSource++) != FLASH_OK)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return FLASH_FAIL;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; destination += 4;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; size -= 4;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp; }&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp; printf("\r\n");&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;&amp;nbsp; return FLASH_OK;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: verdana, geneva;"&gt;&lt;STRONG&gt;}&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In next official release, I will prepare an application note with source code as well as demo firmware and icf file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I spent a week on porting AN4379 on FRDM-KL25Z with IAR. Although this question was posted &lt;STRONG&gt;4 months ago&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That is another problem I solve by myself. I did wish any FSL team can help me to accelerate this process. It took too much time than my expectation.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Oct 2013 13:06:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248856#M6888</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-25T13:06:15Z</dc:date>
    </item>
    <item>
      <title>Re: Any update fro AN4379 MSD device bootloader?</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248857#M6889</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE 07&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The revised MSD device bootloader has been released on &lt;A href="https://community.nxp.com/docs/DOC-97782"&gt;USB MSC device bootloader revision for FRDM-KL25Z (IAR)&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The code is developed on USB stack v4.0.3 with reused functions from AN2295/AN4370. Its version has been promoted to v1.0 beta.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have verified the project by a relocated user application starts from 0x8000. Just download them and try it on your FRDM-KL25Z.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yours sincerely&lt;/P&gt;&lt;P&gt;Allan K Liu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Oct 2013 07:23:08 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Any-update-fro-AN4379-MSD-device-bootloader/m-p/248857#M6889</guid>
      <dc:creator>kai_liu</dc:creator>
      <dc:date>2013-10-30T07:23:08Z</dc:date>
    </item>
  </channel>
</rss>

