public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* Re: [ECOS] How to connect GDB with Redboot
@ 2000-11-01  0:29 ness
  2000-11-01  1:39 ` Jesper Skov
  0 siblings, 1 reply; 5+ messages in thread
From: ness @ 2000-11-01  0:29 UTC (permalink / raw)
  To: jskov; +Cc: ecos-discuss

> ness> Hi Jifl and Jesper.  First ,thank you for your advice.  I use
> ness> the PMON to debug the redboot.srec. Now the program can go to
> ness> cyg_start, and executes the loop successfully. And the net is
> ness> working right. But I can't input redboot's command. And we just
> ness> need ethernet debug, so I just need the module which can connect
> ness> with GDB, and no input is not problem. Is it right?
>
> ness> But when the program executes the "breakpoint()" ,it stops. Do I
> ness> need to do something for the virtual vector table or other?
>
> If you don't see a prompt, there's a problem with the HAL serial
> driver. Or maybe your PMON interaction is spoiling things.
>
> Jesper  

I  just want let GDB connect with target, and GDB can load program via
ethernet. Does redboot provide connection with GDB and let GDB can load
program via ethernet?
If it does ,how do I change the redboot.
Many thanks.
ness

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

* Re: [ECOS] How to connect GDB with Redboot
  2000-11-01  0:29 [ECOS] How to connect GDB with Redboot ness
@ 2000-11-01  1:39 ` Jesper Skov
  2000-11-01  4:15   ` Gary Thomas
  0 siblings, 1 reply; 5+ messages in thread
From: Jesper Skov @ 2000-11-01  1:39 UTC (permalink / raw)
  To: ness; +Cc: ecos-discuss, gthomas

>>>>> "ness" == ness  <root@zh.t2-design.com> writes:

ness> I just want let GDB connect with target, and GDB can load
ness> program via ethernet. Does redboot provide connection with GDB
ness> and let GDB can load program via ethernet?

It does, assuming there is a working driver for your board, but you
may have to set RedBoot to accept connections via ethernet. And that
is done via the fconfig command which you have to use via the serial
line. At least I think you do. Gary?

Jesper



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

* Re: [ECOS] How to connect GDB with Redboot
  2000-11-01  1:39 ` Jesper Skov
@ 2000-11-01  4:15   ` Gary Thomas
  0 siblings, 0 replies; 5+ messages in thread
From: Gary Thomas @ 2000-11-01  4:15 UTC (permalink / raw)
  To: Jesper Skov; +Cc: ecos-discuss, ness

On 01-Nov-2000 Jesper Skov wrote:
>>>>>> "ness" == ness  <root@zh.t2-design.com> writes:
> 
> ness> I just want let GDB connect with target, and GDB can load
> ness> program via ethernet. Does redboot provide connection with GDB
> ness> and let GDB can load program via ethernet?
> 
> It does, assuming there is a working driver for your board, but you
> may have to set RedBoot to accept connections via ethernet. And that
> is done via the fconfig command which you have to use via the serial
> line. At least I think you do. Gary?

The defaults (which can be changed via CDL) will have your board allow
connections over the ethernet.  It will use BOOTP for the connection
and accept GDB conections on port 9000.

If you include a FLASH driver, then you can control/extend this behaviour
via the 'fconfig' command.

This, I believe, begs the question though.  Until you can get the board
to run GDB protocol using RedBoot on the serial port, I would not even
attempt to use the network for same.

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

* Re: [ECOS] How to connect GDB with Redboot
  2000-10-30 19:59 ness
@ 2000-10-31  4:20 ` Jesper Skov
  0 siblings, 0 replies; 5+ messages in thread
From: Jesper Skov @ 2000-10-31  4:20 UTC (permalink / raw)
  To: ness; +Cc: ecos-discuss

>>>>> "ness" == ness  <root@t2-design.com> writes:

ness> Hi Jifl and Jesper.  First ,thank you for your advice.  I use
ness> the PMON to debug the redboot.srec. Now the program can go to
ness> cyg_start, and executes the loop successfully. And the net is
ness> working right. But I can't input redboot's command. And we just
ness> need ethernet debug, so I just need the module which can connect
ness> with GDB, and no input is not problem. Is it right?

ness> But when the program executes the "breakpoint()" ,it stops. Do I
ness> need to do something for the virtual vector table or other?

If you don't see a prompt, there's a problem with the HAL serial
driver. Or maybe your PMON interaction is spoiling things.

Jesper

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

* [ECOS] How to connect GDB with Redboot
@ 2000-10-30 19:59 ness
  2000-10-31  4:20 ` Jesper Skov
  0 siblings, 1 reply; 5+ messages in thread
From: ness @ 2000-10-30 19:59 UTC (permalink / raw)
  To: ecos-discuss

Hi Jifl and Jesper.
First ,thank you for your advice.
I use the PMON to debug the redboot.srec. Now the program can go to 
cyg_start, and executes the loop successfully. And the net is working
right. But I can't input redboot's command. And we just need ethernet
debug, so I just need the module which can connect with GDB, and no input
is not problem. Is it right?

I think when res==0,the program go to the condition waiting connection
from the GDB. Am I right?

But when the program executes the  "breakpoint()" ,it stops. Do I need to
do something for the virtual vector table or other?

Many thanks!

 Ness


    while (true) {
        if (prompt) {
            printf("RedBoot> ");
            prompt = false;
        }
        res = gets(line, sizeof(line), 250);
        if (res < 0) {
            // No input arrived
#ifdef CYGPKG_REDBOOT_NETWORKING
            if (have_net) {
                // Check for incoming TCP debug connection
                net_io_test();
            }
#endif
        } else {
            if (res == 0) {
                // Special case of '$' - need to start GDB protocol
                CYGACC_CALL_IF_SET_CONSOLE_COMM(cur);
                breakpoint();  // Get GDB stubs started, with a proper
environment, etc.
            } else {
                if (strlen(line) > 0) {
                    if ((cmd = parse(line, &argc, &argv[0])) != (struct
cmd *)0) {
                        (cmd->fun)(argc, argv);
                    } else {
                        printf("Illegal command: %s\n", line);
                    }
                }
                prompt = true;
            }
        }


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

end of thread, other threads:[~2000-11-01  4:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-11-01  0:29 [ECOS] How to connect GDB with Redboot ness
2000-11-01  1:39 ` Jesper Skov
2000-11-01  4:15   ` Gary Thomas
  -- strict thread matches above, loose matches on Subject: below --
2000-10-30 19:59 ness
2000-10-31  4:20 ` Jesper Skov

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).