public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Gary Thomas <gthomas@cambridge.redhat.com>
To: Nagendra EM <nagendra.em@eudoramail.com>
Cc: Jonathan Larmour <jlarmour@redhat.com>, ecos-discuss@sources.redhat.com
Subject: Re: [ECOS] How to RUN a program?
Date: Wed, 04 Jul 2001 05:32:00 -0000	[thread overview]
Message-ID: <XFMail.20010704063157.gthomas@cambridge.redhat.com> (raw)
In-Reply-To: <IIIOLDBOFJIBCAAA@shared1-mail.whowhere.com>

Given that your system is not one of our standard platforms, it's difficult
to say exactly what's wrong now.  You do seem to be on the right track though.

Just to show you how it's done, I just ran this on the iPAQ (an SA1110 platform).
Here are exactly the steps I took:

  % mkdir -p /work/iPAQ/test
  % cd /work/iPAQ/test
  % ecosconfig new ipaq
  % ecosconfig tree
  % make
  % cp -a /work2/ecc/doc/examples .
  % cd examples
  % SRCS=hello.c DST=hello ./build_Makefile /work/iPAQ/test
  % make
  % arm-elf-gdb -nw hello
  GNU gdb 4.18-ecos-99r1-991015
  Copyright 1998 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.  This version of GDB is supported
  for customers of Cygnus Solutions.  Type "show warranty" for details.
  This GDB was configured as "--host=i686-pc-linux-gnu --target=arm-elf"...
  (gdb) arem
  0x500471c0 in ?? ()
  (gdb) lo
  Loading section .rom_vectors, size 0x40 lma 0x20000
  Loading section .text, size 0xb1f0 lma 0x20040
  Loading section .rodata, size 0x41c lma 0x2b230
  Loading section .data, size 0x4f8 lma 0x2b64c
  Start address 0x20040 , load size 47940
  Transfer rate: 25568 bits/sec.
  (gdb) c
  Continuing.
  Hello, eCos world!

  Program received signal SIGINT, Interrupt.
  idle_thread_main (data=21423050) at /work2/ecc/ecc/kernel/current/src/common/thread.cxx:1211
  1211        }
  Current language:  auto; currently c++
  (gdb) q
  The program is running.  Exit anyway? (y or n) y

On 03-Jul-2001 Nagendra EM wrote:
> Hi,
> I was trying the configuration which you suggested. It loads the exe file, but same problem
> again...it stops after printing continue and never comes out of it.
> 
> the output is here for your reference,
> -----------------------------------------------
> gdb) target remote COM2
> Remote debugging using COM2
> 0x0 in ?? ()
> 
> (gdb) set remotebaud 38400
> (gdb) load hello.exe
> Loading section .rom_vectors, size 0x40 lma 0x20000
> Loading section .text, size 0xafb0 lma 0x20040
> Loading section .rodata, size 0x3f5 lma 0x2aff0
> Loading section .data, size 0x4e8 lma 0x2b3e8
> Start address 0x20040 , load size 47309
> Transfer rate: 27033 bits/sec, 301 bytes/write.
> 
> (gdb) continue
> Continuing.
> ----------------------------------------------
> 
> please suggest...
> 
> regards,
> - Nagendra.
> 
> --
> 
> On Tue, 03 Jul 2001 06:59:54   Gary Thomas wrote:
>>
>>On 03-Jul-2001 Nagendra EM wrote:
>>> Hi,
>>> These are the steps that have followed.
>>> 
>>> 1. Built redboot.bin using the configuration tool.
>>> 2. Burnt the bootflash on SA1110 using the utility provided by the
>>>    manufacturer.
>>> 3. Built the example program "hello" found in the examples directory
>>>    using arm-elf-gcc and followed the steps given in the "Getting
>>>    started" manual for ARM. (i.e., setting the PKG_INSTALL_DIR and
>>>    XCC).
>>> 4. Started the ARM-GDB by invoking arm-elf-gdb.exe file.
>>> Now, on the gdb prompt, 
>>> ----------------------------------------------------------
>>> gdb) target remote COM2
>>> Remote debugging using COM2
>>> 0x0 in ?? ()
>>> 
>>> (gdb) load hello.exe
>>> Loading section .rom_vectors, size 0x40 lma 0x50000000
>>                                              ^^^^^^^^^^
>>
>>This tells me that you tried to build the 'hello' program for ROM mode.
>>You need to have a startup type of RAM in order to load & run via GDB.
>>
>>The most likely reason for this would be that you tried to reuse a
>>configuration which you used to build RedBoot to build the application.
>>This is not correct.  You must have a new configuration (build directory,
>>etc) for a new environment, namely RAM based applications.
>>
>>
> 
> 
> Join 18 million Eudora users by signing up for a free Eudora Web-Mail account at
> http://www.eudoramail.com

  parent reply	other threads:[~2001-07-04  5:32 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-07-03 10:31 Nagendra EM
2001-07-04  1:46 ` Jesper Skov
2001-07-04  5:32 ` Gary Thomas [this message]
2001-07-04  6:41   ` Jesper Skov
2001-07-04  7:30     ` Jonathan Larmour
  -- strict thread matches above, loose matches on Subject: below --
2001-07-05 22:27 Nagendra EM
2001-07-04 23:30 Nagendra EM
2001-07-04 10:16 Nagendra EM
2001-07-04 10:22 ` Jonathan Larmour
2001-07-04  3:39 Nagendra EM
2001-07-04  3:42 ` Jesper Skov
2001-07-03  6:03 Nagendra EM
2001-07-03  5:49 Nagendra EM
2001-07-03  6:01 ` Gary Thomas
2001-07-03  5:09 Nagendra EM
2001-07-03  5:15 ` Gary Thomas
2001-07-03  0:12 Nagendra EM
2001-07-03  4:59 ` Gary Thomas
2001-07-02 22:00 Nagendra EM
2001-07-01 23:00 Nagendra EM
2001-07-02 14:27 ` Jonathan Larmour

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=XFMail.20010704063157.gthomas@cambridge.redhat.com \
    --to=gthomas@cambridge.redhat.com \
    --cc=ecos-discuss@sources.redhat.com \
    --cc=jlarmour@redhat.com \
    --cc=nagendra.em@eudoramail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).