[Lazarus] Gdb and openocd via lazarus

Martin Schreiber mse00000 at gmail.com
Wed May 28 13:21:05 CEST 2014


On Wednesday 28 May 2014 12:36:57 Koenraad Lelong wrote:
>
> I tried to debug my arm-board with MSEide.
> I manually started openocd (I need to be root).

Maybe it could be done by a root script with setuser flag 
in 'Project'-'Options'-'Debugger'-'Target'-'Start gdb server command run 
target'.

> I configured MSEide 
> debugger : Target connection : extended-remote localhost:3333.

Up to now I used "remote" only.

> I configured debug-target to the elf-file of my project. Is there a
> macro to add an extention to the "make-output-file" ?

The gdb target file can be defined in 'Project'-'Options'-'Debugger'-'Debug 
Target' (as you did). There is a predefined macro ${EXEEXT} in 'Settings' for 
global access or define your own project specific macros 
in 'Project'-'Options'-'Macros'. It is possible to save such a customized 
project as template for future. MSEide project templates are normal project 
(*.prj)-files.

> I compiled the project and manually flashed it, and I left it in reset
> halt. I then can attach to the target, I see gdb connecting to openocd. I
> get the proper source in the source window. I can start the project, but
> since there seems still a problem with the compile-fase (the resulting
> binary does not work properly) I tried to reset the board. There gdb drops
> the connection to the target.
>
> When I set a breakpoint, the target halts, but MSEide does not indicate
> in the source where it stops. I can step, but again MSEide does not
> follow in the source.
>
> I can "continue" the target and stop it. But when I stop it, no
> indication where in the source it stopped.
>
The searched source directories must be listed 
in 'Project'-'Options'-'Debugger'-'Source directories'.
What shows the status line below the MSEide main menu?

BTW, the MSEide+MSEgui mailinglist is here:
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk
Archive and NNTP gateway:
http://news.gmane.org/gmane.comp.ide.mseide.user
I don't think the theme is appropriate for this list. ;-)

Martin




More information about the Lazarus mailing list