Chapter 4. System start-up

Table of Contents
System start-up — the HAL
System start-up — cyg_start()
System startup — cyg_prestart()
System startup — cyg_package_start()
System startup — cyg_user_start()

We describe here the steps performed by eCos upon start-up, mentioning how a programmer can introduce custom start-up routines.

System start-up — the HAL

The HAL (Hardware Abstraction Layer, see Chapter 7) is the eCos package which contains all start-up code. Its start-up procedure is outlined in detail in the section called HAL startup in Chapter 7, but the main steps can be summarized here:

  1. The HAL initializes the hardware, coordinates with the ROM monitor, and performs diagnostics.

  2. The HAL invokes all static and global C++ constructors.

  3. The HAL jumps to cyg_start(), which has the following prototype:

    void cyg_start(void);