2 ## This file is part of the libsigrokdecode project.
4 ## Copyright (C) 2012 Uwe Hermann <uwe@hermann-uwe.de>
6 ## This program is free software; you can redistribute it and/or modify
7 ## it under the terms of the GNU General Public License as published by
8 ## the Free Software Foundation; either version 2 of the License, or
9 ## (at your option) any later version.
11 ## This program is distributed in the hope that it will be useful,
12 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
13 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 ## GNU General Public License for more details.
16 ## You should have received a copy of the GNU General Public License
17 ## along with this program; if not, write to the Free Software
18 ## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
22 JTAG protocol decoder.
24 JTAG (Joint Test Action Group), a.k.a. "IEEE 1149.1: Standard Test Access Port
25 and Boundary-Scan Architecture", is a protocol used for testing, debugging,
26 and flashing various digital ICs.
28 TODO: Protocol details.
30 Protocol output format (WORK IN PROGRESS!):
33 [<packet-type>, <data>]
35 <packet-type> is one of:
36 - 'NEW STATE': <data> is the new state of the JTAG state machine.
37 Valid values: 'TEST-LOGIC-RESET', 'RUN-TEST/IDLE', 'SELECT-DR-SCAN',
38 'CAPTURE-DR', 'SHIFT-DR', 'EXIT1-DR', 'PAUSE-DR', 'EXIT2-DR', 'UPDATE-DR',
39 'SELECT-IR-SCAN', 'CAPTURE-IR', 'SHIFT-IR', 'EXIT1-IR', 'PAUSE-IR',
40 'EXIT2-IR', 'UPDATE-IR'.
41 - 'IR TDI': Bitstring that was clocked into the IR register.
42 - 'IR TDO': Bitstring that was clocked out of the IR register.
43 - 'DR TDI': Bitstring that was clocked into the DR register.
44 - 'DR TDO': Bitstring that was clocked out of the DR register.
47 All bitstrings are a sequence of '1' and '0' characters. The right-most
48 character in the bitstring is the LSB. Example: '01110001' (1 is LSB).
51 https://en.wikipedia.org/wiki/Joint_Test_Action_Group
52 http://focus.ti.com/lit/an/ssya002c/ssya002c.pdf