I use LPC1754 for my project. As I can't get boot source from NXP, I made secondary boot program. It is writed in sector 0 and 1 in flash.
When power up, real boot execute my secondaray boot program. And then download application using by X-Modem and wirte from sector 2 in flash. After all porcess finished, it jump to application which address is 0x2000.
But. It does not work application. Actually, until jump it was good.
Application program's compile option was set 0x2000 in start adress in Keil. After compile, conert .hex to .bin file.
Read .bin file by Edit program, cut off extra FF data in forpart.
What should I do more? What was Wrong?
Hope your advice. Thanks.
Did you map your interrupt vectors?
As start address was changed from 0x0000 to 0x2000, map file changed automatically by keil compiler.
Should I have to change map file artificially in Application program?
REMAP your interrupt vector - not directly related to your map file.
If you change the start address of your program to 0x2000, the one million dollar question would be: How can the processor know that your program doesn't have an interrupt vector table at address zero anymore? Remember that it's the boot loader that owns the address 0x0000 where you originally had the applications interrupt vector table.
That was what I meant with my question.
Make sure that you copied the program correctly, you need to blank the sector before in preparation. After you write try to read and check that writting happened correctly.
Also check that both programs are compatible in terms of clock rate and system setting or you may need to do extra steps.