
Debug Support
ARM DDI 0144B
Copyright 1999, 2000 ARM Limited. All rights reserved.
8-49
Bit 0
Denotes if there is some new data in the comms data read register.
If, from the point of view of the processor, R=1, there is some new
data that can be read using an
MRC
instruction. If, from the point of
view of the debugger, R=0, the comms data read register is free
and new data can be placed there through the scan chain. If R=1,
data previously placed there through the scan chain has not been
collected by the processor, and so the debugger must wait.
From the point of view of the debugger, the registers are accessed using the scan chain
in the usual way. From the processor, these registers are accessed using coprocessor
register transfer instructions. You can use the following instructions:
MRC p14, 0, Rd, c0, c0
Returns the debug comms control register into Rd.
MCR p14, 0, Rn, c1, c0
Writes the value in Rn to the comms data write register.
MRC p14, 0, Rd, c1, c0
Returns the debug data read register into Rd.
Note
The Thumb instruction set does not support coprocessor instructions (to access the
debug comms channel, the core must be in ARM state).
8.14.2
Communication using the comms channel
Communication can take place over the debug comms channel by either an interrupt
driven mechanism or through software polling.
The interrupt driven mechanism requires the
COMMTX
and
COMMRX
signals to be
factored into an interrupt controller. The comms channel is only accessed therefore,
when the write channel has become free or the read channel has received data, allowing
efficient communication.
Software polling requires no external hardware configuration. The program must
examine the debug comms control register to determine if data has been received or if
the write channel has become empty. Only when such an event has occurred can the
debug comms write or read register be accessed.