I have written a bootloader for a cortex-M1 processor that starts at 0x0. It correctly loads the code I have stored in a serial flash chip to RAM starting at 0x60000000. I can successfully go through the debugger with this project and then when I jump to my other projects reset vector I can correctly go through the assembly.
However, I do not want to go through the assembly of my main application I want to debug it like a normal project. What is the best way to do this?
Right now I have two separate projects with each having their own main.c files. If I have to combine the projects, what is the best way to do that?
Hi,
You could use and debug INI file to setup your system like the bootloader does and directly debug from the Main project.
For example have the main project download your code to RAM or wherever it is executed from and set you PC and SP registers accordingly.
That should work, thanks for the suggestion.
Or just temporarily place you application at 0x0...
load the one you want to debug last, i.e. to debug the app load the bootloader, then load the app. ypu can then set a breakpoint in the apps main and when it stop there you have source debug. works with Keil '51, try it with ARM
Erik
Doesn't seem to work, do I need to have the projects in a multi-project workspace? Otherwise, as soon as I hit debug on the main application it just executes code skipping any set breakpoints unless I manage to stop the program, and then it will respond to break points if I resume running.
What Tamir suggested looks like it works. It ignores the bootloader, but should be good enough to give me what I want.
Thanks for all the help.