Hello Keil community,
I have an Atmel AT91SAM7x256 board with selfmade assembly startup code. For testing I had connect a simple switch at PioB to enter the external Interrupt. In simulation mode I can enter the IRQ_Hanlder in single steps without problems . But in debugging Mode the Programm did only enter the IRQ when I start the programm with the "run" Button, but not with single steps. :-(
My questions is now how can I configure the Keil debugger to enable the Interrupt in single step mode? Or maybe there are any special registers in the Atmel processor where I can enable it?
Many thanks and best regards
Norman
Duplicate and Answered.
http://www.keil.com/forum/19663/
Yes but is very important to know how I can enable the IRQ in signle stepping mode. To set brakpoints ist not very helpful for me, becaus I want to programm the serial IRQ_Handler and two breakpoints is not enough. At the other answer he said that ist possible but very difficult. Did any one know how wich parameter or µP register I must write to enable IRQ in single step mode?
best regards
Maybe:
1. Set a breakpoint right at the beginning of the IRQ_Handler. 2. Run the firmware, and wait. 3. Trigger a correct interrupt for that IRQ_Handler. 4. The firmware stops at the beginning of that IRQ_Handler. 5. Now, you are in the single step mode with a triggered interrupt.
That is the normal way to do it, i.e. to have breakpoints inside the relevant interrupt handler, and then have the processor run full-speed until it hits an interrupt.
Single-stepping everything is a concept that normally never works for real hardware, since the outside world do not slow down to a similar pace as the single-stepped program progresses.
It´s too bad to enter the IRQ only in run mode, althought the external Interrupt switch is set all the time between 2 single Steps. But when it is the only way I must set hardware breakpoints. Maybe Keil can fix the problem in one of the next software versions.
Many thanks for your help :-)
It is not a problem with Keil!
The problem, as has already been explained, is that you would somehow have to sychronise the external stimulus to exactly the correct moment after you pressed the 'Step' button so that the target hardware would see it in the moment that it is actually running.
Since you can't time your finger pressing a button to anything better than about 500ms precision, it should be obvious that this is virtually impossible!