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]

RE: problems creating GDB-stub (redboot) and getting eCos



On 27-Jun-2001 Arif.Abbas@combitechsystems.com wrote:
> Hi everyone!
> 
> I am using a product called the mediaEngine from Brightstar Engineering.
> (using a StrongArm CPU).
> Anywayz, since eCos doesn't specificaly support this board, I thought I
> could pick the on
> "that was most similiar" (Thanks Hugo Tyson and everyone else who helped med
> out last time!)
> In this case, it was the nanoEngine, from the same manufacturer.
> 
> Anyway, I looked in the hardware reference manuals and found that they both
> used exactly the same 
> processor, and that the adresses of FLASH and SDRAM where exactly the same.
> 
> So I thought that I could give it a shot and install eCos and Redboot as it
> said in the installation guide for
> the nanoEngine.
> So first I create the binaries for redboot's nanoengine and load the into
> the flash, following the steps on 
> http://sources.redhat.com/ecos/docs-latest/redboot/nano.html. When we got to
> the part where you
> are supposed to reset enigne, we got an error.
> If we don't change the speed of the COM1 (let it stay at 9600) we get a
> distorted prompt, and the prompt freezes: you can't type anything.
> If we do change the COM1 speed to 38400 Baud, we instead encounter a
> different kind of error:
> +FLASH: 0x50000000 - 0x50400000, 64 blocks of 0x00010000 bytes each.
> FLASH configuration checksum error or invalid key
> 

This is not really an error.  It simply means that the 'fconfig' database
which is stored in Flash is not up-to-date.  Once you get RedBoot up and
running, you can run the 'fconfig' command to fix this.

> 
> So my questions are:
> 
> 1) Has anyone encountered similiar problems?
> 
> 2) Does eCos only care about the CPU-commands, or does it have to know where
> ALL hardware is?
>    What I mean is that as I mentioned before, the CPU is the same, the flash
> and SDRAM have the same adresses, but then
>    there are some major differences when it comes to
> Ethernetdrives,serialports etc etc etc

This is quite possibly your problem.  Since this is a new, unproven, port,
a lot can go wrong at this point.  The first thing that RedBoot does is 
initialize the Flash - you've seen that work already.  The next thing is
try and start the network.

I'd suggest that you build a version of RedBoot which does not have networking
or Flash enabled to start.  This is the simplest configuration.  You can program 
it into ROM and then use that version to download new test versions which add 
the additional capabilities.  This way you can see what breaks when and then
have an idea about how to fix it - rather than starting with the whole thing
and trying to find the problem.

Start like this:
  % ecosconfig new nano redboot
  % ecosconfig import startup.ROM
  % ecosconfig tree
  % make

--------  startup.ROM ----------
cdl_component CYG_HAL_STARTUP {
    user_value ROM
};
--------------------------------

Program this into the Flash - you should get a working RedBoot which will
let you type commands, etc.  Once this is proven, try (in a new configuration
directory):

  % ecosconfig new nano redboot
  % ecosconfig add flash
  % ecosconfig tree
  % make

This will create a RAM based version of RedBoot which you can download and
execute on the board, using the ROM based one already in place.  Using a RAM
version is often preferable since it cuts out the ROM/Flash programming
step and will lead to faster turn around as you find problems, bugs, etc.

Once you are happy with the operation of the Flash commands, try adding
the network.  In the same configuration:
  
  % ecosconfig add eth_drivers
  % ecosconfig tree
  % make

And try it again.  Most likely, this is where you'll run into problems
(based on what you've told us).  At this time, you have to debug the
network initialization, etc.  Once that is ready, you can then build
the final ROM based version and program it.

> 
> 3) What kind of changes is one supposed to do in order to taylor eCos to
> EXACTLY match my platform?
>     I mean the profile I have now is for nanoEngine, which is supposed to be
> the closest relative available
>     to the maediaEngine. Do I perform the changes in the Config Tool? Or
> what do I do??
>      
> 4) How do I taylor Redboot binaries for specifically my platform??

I've outlined the basic steps for integrating RedBoot on a new platform.
However, these are only outlines.  The actual process may be considerably
more difficult (or incredibly trivial!).

If you get stuck, you can ask more specific questions.  Alternatively, 
we (Red Hat) are available to provide porting services - that's part
of how we make a living :-)


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