Writing your Assembly Source Files

Once your project is configured, you can start writing your application's assembly source code and the Linker's PRM file.

Note: You can write an assembly application using one or several assembly units. Each assembly unit performs one particular task. An assembly unit is comprised of an assembly source file and, perhaps, some additional include files. Variables are exported from or imported to the different assembly units so that a variable defined in an assembly unit can be used in another assembly unit. You create the application by linking all of the assembly units.

The usual procedure for writing an assembly source-code file is to use the editor that is integrated into the CodeWarrior IDE.

To create a new assembly source file:

  1. Select File > New > Source File from the IDE menu bar. The New Source File dialog box appears.
    Figure 1. New Source File Dialog Box
    New Source File Dialog Box
  2. Enter the folder in which you want to add the new file in the Source Folder text box or click Browse to select the desired folder, for example Project_1/Sources.
  3. Enter the name of the new file with extension *.asm in the Source File text box.
  4. Click Finish.

A newly created file opens in the editor area. Write your assembly source code in the file.