Chapter 6 S12Z Debug (S12ZDBGV2) Module
S12ZVHY/S12ZVHL Family Reference Manual Rev. 1.05
190
Freescale Semiconductor
6.3.2.5
Debug Trace Buffer Register (DBGTB)
Read: Only when unlocked AND not armed and the TSOURCE bit is set, otherwise an error code (0xEE)
is returned. Only aligned word read operations are supported. Misaligned word reads or byte reads return
the error code 0xEE for each byte. The PROFILE bit must be clear to read profiling data,
Write: Aligned word writes when the DBG is disarmed and both PTACT and PROFILE are clear unlock
the trace buffer for reading but do not affect trace buffer contents.
6.3.2.6
Debug Count Register (DBGCNT)
0
STAMP
Timestamp Enable
— This bit, when set, enables the timestamp function. The timestamp function adds a
timestamp to each trace buffer entry in Detail, Normal and Loop1 trace modes.
0 Timestamp function disabled
1 Timestamp function enabled
Address: 0x0104, 0x0105
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
R
Bit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9
Bit 8
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
W
POR
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
X
Other
Resets
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
Figure 6-7. Debug Trace Buffer Register (DBGTB)
Table 6-13. DBGTB Field Descriptions
Field
Description
15–0
Bit[15:0]
Trace Buffer Data Bits
— The Trace Buffer Register is a window through which the lines of the trace buffer may
be read 16 bits at a time. Each valid read of DBGTB increments an internal trace buffer pointer which points to
the next address to be read. When the ARM bit is written to 1 the trace buffer is locked to prevent reading. The
trace buffer can only be unlocked for reading by writing to DBGTB with an aligned word write when the module
is disarmed. The DBGTB register can be read only as an aligned word. Byte reads or misaligned access of these
registers returns 0xEE and does not increment the trace buffer pointer. Similarly word reads while the debugger
is armed or trace buffer is locked return 0xEEEE. The POR state is undefined
Other resets do not affect the trace
buffer contents.
Address: 0x0106
7
6
5
4
3
2
1
0
R
0
CNT
W
Reset
POR
0
0
—
0
—
0
—
0
—
0
—
0
—
0
—
0
= Unimplemented or Reserved
Figure 6-8. Debug Count Register (DBGCNT)
Table 6-12. DBGTCRL Field Descriptions (continued)
Field
Description