bdiGDB for GNU Debugger, BDI2000 | User Manual 31 |
Low level JTAG scan chain configuration:
Sometimes it is necessary to configure the test access port (TAP) of the target before the ARM debug interface is visible and accessible in the usual way. The BDI supports this configuration in a very ge- neric way via the SCANINIT and SCANPOST configuration commands. Both accept a string that de- fines the JTAG sequences to execute. The following example shows how to use these commands:
; Configure | ICEPick module to make | ARM926 TAP visible |
SCANINIT | t1:w1000:t0:w1000: | ;toggle TRST |
SCANINIT | i6=07:d8=89:i6=02: | ;connect and select router |
SCANINIT | d32=81000082: | ;set IP control |
SCANINIT | d32=a018206f: | ;configure TAP0 |
SCANINIT | d32=a018216f:cl5: | ;enable TAP0, clock 5 times in RTI |
SCANINIT | i10=ffff | ;scan bypass |
; |
|
|
;Between SCANINIT and SCANPOST the ARM ICEBreaker is configured
;and the DBGRQ bit in the ARM debug control register is set.
; |
|
|
SCANPOST | i10=002f: | ;IP(router) - ARM(bypass) |
SCANPOST | d33=0102000106: | ;IP control = SysReset |
SCANPOST | i10=ffff | ;scan bypass |
The following low level JTAG commands are supported in the string. Use ":" between commands.
I<n>=<... | b2b1b0> | write IR, b0 is first scanned |
D<n>=<... | b2b1b0> | write DR, b0 is first scanned |
|
| n : the number of bits 1..256 |
|
| bx : a data byte, two hex digits |
W<n> |
| wait for n (decimal) micro seconds |
T1 |
| assert TRST |
T0 |
| release TRST |
R1 |
| assert RESET |
R0 |
| release RESET |
CH<n> |
| clock TCK n (decimal) times with TMS high |
CL<n> |
| clock TCK n (decimal) times with TMS low |
The following diagram shows the parts of the standard reset sequence that are replaced with the SCAN string. Only the appropriate part of the reset sequence is replaced. If only a SCANINIT string is defined, then the standard "post" sequence is still executed.
If (reset mode == hard) Assert reset
Toggle TRST
If (reset mode == hard) Delay for reset time
Execute SCANINIT string
Check if Bypass register(s) present
Read and display ID code
Check if debug module is accessible
If (startup == reset) catch reset exception
If (reset mode == hard) Release reset
Wait until reset is really release
Delay for
Execute SCANPOST string
© Copyright | V 1.04 |