Booting within running GDB

Steve Strobel steve at link-comm.com
Wed Dec 15 21:39:11 UTC 2004


We do that slightly differently, also with uMon.  We have a download.sh 
script that does a bdmreset, then uses tftp to transfer the file to uMon's 
flash file system (if you are using DHCP, there is some timing you can 
tweak to make that work better).  It then uses a "moncmd" (a uMon command 
issued through the network interface) to tell uMon to expand the ezip'ed 
elf file into memory without running it, and finally starts GDB or 
DDD.  The GDB script sets some breakpoints (including actions to disable 
the COP and do a warmstart on uMon) and sets the program counter.  When it 
is finished, we just have to "c" (continue) to execute the application.

Please email me directly if you would like a copy of any of those script 
files.  We use them under Cygwin on a custom MCF5272 target, but it 
shouldn't take much to make them work elsewhere.

Steve


At 12:51 PM 12/15/2004 +0200, you wrote:
>Hello.
>         I ask this question here, as I think that our community will better
>understand my problem...:-)
>
>         Is there any way to execute gdb commands (except Ctrl-C) while 
> application is
>running (by "r" or "c")?
>
>         Below is the description which explains why do I need this:
>         I have my board running uMon boot manager and my RTEMS 
> application. uMon has
>the ability to "tftp in" application and then run it. I do this all under
>GDB+BDM.
>         Now, I try to automate all the boot+download process. For this I 
> wanted to
>write in my .gdbinit the sequence like this:
>1. Reset the board
>2. Run the board (allowing the uMon to get up and start tftp server).
>3. Start tftp client application as a shell command in GDB and download the
>application.
>4. Set some breakpoints in application, let's say in main().
>5. Send to the uMon "call application" command.
>6. Hit the break point...:-))
>
>The problem is that after the "run" command was issued (in 2) GDB does not
>accept any command till RUN ends, which never ends...:-(
>
>
>Many thanks ahead to everybody.
>
>
>Leon Pollak

---
Steve Strobel
Link Communications, Inc.
1035 Cerise Rd
Billings, MT 59101-7378
(406) 245-5002 ext 102
(406) 245-4889 (fax)
WWW: http://www.link-comm.com
MailTo:steve at link-comm.com




More information about the users mailing list