Debug Interface
ARM7TDMI Data Sheet
ARM DDI 0029E
8-16
O
Scan chain 0
Scan chain 0 is intended primarily for inter-device testing (EXTEST), and testing the
core (INTEST). Scan chain 0 is selected via the SCAN_N instruction: see
·
8.8.2
SCAN_N (0010)
on page 8-10.
INTEST allows serial testing of the core. The TAP Controller must be placed in
INTEST mode after scan chain 0 has been selected. During CAPTURE-DR, the
current outputs from the core’s logic are captured in the output cells. During SHIFT-
DR, this captured data is shifted out while a new serial test pattern is scanned in, thus
applying known stimuli to the inputs. During RUN-TEST/IDLE, the core is clocked.
Normally, the TAP controller should only spend 1 cycle in RUN-TEST/IDLE. The whole
operation may then be repeated.
For details of the core’s clocks during test and debug, see
·
8.10 ARM7TDMI Core
Clocks
on page 8-18.
EXTEST allows inter-device testing, useful for verifying the connections between
devices on a circuit board. The TAP Controller must be placed in EXTEST mode after
scan chain 0 has been selected. During CAPTURE-DR, the current inputs to the core's
logic from the system are captured in the input cells. During SHIFT-DR, this captured
data is shifted out while a new serial test pattern is scanned in, thus applying known
values on the core’s outputs. During UPDATE-DR, the value shifted into the data bus
D[31:0]
scan cells appears on the outputs. For all other outputs, the value appears as
the data is shifted round. Note, during RUN-TEST/IDLE, the core is not clocked. The
operation may then be repeated.
Scan chain 1
The primary use for scan chain 1 is for debugging, although it can be used for EXTEST
on the data bus. Scan chain 1 is selected via the SCAN_N TAP Controller instruction.
Debugging is similar to INTEST, and the procedure described above for scan chain 0
should be followed.
Note that this scan chain is 33 bits long - 32 bits for the data value, plus the scan cell
on the
BREAKPT
core input. This 33rd bit serves four purposes:
1
Under normal INTEST test conditions, it allows a known value to be scanned
into the
BREAKPT
input.
2
During EXTEST test conditions, the value applied to the
BREAKPT
input from
the system can be captured.
3
While debugging, the value placed in the 33rd bit determines whether
ARM7TDMI synchronises back to system speed before executing the
instruction. See
·
8.12.5 System speed access
on page 8-25 for further
details.
4
After ARM7TDMI has entered debug state, the first time this bit is captured
and scanned out, its value tells the debugger whether the core entered debug
state due to a breakpoint (bit 33 LOW), or a watchpoint (bit 33 HIGH).