Forums

Debugging from flash

Started by timothymarknorton October 27, 2005
At 04:48 AM 10/29/05 +0000, Eric Engler wrote:
> > What I haven't seen in any of the descriptions of ANY available
>debugger
> > for the ARM microcontrollers is one with a decent watchpoint
>facility. One
> > that would allow you to set a break when a certain value was written
>to a
> > certain location or range of locations for instance (while running
>at full
> > speed of course).
>
>I can only think of 2 ways to implement flexible conditional breakpoints:
>
>1) set an undconditional breakpoint "behind the scenes". and when it
>breaks, the PC will request data on memory contents and the PC decides
>if it will break for the user, or if it will reset the breakpoint and
>continue execution. This is slow, but easy to implement.
>
>2) the highest performance is done by downloading some extra assembler
>code to the ARM. Set an unconditional breakpoint, and when it breaks
>the ARM assembly code will evaluate the condition, and decide what to
>do. This is almost full speed, but it's harder to implement.

Neither of those will provide a data watchpoint though which is what I was
referring to above. Since in order to implement that you would have to
single step through the code at the instruction level and evaluate at every
step. This would be considerably below full speed. I suspect that this is
only possible with a proper ICE and I haven't seen one of those for any
micro that has a BDM or JTAG interface.

Robert " 'Freedom' has no meaning of itself. There are always restrictions, be
they legal, genetic, or physical. If you don't believe me, try to chew a
radio signal. " -- Kelvin Throop, III
http://www.aeolusdevelopment.com/


An Engineer's Guide to the LPC2100 Series

Robert Adsett wrote:

> Neither of those will provide a data watchpoint though which is what I
> was
> referring to above. Since in order to implement that you would have to
> single step through the code at the instruction level and evaluate at
> every
> step. This would be considerably below full speed. I suspect that this
> is
> only possible with a proper ICE and I haven't seen one of those for any
> micro that has a BDM or JTAG interface.

And the ARM7 has a proper ICE.
See my previous post http://groups.yahoo.com/group/lpc2000/message/9851
which explains the function of the ARM Embedded ICE module.

A breakpoint is just a watchpoint that breaks on address + instruction
fetch. A watchpoint breaks on address + data read/write, possibly with a
specific data pattern.

This means that the ARM can use a hardware watchpoint while running at
system speed. I have used this using the ARM RealView tools.

I am not sure of other debuggers though.

Rob


The PutQueue procedure uses a Count Type of Integer.
Arrays that start at 1 are treated differently than arrays that start with 0.
Manual says, "If the queue is full, PutQueue will suspend the task until there is enough room to insert the data."
Keep trying to fix it, and let us know what happens.

Eric
----- Original Message -----
From: wurlitzer28

Subject: [BasicX] BX24 Comm1 should send 3 bytes but only 2 received I have fought this for the last 2 days. This routine looks for a bit
or bits that have changed since the last time the program read a word
from PortA.



At 05:14 AM 10/30/05 +0000, you wrote:
>--- In lpc2000@lpc2..., Robert Adsett <subscriptions@a...> wrote:
>
> > What I haven't seen in any of the descriptions of ANY available
>debugger
> > for the ARM microcontrollers is one with a decent watchpoint
>facility. One
> > that would allow you to set a break when a certain value was written
>to a
> > certain location or range of locations for instance (while running
>at full
> > speed of course).
> >
> > Robert
> >
>
>I am using Ashling PathFinder and Opella. I can "set a break when a
>certain value was written to a certain location or range of locations".


Nice, I hadn't noticed that when I last looked at their literature. Not a
feature you need often but when you do there isn't anything that will
substitute for it.

With that an the ETM you appear to have almost a full ICE capability. I
think the biggest thing left is probably the quantity of breakpoint and
watchpoints. And if other vendors follow Seggers example then that will
just leave the quantity of data watchpoints which is often low in a 'real'
ice anyway.

My thanks to you and Rob for correcting my oversight.

Robert

" 'Freedom' has no meaning of itself. There are always restrictions, be
they legal, genetic, or physical. If you don't believe me, try to chew a
radio signal. " -- Kelvin Throop, III
http://www.aeolusdevelopment.com/