How to make a USB DFU bootloader for MK22DX256VLF5

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to make a USB DFU bootloader for MK22DX256VLF5

ソリューションへジャンプ
6,891件の閲覧回数
paulminusx
Contributor III

Hello all,

First I would like to confirm what is a USB DFU bootloader.According to me a USB DFU bootloader is program that provides HID support and shows itself like a Pendrive and whatever code we copy to it is flashed on to the MCU ,am I right?

Now for my next and the primary question How shall I make USB DFU Bootloader.The functionality that I need is

1)Its should show itself as a Mass Storage device and be able to flash the 'flash memory' of MCU when a .s19 or .bin file is copied to it.

                                                 OR

2)It should just act as a virtual comport  (just like CMSIS-DAP.s19 bootloader for OpenSDA) and can be detected and programmed in Keil.

1 解決策
5,784件の閲覧回数
paulminusx
Contributor III

Finally went with uTasker Project .Here is the guide uTasker Bootloader Porting Guide

元の投稿で解決策を見る

0 件の賞賛
返信
9 返答(返信)
5,785件の閲覧回数
paulminusx
Contributor III

Finally went with uTasker Project .Here is the guide uTasker Bootloader Porting Guide

0 件の賞賛
返信
5,784件の閲覧回数
jeremyzhou
NXP Employee
NXP Employee

Hi Paul,

According to your statement, I think you should choose the USB MSD device bootloader.

And I've also attached an application node, please refer to it for details.
Have a great day,
Ping

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

5,784件の閲覧回数
paulminusx
Contributor III

Yeah this is exactly the same application note I was reading,but the problem is I am not able to port the bootloader for my MCU. I am a complete newbie at ARM/Codewarrior tools .Can please help me with the steps. ?

0 件の賞賛
返信
5,786件の閲覧回数
jeremyzhou
NXP Employee
NXP Employee

Hi Paul,

Thanks for your reply.

To provide the fastest possible support I want to point you to a similar question which has been answered on our Freescale community. Please refer to USB MSD device bootloader revision for FRDM-K64F (IAR)  to view the details.

Wish it helps.
Have a great day,
Ping

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

5,786件の閲覧回数
mjbcswitzerland
Specialist V

Hi

You can get USB-MSD (device or host, or even device and host at the same time!) at the link below for your processor so doesn't need any porting and contains also Kboot loading in parallel.

Regards

Mark

Kinetis: http://www.utasker.com/kinetis.html

K22: http://www.utasker.com/kinetis/FRDM-K22F.html / http://www.utasker.com/kinetis/TWR-K22F120M.html

Serial Bootloader (Ethernet, USB, MSD, KBOOT, AN2295, SREC, SD-card): http://www.utasker.com/forum/index.php?topic=1873.msg6796#msg6796 / http://www.utasker.com/docs/uTasker/uTaskerSerialLoader.PDF

For the complete "out-of-the-box" Kinetis experience and faster time to market

:smileyinfo: Out-of-the-box boot loader support for 46 Kinetis boards, 8 modes and 10 IDEs (over 15'000 combinations from a single code source with no porting required)

5,786件の閲覧回数
paulminusx
Contributor III

HI,

The mentionedd links are only for K22F MCU family ,my MCU is K22DX256VLF5.

0 件の賞賛
返信
5,786件の閲覧回数
mjbcswitzerland
Specialist V

Hi

For the K22DX256VF5 the K21D50M version can be used: http://www.utasker.com/kinetis/TWR-K21D50M.html It just requires the RAM and Flash sizes to be set accordingly:

    #define SIZE_OF_FLASH       (128 * 1024)                             // 128k program Flash
    #define SIZE_OF_RAM         (32 * 1024)                              // 32k SRAM

and the linker script K_128_32.ld to be used.

Regards

Mark

5,786件の閲覧回数
paulminusx
Contributor III

Thank you Mark.I'll try utasker and see if it works and let you know. Also I have become interested in AN4379 USB MSD , can you help me with the steps required to port using code warrior.for my MCU.I haveen trying a lot according to the given document but I suppose I am missing something because of which I am getting compilation errors in CW when I try to compile th e modified example of AN4379 USB MSD bootloader for MK22D5 (originally the example project is for K60 MCU ).Also learning how to port successfully will help know things better cause I am a newbie in this field. 

Best Regards :smileyhappy:

Shubham

0 件の賞賛
返信
5,786件の閲覧回数
mjbcswitzerland
Specialist V

Shubham

AN4379 is an old version which (probably) won't work with Windows 8.1 or MAC OS X. It is only available for CW 10 and K60.

If you are experienced you may be able to port it if you invest a few days of work. If less experienced you will need help from Freescale or a professor and foreseen several weeks of effort - the K60 and K22-50 are quite different parts. Since I don't know the AN4379 code and it is probably not maintained you may need to track down the original author and see whether he/she is willing to coach you.

The uTasker serial loader includes USB-MSD operation equivalent to AN4379 but for all IDEs and processors with Win 8.1 and MAC OS X compatibility so doesn't need any further work.

The uTasker serial loader also incudes AN4368 (host loader from memory stick) operation (also both at the same time so that either device or host can work automatically), KBOOT, AN2295 compatible developer's boot loader, HIDloader.exe compatible loader and various others. It can be build for virtually any processor, with virtually any IDE and the loading methods mixed as required.

The operation can be simulated so allows all details of the Kinetis to be tested and analysed, meaning that it is also much more suitable for educational work.

Regards

Mark