Hi,
I try to use bootloader as AN4767 in my processor MKE02Z16VLC4 (40MHz)
After program bootloader to my processor, I use win_hc08sprg.exe to flash Blink app to my processor
and I get the result
After that, I use S-recoder tool to convert source address range of my Blink.srec, i get a new result
So it still not work. How should I do now
My project is written by Codewarrior
Original Attachment has been moved to: Blink.srec.zip
Original Attachment has been moved to: Bootloader.zip
Sorry for my late reply, I tried to debug and fixed this problem. Just because of some mistakes in uart
Hi Alice,
I've fixed some mistake about my UART and when I debug, the address, length and the data is right.
But after Flash_EraseSector, I got the problem
And I dont know why this error is occurred. The Flash_EraseSector function work fine in my simple project (only write 'a' in address 0x00001410).
Can you help me. My code write for KE02 40MHz and can you use FRDM-KE02 (40MHz) debug for me
Hi,
Please step into Flash_EraseSector to check when run which code, it crash.
BR
Alice
Hello
I recommend you first creating a simple project to download, if still can't work,
please send your application project to me .
BR
Alice
Hi Alice,
I have already created a blink project to download but it still cant work
The bootloader project I have attached in the question.
Can you check what's wrong in my bootloader code?
Hi Huy,
Please pay attention that, the flash size of your chip MKE02Z16VLC4 is 16K 0x0000 - 0x3FFF,
so you can't put the new vector table(APP vector ) into 0x4000 .
Also please refer to AN4767->2.4 User code to configure your APP.
If still have problem, I recommend you open the bootloader GUI win_hc08sprg(it under AN2295 ) project to debug ,
the information from GUI view can find in the GUI project source.
Hope it helps
Have a great day,
TIC
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Alice,
I've changed in FC_Protocol.h and I also change the linker file in my application code
Can you review for me both project in CW
I also use AN2295 GUI and it 's seem wrong
It's wrong in Memory Block. In the Identification it's Block 1 and when erase and write it's Block 0
What should I do
Hello Huy,
I haven't the board about your chip, so I can't debug it on my side.
From the message , it seems erasing failed, please set a breakpoint in your erasing code,
then click "Erase" button, when it run to breakpiont, debug step by step check whether it erased
successfully , or why it failed.
BR
Alice
Hi Alice,
I set breakpoint in the code that contain ERASE code and use the GUI to debug. In the first press button Erase in the app, it doesnt break. But the second time it breaks. So may be it wrong with my UART code, can you review for me.
And can you also send me an bootloader code that it works well on KE02Z board. I can also compare to my code. My email is huyrua291996@gmail.com. Thanks!
Hi,
The AN4767 sw is the bootloader for FRDM-KE02. You can refer to the Reference manual of your chip
to change the bootloader. Sorry I haven't the bootloader for this chip.
When it break, then what happened ? When it run to erase code, check whether it can erase successful.
You can check the UART data to see whether your UART code is wrong.
BR
Alice
Hi Alice,
Now I get a FRDM-KE02 board. But the AN4767sw is code for IAR
Can you give me source code for CW or KDS
And I have an issue about my UART, I set interrupt mode and I set only UART_C2_RIE_MASK, and it work right with another project. Can you give me some advice about it?