Hello everyone,
I'm trying to port a bootloader to a k20 MCU. Reading the reference manual chapter 10 ( which talks about bootloader porting).
I really don't know if this is possible in this particular MCU or if someone has aldready done.
I'm using KDS to port the bootloader.
The first step talks about editing the header files, provided by NXP as CMSIS-compatible packages, has someone any idea where to find them? And if not, is there any other way to implement a bootloader to k20 MCU?
Thank you in advance,
Eduard
Hello Eduard
I thinks its fine keep it up. well some more file need to be modify. Let me attach list of files i had modified when i have successfully ported.it may help you more. Just take a reference of it because my target controller was MK20DX256xxx10.
Files Modified:
• File: fsl_device_registers.h
• Path: /src/include/device
• Changes:
Files Modified:
• File: botloader_config.h
• Path: targets/MK20D25610/src
• Changes:
Files Modified:
• File: startup.c
• Path: src/startup/
• Changes:
File Modified: hardware_init_K20D256.c
• Path: targets/MK20D25610/src/hardware_init_K20D256.c
• Changes:
File Modified: target_config.h
• Path: targets/MK20D25610/src/target_config.h
• Changes:
File Modified: memory_map_K20D256.c
• Path: targets/MK20D25610/src/memory_map_K20D256.c
• Changes:
CPU "CPU_MK20DX256VLL10" changed at project property-> c/c++ build ->setting -> cross ARM c compiler -> Preprocessor ->debug symbols
Need to change linker file
Let me know if any...
Regards,
Harsh
Hello Eduard Pérez
i have already ported for K20DX256xxx10.
Take a reference of MK22F12810 code if you want to port for mk20dx256xxx10.
MK22f25612 for Mk20dx256xxx12.
If you have installed Kinetis design studio than you will get all related header files from \Freescale\KSDK_1.3.0\platform\devices.
Follow chapter 10 of user reference manual.
Let me know if any...
Regards
Harsh
Hello Harsh Patel
I keep trying to port the bootloader following step by step the instructions of reference manual:
The context is:
- Bootloader porting MCU= MK20DX256VHL7
- Reference MCU= MK22F12810 (is that correct?, closest match?)
- CMSIS files, located C:\Freescale\KDS_v3\eclipse\ProcessorExpert\Config\PE\CPE\wizard_data\wizards\kds\MK20D7
(device header files)
- Downloaded NXP_Kinetis_Bootloader_2_0_0
In NXP_Kinetis_Bootloader_2_0_0\targets\MK20D7\src
clock_config_K22F128R ------> clock_config_MK20D7
hardware_init_K22F128R -----> hardware_init_MK20D7
memory_map_K22F128R ----->memory_map_MK20D7
peripherals_K22F128R---------> peripherals_MK20D7
From now I've followed this steps can somebody see an error, if so, let me know it.
Thank very much,
Eduard
Hi
A note about uTasker KBOOT compatible loader and K20s:
- support KBOOT compatible UART, USB-HID and/or MSD
- supports additional options for SD card, memory stick, Ethernet
- Documented at http://www.utasker.com/docs/uTasker/uTaskerSerialLoader.PDF
- Fully tested and operational without any porting
For various K20s see:
- http://www.utasker.com/kinetis/FRDM-K20D50M.html
- http://www.utasker.com/kinetis/TWR-K20D50M.html
- http://www.utasker.com/kinetis/TWR-K20D72M.html
- http://www.utasker.com/kinetis/TEENSY_3.1.html
- http://www.utasker.com/kinetis/tinyK20.html
- Also includes K20F support which has been used in various products based on these parts
- Further potential benefits are smaller code size and greater IDE choice (CW, KDS, IAR, Keil, Atollic, Rowley, CooCox, Green Hills, GCC stand-alone and VisualStudio)
Regards
Mark
Kinetis for professionals: http://www.utasker.com/kinetis.html
Hello David,
First of all lot of thanks for the answer. I use a K20 at 72MHz in particular a mk20dx256, I've just downloaded the ksdk and used the SDK builder tool to download the corresponding package, the path in my case is C:\nxp\SDK_2.0_MK20DX256xxx10\devices\MK20D10.
Is that the correct one? I'm going to use the MK22F25612 as the closest match MCU to copy the header files, is there any way to asure this is a good option to choose?
Thanks a lot.
Regards,
Eduard
Hi Eduard,
The CMSIS files mentioned in the KBOOT Reference Manual are available from KDS installation. In this case for K20_72 MHz device this would be the path:
C:\Freescale\KDS_v3\eclipse\ProcessorExpert\Config\PE\CPE\wizard_data\wizards\kds\MK20D7
However, the porting process might be tricky if you are not experienced with Kinetis. You can port the AN2295 project (serial bootloader) which directly supports your device to KDS and whose latest version was shared in the next thread:
https://community.nxp.com/thread/354802
Another option is to go with a third party solution such as uTasker.
Regards!
Jorge Gonzalez
Hi Eduardo,
That documentation is a bit vague.
I suspect that it really wants you to generate a KSDK_v2 to use.
Which K20 device are you using? 100MHz? 72MHz? or 50MHz?
The 100MHz version is a subset of the K60-100MHz devices as FYI.
If you use the KSDK_v2 SDK Builder tool you can select the specific processor you are using.
Once you download that ZIP and place someplace then you have access to the header files mentioned earlier.
My download has following path for reference:
C:\NXP\KSDK_v2\SDK_2.0_MK20DN512xxx10_KDS\devices\MK20D10
Regards,
David