Error while connecting to LPC2378

I tried to run openOCD on a keil MCB2300 (with a LPC2378) but got the following error:

Error: embeddedice.c:175 embeddedice_build_reg_cache(): unknown EmbeddedICE version (comms ctrl: 0x70000000)

I’m using the openocd-2007re128, and the Olimex ARM-USB-OCD with the latest Yagarto toolchain.

had no problems debugging a LPC2294…

I pretty new at this, so I’m probably doing something wrong here.

Anyone out there who can give me a clue…?

Frank

Hello Frank,

I’ve never encountered a target with EmbeddedICE version 7, and last time I checked this wasn’t listed in any of the ARM docs.

Could you please run the OpenOCD with “-f -d -l ” and send me the resulting log (Dominic Rath gmx de)?

It’s also possible that this is just a communication problem because of a too high JTAG frequency - the LPC23xx comes out of reset at a very low frequency (4MHz).

Here’s what I replied to the LPC2000 group at yahoo a few weeks ago:

The LPC23xx starts up running from the internal RC oszillator at 4MHz. As long as there’s no software on the LPC that enables the main oszillator or PLL, you have to limit the JTAG frequency to ~600kHz, “jtag_speed 9” should work, but you could use a slightly higher value just to be sure.

Regards,

Dominic

Dominic,

Just send you the log-file.

I tried reducing the JTAG speed(up to val 10) before placing this message…but without any difference.

The board came in yesterdag from Keil.(very fresh)

Frank

Hi,

the log file doesn’t show anything unusual. The IDCODE is 0x4f1f0f0f, indicating an ARM7TDMI-S Rev.4, which should be EmbeddedICE version 1. The most recent version I could find is version 6, but that’s only found on ARM9E(J)-S cores.

I’ve uploaded a patch at http://mmd.ath.cx/openocd/embeddedice_v7.patch which initializes the EmbeddedICE settings with the ARM7TDMI-S R4 defaults. This should allow you to use the OpenOCD with your core, but there could be side effects.

The patch is against latest SVN, let me know if you have problems compiling it yourself, and I’ll see if I can provide you a windows binary.

I’ve ordered a new ARM documentation CD from ARM, maybe there’s newer documentation than on the web, but it usually takes a week or two before it arrives.

Regards,

Dominic