I'm using a Keil Ulink2 ICE debugger with an Atmel AT91RM9200 (ARM 9) powered board. My problem is that it doesn't look like I'm benefiting from all the features of the debugger. For example, in the Disassembly window, I don't see the C code mixed with the assembly instructions, like in the following picture:
http://www.keil.com/uvision/db_view_disasm.asp
Also, the Debug Settings from the Debug menu is not active.
When I use the simulator from uVision, I can use both of these features. But the simulator doesn't help me too much, as I need the hardware.
Are there some hidden settings in order to fully use the ICE debugger? Thanks
UPDATE
I link the code at address 0x10000000 but when I start the ICE debugger it shows me the code at address 0x0. If I go to address 0x10000000 I can see the C code (with comments), but the assembly code from that address is junk. My assembly code is at address 0x0.
Why?
I don't see this problem with the simulator.
My scatter file looks like this:
BOOT_MEM 0x10000000 0x10000
{
BOOT_RO +0
cstartup_keil_new.o (reset, +First)
* (+RO)
}
BOOT_RW +0
* (+RW)
BOOT_ZI +0
* (+ZI)
ARM_LIB_HEAP 0x10005000 EMPTY 0xB000-0x400{}
ARM_LIB_STACK 0x10010000 EMPTY -0x400{}
OK. Sorry for the ambiguous previous posts. My code is at the address I linked it, where it should be, not at address 0x0, as I said. I got confused, because at address 0x0 it is mapped the ROM code with the original Vector table. I have my own vector table and I thought the one from 0x0 was mine. So I did manage to find my assembly code interleaved with the commented source code.
The problem that I still face is that the code doesn't get executed. I tried with a step by step execution and the instructions remain gray (they don't get turn into green or something else), as if they were not executed. The PC is incremented and the registers get modified (I looked in the register window) but the instructions are not executed. BL, BX instructions are just ignored and the PC is not updated with the address of the called functions. It is incremented by 4 and that's it. Eventually the code gets into a prefetch abort or in a loop from the ROM code, depending on how I link it.
Why is this happening and how can I solve it? Thanks.
Have you looked at the PC value? Where is the processor running? Where your application is downloaded?
What reason would your processor have to know where you have downloaded your program? What would make it jump to the start address of your program?
View all questions in Keil forum