Debugger not working properly

Hi all,

I finally have my board running and have JTAG connection, only it is not behaving the way it should and I’m running out of ideas what I might be doing wrong.

I set up everything as described in James P. Lynch’s tutorial but I get this output:

target remote localhost:3333
0x00011624 in ?? ()
Warning: /cygdrive/C/gccfd/projects/test2378_2: No such file or directory.
mi_cmd_break_watch: Missing <expression>
monitor reset 
Ignoring packet error, continuing...
Reply contains invalid hex digit 116
monitor sleep 500 
putpkt: write failed: Bad file descriptor.
monitor soft_reset_halt 
putpkt: write failed: No error.
monitor poll 
putpkt: write failed: No error.
monitor wait_halt 
putpkt: write failed: No error.
monitor arm7_9 force_hw_bkpts enable 
putpkt: write failed: No error.
symbol-file main.out
thbreak main 
Hardware assisted breakpoint 2 at 0x16c: file main.c, line 59.
load 
Loading section .text, size 0xf3c lma 0x0
putpkt: write failed: No error.
continue
putpkt: write failed: No error.

I think everything goes wrong because of the first warning : “Warning: /cygdrive/C/gccfd/projects/test2378_2: No such file or directory.” but the directory “C:\gccfd\projects\test2378_2” exists and contains my project with main.out.

These are my run commands:

monitor reset 
monitor sleep 500 
monitor soft_reset_halt 
monitor poll 
monitor wait_halt 
monitor arm7_9 force_hw_bkpts enable 
symbol-file main.out

I am using lpc-2378-stk board from olimex.

Regards,

Jef

Which tutorial??? Is Lynch advocating the use of Cygwin still?

I’d try a simpler toolchain like WinARM or YARGARTO.

What debugger are you using? I am having inconsitant results with the Olimex ARM-USB-OCD on the LPC23xx and LPC24xx chips.

Hi Jef.

The tutorial which targets the NXP LPC2000 parts is nearly three years old. Please look at my most recent tutorial “Using Open Source Tools for AT91SAM7 Cross Deveopment” at the Atmel support site here:

http://www.atmel.com/dyn/resources/prod … source.zip

While this tutorial targets the Atmel chips, it uses YAGARTO and has lots of information that you could transfer to the NXP environment.

Cheers,

Jim Lynch

Hi and thanks for the help so far.

I am a bit confused. It might be that I first installed an older version of YAGARTO from the CD accompanied with the ARM_USB_OCD but I think I have the latest versions, I will reinstall to be sure.

I am using the latest version of the tutorial (many thanks for all the work! we all owe you) and on page 130 you explain on how to use the debugger. this is exactly what I did. I use arm-elf-gdb.exe, isn’t that what is causing the warning and the errors? Do you think something else is causing this?

regards, Jef

Hello Jef,

I have never seen the CD with YAGARTO, therefore I could not

tell you which version was used on it. The problems of the CD

is that in this case OpenOCD is “very old” on the CD if the CD comes out.

Therefor if you have some problems, take a look at tha YAGARTO page

and use this OpenOCD version.

Regards,

Michael

:oops:

Sorry for the confusion guys. What I meant is that Olimex provides a CD with some old version of the open source toolchain with the ARM-USB-OCD. I apperently installed that although that was not my intention.

I now indeed have everything up and running up to the point where the first breakpoint is hit. For some reason it can not make the connection to my sourcecode. In the console I see this:

target remote localhost:3333
0x000053bc in ?? ()
monitor reset 
monitor sleep 500 
monitor soft_reset_halt 
monitor poll 
monitor wait_halt 
monitor arm7_9 force_hw_bkpts enable 
symbol-file main.out

And the editor shows:

No source available for “”

Any ideas on this?

I have read your first post on the forum. You said:

“I think everything goes wrong because of the first warning : “Warning: /cygdrive/C/gccfd/projects/test2378_2: No such file or directory.” but the directory “C:\gccfd\projects\test2378_2” exists and contains my project with main.out.”

I think that, if you are using YAGARTO without Cygwin, you should select “Embedded debug (Native)” instead of “Embedded debug (Cygwin)” in the debug configuration window. Perhaps this is the cause of the warning “Warning: /cygdrive/C/gccfd/projects/test2378_2: No such file or directory.”

I began developing with WinARM + Cygwin + eclipse + openocd and when I switched to YAGARTO + eclipse + openocd I experienced a problem similar to that you describe. I corrected the problem with this change.

After using this free toolchain for a time I am using Rowley CrossWorks now. It is based on the ARM GNU compiler but the debugger is much better and the personal license is affordable.

I hope this can help you.

Víctor