Analysis of Files in CodeWarrior Projects View

Expand the groups by clicking your mouse in the CodeWarrior Projects view to display all the default files generated by the New Bareboard Project wizard.

The wizard generates following three C source c ode files, located in their respective folders in the project directory:

At this time, the project should be configured correctly and the source code should be free of syntactical errors. If the project has been built earlier, you should see a link to the project's binary files, and the FLASH folder present in the CodeWarrior Projects view.

To understand what the IDE does while building a project, clean the project and build the project again:

  1. Select Project > Clean from the IDE menu bar.

    The Clean dialog box appears.

  2. Select the Clean projects selected below option and check the project you want to build again.
  3. Clear the Start a build immediately checkbox, if you want to build the project manually after cleaning.
    Figure 1. Clean Dialog Box
    Clean Dialog Box
  4. Click OK.

    The Binaries link disappears, and the FLASH folder is deleted.

  5. To build the project, right-click the project and select Build Project.

The Console view displays the statements that direct the build tools to compile and link the project. The Binaries link appears, and so does the FLASH folder.

During a project build, the C source code is compiled, the object files are linked together, and the CPU derivative's ROM and RAM area are allocated by the linker according to the settings in the linker command file. When the build is complete, the FLASH folder contains the Project1.abs file.

The Linker Map file, Project1.map, file indicates the memory areas allocated for the program and contains other useful information.

To examine the source file, main.c, double click on the main.c file in the Sources group.

The IDE editor opens the default main.c file in the editor area.

Figure 2. Default main.c File
Default main.c File

Use the integrated editor to write your C source files ( *.c and *.h) and add them to your project. During development, you can test your source code by building and simulating/debugging your application.

The Graphical User Interface chapter provides information about configuring the options for the Compiler and other Build Tools, as well as information about feedback messages.