SEARCH
TOOLBOX
LANGUAGES
modified on 26 March 2012 at 19:53 ••• 95,798 views

Cortex M3 Compiler Installation

From Manuals

Revision as of 19:53, 26 March 2012 by Support (Talk | contribs)
Jump to: navigation, search

Contents

Choose a Compiler and IDE (Integrated Development Environment)

Choosing a Compiler

The Code Examples currently supports the following C and C++ compilers :

  • IAR Embedded Workbench for ARM (ewarm) 5.40
  • GNU Toolchain (gcc) for ARM 4.4.1 – CodeSourcery G++ 2010q1
  • GNU Toolchain (gcc) for ARM 4.4.3 – devkitARM 30

The IAR EWARM C/C++ compiler generally produces the smallest code sizes for ARM targets and has excellent integrated debugging capabilities versus the GNU Toolchain. If a GNU chain is used then an IDE needs to be chosen.

Choosing an IDE

An IDE installs when the IAR C/C++ Compiler is installed where the GNU tool chains do not install one. Code::Blocks IDE and the Eclipse IDE are the IDEs currently supported by the Eagle Code Examples. Debugging is currently not supported in the Code::Blocks IDE. If a debug environment is needed the Eclipse IDE should be use.

Install the Chosen Compiler and IDE

Installing EWARM

The IAR EWARM Kickstart Edition is a 32 KB code-sized limited version of the IAR C/C++ compiler and debugger. It can be downloaded from IAR's website.

After downloading the EWARM-KS-CD click on the application to install the IAR Embedded Workbench for ARM. Select the “Install IAR Embedded Workbench” option from the Applications main menu as shown in Figure 2.4. Follow the instructions in the installation application. We suggest that you use the default directories, and the “Full” installation option.

IAR KickStart CD
Figure 2.4: IAR Kickstart Main Menu

Installing a GNU Compiler and IDE

The Code Examples currently support two GNU tool chains:

  • GNU Toolchain (gcc) for ARM 4.4.1 – EABI CodeSourcery G++ Lite 2010q1
  • GNU Toolchain (gcc) for ARM 4.4.3 – devkitARM 30

Installing the Sourcery CodeBench Lite Edition for ARM EABI GNU Compiler

Download the Sourcery G++ Lite 2010q1 for ARM EABI version of Sourcery CodeBench Lite Edition for ARM from Mentor Graphics website. When it is finished downloading click on the application to install it and a screen similar to Figure 2.5 should appear. We suggest that you use the default directories during the installation.

Sourcery G++
Figure 2.5: Sourcery CodeBench Lite Edition for ARM EABI Main Menu

Installing the devkitARM GNU Compiler

Download the devkitARM compiler from the Sourceforge website.

Installing the Eclipse IDE

Eclipse is a Java application and has the potential to be run on a wide variety of hardware and operating systems. Eclipse may install on systems with as little as 64MB of memory, however, we recommend to have 1GB of memory or more. The following software is required prior to install:

  • GNU ARM Toolchain – Tools for embedded ARM development
  • Java Runtime Environment (JRE) – Environment required for Java applications

The Eclipse SDK includes the Eclipse Platform which provides support for a full featured IDE. The SDK is provided as an archive and should be extracted to its desired directory (commonly ‘C:\Program Files\’). Eclipse can then be run by opening ‘eclipse.exe’ under INSTALL_DIR\eclipse\ and it is recommended that a shortcut be created to the application for easy access. At startup, Eclipse will prompt the user to specify the workspace directory and should point to the directory containing all of the user’s project folders. This would be ‘C:\Program Files\Micromint\Eagle\StellarisWare\boards\eagle’ for the Eagle example applications and ‘%USERPROFILE%\Projects\Micromint\Lincoln’ for the Lincoln example applications.

Figure 1 – Specifying Workspace in Eclipse

The Eclipse IDE does not come with embedded ARM development support right out of the box. Plug-ins are needed to add this functionality and can be installed by selecting ‘Help’, ‘Install new software…’ via the Eclipse File menu. Click ‘Add’ to specify a plug-in source. An internet URL can be entered into the text box or a local directory or archive can be selected. The following two plug-ins can be installed via internet repository:

Figure 2 – Installing the CDT plug-in

The following plug-in will need to be downloaded manually and installed via the archive method:

Installing the CodeBlocks IDE