I first tried to start with the software from Olimex Board LPC2148.
Didn’t work (see viewtopic.php?t=9133)
I installed fresh new Cygwin and from http://www.yagarto.de/#download, also the new OpenOCD r247.
From CygWin I do
tverr@Eye /cygdrive/c/GCCFD/projects/lpc2148
$ openocd-ftd2xx.exe --file lpc2xxx_armusbocd.cfg
Info: openocd.c:93 main(): Open On-Chip Debugger (2007-12-30 17:00 CET) svn: 247
Info: openocd.c:94 main(): $URL: http://svn.berlios.de/svnroot/repos/openocd/trunk/src/openocd.c $
Error: lpc2000.c:384 lpc2000_flash_bank_command(): unknown LPC2000 variant
Error: flash.c:192 handle_flash_bank_command(): 'lpc2000' driver rejected flash bank at 0x00000000
Info: jtag.c:1291 jtag_examine_chain(): JTAG device found: 0x4f1f0f0f (Manufacturer: 0x787, Part: 0xf1f0, Version: 0x4)
(The ARM-USB-OCD LED shortly goes yellow and back green, short beep)
The original OLIMEX-config file looks like this:
#daemon configuration
telnet_port 4444
gdb_port 3333
#interface
interface ft2232
ft2232_device_desc "Olimex OpenOCD JTAG A"
ft2232_layout "olimex-jtag"
ft2232_vid_pid 0x15BA 0x0003
# Changed this: 2 is fast, 5 is slow!
#jtag_speed 2
jtag_speed 5
#use combined on interfaces or targets that can't set TRST/SRST separately
reset_config trst_and_srst separate
#jtag scan chain
#format L IRC IRCM IDCODE (Length, IR Capture, IR Capture Mask, IDCODE)
jtag_device 4 0x1 0xf 0xe
#target configuration
daemon_startup reset
#target <type> <startup mode>
#target arm7tdmi <reset mode> <chainpos> <endianness> <variant>
target arm7tdmi little run_and_halt 0 arm7tdmi-s_r4
run_and_halt_time 0 30
#target_script 0 reset oocd_flash2138.script
working_area 0 0x40000000 0x40000 nobackup
#flash configuration
flash bank lpc2000 0x0 0x40000 0 0 lpc2000_v1 0 14765 calc_checksum
# For more information about the configuration files, take a look at:
# http://openfacts.berlios.de/index-en.phtml?title=Open+On-Chip+Debugger
When I uncomment the flash command, I get this from shell:
Tverr@Eye /cygdrive/c/GCCFD/projects/lpc2148
$ openocd-ftd2xx.exe --file lpc2xxx_armusbocd.cfg
Info: openocd.c:93 main(): Open On-Chip Debugger (2007-12-30 17:00 CET) svn: 247
Info: openocd.c:94 main(): $URL: http://svn.berlios.de/svnroot/repos/openocd/trunk/src/openocd.c $
Info: jtag.c:1291 jtag_examine_chain(): JTAG device found: 0x4f1f0f0f (Manufacturer: 0x787, Part: 0xf1f0, Version: 0x4)
I looked into the installation of the new OpenOCD and compared the driver “arm_usb_ocd” with the Olimex-installaiton-Disk version. The Olimex Version installed a new Driver , and has README saying
It contains a folder "Olimex OpenOCD driver_old" - It seems to be the driver that is also used by the new OpenOCD!This is the first release based on the CDM2.0 drivers from FTDI. It may contain some bugs and is not thoroughly tested. If you suspect a driver problem, please try the older one.
(But playing with the different driver versions didn’t effect my flash-problem…)
**So besides my problem with flashing, maybe I also have unrevealed a more general "driver-version-mismatch" problem in OpenOCD! Hopefully someone can look over it!**