Configure the Keil Compiler

Design Flow

  1. System Configuration

  1. Generate Header File
  2. Develop the Application
    • Specify operation
    • Configure compiler
    • Write code
    • Compile

  3. Code Simulation and Debug
  4. Compile, Create Object File
  5. Bind Peripherals, Create Download File
  6. Download the Design
  7. In-System Debugging
 

Setting Up Your Project

Now that we've finished writing the application program, let's set up the Keil project.

From the Project menu, click on New Project.

Creating a new Project

Select the location of your Project Registry, and enter a name for your Keil project.

Enter a name for your new Keil project.

Click OK when complete.

Now let's add our 'C' source file to the project. Select Project and then Edit Project from the menu.

Edit the project to add your source code.

Once the dialog box appears, click Add and select the source file, mydesign.c. Click Save when finished.

Add your 'C' source file.


Setting Up the 'C' Compiler Options

To set options for the 'C' compiler, click the Options menu item and select C51 Compiler....

C Compiler Options

Object File Options

To set options for the object file, select the Object tab from the dialog box.

Enable the debugging information.

For improved debugging visibility, choose the Include debug information and the Include extended debug information options. Do not click the OK button just yet.

Chip Options

To set options for device-specific compiler optimization, choose the Chip tab from the dialog box. The 8032 "Turbo" microcontroller has two data pointers, similar to the Dallas 80C320 devices. Choose 2: Dallas (MODDP2) from the selection drop list.

The E5 8032 "MCU" has two data pointers, similar to the Dallas 80C320 devices.

Click OK when finished.

Linker Options

The 8032 "Turbo" microcontroller embedded within the Triscend E5 device has 256 bytes of RAM, just like other 8052/8032 derivates. By default however, the Keil linker uses 128 bytes. To change these setting, select the Options menu item, then BL51 Code Banking Linker....

Modify the linker options to utilize all the RAM inside the 8032 "Turbo" microcontroller.

In the resulting dialog box, click the Size/Location tab. Update the Ram Size (decimal): setting from 128 to 256. Click OK when finished.

Change the RAM size to 256.