Hi,
I am writing a bit of software to control a JTAG port, but I am having a bit of trouble getting it working.
Below are the steps my software is following to test out a JTAG connection. I think that there must be an error in there somewhere, but from my understanding of the JTAG TAP and the way JTAG works, I can't see a problem at the moment.
Can anyone comment on whether I am controlling the TAP correctly?
Thanks,
Paul.
(Note: for each clock cycle below, tms and tdo are set before the clk is set high)
(1) Make sure TAP is in reset: clk 1: tms = 1, tdo = 0 clk 2: tms = 1, tdo = 0 clk 3: tms = 1, tdo = 0 clk 4: tms = 1, tdo = 0 clk 5: tms = 1, tdo = 0
(2) Move TAP to Select-DR-Scan state clk 6: tms = 0, tdo = 0 clk 7: tms = 1, tdo = 0
(3) Move TAP to SHIFT-IR clk 8: tms = 1, tdo = 0 clk 9: tms = 0, tdo = 0 clk 10: tms = 0, tdo = 0
(4) Shift 3 to put into bypass mode then move TAP to Select-DR-Scan state (IR length is 2 bits): clk 11: tms = 0, tdo = 1 clk 12: tms = 1, tdo = 1 clk 13: tms = 1, tdo = 0 clk 14: tms = 1, tdo = 0
(5) TAP to SHIFT-DR clk 15: tms = 0, tdo = 0 clk 16: tms = 0, tdo = 0
(6) Shift out 8 bits, 0x55 to see if it comes back on device's TDO clk 17: tms = 0, tdo = 1 clk 18: tms = 0, tdo = 0 clk 19: tms = 0, tdo = 1 clk 20: tms = 0, tdo = 0 clk 21: tms = 0, tdo = 1 clk 22: tms = 0, tdo = 0 clk 23: tms = 0, tdo = 1 clk 24: tms = 1, tdo = 0
(7) Move TAP to Select-DR-Scan state ready for next operation clk 25: tms = 1, tdo = 0 clk 26: tms = 1, tdo = 0