Who wants to help a NEWBIE with ARM-USB-OCD and LPC2148

Hi everybody,

I am completely new to this environment and can use some help.

I have the Olimex LPC2148 board and their ARM-USB-OCD.

I have read many tutorials and tried a lot, but nothing works.

None of the tutorials describes a simple session using my board and my debugger.

I tried Eclipse, but I messed with the configuration and now nothing works

with it anymore. So I decided to go back and try to get it working

using just my own editor and make and the insight debugger.

I Installed

  • Open OCD, R100

  • Yagarto tool chain

The link here: http://www.yagarto.de/howto/openocd/index.html

doesn’t describe how to install the USB drivers, so I simple right clicked all the inf files and selected install.

Then I have plugged in the device into USB and drivers got installed.

Then I tried to start it using:

=====================

C:\openocd-2006re100\bin>openocd-ftd2xx.exe -f lpc2xxx_armusbocd.cfg

Info: openocd.c:82 main(): Open On-Chip Debugger (2006-09-28 20:00 CEST)

Error: ft2232.c:966 ft2232_init(): unable to open ftdi device: 2

=====================

That is my first problem.

Second problem, during setup of the toolchain, i selected, add Yagarto to path variable, however, nothing was added, so the compiler isn’t running.

I asume that not only a path variable is enough, but I probably need more environment settings (For include path and lib).

So can anybody tell me what settings I need to run the compiler through make?

Please help me with my starting up problems.

Regards,

Bert

So I want to go back to the start, I installed the Yagarto toolchain and have a flashing led program with a make file.

I’ll help you with Eclipse. I use it all the time. What seems to be wrong with it ?

Hello Bert,

have you installed now the USB driver and is it working?

If you plug in the ARM-USB-OCD, windows will ask you

about the driver. If you have installed OpenOCD from the

YAGARTO side, you will find the driver here:

\driver\arm_usb_ocd

Regards,

Michael

I believe Bert’s problem are solved by now. There were several threads, and I also exchanged several private mails with him.

Regards,

Dominic

I just got my ARM-USB-OCD pod yesterday.

I had the same problem as the OP in the first email. I found it was caused by permission. When I run oocd, it works fine.

But then I get this:

Open On-Chip Debugger (2006-11-22 14:00 CEST)

Error: jtag.c:1156 jtag_validate_chain(): Error validating JTAG scan chain, IR mismatch, scan returned 0x3f

What is an IR mismatch ?

I assume its related to this in my cfg file:

#jtag scan chain

#format L IRC IRCM IDCODE (Length, IR Capture, IR Capture Mask, IDCODE)

jtag_device 4 0x1 0xf 0xe

Do different devices use different IR codes ? If so, what are the codes for a LPC2148 ?

Thanks.

I found the problem.

The problem was that my board, an Olimex P2148 has a jumper to enable the JTAG port and it also has a jumper and switches for doing ISP. I changed these and I think it runs properly.

When I run it now, with debugging turned off, I get:

openocd &

[1] 13625

Info: openocd.c:84 main(): Open On-Chip Debugger (2006-11-22 14:00 CEST)

armdeveloper:
The problem was that my board, an Olimex P2148 has a jumper to enable the JTAG port and it also has a jumper and switches for doing ISP. I changed these and I think it runs properly.

When you solve a problem, it would be helpful to others if you post exactly what you changed to get things working. I am having a communication issue with my new Olimex LPC-2148 Proto Board, and I don't know why.

There is next to no documentation from Olimex about their boards. :frowning:

8-Dale

  1. I have a JTAG USB OCD Tiny. The PID for the USB Tiny has been changed. It is 0x0004. You can change it manually in the INF files if you know what you are doing (or have worked with USB driver development in the past). You have to change it in 3 different files if you use the latest YAGARTO. The best way for newbie is to install the CDs that came with the JTAG USB OCD Tiny from Olimex. Then plug in the USB cable and point it to the Olimex correct driver directory. You can choose to un-install the Olimex software stuff later or leave it there for reference.

  2. Make sure all your CFG files have the following:

ft2232_device_desc “Olimex OpenOCD JTAG TINY A”

The key here is to have the word TINY in the desc. If not, add it yourself. Don’t ask why…just the way it was designed. Linux people don’t have to do this. Only Windows people.

  1. Make sure you have working_area and flash bank command set up in your CFG if you want to do a telnet session to Openocd and issue command like “config info 0” to see if you have to unlock some regions of the flash before you can do your own “flashing” (writing to flash not flashing an LED).

There you have it. I wish we could have FAQ this somewhere for newbie cause I spent hours searching and reading the newsgroup for this and I am not a beginner in embedded development!

Hoang