# Error: wrong JTAG tap

**URL:** <https://community.sparkfun.com/t/error-wrong-jtag-tap/9492>\
**Category:** MicroMod\
**Tags:** arm-lpc\
**Created:** [December 29, 2008, 12:17am UTC](https://community.sparkfun.com/t/error-wrong-jtag-tap/9492 "2008-12-29T00:17:09Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Herrbert](https://avatars.discourse-cdn.com/v4/letter/h/e9a140/32.png) [@Herrbert](https://community.sparkfun.com/u/Herrbert)\
**Post date:** [December 29, 2008, 12:17am UTC](https://community.sparkfun.com/t/error-wrong-jtag-tap/9492/1 "2008-12-29T00:17:09Z")

</div>

Hi everyone,

I’am new to openOCD but with lots of reading and trying i got it running - finally.

One last problem remains, in my lpc2103.cfg (see below for complete listing) I have to do

set \_CPUTAPID 0x4f1f0f0f

because without that i get the error:

```auto
simon@PuckLin:~/projekte/common/openOCD_config$ sudo openocd -f daemon/daemon.cfg -f interface/Olimex_ARM_USB_Tiny.cfg -f target/lpc2103.cfg -c init -c reset
Open On-Chip Debugger 1.0 (2008-12-26-16:30) svn:1274

BUGS? Read http://svn.berlios.de/svnroot/repos/openocd/trunk/BUGS

$URL: http://svn.berlios.de/svnroot/repos/openocd/trunk/src/openocd.c $
force hard breakpoints
jtag_speed: 20
200 kHz
Info : JTAG tap: lpc2103.cpu tap/device found: 0x4f1f0f0f (Manufacturer: 0x787, Part: 0xf1f0, Version: 0x4)
Error: JTAG tap: lpc2103.cpu got: 0x4f1f0f0f (mfg: 0x787, part: 0xf1f0, ver: 0x4)
Error: JTAG tap: lpc2103.cpu expected 1 of 1: 0xffffffff (mfg: 0x7ff, part: 0xffff, ver: 0xf)
Error: trying to validate configured JTAG chain anyway...
Info : JTAG tap: lpc2103.cpu tap/device found: 0x4f1f0f0f (Manufacturer: 0x787, Part: 0xf1f0, Version: 0x4)
Error: JTAG tap: lpc2103.cpu got: 0x4f1f0f0f (mfg: 0x787, part: 0xf1f0, ver: 0x4)
Error: JTAG tap: lpc2103.cpu expected 1 of 1: 0xffffffff (mfg: 0x7ff, part: 0xffff, ver: 0xf)
Error: trying to validate configured JTAG chain anyway...

```

From that one can see that the error TAP ID is set. But I simply don’t understand why and how to fix the problem in a better way than mine.

I have to admit that I’am far from understandig the config - in parts yes but much of it is copied from examples.

I use an OLIMEX ARM-USB-TINY and LPC-H2103 (also a board from olimex).

Hope someone has a clue for me!

Thanks!

lpc2103.cfg:

```auto
#LPC-2103 CPU

if { [info exists CHIPNAME] } {
   set _CHIPNAME $CHIPNAME
} else {
   set _CHIPNAME lpc2103
}

if { [info exists ENDIAN] } {
   set _ENDIAN $ENDIAN
} else {
   set _ENDIAN little
}

if { [info exists CPUTAPID] } {
   set _CPUTAPID $CPUTAPID
} else {
  # force an error till we get a good number
   set _CPUTAPID 0xffffffff
}

#debug override
set _CPUTAPID 0x4f1f0f0f 

#use combined on interfaces or targets that can't set TRST/SRST separately
reset_config trst_and_srst srst_pulls_trst
jtag_khz 200
#jtag scan chain
jtag newtap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id $_CPUTAPID

set _TARGETNAME [format "%s.cpu" $_CHIPNAME]
target create $_TARGETNAME arm7tdmi -endian $_ENDIAN -chain-position $_TARGETNAME -variant arm7tdmi-s_r4

$_TARGETNAME configure -work-area-virt 0 -work-area-phys 0x40000000 -work-area-size 0x2000

#flash bank <driver> <base> <size> <chip_width> <bus_width>
flash bank lpc2000 0x0 0x8000 0 0 0 lpc2000_v2 14765 calc_checksum

```

---

<div class="post-metadata">

**Author:** ![csabi911](https://avatars.discourse-cdn.com/v4/letter/c/85f322/32.png) [@csabi911](https://community.sparkfun.com/u/csabi911)\
**Post date:** [March 4, 2009, 1:26pm UTC](https://community.sparkfun.com/t/error-wrong-jtag-tap/9492/2 "2009-03-04T13:26:16Z")

</div>

Did you ever get this to work ? Cause I am in the same boat like you.

my LP2103.cfg file is missing / needs to be configured.

I am basically hanging myself on this thread 🙂

Thanks

Csaba
