![](http://datasheet.mmic.net.cn/370000/P312XDP512F0VFV_datasheet_16728159/P312XDP512F0VFV_760.png)
Chapter 20 S12X Debug (S12XDBGV3) Module
MC9S12XDP512 Data Sheet, Rev. 2.17
760
Freescale Semiconductor
20.3.2.7.2
Debug State Control Register 2 (DBGSCR2)
Read: Anytime
Write: Anytime when S12XDBG not armed.
This register is visible at 0x0027 only with COMRV[1:0] = 01. The state control register 2 selects the
targeted next state whilst in State2. The matches refer to the match channels of the comparator match
control logic as depicted in
Figure 20-1
and described in
Section 20.3.2.8.1”
. Comparators must be
enabled by setting the comparator enable bit in the associated DBGXCTL control register.
The trigger priorities described in
Table 20-38
dictate that in the case of simultaneous matches, the match
on the lower channel number (0,1,2,3) has priority. The SC[3:0] encoding ensures that a match leading to
final state has priority over all other matches.
Address: 0x0027
7
0
6
0
5
0
4
0
3
2
1
0
R
W
SC3
SC2
SC1
SC0
Reset
0
0
0
0
0
0
0
0
= Unimplemented or Reserved
Figure 20-10. Debug State Control Register 2 (DBGSCR2)
Table 20-22. DBGSCR2 Field Descriptions
Field
Description
3–0
SC[3:0]
These bits select the targeted next state whilst in State2, based upon the match event.
Table 20-23. State2 —Sequencer Next State Selection
SC[3:0]
0000
0001
0010
0011
0100
0101
0110
0111
1000
1001
1010
1011
1100
1101
1110
1111
Description
Any match triggers to state1
Any match triggers to state3
Any match triggers to Final State
Match3 triggers to State1....... Other matches have no effect
Match3 triggers to State3....... Other matches have no effect
Match3 triggers to Final State....... Other matches have no effect
Match0 triggers to State1....... Match1 triggers to State3....... Other matches have no effect
Match1 triggers to State3....... Match0 triggers Final State....... Other matches have no effect
Match0 triggers to State1....... Match2 triggers to State3....... Other matches have no effect
Match2 triggers to State3....... Match0 triggers Final State....... Other matches have no effect
Match1 triggers to State1....... Match3 triggers to State3....... Other matches have no effect
Match3 triggers to State3....... Match1 triggers Final State....... Other matches have no effect
Match2 triggers to State1..... Match3 trigger to Final State
Match2 has no affect, all other matches (M0,M1,M3) trigger to Final State
Reserved
Reserved