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: Problem running applications. Breakpoint getting set automatically at atexit.cxx


Thankz Nick,

I am new to eCos and I am kind of running wild to learn and get things
working,  as I am running short of time.

Can you clarify some of the basic doubts that I have ?.

When I am creating a configuration for booting eCos from a floppy, I
select i386 PC Target with Gigabit Ethernet as the hardware and in
packages, I select Redboot. Then I import a file named
redboot_FLOPPY.ecm for the i386 architecture. I set the startup type to
"FLOPPY". On building this, I get a redboot.bin file, which I copy to
the floopy and use the same to boot.

There is an other way, where instead of selecting Redboot, I selected
the "stubs" option to create a boot image.

In both of these options, I was able to load the sample applications
like "hello" and "twothreads".

While these options are selected (reboot or stubs), I did not see the
kernel package to be included. Ie. The eCos kernel package is not
included.

Does that mean that the kernel is not included ?. 

If the kernel is not included, then how come I am able to create 2
threads in the twothreads sample. (Some of the questions may be very
trivial, kindly excuse my stupidity) ?.

Now that I was able to run the sample applications, I thought I will
repeat the same procedure with the eCos kernel package included.

This is when I ran into trouble running the applications (the head of
this thread)


Thankz for all the help.

-Mohasin


-----Original Message-----
From: ecos-discuss-owner@ecos.sourceware.org
[mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Nick
Garnett
Sent: Monday, April 26, 2004 2:28 PM
To: Syed Mohasin Zaki (WT01 - EMBEDDED & PRODUCT ENGINEERING SOLUTIONS)
Cc: mohanlaljangir@hotmail.com; ecos-discuss@ecos.sourceware.org
Subject: Re: [ECOS] Problem running applications. Breakpoint getting set
automatically at atexit.cxx

<mohasin.zaki@wipro.com> writes:

> Ummhh.. but why I am getting problem with all the executables that
I've
> built.
> 
> Also as I have mentioned earlier, I am able to load them as test them
as
> long as I don't include the eCos kernel package (note that I am not
> using redboot here).

I think you are getting confused here. You must be using RedBoot,
since you are connecting to it when you execute

(gdb) target remote /dev/ttyS0

The breakpoint you see at 0x00006b00 is the breakpoint that RedBoot
has used to put itself into GDB mode. After connecting GDB tries to
interpret this address in terms of the executable it has in
hand. Since the address is outside the executable's address range, GDB
makes its best guess and describes it as belonging to the closest
piece of code, which in your case just happens to be in atexit.cxx.

This address will be changed when you load the executable to be the
start address of the program.

Clearly you will never see threads in your application if you do not
have the kernel installed. 

I suggest that before messing about with advanced configuration
options, like removing the kernel, that you go back and follow the
documentation and get more familiar with eCos as is comes.

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


Confidentiality Notice 

The information contained in this electronic message and any attachments to this message are intended
for the exclusive use of the addressee(s) and may contain confidential or privileged information. If
you are not the intended recipient, please notify the sender at Wipro or Mailadmin@wipro.com immediately
and destroy all copies of this message and any attachments.

--
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]