SparkFun Forums 

Where electronics enthusiasts find answers.

Open source ARM Debugger
By planius
#82199
Hi there

I am switching from Atmel AVR to ARM and I received my Olimex LPC-E2214 board and Olimex ARM-USB-OCD JTAG today. I followed the instructions on the YAGARTO site to install OpenOCD 0.2, YAGARTO and Eclipse on my Windows XP SP3 machine. I used the Windows versions of OpenOCD from here: http://www.freddiechopin.info/.

I successfully installed all parts of the YAGARTO chain and also the Olimex ARM-USB-OCD drivers. Windows Device Manager reports the device is functioning normally.

But when I start OpenOCD in Eclipse (using Run command) I get the following error:
Error: 106 31 ft2232.c:1997 ft2232_init_libftdi(): unable to open ftdi device: device not found

The External Tools Configuartion in Eclipse calls openocd.exe with the following arguments:
Code: Select all
 -f board/olimex_lpc_e2294.cfg -f interface/olimex-arm-usb-ocd.cfg -d -c init 
Here is the debug output:
Code: Select all
Open On-Chip Debugger 0.2.0 (2009-07-18-09:50) Release
$URL: http://svn.berlios.de/svnroot/repos/openocd/tags/openocd-0.2.0/src/openocd.c $
For bug reports, read http://svn.berlios.de/svnroot/repos/openocd/trunk/BUGS
User : 5 0 command.c:396 command_print(): debug_level: 3
Debug: 6 0 configuration.c:83 find_file(): found C:\Program Files\OpenOCD\0.2.0\bin\../board/olimex_lpc_e2214.cfg
Debug: 7 16 configuration.c:83 find_file(): found C:\Program Files\OpenOCD\0.2.0\bin\../target/lpc2214.cfg
Debug: 9 16 command.c:68 script_debug(): command - jtag_nsrst_delay
Debug: 10 16 command.c:77 script_debug(): jtag_nsrst_delay - argv[0]=ocd_jtag_nsrst_delay
Debug: 11 16 command.c:77 script_debug(): jtag_nsrst_delay - argv[1]=200
User : 12 16 command.c:396 command_print(): jtag_nsrst_delay: 200
Debug: 14 16 command.c:68 script_debug(): command - jtag_ntrst_delay
Debug: 15 16 command.c:77 script_debug(): jtag_ntrst_delay - argv[0]=ocd_jtag_ntrst_delay
Debug: 16 16 command.c:77 script_debug(): jtag_ntrst_delay - argv[1]=200
User : 17 16 command.c:396 command_print(): jtag_ntrst_delay: 200
Debug: 19 16 command.c:68 script_debug(): command - reset_config
Debug: 20 16 command.c:77 script_debug(): reset_config - argv[0]=ocd_reset_config
Debug: 21 16 command.c:77 script_debug(): reset_config - argv[1]=trst_and_srst
Debug: 22 16 command.c:77 script_debug(): reset_config - argv[2]=srst_pulls_trst
Debug: 23 16 tcl.c:237 jim_newtap_cmd(): Creating New Tap, Chip: lpc2214, Tap: cpu, Dotted: lpc2214.cpu, 8 params
Debug: 24 16 tcl.c:253 jim_newtap_cmd(): Processing option: -irlen
Debug: 25 16 tcl.c:253 jim_newtap_cmd(): Processing option: -ircapture
Debug: 26 16 tcl.c:253 jim_newtap_cmd(): Processing option: -irmask
Debug: 27 16 tcl.c:253 jim_newtap_cmd(): Processing option: -expected-id
Debug: 28 16 core.c:1116 jtag_tap_init(): Created Tap: lpc2214.cpu @ abs position 0, irlen 4, capture: 0x1 mask: 0xf
Debug: 29 16 target.c:4295 jim_target(): Target command params:
Debug: 30 16 target.c:4296 jim_target(): target create lpc2214.cpu arm7tdmi -endian little -chain-position lpc2214.cpu -variant arm7tdmi-s_r4 
Debug: 32 16 command.c:68 script_debug(): command - bank
Debug: 33 16 command.c:77 script_debug(): bank - argv[0]=ocd_flash_bank
Debug: 34 16 command.c:77 script_debug(): bank - argv[1]=lpc2000
Debug: 35 16 command.c:77 script_debug(): bank - argv[2]=0x0
Debug: 36 16 command.c:77 script_debug(): bank - argv[3]=0x40000
Debug: 37 16 command.c:77 script_debug(): bank - argv[4]=0
Debug: 38 16 command.c:77 script_debug(): bank - argv[5]=0
Debug: 39 16 command.c:77 script_debug(): bank - argv[6]=0
Debug: 40 16 command.c:77 script_debug(): bank - argv[7]=lpc2000_v1
Debug: 41 16 command.c:77 script_debug(): bank - argv[8]=14765
Debug: 42 16 command.c:77 script_debug(): bank - argv[9]=calc_checksum
Debug: 43 16 configuration.c:83 find_file(): found C:\Program Files\OpenOCD\0.2.0\bin\../interface/olimex-arm-usb-ocd.cfg
Debug: 45 32 command.c:68 script_debug(): command - interface
Debug: 46 32 command.c:77 script_debug(): interface - argv[0]=ocd_interface
Debug: 47 32 command.c:77 script_debug(): interface - argv[1]=ft2232
Debug: 49 32 command.c:68 script_debug(): command - ft2232_device_desc
Debug: 50 32 command.c:77 script_debug(): ft2232_device_desc - argv[0]=ocd_ft2232_device_desc
Debug: 51 32 command.c:77 script_debug(): ft2232_device_desc - argv[1]=Olimex OpenOCD JTAG A
Debug: 53 32 command.c:68 script_debug(): command - ft2232_layout
Debug: 54 32 command.c:77 script_debug(): ft2232_layout - argv[0]=ocd_ft2232_layout
Debug: 55 32 command.c:77 script_debug(): ft2232_layout - argv[1]=olimex-jtag
Debug: 57 32 command.c:68 script_debug(): command - ft2232_vid_pid
Debug: 58 32 command.c:77 script_debug(): ft2232_vid_pid - argv[0]=ocd_ft2232_vid_pid
Debug: 59 32 command.c:77 script_debug(): ft2232_vid_pid - argv[1]=0x15ba
Debug: 60 32 command.c:77 script_debug(): ft2232_vid_pid - argv[2]=0x0003
Debug: 62 32 command.c:68 script_debug(): command - init
Debug: 63 32 command.c:77 script_debug(): init - argv[0]=ocd_init
Debug: 64 32 openocd.c:129 handle_init_command(): target init complete
Debug: 65 32 ft2232.c:2059 ft2232_init(): ft2232 interface using shortest path jtag state transitions
Debug: 66 32 ft2232.c:1978 ft2232_init_libftdi(): 'ft2232' interface using libftdi with 'olimex-jtag' layout (15ba:0003)
Error: 67 32 ft2232.c:1997 ft2232_init_libftdi(): unable to open ftdi device: device not found
Debug: 68 32 command.c:440 run_command(): Command failed with error code -100
User : 69 32 command.c:642 openocd_jim_vfprintf(): Runtime error, file "command.c", line 469:
    User : 70 32 command.c:642 openocd_jim_vfprintf(): 
Windows Device Manager reports the JTAG as follows:
Code: Select all
USB\VID_15BA&PID_0003&MI_00\6&517B143&0&0000
The board passes it's self-test successfully and the green LED on the ARM-USB-OCD is on. I have not changed the default jumper settings on the board.

What have I missed?

Thanks
Peter
By planius
#82252
Update: I have managed to connect to the board using CrossWorks, so it's not the Windows drivers or the ARM-USB-OCD that are the problem. Must have to to with OpenOCD...
By bobcousins
#82782
The latest OpenOcd does not support the FTDI drivers, you will to need unpack the file drivers/ft2232.zip and follow the instructions in "info.txt".