eCos Product

eCos Net Distribution


RedBoot Product
 
RedBoot Net Distribution


Supported Hardware

Downloading and Installation

Documentation

FAQ

Keeping in Touch

Problems

Licensing

Anonymous CVS

Contributions and Third Party Projects

Red Hat eCos

RedBoot CDL


The RedBoot package takes care of building RedBoot. The platform CDL may be used to provide platform-specific RedBoot commands, and additional file conversion steps after the RedBoot ELF image file has been built.

The platform RedBoot CDL should be put in a component like the below, which is disabled when the RedBoot package is not included.

    cdl_component CYGPKG_REDBOOT_HAL_OPTIONS {
        display       "Redboot HAL options"
        flavor        none
        no_define
        parent        CYGPKG_REDBOOT
        active_if     CYGPKG_REDBOOT
        description   "
            This option lists the target's requirements for a valid Redboot
            configuration."
    }

Platform Specific RedBoot Commands

If you are adding extra commands to RedBoot, you need to add a compile statement to the CDL. For instance, to build the file redboot_cmds.c and include it in the RedBoot image, add this to the above CDL component:

            compile -library=libextras.a redboot_cmds.c

Extra build steps

The example build rule below takes the final redboot ELF image and converts it to both binary and SREC format, in preparation for being put into flash or ROM. You may have to tweak those rules or add more, depending on the method you use to get the data into the target.

        cdl_option CYGBLD_BUILD_REDBOOT_BIN {
            display       "Build Redboot ROM binary image"
            active_if     CYGBLD_BUILD_REDBOOT
            default_value 1
            no_define
            description "This option enables the conversion of the Redboot ELF
                         image to a binary image suitable for ROM programming."

            make -priority 325 {
                <PREFIX>/bin/redboot.bin : <PREFIX>/bin/redboot.elf
                $(OBJCOPY) --strip-debug $< $(@:.bin=.img) 
                $(OBJCOPY) -O srec $< $(@:.bin=.srec)
                $(OBJCOPY) -O binary $< $@
            }
        }