Help: How to debug with GDB + Eclipse + Yagarto + openOCD + LPC1768?

OP (Company: Student) #2134695
Hello. I am done, it is too difficult to set up this:

I have a LPC1768H board and a OpenOCD-USB interface (for OpenOCD and 
GDB).
I followed the tutorial in yagarto 
(http://www.yagarto.de/howto/yagarto2/index.html) which is very useful, 
but I can not debug. The tutorial is for the SEGGER jlink but i have 
another one.

I have:
1. installed OpenOCD, and run it with:
openocd -f /interface/openocd-usb.cfg  -f /target/lpc1768.cfg
It starts it and I can telnet to localhost 4444, so it works fine. I can 
also flash programs to the uController using commands.
2. I installed Yagarto, Eclipse, etc and put a blinky led program, I can 
successfuly build y main.elf application.
3. I have followed many tutorials to set up the debug, with zylin or 
without it, in the end, GDB connects to the target when debugging but 
never breakpoints in the main, always shows different errors. [I dont 
post the errors since I suppose that my GDB commands are wrong, I dont 
want to work on them, Soemone has to have the right ones]


My main question is: Which exact GDB inicialization commands should I 
use in the debug configuration for Eclipse and LPC1768?

Thanks in advance!
OP (Company: Student)
Hi...

I will answer myself:
I found the commands in a polish website:
http://www.freddiechopin.info/index.php ... y/35-arm/5 
9-arm-toolchain-tutorial?start=4

monitor reset
Monitor soft_reset_halt
MWW monitor 0xE01FC040 0x0002
load


I also put in the run commands:

monitor reg r13 = (0x10000000)
monitor reg pc = (0x10000004)
continue


That was all, but it was so difficult to find. Now i can debug on chip 
with my LPC1768!

Reply

A question of your own? This thread is over 15 years old. Ask it in a thread of its own – more people read along there, and it gets answered more often and sooner.

Start a new thread

A fix, an addition or feedback on this thread? Then reply here.

Formatting
  • [c]C-Code[/c]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]
  • [[Title]] – link to an article
  • Link to another post: right-click its post ID (#8078628), copy the address, paste it into the text

More about formatting

Post long source code as an attachment, not in the text.

Already registered? Log in

Not shown to anyone. We send you a link; your post appears once you confirm it there.

By submitting you create a free account and accept the terms of use.