19-28
MCF5249UM
MOTOROLA
Real-Time Debug Support
19.4.2
PROGRAMMING MODEL
In addition to the existing BDM commands that provide access to the processor’s registers and the
memory subsystem, the debug module contains nine registers to support the required functionality. All of
these registers are treated as 32-bit quantities, regardless of the actual number of bits in the
implementation. The registers, known as the debug control registers, are accessed through the BDM port
using two new BDM commands: WDMREG and RDMREG. These commands contain a 4-bit field, DRc,
which specifies the particular register being accessed.
These registers are also accessible from the processor’s supervisor programming model through the
execution of the WDEBUG instruction. Thus, the breakpoint hardware within the debug module may be
accessed by the external development system using the serial interface, or by the operating system
running on the processor core. It is the responsibility of the software to guarantee that all accesses to
these resources are serialized and logically consistent. The hardware provides a locking mechanism in the
CSR to allow the external development system to disable any attempted writes by the processor to the
breakpoint registers (setting IPW = 1). The BDM commands must not be issued if the ColdFire processor
is accessing the debug module registers using the WDEBUG instruction.
Figure 19-25 Debug Programming Mode
19.4.2.1
Address Breakpoint Registers
The address breakpoint registers (ABLR and ABHR) define a region in the operand address space of the
processor that can be used as part of the trigger. The full 32-bits of the ABLR and ABHR values are
compared with the address for all transfers on the processor’s high-speed local bus. The trigger definition
register (TDR) determines if the trigger is the inclusive range bound by ABLR and ABHR, all addresses
Table 19-21 Shared BDM/Breakpoint Hardware
REGISTER
BDM FUNCTION
BREAKPOINT FUNCTION
Bus Attributes for All Memory Commands
Attributes for Address Breakpoint
Address for All Memory Commands
Address for Address Breakpoint
Data for All BDM Write Commands
Data for Data Breakpoint
ADDRESS
BREAKPOINT REGISTERS
PC BREAKPOINT
REGISTERS
DATA BREAKPOINT
REGISTERS
15
0
31
TRIGGER DEFINITION
REGISTER
ADDRESS ATTRIBUTE
TRIGGER REGISTER
7
0
15
CONFIGURATION/STATUS
REGISTER
BDM ADDRESS
ATTRIBUTE REGISTER
F
re
e
sc
a
le
S
e
m
ic
o
n
d
u
c
to
r,
I
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com
n
c
..
.