Olimex LPC2148H fault

I am playing with that header board for LPC2148 for a while. I was having around 2-3 project successfully compiled and build both with Eclipse/OpenOCD and Crossworks but today something strange happened.

I was in the middle of debugging (I am useing RAM debug target for faster debug) and suddenly the crossworks started to give me verify errors. I stoped debug process, restarted both target and my Olimex ARM USB OCD and then I was able to reload my program. Then after a while the RAM target again give me error, so I tried flash debug and it worked. Then after 2-3 failures my board stopped to response. The flashed program starts, I can see the LED activity, but crossworks could not identify the target anymore.

I have tried my OCD with another board and it worked, so what do you think, where is my problem…? :frowning:

I had the same problem with the Olimex LPC2468 and IAR workbench. I think the problem is that the IAR can’t reset the CPU state, it’s really strange problem. what I did is I used the Flash magic tool to erase the flash, created a new project.

maybe you should test your board with another project or create a new one.

it’s really a voodoo like problem.

Z. Nakrachi

Thanks, I guess you are right. I have started OpenOCD and I saw this:

Open On-Chip Debugger 1.0 (2008-10-04-10:00) svn:exported
$URL: http://svn.berlios.de/svnroot/repos/openocd/trunk/src/openocd.c $
Info:    options.c:50 configuration_output_handler(): jtag_speed: 2, 2
Info:    options.c:50 configuration_output_handler(): Open On-Chip Debugger 1.0 (2008-10-04-10:00) svn:exported
Error:   jtag.c:1351 jtag_examine_chain(): JTAG communication failure, check connection, JTAG interface, target power etc.
Error:   jtag.c:1556 jtag_init_inner(): trying to validate configured JTAG chain anyway...
Error:   embeddedice.c:191 embeddedice_build_reg_cache(): unknown EmbeddedICE version (comms ctrl: 0x00000000)
Info:    jtag.c:1389 jtag_examine_chain(): JTAG device found: 0x4f1f0f0f (Manufacturer: 0x787, Part: 0xf1f0, Version: 0x4)
User:    target.c:436 target_process_reset(): Timed out waiting for halt after reset
Error:   armv4_5.h:114 armv4_5_mode_to_number(): invalid mode value encountered
Error:   arm7_9_common.c:1102 arm7_9_debug_entry(): cpsr contains invalid mode value - communication failure
Error:   armv4_5.h:114 armv4_5_mode_to_number(): invalid mode value encountered

Now I have to figure out how to erase flash… :frowning:

use flash magic http://www.flashmagictool.com/download. … hMagic.exe

when you use the flash magic you have to setup your board to suport SPI and external reset. you may have two jumpers for this purpose. you have to setup both jumpers before you can use the flashmagic tool.

last thing to do is to config the flashmagic tool to use the DTR and RTS.

hope it helps

Z. Nakrachi

Thanks Zanak, but I use header board which does not have serial port. I was hoping that there will be a solution with my USB OCD but I still can’t find one. So in order to save my board I will need to solder one max3232…