Atmel website | ARM Community | AVR freaks | Technical Support
Banner
 FAQ •  Search •  Register •  Login 

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: GDB Setup for SAM9Gx5?
PostPosted: Fri May 04, 2012 5:32 pm 
Offline

Joined: Fri Oct 28, 2011 7:25 pm
Posts: 57
I'm trying to use a Segger J-Link with Eclipse and GDB to debug my userspace application on a SAM9G25. I'm having issues getting the initial connection to my board.

I have installed the JLink GDB package from Segger on my host machine under /opt/JLink. I start up /opt/JLink/JLinkGDBServer under a terminal and it finds my JTAG emulator. I launch a "Remote C/C++ Application" debug session for my application under Eclipse. When it tries to make the initial connection, I get the following error under the "Remote Shell" log:
Code:
sh: line 2: gdbserver: command not found


And then under the "gdb" log I get these errors:
Code:
warning: Unable to find dynamic linker breakpoint function.
GDB will be unable to debug shared library initializers
and track explicitly loaded dynamic code.
warning: RMT ERROR : failed to get remote thread list.
warning: RMT ERROR : failed to get remote thread list.


I've searched around for like cases and I'm at a loss. Anyone have success getting GDB running in this manner?

If it helps, here's also the output from the gdb traces log:
Code:
027,330 2-environment-cd /home/engineer/embest/application/IH3MainApp
027,331 2^done
027,332 (gdb)
027,332 3-gdb-set breakpoint pending on
027,333 3^done
027,333 (gdb)
027,334 4-gdb-set detach-on-fork on
027,334 4^done
027,334 (gdb)
027,335 5-enable-pretty-printing
027,336 5^done
027,336 (gdb)
027,337 6maintenance set python print-stack off
027,337 &"maintenance set python print-stack off\n"
027,338 6^done
027,338 (gdb)
027,338 7source .gdbinit
027,339 &"source .gdbinit\n"
027,339 &".gdbinit: No such file or directory.\n"
027,339 7^error,msg=".gdbinit: No such file or directory."
027,339 (gdb)
027,340 8-gdb-set auto-solib-add on
027,341 8^done
027,341 (gdb)
027,345 9-file-exec-and-symbols --thread-group i1 /home/engineer/embest/application/IH3MainApp/ih3_m\
ain_app
027,350 9^done
027,350 (gdb)
027,351 10-target-select remote LOCALHOST:2331
027,697 11-list-thread-groups
030,412 =thread-group-started,id="i1",pid="42000"
030,413 =thread-created,id="1",group-id="i1"
030,415 12-list-thread-groups --available
030,588 &"warning: Unable to find dynamic linker breakpoint function.\nGDB will be unable to debug s\
hared library initializers\nand track explicitly loaded dynamic code."
030,589 &"\n"
032,291 *stopped,frame={addr="0x00000000",func="??",args=[]},thread-id="1",stopped-threads="all"
032,295 10^connected
032,295 (gdb)
032,296 &"warning: RMT ERROR : failed to get remote thread list.\n"
032,296 11^done,groups=[{id="i1",type="process",pid="42000",executable="/home/engineer/embest/applic\
ation/IH3MainApp/ih3_main_app"}]
032,304 (gdb)
032,304 12^error,msg="Can not fetch data now.\n"
032,305 (gdb)
032,315 13-break-insert --thread-group i1 -t -f main
032,377 14-list-thread-groups i1
032,490 13^done,bkpt={number="1",type="breakpoint",disp="del",enabled="y",addr="0x00008ee0",func="ma\
in",file="IH3_main_process.c",fullname="/home/engineer/embest/application/IH3MainApp/IH3_main_proces\
s.c",line="1327",times="0",original-location="main"}
032,491 (gdb)
032,493 &"warning: RMT ERROR : failed to get remote thread list.\n"
032,493 14^done,threads=[{id="1",target-id="Thread <main>",frame={level="0",addr="0x00000000",func="\
??",args=[]},state="stopped"}]
032,495 (gdb)
032,531 15-stack-info-depth --thread 1 11
032,531 16-exec-continue --thread-group i1
034,061 15^done,depth="2"
034,062 (gdb)
034,400 16^error,msg="Warning:\nCannot insert breakpoint -1.\nError accessing memory address 0x8dd0:\
 Unknown error 4294967295.\nCannot insert breakpoint 1.\nError accessing memory address 0x8ee0: Unkn\
own error 4294967295.\n"
034,401 (gdb)
034,420 ~"Hangup detected on fd 0\n"
034,420 ~"error detected on stdin\n"
034,420 ~"A debugging session is active.\n\n\tInferior 1 [Remote target] will be killed.\n\nQuit any\
way? "
034,421 ~"(y or n) [answered Y; input not from terminal]\n"
034,421 =thread-group-exited,id="i1"


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: Bing [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: