This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: RE: ctrl-c in GDB


Nick,

My program has a main, which turns on an LED on the board.
After that there  is a while(1) loop.  Could  this  be the
problem that  somehow GDB is not getting the control back?

NOTE: Putting a breakpoint  at main()  or cyg_user_start()
did not help.

Anyway I will test some of the kernel tests along with the
eCos as suggested by you.

Regards,
Vikas


-----Original Message-----
From: Nick Garnett [mailto:nickg@ecoscentric.com]
Sent: Tuesday, September 28, 2004 10:02 PM
To: Vikas K. Prasad
Cc: ecos-discuss@sources.redhat.com
Subject: Re: [ECOS] RE: ctrl-c in GDB


"Vikas K. Prasad" <vikas.prasad@ittiam.com> writes:

> Hi,
> 
> I got the interrupt to work. The UART RSR register
> was not  read  (and so the interrupt bit was never
> cleared).
> 
> However, I am still having issues with gdb ^c. Can
> someone help me out? The program is loaded correctly
> but control does not get transfered to application
> and neither the ^c work.
> 
> (gdb) so ldl.spt
> 0x00003018 in ?? ()
> Loading section .rom_vectors, size 0x40 lma 0x4100000
> Loading section .text, size 0xf6c8 lma 0x4100180
> Loading section .rodata, size 0x26c lma 0x410f848
> Loading section .data, size 0x3a0 lma 0x410fab4
> Start address 0x4100180, load size 64788
> Transfer rate: 86384 bits/sec, 298 bytes/write.
> (gdb) c
> Continuing.
> Interrupted while waiting for the program.
> Give up (and stop debugging it)? (y or n) y

If the program just dies without giving any output, then the best
thing to do is to plant some breakpoints in the startup code and find
how far it gets. A bit of binary chopping will narrow the area where
it is failing down and you should be able to find out where it fails.

Also try running some of the standard kernel tests provided with
eCos. If these fail then there is something wrong with the board
port.

-- 
Nick Garnett                    eCos Kernel Architect
http://www.ecoscentric.com/     The eCos and RedBoot experts


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]