public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] gdb problem
@ 2006-05-18  9:46 Ram Sudhir Tadavarthi
  2006-05-18  9:53 ` Andrew Lunn
  0 siblings, 1 reply; 12+ messages in thread
From: Ram Sudhir Tadavarthi @ 2006-05-18  9:46 UTC (permalink / raw)
  To: ecos-discuss

Hello,

Aim:
To get the gdb debugger working 

Target environment:
Platform : Motorola PQ2FADS-ZU Board
Processor: MPC 8280 (predecessor of MPC 8260) Clock frequency : 100MHz

I have built a hello world eCos RAM application (hello.elf,hello.srec from
hello.c). If I load the hello.srec from redboot monitor via tftp and execute
it with "go" command. 

The output on the console is

Init device '/dev/ttydiag'
Init tty channel: 38170
Init device '/dev/haldiag'
HAL/diag SERIAL init
Hello, world!


I tried to load and run the image(hello.elf) over gdb(via network) with the
following commands

$ powerpc-eabi-gdb -nw hello.elf
GNU gdb 5.3 (eCosCentric)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "--host=i686-pc-cygwin --target=powerpc-eabi"...
(gdb) target remote 192.168.20.238:9000
Remote debugging using 192.168.20.238:9000
0xfff16534 in ?? ()
(gdb) load
Loading section .text, size 0x170e0 lma 0x20000
Loading section .rodata, size 0xb30 lma 0x370e0
Loading section .data, size 0x754 lma 0x37c10
Start address 0x20000, load size 99172
Transfer rate: 72125 bits/sec, 508 bytes/write.
(gdb) continue
Continuing.


And I don't see the output on the console.I wonder why the same RAM
application which runs via redboot load doesn't work with gdb.

I hope it isn't problem with eCos configuration.For reference the "ecc" file
is available at

http://www.yousendit.com/transfer.php?action=download&ufid=DCB915D05E9624A8

I will be obliged if anyone can give me a hint or reference/pointer how to
make gdb work with my application.

Thanks a lot,
Ram


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [ECOS] gdb problem
  2006-05-18  9:46 [ECOS] gdb problem Ram Sudhir Tadavarthi
@ 2006-05-18  9:53 ` Andrew Lunn
  2006-05-18 10:13   ` AW: " Ram Sudhir Tadavarthi
  0 siblings, 1 reply; 12+ messages in thread
From: Andrew Lunn @ 2006-05-18  9:53 UTC (permalink / raw)
  To: Ram Sudhir Tadavarthi; +Cc: ecos-discuss

On Thu, May 18, 2006 at 11:45:32AM +0200, Ram Sudhir Tadavarthi wrote:
> Hello,
> 
> Aim:
> To get the gdb debugger working 
> 
> Target environment:
> Platform : Motorola PQ2FADS-ZU Board
> Processor: MPC 8280 (predecessor of MPC 8260) Clock frequency : 100MHz
> 
> I have built a hello world eCos RAM application (hello.elf,hello.srec from
> hello.c). If I load the hello.srec from redboot monitor via tftp and execute
> it with "go" command. 
> 
> The output on the console is
> 
> Init device '/dev/ttydiag'
> Init tty channel: 38170
> Init device '/dev/haldiag'
> HAL/diag SERIAL init

Try disabling these messages. The ethernet gdb stub can get itself
into knots if it is asked to output messages too soon during booting. 

     Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* AW: [ECOS] gdb problem
  2006-05-18  9:53 ` Andrew Lunn
@ 2006-05-18 10:13   ` Ram Sudhir Tadavarthi
  0 siblings, 0 replies; 12+ messages in thread
From: Ram Sudhir Tadavarthi @ 2006-05-18 10:13 UTC (permalink / raw)
  To: 'Andrew Lunn'; +Cc: ecos-discuss


Hi,

Thanks a lot for the response.

>> Hello,
>> 
>> Aim:
>> To get the gdb debugger working 
>> 
>> Target environment:
>> Platform : Motorola PQ2FADS-ZU Board
>> Processor: MPC 8280 (predecessor of MPC 8260) Clock frequency : 100MHz
>> 
>> I have built a hello world eCos RAM application (hello.elf,hello.srec
>from
>> hello.c). If I load the hello.srec from redboot monitor via tftp and
>execute
>> it with "go" command. 
>> 
>> The output on the console is
>> 
>> Init device '/dev/ttydiag'
>> Init tty channel: 38170
>> Init device '/dev/haldiag'
>> HAL/diag SERIAL init
>
>Try disabling these messages. The ethernet gdb stub can get itself
>into knots if it is asked to output messages too soon during booting. 

I have disabled the messages but still the same response, no messages on
console.

GNU gdb 5.3 (eCosCentric)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "--host=i686-pc-cygwin --target=powerpc-eabi"...
(gdb) target remote 192.168.20.238:9000
Remote debugging using 192.168.20.238:9000
0xfff16534 in ?? ()
(gdb) load
Loading section .text, size 0x17068 lma 0x20000
Loading section .rodata, size 0xaa0 lma 0x37068
Loading section .data, size 0x754 lma 0x37b08
Start address 0x20000, load size 98908
Transfer rate: 65938 bits/sec, 507 bytes/write.
(gdb) break main
Breakpoint 1 at 0x205f0: file hello.c, line 5.
(gdb) continue
Continuing.


and the network still works(checked with ping). Any other hint please?

Thank you,
Ram


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [ECOS] GDB Problem
  2005-11-01  5:58 [ECOS] GDB Problem Henry Yu
@ 2005-11-01  7:47 ` Andrew Lunn
  0 siblings, 0 replies; 12+ messages in thread
From: Andrew Lunn @ 2005-11-01  7:47 UTC (permalink / raw)
  To: Henry Yu; +Cc: Andrew Lunn, ecos-discuss, steven

On Mon, Oct 31, 2005 at 09:58:12PM -0800, Henry Yu wrote:
> Andrew
>     Thank you so much for taking the time to reply me, follow you direction, I use serial port to connect boards, in gdb mode I type:
> "(gdb) set remotebaud 115200"
> "(gdb) target remote com1"
> but some error show me:
> "Remote debugging using com1"
> "couldn't establish connection to remote target"
> "cannot access memory at address 0xcca7cd2a"

Does your serial cable work OK? 

try doing

set remotedebug on

and see if there is any communication between the host and the target.

        Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [ECOS] GDB Problem
@ 2005-11-01  5:58 Henry Yu
  2005-11-01  7:47 ` Andrew Lunn
  0 siblings, 1 reply; 12+ messages in thread
From: Henry Yu @ 2005-11-01  5:58 UTC (permalink / raw)
  To: Andrew Lunn; +Cc: ecos-discuss, steven

Andrew
    Thank you so much for taking the time to reply me, follow you direction, I use serial port to connect boards, in gdb mode I type:
"(gdb) set remotebaud 115200"
"(gdb) target remote com1"
but some error show me:
"Remote debugging using com1"
"couldn't establish connection to remote target"
"cannot access memory at address 0xcca7cd2a"

Please give me a hand!


Thank you!

Henry,
Sincerely



--- Andrew Lunn <andrew@lunn.ch> wrote:

From: Andrew Lunn <andrew@lunn.ch>
Date: Mon, 31 Oct 2005 06:36:47 +0100
To: Henry Yu <henry@sigpro.com>
Cc: ecos-discuss@ecos.sourceware.org
Subject: Re: [ECOS] GDB Problem

On Sun, Oct 30, 2005 at 06:48:25PM -0800, Henry Yu wrote:
> Hello,
>      Now  I porting RedBoot from Mips 4kc to TI's TNETV 1060, I
> can see "RedBoot>". When I type "fconfig -l" it list:
> 
> RedBoot> fconfig -l
> Run script at boot: false
> Console baud rate: 38400
> RedBoot>
> 
> How Can I get GDB support?

http://ecos.sourceware.org/docs-latest/user-guide/using-commandline-testcase.html

        Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [ECOS] GDB Problem
  2005-10-31  2:48 Henry Yu
@ 2005-10-31  5:36 ` Andrew Lunn
  0 siblings, 0 replies; 12+ messages in thread
From: Andrew Lunn @ 2005-10-31  5:36 UTC (permalink / raw)
  To: Henry Yu; +Cc: ecos-discuss

On Sun, Oct 30, 2005 at 06:48:25PM -0800, Henry Yu wrote:
> Hello,
>      Now  I porting RedBoot from Mips 4kc to TI's TNETV 1060, I
> can see "RedBoot>". When I type "fconfig -l" it list:
> 
> RedBoot> fconfig -l
> Run script at boot: false
> Console baud rate: 38400
> RedBoot>
> 
> How Can I get GDB support?

http://ecos.sourceware.org/docs-latest/user-guide/using-commandline-testcase.html

        Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ECOS] GDB Problem
@ 2005-10-31  2:48 Henry Yu
  2005-10-31  5:36 ` Andrew Lunn
  0 siblings, 1 reply; 12+ messages in thread
From: Henry Yu @ 2005-10-31  2:48 UTC (permalink / raw)
  To: ecos-discuss

Hello,
     Now  I porting RedBoot from Mips 4kc to TI's TNETV 1060, I
can see "RedBoot>". When I type "fconfig -l" it list:

RedBoot> fconfig -l
Run script at boot: false
Console baud rate: 38400
RedBoot>

How Can I get GDB support?

Henry,
Best regards.

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ECOS] gdb problem
@ 2002-09-25  4:04 Vinayak P Risbud
  0 siblings, 0 replies; 12+ messages in thread
From: Vinayak P Risbud @ 2002-09-25  4:04 UTC (permalink / raw)
  To: Ecos-Discuss, gdb

        Hi,
            I am using gdb with jtag interface for debugging arm9 board.

            When I view for Mixed sources  ( i.e assembly and C)
            some of higher addresses come before than lower address
            for example

                16100 <cyg_start> mov...
                16104
                16108
                1610c   <cyg_start+12>
                16114   <cyg_start+20>
                16120   <cyg_start+32>
                16110   <cyg_start+16>
                16118   <cyg_start+24>
                1611c   <cyg_start+20>

            As you can see...the addresses are not linear...
            Is it a problem ?  If yes...where exactly could be the
problem ?

            Thanks in advance
                Vinayak


-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [ECOS] GDB Problem
  2002-02-11  8:49 [ECOS] GDB Problem Sébastien Bouthillier
@ 2002-02-11  8:58 ` Andrew Lunn
  0 siblings, 0 replies; 12+ messages in thread
From: Andrew Lunn @ 2002-02-11  8:58 UTC (permalink / raw)
  To: Sébastien Bouthillier; +Cc: ecos-discuss

On Mon, Feb 11, 2002 at 11:49:36AM -0500, Sébastien Bouthillier wrote:
> 
> Hi,
> 
> I have built the hello.c example using the
> makefile in the same directory. The program has
> been compiled for a i386 pc target.
> 
> Now when I try to run the .exe file with GDB, I get
> this error message : "Don't know how to run".

You need to start thinking about host-target systems. You need to load
the image onto the target and then execute it. Run tries to run it on
the local host system.

look at the documentation for the following gdb commands

target
load
continue

typical commands i use for an StrongARM board are

set remotespeed 38400
target remote com2
load
continue

        Andrew

Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ECOS] GDB Problem
@ 2002-02-11  8:49 Sébastien Bouthillier
  2002-02-11  8:58 ` Andrew Lunn
  0 siblings, 1 reply; 12+ messages in thread
From: Sébastien Bouthillier @ 2002-02-11  8:49 UTC (permalink / raw)
  To: ecos-discuss


Hi,

I have built the hello.c example using the
makefile in the same directory. The program has
been compiled for a i386 pc target.

Now when I try to run the .exe file with GDB, I get
this error message : "Don't know how to run".

What can I do to solve this?

Thank You
Sebastien


_________________________________________________________________
Join the worldÂ’s largest e-mail service with MSN Hotmail. 
http://www.hotmail.com


Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [ECOS] GDB problem
  2001-07-15 22:37 [ECOS] GDB problem Tony Ko
@ 2001-07-16 13:22 ` Jonathan Larmour
  0 siblings, 0 replies; 12+ messages in thread
From: Jonathan Larmour @ 2001-07-16 13:22 UTC (permalink / raw)
  To: Tony Ko; +Cc: ecos-discuss

Tony Ko wrote:
> 
> so what's for "run" command?

Native targets and simulators. Not remote targets.

> and what's the difference between "run" and "continue"?

Run starts a program from the beginning. But a remote target must already
be running _something_ even if only a boot loader, hence "continue".

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine
Come to the Red Hat TechWorld open source conference in Brussels!
Keynotes, techie talks and exhibitions    http://www.redhat-techworld.com/

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [ECOS] GDB problem
@ 2001-07-15 22:37 Tony Ko
  2001-07-16 13:22 ` Jonathan Larmour
  0 siblings, 1 reply; 12+ messages in thread
From: Tony Ko @ 2001-07-15 22:37 UTC (permalink / raw)
  To: ecos-discuss

hi.
look at the script below,

[root -root]#powerpc-eabi-gdb -nw wcdma_test
GNU gdb 5.0
Copyright 2000 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "--host=i686-pc-linux-gnu --target=powerpc-
eabi"...
(gdb) set remotebaud 38400
(gdb) target remote /dev/ttyS0
Remote debugging using /dev/ttyS0
0xfe00b39c in ?? ()
(gdb) load
Loading section .vectors, size 0x2000 lma 0x10000
Loading section .text, size 0x30ae8 lma 0x12000
Loading section .rodata, size 0x2e10 lma 0x42ae8
Loading section .data, size 0xf14 lma 0x458f8
Start address 0x10100 , load size 223244
Transfer rate: 27059 bits/sec, 509 bytes/write.
(gdb) r
The program being debugged has been started already.
Start it from the beginning? (y or n) y

Starting program: /mbxecos/ecos-1.3.1/tests/ap/v1_3_1/tests/wcdma_test 
Don't know how to run.  Try "help target".
(gdb) 

my question is why "run" command does not operate properly.
instead of "run", "continue" command works. program runs by "continue".

so what's for "run" command?
and what's the difference between "run" and "continue"?

thanks in advance.

Tony



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2006-05-18 10:13 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-18  9:46 [ECOS] gdb problem Ram Sudhir Tadavarthi
2006-05-18  9:53 ` Andrew Lunn
2006-05-18 10:13   ` AW: " Ram Sudhir Tadavarthi
  -- strict thread matches above, loose matches on Subject: below --
2005-11-01  5:58 [ECOS] GDB Problem Henry Yu
2005-11-01  7:47 ` Andrew Lunn
2005-10-31  2:48 Henry Yu
2005-10-31  5:36 ` Andrew Lunn
2002-09-25  4:04 [ECOS] gdb problem Vinayak P Risbud
2002-02-11  8:49 [ECOS] GDB Problem Sébastien Bouthillier
2002-02-11  8:58 ` Andrew Lunn
2001-07-15 22:37 [ECOS] GDB problem Tony Ko
2001-07-16 13:22 ` Jonathan Larmour

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).