Description of the JTAG interface of the ALICE1LHCB chip
Contents
1. Introduction 1
2. Instruction Register
*3. Scan Check Circuit
*4. JTAG Data Registers
*4.1. Configuring a pixel column
*4.2. Configuring a global register
*4.3. Bypass and Scan_Check Registers
*4.4. Boundary Scan Register
*5. Appendix
*
These notes are written as a guide to configuring the chip via the JTAG serial interface. They contain listings of the codes necessary to operate the JTAG controller and address the internal registers. The majority of the JTAG interface circuitry on the chip complies with the IEEE Standard Test Access Port and Boundary-Scan Architecture (IEEE Std 1149.1), and we assume that the reader is familiar with this standard.
In the chip, the following convention has been adopted:
the LSB of a register is the bit which is shifted-out first during the shift sequence; ie it is the contents of the flip-flop nearest to the TDO port.
In compliance with standard, the JTAG block on the chip consists of a controller, instruction register, boundary scan register, bypass register and data registers. In addition, there is a block to carry out a simple check of the functionality of the previous chip in the serial chain (scan check sequence). This is for the ALICE scenario and is described in Section 3.
The input/output signals are TMS, TCLK, TRESET*, TDI0, TDI1 and TDO. TMS, TCLK and TRESET* comply with the standard. In the ALICE scenario, TDI0 is an input which is taken from the TDO of the previous chip (n-1) in the serial chain and TDI1 is taken from the chip before that (n-2). The selection of which input to use is done during the scan check sequence. In the LHCb scenario, these two pins should be connected together.
The instruction register is compliant with IEEE 1149.1. It is a 4-bit register whose value after reset is 1111, which selects the bypass mode. Note that the capture value of the instruction register is fixed to be 1101. The data shifted into the instruction register define what action is to be carried out by the JTAG circuitry. The instruction set is listed in the following table:
|
Code (msb…..lsb) |
|
|
Sel_EXTEST |
0000 |
|
Sel_ENBL |
0001 |
|
Sel_THR |
0010 |
|
Sel_TM |
0011 |
|
Sel_GLOBAL |
0100 |
|
Sel_SP (sample/preload) |
0101 |
|
Sel_SCAN_CHECK |
0110 |
|
Sel_BYPASS |
1111 |
The data registers which are selected by these instructions are described in Section 4.
The scan check block is the only feature which is not part of the IEEE 1149.1 standard.
In the ALICE scenario, the scan check sequence is carried out after execution of the TEST_LOGIC_RESET state of the TAP controller. It is not used in the LHCb scenario, where data should be loaded through TDI0. The sequence consists of shifting the capture value of the instruction register in each chip (n-1) into the instruction register of the next chip in the chain (n). This requires that the TAP controller execute the states CAPTURE_IR, SHIFT_IR and UPDATE_IR. The value loaded into the instruction register by the UPDATE_IR command is compared with the expected value of 1101. A negative comparison signifies an error in the functionality of chip n-1. A multiplexer selects between TDI0 and TDI1 according to the result of this comparison, and ensures that the JTAG chain is complete. Immediately after a TEST_LOGIC_RESET state, TDI0 is selected by default. Note that the selection of the TDI0 or TDI1 is determined by the value loaded into the instruction register by the first UPDATE_IR executed after leaving the TEST_LOGIC_RESET state. This selection will remain until another TEST_LOGIC_RESET state has been executed. The result of the comparison is also latched by the scan-check register, as described in Section 4.
|
Pixel column |
32 |
256 |
Sel_THR,sel_TM |
|
Enable register |
1 |
7 |
Sel_ENBL |
|
Global register |
44 |
8 |
Sel_GLOBAL |
|
Bypass register |
1 |
1 |
Sel_BYPASS |
|
Scan-check register |
1 |
1 |
Sel_SCAN_CHK |
|
Boundary scan register |
1 |
38 |
Sel_SP, Sel_EXTEST |
Notes:
The loading of these registers is explained in the subsequent sections.
The loading of configuration data into a column of pixels is a two-step process.
|
Msb |
lsb |
|||||
|
BIT_1 |
BIT_0 |
A4 |
A3 |
A2 |
A1 |
A0 |
Bits A0-4 select the column address (0 – 31). BIT_1 and BIT_0 select the configuration bit according to the following settings:
|
0 |
0 |
No selection |
|
0 |
1 |
THRESH B0 or TEST |
|
1 |
0 |
THRESH B1 or MASK |
|
1 |
1 |
THRESH B2 |
|
msb |
lsb |
|||||
|
1 |
0 |
0 |
1 |
0 |
0 |
1 |
The sel_THR instruction should then be selected, and the 256 bits of data shifted in.
The loading of the global registers is a two-step process, similar to that for the pixel columns in section 2.
i) Selecting the global register: the address of the global register must be loaded into the enable register. To load the enable register, it should be selected by the sel_ENBL instruction. The corresponding contents of the 7-bit enable register are shown in the following table:
|
msb |
lsb |
|||||
|
DAC_OUT_EN |
A5 |
A4 |
A3 |
A2 |
A1 |
A0 |
Bits A0-5 select the global address (0-63 of which 0-43 are used). DAC_OUT_EN is used for sensing the outputs of the DAC addressed by A0-5. If DAC_OUT_EN is set high, then the output of the DAC will be connected to one of the output pads DAC_SENSE_I or DAC_SENSE_V (depending on whether the DAC produces a voltage or a current).
The list of global registers and their 6-bit addresses is in the appendix to this note.
The Bypass register complies with IEEE standard 1149.1. It is selected by the sel_BYPASS instruction.
The Scan_Check register consists of one bit. When selected, it will capture the result of the scan-check sequence, and can then be shifted out to identify the location of any faults in the serial JTAG chain. It is selected by the sel_SCAN_CHK instruction.
The boundary scan register is a serial chain of cells, each of which is connected to an input or output pin of the chip. This allows the setting of known values on these pins via the JTAG port, and facilitates testing. The register is selected by the sel_SP or sel_EXTEST instruction.
There are 38 elements in the boundary scan register, and these are listed in the following table:
|
Bit Number (lsb = 0) |
Pad Name |
Input or Output |
Bit Number (lsb = 0) |
Pad Name |
Input or Output |
|
0 |
DATA*<31> |
O |
19 |
NEVR* |
I |
|
1 |
DATA*<30> |
O |
20 |
CLK* |
I |
|
2 |
DATA*<29> |
O |
21 |
CLK |
I |
|
3 |
DATA*<28> |
O |
22 |
DATA*<15> |
O |
|
4 |
DATA*<27> |
O |
23 |
DATA*<14> |
O |
|
5 |
DATA*<26> |
O |
24 |
DATA*<13> |
O |
|
6 |
DATA*<25> |
O |
25 |
DATA*<12> |
O |
|
7 |
DATA*<24> |
O |
26 |
DATA*<11> |
O |
|
8 |
DATA*<23> |
O |
27 |
DATA*<10> |
O |
|
9 |
DATA*<22> |
O |
28 |
DATA*<9> |
O |
|
10 |
DATA*<21> |
O |
29 |
DATA*<8> |
O |
|
11 |
DATA*<20> |
O |
30 |
DATA*<7> |
O |
|
12 |
DATA*<19> |
O |
31 |
DATA*<6> |
O |
|
13 |
DATA*<18> |
O |
32 |
DATA*<5> |
O |
|
14 |
DATA*<17> |
O |
33 |
DATA*<4> |
O |
|
15 |
DATA*<16> |
O |
34 |
DATA*<3> |
O |
|
16 |
ABORT* |
I |
35 |
DATA*<2> |
O |
|
17 |
CE* |
I |
36 |
DATA*<1> |
O |
|
18 |
STROBE* |
I |
37 |
DATA*<0> |
o |
IMPORTANT: The following two points should be noted, and the appropriate actions taken:
Global Registers
DACs
|
Register Number |
Binary Address |
No. of bits |
Name |
|
msb lsb |
|||
|
0 |
000000 |
8 |
dis_BIASTH |
|
1 |
000001 |
8 |
dis_VCASD4 |
|
2 |
000010 |
8 |
dis_VCASD21 |
|
3 |
000011 |
8 |
dis_VIBCOMP |
|
4 |
000100 |
8 |
dis_VIBIASCARD |
|
5 |
000101 |
8 |
dis_VIDISC |
|
6 |
000110 |
8 |
dis_VREF2DISC |
|
7 |
000111 |
8 |
eu_VBIAS |
|
8 |
001000 |
8 |
eu_VBN |
|
9 |
001001 |
8 |
eu_VBNBUFFER |
|
10 |
001010 |
8 |
eu_VBNBUSLATCH |
|
11 |
001011 |
8 |
eu_VBNG |
|
12 |
001100 |
8 |
eu_VBNLHCB |
|
13 |
001101 |
8 |
eu_VBPPULLDOWN |
|
14 |
001110 |
8 |
Fast_CGPOL |
|
15 |
001111 |
8 |
Fast_CGPOLFM |
|
16 |
010000 |
8 |
Fast_COMPREF |
|
17 |
010001 |
8 |
Fast_CONVPOL |
|
18 |
010010 |
8 |
Fast_CONVPOLFM |
|
19 |
010011 |
8 |
Fast_FMPOL |
|
20 |
010100 |
8 |
Fast_FOPOL |
|
21 |
010101 |
8 |
Ken_EOCVBN |
|
22 |
010110 |
8 |
Ken_VBN |
|
23 |
010111 |
8 |
Ken_VBNM |
|
24 |
011000 |
8 |
Ken_VBNS |
|
25 |
011001 |
8 |
Ken_VBUFFVBN |
|
26 |
011010 |
8 |
Pre_VI1 |
|
27 |
011011 |
8 |
Pre_VI2 |
|
28 |
011100 |
8 |
Pre_VI3 |
|
29 |
011101 |
8 |
Pre_VI4 |
|
30 |
011110 |
8 |
Pre_VI5 |
|
31 |
011111 |
8 |
Pre_VIFB |
|
32 |
100000 |
8 |
Pre_VIPREAMP |
|
33 |
100001 |
8 |
Pre_VREF1 |
|
34 |
100010 |
8 |
Pre_VREF2 |
|
35 |
100011 |
8 |
Pre_VREF3 |
|
36 |
100100 |
8 |
Pre_VREF4 |
|
37 |
100101 |
8 |
Pre_VREF5 |
|
38 |
100110 |
8 |
Pre_VREF6 |
|
39 |
100111 |
8 |
Pre_VTH |
|
40 |
101000 |
8 |
Val_BUFFIN |
|
41 |
101001 |
8 |
Val_BUFFOUT |
"SPECIAL"
|
42 |
101010 |
8 |
delay_control |
|
43 |
101011 |
8 |
misc_control |
Note: the register "misc_control" has two functions.
Bit 7 (msb) controls the switch to turn on leakage current compensation in the front-end. Its state after reset is 1.
Bit 6 controls the delay of the strobe inside the chip. If Bit 6 = 0, the strobe is not delayed. If bit 6 = 1, the strobe is delayed by one clock period. Its state after reset is 0.
Bits 0-5 are not used.