EWARM IDEGuide - ENU
EWARM IDEGuide - ENU
UIDEARM-18
COPYRIGHT NOTICE
© 1999–2023 IAR Systems AB.
No part of this document may be reproduced without the prior written consent of IAR
Systems AB. The software described in this document is furnished under a license and
may only be used or copied in accordance with the terms of such a license.
DISCLAIMER
The information in this document is subject to change without notice and does not
represent a commitment on any part of IAR Systems. While the information contained
herein is assumed to be accurate, IAR Systems assumes no responsibility for any errors
or omissions.
In no event shall IAR Systems, its employees, its contractors, or the authors of this
document be liable for special, direct, indirect, or consequential damage, losses, costs,
charges, claims, demands, claim for lost profits, fees, or expenses of any nature or kind.
TRADEMARKS
IAR Systems, IAR Embedded Workbench, Embedded Trust, C-Trust, IAR Connect,
C-SPY, C-RUN, C-STAT, IAR Visual State, IAR KickStart Kit, I-jet, I-jet Trace,
I-scope, IAR Academy, IAR, and the logotype of IAR Systems are trademarks or
registered trademarks owned by IAR Systems AB.
Microsoft and Windows are registered trademarks of Microsoft Corporation.
Arm, Cortex, Thumb, and TrustZone are registered trademarks of Arm Limited.
EmbeddedICE is a trademark of Arm Limited. uC/OS-II and uC/OS-III are trademarks
of Micrium, Inc. CMX-RTX is a trademark of CMX Systems, Inc. Azure RTOS
ThreadX is a trademark of Microsoft Corporation. RTXC is a trademark of Quadros
Systems. Fusion is a trademark of Unicoi Systems.
Renesas Synergy is a trademark of Renesas Electronics Corporation.
Adobe and Acrobat Reader are registered trademarks of Adobe Systems Incorporated.
All other product names are trademarks or registered trademarks of their respective
owners.
EDITION NOTICE
Eighteenth edition: June 2023
Part number: UIDEARM-18
This guide applies to version 9.40.x of IAR Embedded Workbench® for Arm.
Internal reference: BB14, FF9.2.x, ISHP.
AFE1_AFE2-1:1
Brief contents
Brief contents ....................................................................................................... 3
Tables ..................................................................................................................... 13
Preface .................................................................................................................... 15
AFE1_AFE2-1:1
IDE Project Management and Building Guide
4 for Arm
AFE1_AFE2-1:1
Contents
Brief contents ....................................................................................................... 3
Tables ..................................................................................................................... 13
Preface .................................................................................................................... 15
Who should read this guide ............................................................... 15
Required knowledge .......................................................................... 15
How to use this guide ........................................................................... 15
What this guide contains ..................................................................... 16
Part 1. Project management and building .......................................... 16
Part 2. Reference information ............................................................ 16
Other documentation ........................................................................... 17
User and reference guides .................................................................. 17
The online help system ...................................................................... 18
Web sites ............................................................................................ 18
Document conventions ........................................................................ 18
Typographic conventions ................................................................... 19
Naming conventions .......................................................................... 20
AFE1_AFE2-1:1
Specifying tool options ...................................................................... 33
Adding a button to a toolbar .............................................................. 33
Removing a button from a toolbar ..................................................... 34
Showing/hiding toolbar buttons ......................................................... 35
Recognizing filename extensions ....................................................... 36
Getting started using external analyzers ............................................ 36
Invoking external tools from the Tools menu .................................... 38
Adding command line commands to the Tools menu ........................ 39
Using an external editor ..................................................................... 39
Reference information on the IDE .................................................. 40
IAR Embedded Workbench IDE window ......................................... 42
Customize dialog box ......................................................................... 47
Button Appearance dialog box ........................................................... 49
Tool Output window .......................................................................... 50
Colors and Fonts options .................................................................... 51
Edit Colors dialog box ....................................................................... 54
Edit Fonts dialog box ......................................................................... 55
Key Bindings options ......................................................................... 56
Language options ............................................................................... 58
Editor options ..................................................................................... 59
Configure Auto Indent dialog box ..................................................... 63
External Editor options ...................................................................... 64
Editor Setup Files options .................................................................. 65
Editor Syntax Feedback options ........................................................ 66
Messages options ............................................................................... 67
Troubleshooting options .................................................................... 68
Project options .................................................................................... 69
External Analyzers options ................................................................ 71
External Analyzer dialog box ............................................................ 73
Source Code Control options (deprecated) ........................................ 75
Debugger options ............................................................................... 76
Stack options ...................................................................................... 77
Terminal I/O options .......................................................................... 79
Configure Tools dialog box ............................................................... 81
AFE1_AFE2-1:1
Contents
AFE1_AFE2-1:1
Building a project .................................................................................. 120
Setting project options using the Options dialog box ...................... 121
Building your project ....................................................................... 124
Correcting errors found during build ............................................... 125
Using pre- and post-build actions .................................................... 125
Building multiple configurations in a batch ..................................... 126
Building from the command line ..................................................... 127
Adding an external tool .................................................................... 127
Reference information on building ............................................... 128
Options dialog box ........................................................................... 129
Build window ................................................................................... 130
Batch Build dialog box .................................................................... 132
Edit Batch Build dialog box ............................................................. 133
iarbuild.exe—the IAR Command Line Build Utility ....................... 134
AFE1_AFE2-1:1
Contents
AFE1_AFE2-1:1
The common directory ..................................................................... 187
The install-info directory ................................................................. 187
Project directory structure .............................................................. 187
Various settings files ............................................................................ 188
Files for global settings .................................................................... 189
Files for local settings ...................................................................... 189
File types ................................................................................................... 190
Menu reference ............................................................................................... 193
AFE1_AFE2-1:1
Contents
11
AFE1_AFE2-1:1
Optimizations ................................................................................... 265
Advanced ......................................................................................... 266
Output ............................................................................................... 267
List ................................................................................................... 268
#define .............................................................................................. 269
Diagnostics ....................................................................................... 270
Checksum ......................................................................................... 272
Encodings ......................................................................................... 274
Extra Options ................................................................................... 275
Edit Additional Libraries dialog box ............................................... 276
Linker Configuration File Editor dialog box ................................... 277
AFE1_AFE2-1:1
Tables
1: Typographic conventions used in this guide ......................................................... 19
2: Naming conventions used in this guide ................................................................ 20
3: Argument variables ............................................................................................... 88
4: iarbuild.exe command line options ..................................................................... 134
5: Editor shortcut keys for insertion point navigation ............................................. 179
6: Editor shortcut keys for selecting text ................................................................. 180
7: Editor shortcut keys for scrolling ........................................................................ 180
8: Miscellaneous editor shortcut keys ..................................................................... 180
9: Additional Scintilla shortcut keys ....................................................................... 181
10: The arm directory ............................................................................................. 186
11: The common directory ...................................................................................... 187
12: File types ........................................................................................................... 190
13
AFE1_AFE2-1:1
IDE Project Management and Building Guide
14 for Arm
AFE1_AFE2-1:1
Preface
● Who should read this guide
● Other documentation
● Document conventions
REQUIRED KNOWLEDGE
To use the tools in IAR Embedded Workbench, you should have working knowledge of:
● The architecture and instruction set of the Arm core you are using (refer to the chip
manufacturer's documentation)
● The C or C++ programming language
● Application development for embedded systems
● The operating system of your host computer.
For more information about the other development tools incorporated in the IDE, refer
to their respective documentation, see Other documentation, page 17.
15
AFE1_AFE2-1:1
What this guide contains
● Reference information, which gives reference information related to the topic area.
Read this section for information about certain features or GUI components. You
can easily access this type of information for a GUI component in the IDE by
pressing F1.
If you are new to using IAR Embedded Workbench, we suggest that you first go through
the tutorials, which you can find in IAR Information Center in the product, under
Product Explorer. They will help you get started.
Finally, we recommend the Glossary if you should encounter any unfamiliar terms in
the IAR user documentation.
AFE1_AFE2-1:1
Preface
● Output converter options describes the options available for converting linker
output files from the ELF format.
● Custom build options describes the options available for custom tool configuration.
● Build actions options describes the options available for pre-build and post-build
actions.
● Linker options describes the options for setting up for linking.
● Library builder options describes the options for building a library.
Other documentation
User documentation is available as hypertext PDFs and as a context-sensitive online
help system in HTML format. You can access the documentation from the IAR
Information Center or from the Help menu in the IAR Embedded Workbench IDE. The
online help system is also available via the F1 key.
17
AFE1_AFE2-1:1
Document conventions
WEB SITES
Recommended web sites:
● The chip manufacturer’s web site.
● The Arm Limited web site, www.arm.com, that contains information and news
about the Arm cores.
● The IAR web site, www.iar.com, that holds application notes and other product
information.
● The web site of the C standardization working group,
www.open-std.org/jtc1/sc22/wg14.
● The web site of the C++ Standards Committee, www.open-std.org/jtc1/sc22/wg21.
● The C++ programming language web site, isocpp.org. This web site also has a list
of recommended books about C++ programming.
● The C and C++ reference web site, en.cppreference.com.
Document conventions
When, in the IAR documentation, we refer to the programming language C, the text also
applies to C++, unless otherwise stated.
When referring to a directory in your product installation, for example arm\doc, the full
path to the location is assumed, for example c:\Program Files\IAR
Systems\Embedded Workbench N.n\arm\doc, where the initial digit of the version
number reflects the initial digit of the version number of the IAR Embedded Workbench
shared components.
AFE1_AFE2-1:1
Preface
TYPOGRAPHIC CONVENTIONS
The IAR documentation set uses the following typographic conventions:
Style Used for
computer • Source code examples and file paths.
• Text on the command line.
• Binary, hexadecimal, and octal numbers.
parameter A placeholder for an actual value used as a parameter, for example
filename.h where filename represents the name of the file.
[option] An optional part of a linker or stack usage control directive, where [
and ] are not part of the actual directive, but any [, ], {, or } are part
of the directive syntax.
{option} A mandatory part of a linker or stack usage control directive, where {
and } are not part of the actual directive, but any [, ], {, or } are part
of the directive syntax.
[option] An optional part of a command line option, pragma directive, or library
filename.
[a|b|c] An optional part of a command line option, pragma directive, or library
filename with alternatives.
{a|b|c} A mandatory part of a command line option, pragma directive, or
library filename with alternatives.
bold Names of menus, menu commands, buttons, and dialog boxes that
appear on the screen.
italic • A cross-reference within this guide or to another guide.
• Emphasis.
… An ellipsis indicates that the previous item can be repeated an arbitrary
number of times.
Identifies instructions specific to the IAR Embedded Workbench® IDE
interface.
Identifies instructions specific to the command line interface.
Identifies helpful tips and programming hints.
Identifies warnings.
19
AFE1_AFE2-1:1
Document conventions
NAMING CONVENTIONS
The following naming conventions are used for the products and tools from IAR, when
referred to in the documentation:
Brand name Generic term
IAR Embedded Workbench® for Arm IAR Embedded Workbench®
IAR Embedded Workbench® IDE for Arm the IDE
IAR C-SPY® Debugger for Arm C-SPY, the debugger
IAR C-SPY® Simulator the simulator
IAR C/C++ Compiler™ for Arm the compiler
IAR Assembler™ for Arm the assembler
IAR ILINK Linker™ ILINK, the linker
IAR DLIB Runtime Environment™ the DLIB runtime environment
Table 2: Naming conventions used in this guide
In 32-bit mode refers to using IAR Embedded Workbench for Arm configured for the
instruction sets T32/T and A32.
In 64-bit mode refers to using IAR Embedded Workbench for Arm configured for the
instruction set A64.
For more information, see Execution modes, page 25.
AFE1_AFE2-1:1
Part 1. Project
management and building
This part contains these chapters:
● Project management
● Building projects
● Editing
21
22
The development
environment
● Introduction to the IAR Embedded Workbench IDE
● Execution modes
23
AFE1_AFE2-1:1
Introduction to the IAR Embedded Workbench IDE
AFE1_AFE2-1:1
The development environment
● Use the Subversion version control system to keep track of different versions of
your source code. The IDE can attach to files in a Subversion working copy.
● Add an external analyzer, for example a lint tool, of your choice to be used on whole
projects, groups of files, or an individual file of your project. Typically, you might
want to perform a static code analysis on your source code, using the same settings
and set of source code files as when you compile. See Getting started using external
analyzers, page 36.
● Add external tools to the Tools menu, for convenient access from within the IDE.
For this reason, the menu might look different depending on which tools you have
preconfigured to appear as menu commands.
● Configure custom argument variables, which typically can be useful if you install a
third-party product and want to specify its include directory. Custom argument
variables can also be used for simplifying references to files that you want to be part
of your project.
Execution modes
IAR Embedded Workbench for Arm supports the 32-bit and 64-bit Arm architectures by
means of execution modes.
25
AFE1_AFE2-1:1
Using and customizing the IDE
In 32-bit mode refers to using IAR Embedded Workbench for Arm configured to
generate and debug code for the T32/T and A32 instruction sets, either on an
Armv4/5/6/7 core or in the AArch32 execution state on an Arm v8-A core. In 32-bit
mode, you can use both the A32 and T32/T instruction sets and switch between them.
In 64-bit mode refers to using IAR Embedded Workbench for Arm configured to
generate and debug code for the A64 instruction set in the AArch64 execution state on
an Arm v8-A core. Code in 64-bit mode can call code in 32-bit mode, and that code can
return back. However, the IAR translator tools do not support this switch being used in
a single linked image. Switching between A32/T32/T code and A64 code must be
performed by using several images. For example, an OS using 64-bit mode can start
applications in either 64-bit or in 32-bit mode.
The AArch32 execution state is compatible with the Arm v7 architecture. The AArch32
execution state is emulated inside the AArch64 execution state.
AFE1_AFE2-1:1
The development environment
The file IarIdePm.exe is located in the common\bin directory under your IAR
installation, in case you want to start the program from the command line or from within
Windows Explorer.
27
AFE1_AFE2-1:1
Using and customizing the IDE
4 In the dialog box that is displayed, choose where to get the examples from. Choose
between:
● Download from IAR
● Copy from the installation DVD. In this case, use the browse button to locate the
required self-extracting example archive. You can find the archive in the
\examples-archive directory on the DVD.
The examples for the selected device vendor will be extracted to your computer. Unless
you have changed the location by defining a global custom argument variable
$EXAMPLES_DIR$, the examples will be extracted to the Program Data directory or
the corresponding directory depending on your Windows operating system.
5 The downloaded examples will now appear in the list of installed example projects in
the Information Center.
AFE1_AFE2-1:1
The development environment
29
AFE1_AFE2-1:1
Using and customizing the IDE
For more information about the CMSIS Manager dialog box, see CMSIS Manager
dialog box, page 92.
AFE1_AFE2-1:1
The development environment
4 If you did not already install the CMSIS-Pack software pack as described in Installing
a CMSIS-Pack software pack, click the tab Packs, select the pack you need, and click
the Install button.
Focus shifts to the Console view which prints status messages concerning the
installation process.
5 Click the Devices tab and make sure your device is still selected.
6 Click the Examples tab. The Examples view lists the available example projects for
the selected device.
7 Select an example and click the corresponding action button Copy to copy the CMSIS
example project into your IAR Embedded Workbench workspace.
31
AFE1_AFE2-1:1
Using and customizing the IDE
8 In the Components view, check if there are any unresolved dependencies to other
software packs. For information about resolving dependencies, see Installing a
CMSIS-Pack software pack, page 104, specifically step 6.
9 Choose Project>Options and verify the settings of your project options. You are now
ready to start working with your CMSIS example project in IAR Embedded
Workbench.
AFE1_AFE2-1:1
The development environment
To place a window in the same tab group as another open window, drag the window you
want to relocate and drop it on the other window. Drop it on one of the arrow buttons of
the organizer control, to control how to dock it.
See also The layout of the windows on the screen, page 25.
2 To access the options to the right in the dialog box, select a category to the left.
For more information about various options for customizing the IDE, see Tools menu,
page 210.
33
AFE1_AFE2-1:1
Using and customizing the IDE
3 Drag a command from the Commands list to one of the toolbars where you want to
insert the command as a button.
You can rearrange the existing buttons by dragging them to new positions.
Note: If you instead of adding a button want to show a button that has been hidden
temporarily, see Showing/hiding toolbar buttons, page 35.
AFE1_AFE2-1:1
The development environment
2 Right-click on the toolbar button that you want to remove and choose Delete from the
context menu.
Note: If you instead of removing a button want to hide it temporarily, see
Showing/hiding toolbar buttons, page 35.
35
AFE1_AFE2-1:1
Using and customizing the IDE
Specify the details required for the analyzer you want to be able to invoke.
Use Output matching patterns to specify (or choose from a list) three regular
expressions for identifying warning and error messages and to find references to source
file locations.
Click OK when you have finished.
AFE1_AFE2-1:1
The development environment
For more information about this dialog box, see External Analyzer dialog box, page 73.
3 In the IDE Options dialog box, click OK.
4 Choose Project>Analyze Project and select the analyzer that you want to run,
alternatively choose Analyze File(s) to run the analyzer on individual files.
Each of the regular expressions that you specified will be applied on each line of output
from the external analyzer. Output from the analyzer is listed in the Build Log window.
You can double-click any line that matches the Location regular expression you
specified in the External Analyzer dialog box to jump to the corresponding location in
the editor window.
Note: If you want to stop the analysis before it is finished, click the Stop Build button.
37
AFE1_AFE2-1:1
Using and customizing the IDE
2 Fill in the text fields according to the screenshot. For more information about this
dialog box, see Configure Tools dialog box, page 81.
3 After you have entered the appropriate information and clicked OK, the menu
command you have specified is displayed on the Tools menu.
Note: You cannot use the Configure Tools dialog box to extend the toolchain in the
IDE. If you intend to add an external tool to the standard build toolchain, see Extending
the toolchain, page 119.
AFE1_AFE2-1:1
The development environment
where name is the name of the command or batch file you want to run.
The /C option terminates the shell after execution, to allow the IDE to detect when the
tool has finished.
39
AFE1_AFE2-1:1
Reference information on the IDE
To send an argument to the external editor, type the argument in the Arguments field.
For example, type $FILE_PATH$ to start the editor with the active file (in editor, project,
or messages windows).
3 Click OK.
When you double-click a filename in the Workspace window, the file is opened by the
external editor.
Variables can be used in the arguments. For more information about the argument
variables that are available, see Argument variables, page 88.
AFE1_AFE2-1:1
The development environment
41
AFE1_AFE2-1:1
Reference information on the IDE
Menu bar
The menu bar contains:
File
Commands for opening source and project files, saving and printing, and exiting
from the IDE.
Edit
Commands for editing and searching in editor windows and for enabling and
disabling breakpoints in C-SPY.
View
Commands for opening windows and controlling which toolbars to display.
AFE1_AFE2-1:1
The development environment
Project
Commands for adding files to a project, creating groups, and running the IAR
tools on the current project.
Simulator
Commands specific for the C-SPY simulator. This menu is only available when
you have selected the simulator driver in the Options dialog box.
C-SPY hardware driver
Commands specific for the C-SPY hardware debugger driver you are using, in
other words, the C-SPY driver that you have selected in the Options dialog box.
For some IAR Embedded Workbench products, the name of the menu reflects
the name of the C-SPY driver you are using and for others, the name of the menu
is Emulator.
Tools
User-configurable menu to which you can add tools for use with the IDE.
Window
Commands for manipulating the IDE windows and changing their arrangement
on the screen.
Help
Commands that provide help about the IDE.
For more information about each menu, see Menus, page 193.
Toolbar
The buttons on the IDE toolbar provide shortcuts for the most useful commands on the
IDE menus, and a text box for typing a string to do a quick search. For information about
how to add and remove buttons on the toolbars, see Using and customizing the IDE, page
26.
For a description of any button, point to it with the mouse pointer. When a command is
not available, the corresponding toolbar button is dimmed, and you will not be able to
click it.
The toolbars are dockable—drag and drop to rearrange them.
43
AFE1_AFE2-1:1
Reference information on the IDE
This figure shows the menu commands corresponding to each of the toolbar buttons:
Note: When you start C-SPY, the Download and Debug button will change to a Make
and Restart Debugger button , and the Debug without Downloading will change
to a Restart Debugger button .
Toolbar Options
Click the Toolbars Options button to open the Toolbars Options menu.
Context menu
This context menu is available by right-clicking a toolbar button when the Customize
dialog box is open. For information about how to open this dialog box, see Customize
dialog box, page 47.
AFE1_AFE2-1:1
The development environment
Button Appearance
Displays the Button Appearance dialog box, see Button Appearance dialog
box, page 49.
Image
Displays the button only as an icon.
Text
Displays the button only as text.
Image and Text
Displays the button both as an icon and as text.
Start Group
Inserts a delimiter to the left of the button.
45
AFE1_AFE2-1:1
Reference information on the IDE
Customize
Displays the Customize dialog box, see Customize dialog box, page 47.
Status bar
The status bar at the bottom of the window can be enabled from the View menu.
AFE1_AFE2-1:1
The development environment
These are the options on the Commands page of the Customize dialog box:
Categories
Lists the menus in the IDE. Select a menu name to make the commands on that menu
available for adding as buttons to a toolbar. Select New Menu to add a custom
drop-down menu to a toolbar.
Commands
Lists menu commands that can be dragged to one of the toolbars and inserted as buttons.
If New Menu is the selected Category, the command New Menu can be dragged to a
47
AFE1_AFE2-1:1
Reference information on the IDE
toolbar to add a custom drop-down menu to the toolbar. Commands from the
Commands list can then be dragged to populate the custom menu.
These are the options on the Options page of the Customize dialog box:
Large Icons
Increases the size of the buttons on the toolbars.
AFE1_AFE2-1:1
The development environment
These are the options on the Toolbars page of the Customize dialog box:
Toolbars
Select/deselect a toolbar to show/hide it in the main IDE window. The menu bar cannot
be hidden.
Reset
Restores the selected toolbar to its default appearance.
Reset All
This button is disabled.
Use this dialog box to change the display name of a toolbar button.
Image only
This option has no effect.
Text only
Enables the text box Button text.
49
AFE1_AFE2-1:1
Reference information on the IDE
New
This button is disabled.
Edit
This button is disabled.
Button text
The display name of the toolbar button. Edit the text to change the name.
This window displays any messages output by user-defined tools in the Tools menu,
provided that you have selected the Redirect to Output Window option in the
Configure Tools dialog box, see Configure Tools dialog box, page 81. When opened,
this window is, by default, grouped together with the other message windows.
Context menu
This context menu is available:
AFE1_AFE2-1:1
The development environment
Use this page to configure the colors and fonts used for the windows in the IDE.
Themes
A colors and fonts theme is a combination of font and color settings for the IDE
windows. Select the theme you want to use and either click OK to close the dialog box
and apply the theme, or use the buttons in the dialog box to modify the theme. On the
right-hand side of the dialog box is a preview of the settings you make. You can use one
of the predefined themes or create your own custom theme.
51
AFE1_AFE2-1:1
Reference information on the IDE
Colors
Opens the Edit Colors dialog box where you can change the colors used in the editor
window, see Edit Colors dialog box, page 54.
Fonts
Opens the Edit Fonts dialog box where you can change the fonts used in all IDE
windows, see Edit Fonts dialog box, page 55.
Reset
Restores the selected modified theme to its default setting.
AFE1_AFE2-1:1
The development environment
Duplicate
Creates a copy of the selected theme.
Remove
Deletes the selected custom theme.
Rename
Makes the name of the selected custom theme editable.
Import
Opens a standard Windows Open dialog box to let you import an XML file with a saved
colors and fonts theme.
Export
Opens a standard Windows Save dialog box to let you save a colors and fonts theme as
an XML file. Save it as a back-up or share it with colleagues.
53
AFE1_AFE2-1:1
Reference information on the IDE
Use this dialog box to customize the colors used by the selected theme in the editor
window. A preview is shown of all the changes you make.
Syntax Coloring
Select the syntactic source code element that you want to modify. The User keyword
element corresponds to the keywords that you have listed in the custom keyword file,
see Editor Setup Files options, page 65.
Color
Lists colors to choose from. Automatic matches the standard color set in the Windows
preferences. The current color has an asterisk (*) next to its name.
Type style
Select Normal, Bold, or Italic style for the selected element.
AFE1_AFE2-1:1
The development environment
Background Color
Click to set the background color of the editor window. Automatic matches the standard
color set in the Windows preferences. The current color has an asterisk (*) next to its
name.
Use this dialog box to customize the fonts used by the selected theme in the IDE
windows. Previews are shown of all the changes you make.
Proportional Font
Opens a font picker where you can select which proportional (variable-width) font and
size to use for plain text in all windows.
55
AFE1_AFE2-1:1
Reference information on the IDE
Fixed Font
Opens a font picker where you can select which fixed-width (monospace) font and size
to use for values and addresses in all windows except the editor window.
Editor Font
Opens a font picker where you can select which fixed-width (monospace) font and size
to use in the editor window.
Use this page to customize the shortcut keys used for the IDE menu commands.
Menu
Selects the menu to be edited. Any currently defined shortcut keys for the selected menu
are listed below the Menu drop-down list.
List of commands
Selects the menu command you want to configure your own shortcut keys for, from this
list of all commands available on the selected menu.
AFE1_AFE2-1:1
The development environment
Primary
Choose to:
Set
Saves the key combination in the Press shortcut key field as a shortcut for the
selected command in the list.
Clear
Removes the listed primary key combination as a shortcut for the selected
command in the list.
The new shortcut will be displayed next to the command on the menu.
Alias
Choose to:
Add
Saves the key combination in the Press shortcut key field as an alias—a hidden
shortcut—for the selected command in the list.
Clear
Removes the listed alias key combination as a shortcut for the selected
command in the list.
The new shortcut will be not displayed next to the command on the menu.
Reset All
Reverts the shortcuts for all commands to the factory settings.
57
AFE1_AFE2-1:1
Reference information on the IDE
Language options
The Language options are available by choosing Tools>Options.
Use this page to specify the language to be used in windows, menus, dialog boxes, etc.
Language
Selects the language to be used. The available languages depend on your product
package, English (United States) and Japanese (Japan).
Note: If you have installed IAR Embedded Workbench for several different toolchains
in the same directory, the IDE might be in mixed languages if the toolchains are
available in different languages.
AFE1_AFE2-1:1
The development environment
Editor options
The Editor options are available by choosing Tools>Options.
Use this page to configure the editor. For more information about the editor, see Editing,
page 139.
Tab size
Specify the width of a tab character, in terms of character spaces.
Indent size
Specify the number of spaces to be used when tabulating with an indentation.
59
AFE1_AFE2-1:1
Reference information on the IDE
File Encoding
Controls file encoding. Choose between:
Default character encoding
Selects the character encoding to be used by default for new files. Choose
between:
System (uses the Windows settings)
Western European
UTF-8
Japanese (Shift-JIS)
Chinese Simplified (GB2312)
Chinese Traditional (Big5)
Korean (Unified Hangul Code)
Arabic
Central European
Greek
Hebrew
Thai
Baltic
Russian
Vietnamese
Note that if you have specified a character encoding from the editor window
context menu, that encoding will override this setting for the specific document.
Auto-detect character encoding
Detects automatically which character encoding that should be used when you
open an existing document.
AFE1_AFE2-1:1
The development environment
EOL characters
Selects which line break character to use when editor documents are saved.
Choose between:
PC (default), Windows and DOS end of line characters.
UNIX, UNIX end of line characters.
Preserve, the same end of line character as the file had when it was opened,
either PC or UNIX. If both types or neither type are present in the opened file,
PC end of line characters are used.
Syntax highlighting
Makes the editor display the syntax of C or C++ applications in different text styles.
For more information about syntax highlighting, see Edit Colors dialog box, page 54
and Syntax coloring, page 146.
Auto indent
Makes the editor indent the new line automatically when you press Return. For C/C++
source files, click the Configure button to configure the automatic indentation, see
Configure Auto Indent dialog box, page 63. For all other text files, the new line will have
the same indentation as the previous line.
Show bookmarks
Makes the editor display a column on the left side in the editor window, with icons for
compiler errors and warnings, Find in Files results, user bookmarks, and breakpoints.
61
AFE1_AFE2-1:1
Reference information on the IDE
Show whitespaces
Toggles the display of period (.) characters for single blank spaces and arrow (—>)
characters for tabs in the editor window.
AFE1_AFE2-1:1
The development environment
Use this dialog box to configure the editor’s automatic indentation of C/C++ source
code.
For more information about indentation, see Indenting text automatically, page 141.
Body (b)
Specify the number of additional spaces used for indenting code after an opening brace,
or a statement that continues onto a second line.
Label (c)
Specify the number of additional spaces used for indenting a label, including case labels.
Sample code
This area reflects the settings made in the text boxes for indentation. All indentations are
relative to the preceding line, statement, or other syntactic structures.
63
AFE1_AFE2-1:1
Reference information on the IDE
Editor
Specify the filename and path of your external editor. A browse button is available.
Arguments
Specify any arguments to be passed to the editor.
AFE1_AFE2-1:1
The development environment
65
AFE1_AFE2-1:1
Reference information on the IDE
Use this page to specify how much syntax feedback you want in the editor, in the form
of squiggly lines and tooltips. Syntax feedback is only available if the option Generate
browse information has been selected in the Project category of the IDE Options
dialog box.
For more information, see under Editor window, page 151.
AFE1_AFE2-1:1
The development environment
Messages options
The Messages options are available by choosing Tools>Options.
67
AFE1_AFE2-1:1
Reference information on the IDE
Troubleshooting options
The Troubleshooting options are available by choosing Tools>Options.
Logging directory
Specify a location for the log files.
AFE1_AFE2-1:1
The development environment
Project options
The Project options are available by choosing Tools>Options.
Use this page to set options for the Make and Build commands.
69
AFE1_AFE2-1:1
Reference information on the IDE
Always
Always saves before Make or Build.
AFE1_AFE2-1:1
The development environment
No source browser and build status updates when the IDE is not the foreground process
Halts the source browser when the IDE is not the foreground process. This also means
that the build status is no longer updated in the Workspace window. This option is
useful, for example, if you are using a laptop and want to reduce power consumption.
Use this page to add an external analyzer to the standard build toolchain. External
analyzers operate on C/C++ source code in the user project. Header files or assembler
source code files are not analyzed.
71
AFE1_AFE2-1:1
Reference information on the IDE
For more information, see Getting started using external analyzers, page 36.
Analyzers
Lists the external analyzers that you have added to the standard build toolchain.
Move Up
Moves the analyzer you have selected in the list one step up. This order is reflected on
the Project menu.
Move Down
Moves the analyzer you have selected in the list one step down. This order is reflected
on the Project menu.
Add
Displays the External Analyzer dialog box where you can add a new analyzer to the
toolchain and configure the invocation of the analyzer.
Delete
Deletes the selected analyzer from the list of analyzers.
Edit
Displays the External Analyzer dialog box where you can edit the invocation details of
the selected analyzer.
AFE1_AFE2-1:1
The development environment
Use this dialog box to configure the invocation of the external analyzer that you want to
add to the standard build toolchain.
External analyzers operate on C/C++ source code in the user project. Header files or
assembler source code files are not analyzed.
For more information, see Getting started using external analyzers, page 36.
Name
Specify the name of the external analyzer. Note that the name must be unique.
Path
Specify the path to the analyzer’s executable file. A browse button is available.
Arguments
Specify the arguments that you want to pass to the analyzer.
Note that you can use argument variables for specifying the arguments, see Argument
variables, page 88.
73
AFE1_AFE2-1:1
Reference information on the IDE
Location
Specify a regular expression used for finding source file locations. The regular
expression is applied to each output line which will appear as text in the Build Log
window. You can double-click a line that matches the regular expression you specify.
You can use the argument variables $FILE_NAME$, $LINE_NUMBER$, and
$COLUMN_NUMBER$ to identify a filename, line number, and column number,
respectively. Choose one of the predefined expressions:
\"?$FILE_NAME$\"?:$LINE_NUMBER$
Will, for example, match a location of the form file.c:17.
\"?$FILE_NAME$\"? +$LINE_NUMBER$
Will, for example, match a location of the form file.c17.
\"?$FILE_NAME$\"?
Will, for example, match a location of the form file.c.
Alternatively, you can specify your own expression. For example, the regular expression
Msg: $FILE_NAME$ @ $LINE_NUMBER$, when applied to the output string
Msg:MySourceFile.c @ 32, will identify the file as MySourceFile.c, and the line
number as 32.
Warning
Any output line that matches this expression is tagged with the warning symbol.
For example, the expression (?i)warning(?-i): will identify any line that contains
the string warning: (regardless of case) as a warning.
Error
Any output line that matches this expression is tagged with the error symbol. Errors have
precedence over warnings.
For example, the expression (?i)error(?-i): will identify any line that contains the
string error: (regardless of case) as an error.
AFE1_AFE2-1:1
The development environment
Use this page to configure the interaction between an IAR Embedded Workbench
project and an SCC project.
Note: This is a deprecated feature which is not supported for new projects.
75
AFE1_AFE2-1:1
Reference information on the IDE
Debugger options
The Debugger options are available by choosing Tools>Options.
AFE1_AFE2-1:1
The development environment
Update intervals
Specify how often the contents of the Live Watch window and the Memory window
are updated in milliseconds.
These text boxes are only available if the C-SPY driver you are using has access to the
target system memory while executing your application.
Stack options
The Stack options are available by choosing Tools>Options or from the context menu
in the Memory window.
77
AFE1_AFE2-1:1
Reference information on the IDE
Warnings
Selects where warnings should be issued. Choose between:
Log
Warnings are issued in the Debug Log window.
Log and alert
Warnings are issued in the Debug Log window and as alert dialog boxes.
AFE1_AFE2-1:1
The development environment
Note: The Stack window does not affect the execution performance of your application,
but it might read a large amount of data to update the displayed information when the
execution stops.
Input mode
Controls how the terminal I/O input is read. Choose between:
Keyboard
Makes the input characters be read from the keyboard. Choose between:
● Buffered, Buffers input characters
● Direct, Does not buffer input characters
File
Makes the input characters be read from a file. Choose between:
● Text, Reads input characters from a text file
79
AFE1_AFE2-1:1
Reference information on the IDE
Input echoing
Determines whether to echo the input characters and where to echo them. Choose
between:
Log file
Echoes the input characters in the Terminal I/O log file. Requires that you have
enabled the option Debug>Logging>Set Terminal I/O Log File>Enable
Terminal I/O log file.
Terminal I/O window
Echoes the input characters in the Terminal I/O window.
Encoding
Determines the encoding used for terminal input and output. Choose between:
System
Uses the Windows settings.
UTF-8
Uses the UTF-8 encoding.
AFE1_AFE2-1:1
The development environment
Use this dialog box to specify a tool of your choice to add to the Tools menu, for
example Notepad:
Note: If you intend to add an external tool to the standard build toolchain, see Extending
the toolchain, page 119.
You can use variables in the arguments, which allows you to set up useful tools such as
interfacing to a command line revision control system, or running an external tool on the
selected file.
To add a command line command or batch file to the Tools menu:
1 Type or browse to the cmd.exe command shell in the Command text box.
81
AFE1_AFE2-1:1
Reference information on the IDE
2 Type the command line command or batch file name in the Argument text box as:
/C name
where name is the name of the command or batch file you want to run.
The /C option terminates the shell after execution, to allow the IDE to detect when the
tool has finished.
For an example, see Adding command line commands to the Tools menu, page 39.
New
Creates a stub for a new menu command for you to configure using this dialog box.
Delete
Removes the command selected in the Menu Content list.
Menu Content
Lists all menu commands that you have defined.
Menu Text
Specify the name of the menu command. If you add the & sign anywhere in the name,
the following letter, N in this example, will appear as the mnemonic key for this
command. The text you specify will be reflected in the Menu Content list.
Command
Specify the tool and its path, to be run when you choose the command from the menu.
A browse button is available.
Argument
Optional. Specify an argument for the command.
Initial Directory
Specify an initial working directory for the tool.
AFE1_AFE2-1:1
The development environment
Tool Available
Specifies in which context the tool should be available. Choose between:
● Always
● When debugging
● When not debugging.
This dialog box lists overrides to the default associations between the document formats
that IAR Embedded Workbench can handle and viewer applications.
Display area
This area contains these columns:
Extensions
Explicitly defined filename extensions of document formats that IAR
Embedded Workbench can handle.
Action
The viewer application that is used for opening the document type. Explorer
Default means that the default application associated with the specified type in
Windows Explorer is used.
83
AFE1_AFE2-1:1
Reference information on the IDE
New
Displays the Edit Viewer Extensions dialog box, see Edit Viewer Extensions dialog
box, page 84.
Edit
Displays the Edit Viewer Extensions dialog box, see Edit Viewer Extensions dialog
box, page 84.
Delete
Removes the association between the selected filename extensions and the viewer
application.
Import
Opens a file browser where you can locate and import a File Viewer Association file in
XML format. This file contains associations between document formats and viewer
applications. The XML structure of this file is described in the example file
FileViewerAssociationsExample.xml located in the arm\src\ide\ directory in
your product installation.
Export
Displays a standard Save As dialog box to let you save the current associations between
document formats and viewer applications in the Configure Viewers dialog box to a file
in XML format.
Use this dialog box to specify how to open a new document type or edit the setting for
an existing document type.
AFE1_AFE2-1:1
The development environment
Action
Selects how to open documents with the filename extension specified in the Filename
extensions text box. Choose between:
Built-in text editor
Opens all documents of the specified type with the IAR Embedded Workbench
text editor.
Use file explorer associations
Opens all documents of the specified type with the default application
associated with the specified type in Windows Explorer.
Command line
Opens all documents of the specified type with the viewer application you type
or browse your way to. You can give any command line options you would like
to the tool, for instance, type $FILE_PATH$ after the path to the viewer
application to start the viewer with the active file (in editor, project, or messages
windows).
Use this dialog box to customize the filename extensions recognized by the build tools.
This is useful if you have many source files with different filename extensions.
Toolchain
Lists the toolchains for which you have an IAR Embedded Workbench installed on your
host computer. Select the toolchain you want to customize filename extensions for.
85
AFE1_AFE2-1:1
Reference information on the IDE
Edit
Displays the Filename Extension Overrides dialog box, see Filename Extension
Overrides dialog box, page 86.
This dialog box lists filename extensions recognized by the build tools.
Display area
This area contains these columns:
Tool
The available tools in the build chain.
Factory Setting
The filename extensions recognized by default by the build tool.
Override
The filename extensions recognized by the build tool if there are overrides to the
default setting.
Edit
Displays the Edit Filename Extensions dialog box for the selected tool.
AFE1_AFE2-1:1
The development environment
This dialog box lists the filename extensions recognized by the IDE and lets you add
new filename extensions.
Factory setting
Lists the filename extensions recognized by default.
Override
Specify the filename extensions you want to be recognized. Extensions can be separated
by commas or semicolons, and should include the leading period.
This dialog box lists the version number of your IAR Embedded Workbench product
installation and the shared components.
Note: The initial digit of the version number of the shared components (8 in this figure)
is reflected by the default installation directory x:\Program Files\IAR
Systems\Embedded Workbench 8.n\.
87
AFE1_AFE2-1:1
Reference information on the IDE
Details
Opens a dialog box which lists the version numbers of the various components part of
your product installation.
Argument variables
You can use argument variables for paths and arguments, for example when you specify
include paths in the Options dialog box or whenever there is a need for a macro-like
expansion that depends on the current context, for example in arguments to tools. You
can use a wide range of predefined argument variables as well as create your own, see
Configure Custom Argument Variables dialog box, page 90. These are the predefined
argument variables:
Variable Description
$COMPILER_ARGS$ All compiler options except for the filename that is used when
compiling using the compiler. Note that this argument variable is
restricted to the Arguments text box in the External Analyzer
dialog box.
$CONFIG_NAME$ The name of the current build configuration, for example Debug or
Release.
$CUR_DIR$ Current directory
$CUR_LINE$ Current line
$DATE$ Today’s date, formatted according to the current locale. Note that
this might make the variable unsuited for use in file paths.
$EW_DIR$ Top directory of IAR Embedded Workbench, for example
c:\Program Files\IAR Systems\Embedded Workbench
N.n
$EXE_DIR$ Directory for executable output
$FILE_BNAME$ Filename without extension
$FILE_BPATH$ Full path without extension
$FILE_DIR$ Directory of active file, no filename
$FILE_FNAME$ Filename of active file without path
$FILE_PATH$ Full path of active file (in editor, project, or message window)
$LIST_DIR$ Directory for list output
$OBJ_DIR$ Directory for object output
$PROJ_DIR$ Project directory
$PROJ_FNAME$ Project filename without path
Table 3: Argument variables
AFE1_AFE2-1:1
The development environment
Variable Description
$PROJ_PATH$ Full path of project file
$TARGET_DIR$ Directory of primary output file
$TARGET_BNAME$ Filename without path of primary output file and without extension
$TARGET_BPATH$ Full path of primary output file without extension
$TARGET_FNAME$ Filename without path of primary output file
$TARGET_PATH$ Full path of primary output file
$TOOLKIT_DIR$ Directory of the active product, for example c:\Program
Files\IAR Systems\Embedded Workbench N.n\arm
$USER_NAME$ Your host login name
$WS_DIR$ The active workspace directory (only available in the IDE, not when
using iarbuild.exe or cspybat.exe)
$_ENVVAR_$ The Windows environment variable ENVVAR. Any name within $_
and _$ will be expanded to that system environment variable.
$MY_CUSTOM_VAR$ Your own argument variable, see Configure Custom Argument Variables
dialog box, page 90. Any name within $ and $ will be expanded to the
value you have defined.
Table 3: Argument variables (Continued)
Argument variables can also be used on some pages in the IDE Options dialog box, see
Tools menu, page 210.
89
AFE1_AFE2-1:1
Reference information on the IDE
Use this dialog box to define and edit your own custom argument variables. Typically,
this can be useful if you install a third-party product and want to specify its include
directory by using argument variables. Custom argument variables can also be used for
simplifying references to files that you want to be part of your project.
Custom argument variables have one of two different scopes:
● Workspace-local variables, which are associated with a specific workspace and can
only be seen by the workspace that was loaded when the variables were created.
● Global variables, which are available for use in all workspaces
You can organize your variables in named groups.
AFE1_AFE2-1:1
The development environment
Global
● Only variables that are defined as global are visible in the display area—all
these variables can be edited or removed.
● Groups of variables as well as individual variables can be added or imported
to the global level.
● Global variables are stored in the file global.custom_argvars in a
specific directory, see Files for global settings, page 189.
Note that when you rely on custom argument variables in the build tool settings, some
of the information needed for a project to build properly might now be in a
.custom_argvars file. You should therefore consider version-controlling your custom
argument file (workspace-local and global), and whether to document the need for using
these variables.
Expand/Collapse All
Expands or collapses the view of the variables.
New Group
Opens the New Group dialog box where you can specify a name for a new group. When
you click OK, the group is created and appears in the list of custom argument variables.
Add Variable
Opens the Add Variables dialog box where you can specify a name and value of a new
variable to the group you have selected. When you click OK, the variable is created and
appears in the list of custom argument variables.
Note that you can also add variables by importing previously defined variables. See
Import below.
91
AFE1_AFE2-1:1
Reference information on the IDE
Edit Variable
Opens the Edit Variables dialog box where you can edit the name and value of a
selected variable. When you click OK, the variable is created and appears in the list of
custom argument variables.
Delete
Deletes the selected group or variable.
Import
Opens a file browser where you can locate a Workspace.custom_argvars file. The
file can contain variables already defined and associated with another workspace or be
a file created when installing a third-party product.
Use this dialog box to manage CMSIS software packs and example projects.
For more information, see:
● Installing a CMSIS-Pack software pack, page 104
● Using CMSIS-Pack support in IAR Embedded Workbench, page 104
● Working with example projects, page 27, specifically the procedure To use a
CMSIS-Pack example project
AFE1_AFE2-1:1
The development environment
For information about the views, buttons, and menu commands available in this dialog
box, press F1 or click the question mark icon to display the online help. The online help
system is context-sensitive, which means that depending on which view is in focus,
different help topics are displayed.
93
AFE1_AFE2-1:1
Reference information on the IDE
AFE1_AFE2-1:1
Project management
● Introduction to managing projects
● Managing projects
95
AFE1_AFE2-1:1
Introduction to managing projects
modules. You create workspaces and let them contain one or several projects. Files can
be organized in file groups, and options can be set on all levels—project, group, or file.
Changes are tracked so that a request for rebuild will retranslate all required modules,
making sure that no executable files contain out-of-date modules.
These are some additional features of the IDE:
● Project templates to create a project that can be built and executed for a smooth
development startup
● Hierarchical project representation
● Source browser with an hierarchical symbol presentation
● Options can be set globally, on groups of source files, or on individual source files
● The Make command automatically detects changes and performs only the required
operations
● Project connection to set up a connection between IAR Embedded Workbench and
an external tool
● Text-based project files
● Custom Build utility to expand the standard toolchain in an easy way
● Command line build with the project file as input.
AFE1_AFE2-1:1
Project management
97
AFE1_AFE2-1:1
Introduction to managing projects
Each workspace you define can contain one or more projects, and each project must be
part of at least one workspace.
Consider this example: two related applications—for instance A and B—are developed,
requiring one development team each (team A and B). Because the two applications are
related, they can share parts of the source code between them. The following project
model can be applied:
● Three projects—one for each application, and one for the common source code
● Two workspaces—one for team A and one for team B.
Collecting the common sources in a library project (compiled but not linked object code)
is both convenient and efficient, to avoid having to compile it unnecessarily. This figure
illustrates this example:
AFE1_AFE2-1:1
Project management
Additional build configurations might be useful, for instance, if you intend to use the
application on different target devices. The application is the same, but hardware-related
parts of the code differ. Thus, depending on which target device you intend to build for,
you can exclude some source files from the build configuration. These build
configurations might fulfill these requirements for Project A:
● Project A - Device 1:Release
● Project A - Device 1:Debug
● Project A - Device 2:Release
● Project A - Device 2:Debug
Groups
Normally, projects contain hundreds of files that are logically related. You can define
each project to contain one or more groups, in which you can collect related source files.
You can also define multiple levels of subgroups to achieve a logical hierarchy. By
default, each group is present in all build configurations of the project, but you can also
specify a group to be excluded from a particular build configuration.
99
AFE1_AFE2-1:1
Managing projects
Paths to files that are part of the project file are absolute if the files are located on
different drives.
● Workspace files
For files located on the same drive as the workspace file, the path is relative to
$PROJ_DIR$.
For files located on another drive than the workspace file, the path is absolute.
● Debug files
If your debug image file contains debug information, any paths in the file that refer
to source files are absolute.
Managing projects
These tasks are covered:
● Creating and managing a workspace and its projects
● Viewing the workspace and its projects
● Interacting with Subversion
AFE1_AFE2-1:1
Project management
Note: You do not have to use the same toolchain for the new build configuration as for
other build configurations in the same project, and it might not be necessary for you to
perform all of these steps and not in this order.
101
AFE1_AFE2-1:1
Managing projects
The File menu provides commands for creating workspaces. The Project menu
provides commands for creating projects, adding files to a project, creating groups,
specifying project options, and running the IAR development tools on the current
projects.
For each file that has been built, an Output folder icon appears, containing generated
files, such as object files and list files. The latter is only generated if the list file option
is enabled. The Output folder related to the project node contains generated files related
to the whole project, such as the executable file and the linker map file (if the list file
option is enabled).
Also, any included header files will appear, showing dependencies at a glance.
2 To display the project with a different build configuration, choose that build
configuration from the drop-down list at the top of the Workspace window.
The project and build configuration you have selected are displayed highlighted in the
Workspace window. It is the project and build configuration that you select from the
drop-down list that are built when you build your application.
3 To display an overview of all projects in the workspace, click the Overview tab at the
bottom of the Workspace window.
AFE1_AFE2-1:1
Project management
The current selection in the Build Configuration drop-down list is also highlighted
when an overview of the workspace is displayed.
103
AFE1_AFE2-1:1
Managing projects
AFE1_AFE2-1:1
Project management
3 Save your project using the Save As dialog box that is displayed. Note that the project
must be saved in a different directory than the workspace you are using.
4 In the Select device dialog box that is displayed, select your device and click OK.
105
AFE1_AFE2-1:1
Managing projects
5 The CMSIS Manager dialog box is now displayed. Use this dialog box to select
prebuilt CMSIS-Pack software components and example projects that are available for
your device. For more information, see CMSIS Manager dialog box, page 92. See also
Working with example projects, page 27.
AFE1_AFE2-1:1
Project management
6 In the Components view, select the software components that you need.
107
AFE1_AFE2-1:1
Reference information on managing projects
Workspace window
The Workspace window is available from the View menu.
Use this window to access your projects and files during the application development.
Drop-down list
At the top of the window there is a drop-down list where you can choose a build
configuration to display in the window for a specific project.
AFE1_AFE2-1:1
Project management
The Files column displays the name of the current workspace and a tree representation
of the projects, groups and files included in the workspace. One or more of these icons
are displayed:
Workspace
Project
Project with multi-file compilation
Group of files
Group excluded from the build
Group of files, part of multi-file compilation
Group of files, part of multi-file compilation, but excluded from the build
Object file or library
Assembler source file
C source file
C++ source file
Source file excluded from the build
Header file
Text file
HTML text file
Control file, for example the linker configuration file
IDE internal file
Other file
The column that contains status information about option overrides can have one of
three icons for each level in the project:
109
AFE1_AFE2-1:1
Reference information on managing projects
The column contains status information about version control, if this is enabled. For
information about the various icons, see Subversion states, page 118.
Use the tabs at the bottom of the window to choose which project to display.
Alternatively, you can choose to display an overview of the entire workspace.
For more information about project management and using the Workspace window, see
the Introduction to managing projects, page 95.
Context menu
This context menu is available:
AFE1_AFE2-1:1
Project management
Compile
Compiles or assembles the currently active file as appropriate. You can choose
the file either by selecting it in the Workspace window, or by selecting the
editor window containing the file you want to compile.
Rebuild All
Recompiles and relinks all files in the selected build configuration.
Clean
Deletes intermediate files.
C-STAT Static Analysis>Analyze Project
Makes C-STAT analyze the selected project. For more information about
C-STAT, see the C-STAT® Static Analysis Guide.
C-STAT Static Analysis>Analyze File(s)
Makes C-STAT analyze the selected file(s). For more information about
C-STAT, see the C-STAT® Static Analysis Guide.
C-STAT Static Analysis>Clear Analysis Results
Makes C-STAT clear the analysis information for previously performed
analyses. For more information about C-STAT, see the C-STAT® Static Analysis
Guide.
C-STAT Static Analysis>Generate HTML Summary
Shows a standard Save As dialog box where you can select the destination for a
report summary in HTML and then create it. For more information about
C-STAT, see the C-STAT® Static Analysis Guide.
C-STAT Static Analysis>Generate Full HTML Report
Shows a standard Save As dialog box where you can select the destination for a
full report in HTML and create it. For more information about C-STAT, see the
C-STAT® Static Analysis Guide.
Stop Build
Stops the current build operation.
Add>Add Files
Displays a dialog box where you can add files to the project.
Add>Add filename
Adds the indicated file to the project. This command is only available if there is
an open file in the editor.
111
AFE1_AFE2-1:1
Reference information on managing projects
Add>Add Group
Displays the Add Group dialog box where you can add new groups to the
project. For more information about groups, see Groups, page 99.
Remove
Removes selected items from the Workspace window.
Rename
Displays the Rename Group dialog box where you can rename a group. For
more information about groups, see Groups, page 99.
Version Control System
Opens a submenu with commands for source code control, see Version Control
System menu for Subversion, page 116.
Open Containing Folder
Opens the File Explorer that displays the directory where the selected file
resides.
File Properties
Displays a standard File Properties dialog box for the selected file.
Set as Active
Sets the selected project in the overview display to be the active project. It is the
active project that will be built when the Make command is executed.
AFE1_AFE2-1:1
Project management
Use this dialog box to create a new project based on a template project. Template
projects are available for C/C++ applications, assembler applications, and library
projects. You can also create your own template projects.
Tool chain
Selects the target to build for. If you have several versions of IAR Embedded Workbench
for different targets installed on your host computer, the drop-down list might contain
some or all of these targets.
Project templates
Select a template to base the new project on, from this list of available template projects.
Description
A description of the currently selected template.
113
AFE1_AFE2-1:1
Reference information on managing projects
Use this dialog box to define new build configurations for the selected project—either
entirely new, or based on a previous project.
Configurations
Lists existing configurations, which can be used as templates for new configurations.
New
Displays a dialog box where you can define new build configurations, see New
Configuration dialog box, page 115.
Remove
Removes the configuration that is selected in the Configurations list.
AFE1_AFE2-1:1
Project management
Use this dialog box to define new build configurations—either entirely new, or based on
any currently defined configuration.
Name
Type the name of the build configuration.
Tool chain
Specify the target to build for. If you have several versions of IAR Embedded
Workbench for different targets installed on your host computer, the drop-down list
might contain some or all of these targets.
Based on configuration
Selects a currently defined build configuration to base the new configuration on. The
new configuration will inherit the project settings and information about the factory
settings from the old configuration. If you select None, the new configuration will be
based strictly on the factory settings.
Factory settings
Select the default factory settings that you want to apply to your new build
configuration. These factory settings will be used by your project if you click the
Factory Settings button in the Options dialog box.
Choose between:
Debug, Factory settings suitable for a debug build configuration.
Release, Factory settings suitable for a release build configuration.
115
AFE1_AFE2-1:1
Reference information on managing projects
Use this dialog box to set up a project connection between IAR Embedded Workbench
and an external tool. This can, for example, be useful if you want IAR Embedded
Workbench to build source code files provided by the external tool. The source files will
automatically be added to your project. If the set of files changes, the new set of files
will automatically be used when the project is built in IAR Embedded Workbench.
To disable support for this, see Project options, page 69.
Connect using
Chooses the external tool that you want to set up a connection with.
OK
Displays a dialog box where you specify the connection.
For more information about interacting with an external version control system, see The
IDE interacting with version control systems, page 100.
AFE1_AFE2-1:1
Project management
Menu commands
These commands are available for Subversion:
Commit
Displays Tortoise’s Commit dialog box for the selected file(s).
Add
Displays Tortoise’s Add dialog box for the selected file(s).
Revert
Displays Tortoise’s Revert dialog box for the selected file(s).
Update
Opens Tortoise’s Update window for the selected file(s).
Diff
Opens Tortoise’s Diff window for the selected file(s).
Log
Opens Tortoise’s Log window for the selected file(s).
Properties
Displays information available in the version control system for the selected file.
Refresh
Updates the version control system display status for all files that are part of the
project. This command is always enabled for all projects under the version
control system.
Connect Project to Subversion
Checks whether svn.exe and TortoiseProc.exe are in the path and then
enables the connection between the IAR Embedded Workbench project and an
existing checked-out working copy. After this connection has been created, a
special column that contains status information appears in the Workspace
window. Note that you must check out the source files from outside the IDE.
Disconnect Project from Subversion
Removes the connection between the selected IAR Embedded Workbench
project and Subversion. The column in the Workspace window that contains
SVN status information will no longer be visible for that project.
117
AFE1_AFE2-1:1
Reference information on managing projects
Subversion states
Each Subversion-controlled file can be in one of several states.
(blue A) Added.
(red C) Conflicted.
(red D) Deleted.
(red I) Ignored.
(blank) Not modified.
(red M) Modified.
(red R) Replaced.
(gray X) An unversioned directory created by an external definition.
(gray question Item is not under version control.
mark)
(black exclamation Item is missing—removed by a non-SVN command—or
mark) incomplete.
(red tilde) Item obstructed by an item of a different type.
Note: The version control system in the IAR Embedded Workbench IDE depends on the
information provided by Subversion. If Subversion provides incorrect or incomplete
information about the states, the IDE might display incorrect symbols.
AFE1_AFE2-1:1
Building projects
● Introduction to building projects
● Building a project
119
AFE1_AFE2-1:1
Building a project
between the external tool and its input files and generated output files is similar to the
relation between the C/C++ Compiler, c files, h files, and o files. For more information
about custom build options, see Custom build options, page 255.
You specify filename extensions of the files used as input to the external tool. If the input
file has changed since you last built your project, the external tool is executed—just as
the compiler executes if a c file has changed. In the same way, any changes in additional
input files (for instance, include files) are detected.
You must specify the name of the external tool. You can also specify any necessary
command line options needed by the external tool, and the name of the output files
generated by the external tool. Note that you can use argument variables for some of the
file information.
You can specify custom build options to any level in the project tree. The options you
specify are inherited by any sub-level in the project tree.
Building a project
These tasks are covered:
● Setting project options using the Options dialog box
● Building your project
● Correcting errors found during build
● Using pre- and post-build actions
● Building multiple configurations in a batch
● Building from the command line
● Adding an external tool
AFE1_AFE2-1:1
Building projects
By default, the IDE creates two build configurations when a project is created—Debug
and Release. Every build configuration has its own project settings, which are
independent of the other configurations.
For example, a configuration that is used for debugging would not be highly optimized,
and would produce output that suits the debugging. Conversely, a configuration for
building the final application would be highly optimized, and produce output that suits
a flash or PROM programmer.
121
AFE1_AFE2-1:1
Building a project
2 Decide which level you want to set the options on—the entire project, groups of files,
or for an individual file. Select that level in the Workspace window (in this example,
the project level) and choose Options from the context menu to display the Options
dialog box.
Note: There is one important restriction on setting options. If you set an option on group
or file level (group or file level override), no options on higher levels that operate on files
will affect that group or file.
3 The Options dialog box provides options for the build tools—a category for each build
tool.
Options in the General Options, Linker, and Debugger categories can only be set on
project level because they affect the entire build configuration, and cannot be set for
individual groups and files. However, the options in the other categories can be set for
the project, a group of files, or an individual file.
AFE1_AFE2-1:1
Building projects
4 Select a category from the Category list to select which building tool to set options for.
Which tools that are available in the Category list depends on which tools are included
in your product. When you select a category, one or more pages containing options for
that component are displayed.
5 Click the tab that corresponds to the type of options you want to view or change. Make
the appropriate settings. Some hints:
● To override project level settings, select the required item—for instance a specific
group of files or an individual file—and select the option Override inherited
settings.
The new settings will affect all members of that group, that is, files and any groups
of files. Your local overrides are indicated with a checkmark in a separate column in
the Workspace window.
123
AFE1_AFE2-1:1
Building a project
● Use the Extra Options page to specify options that are only available as command
line options and are not in the IDE.
● To restore all settings to the default factory settings, click the Factory Settings
button, which is available for all categories except General Options and Custom
Build. Note that two sets of factory settings are available—Debug and Release.
Which one is used depends on your build configuration, see New Configuration
dialog box, page 115.
● If you add a source file with a non-recognized filename extension to your project,
you cannot set options on that source file. However, you can add support for
additional filename extensions. For more information, see Filename Extensions
dialog box, page 85.
AFE1_AFE2-1:1
Building projects
125
AFE1_AFE2-1:1
Building a project
6 Set the Build order to Run after linking and click OK.
7 Every time you build the project, timestamp.c will be recompiled and the correct
timestamp will end up in the binary file.
This command copies the file from the network drive to your project directory.
4 In the Output files box, specify localcopy.c.
5 In the Input files box, specify \\my-network-drive\remotefile.c.
6 Let the Build order setting remain Automatic (based on input and output), and click
OK.
7 Every time you use the Make command, and localcopy.c does not exist or is older
than remotefile.c, the build action will copy the file from the network drive to your
project directory.
AFE1_AFE2-1:1
Building projects
For more information about the Batch Build dialog box, see Batch Build dialog box,
page 132.
For reference information about the invocation syntax, see iarbuild.exe—the IAR
Command Line Build Utility, page 134.
1 Add the file you want to work with to your project, for example myFile.lex.
2 Select this file in the Workspace window and choose Project>Options. Select
Custom Build from the list of categories.
3 In the Filename extensions field, type the filename extension .lex. Remember to
specify the leading period (.).
4 In the Command line field, type the command line for executing the external tool, for
example:
flex $FILE_PATH$ -o$FILE_BNAME$.c
Note the usage of argument variables and specifically the use of $FILE_BNAME$ which
gives the base name of the input file, in this example appended with the c extension to
provide a C source file in the same directory as the input file foo.lex. For more
information about these variables, see Argument variables, page 88.
5 In the Output files field, describe the output files that are relevant for the build. In this
example, the tool Flex would generate two files—one source file and one header file.
The text in the Output files text box for these two files would look like this:
127
AFE1_AFE2-1:1
Reference information on building
$FILE_BPATH$.c
$FILE_BPATH$.h
6 If the external tool uses any additional files during the build, these should be added in
the Additional input files field, for instance:
$TOOLKIT_DIR$\inc\stdio.h
This is important, because if the dependency files change, the conditions will no longer
be the same and the need for a rebuild is detected.
7 Click OK.
8 To build your application, choose Project>Make.
AFE1_AFE2-1:1
Building projects
Category
Selects the build tool you want to set options for. The available categories will depend
on the tools installed in your IAR Embedded Workbench IDE, and will typically
include:
● General options
● Static Analysis, see the C-STAT® Static Analysis Guide for more information about
these options
● Runtime Checking, see the C-SPY® Debugging Guide for Arm for more
information about these options
● C/C++ Compiler
● Assembler
129
AFE1_AFE2-1:1
Reference information on building
Factory Settings
Restores all settings to the default factory settings. Note that this option is not available
for all categories.
Build window
The Build window is available by choosing View>Messages.
This window displays the messages generated when building a build configuration.
When opened, the window is, by default, grouped together with the other message
windows. Double-click a message in the Build window to open the appropriate file for
editing, with the insertion point at the correct position.
AFE1_AFE2-1:1
Building projects
Context menu
This context menu is available:
131
AFE1_AFE2-1:1
Reference information on building
This dialog box lists all defined batches of build configurations. For more information,
see Building multiple configurations in a batch, page 126.
Batches
Select the batch you want to build from this list of currently defined batches of build
configurations.
Build
Give the build command you want to execute:
● Make
● Clean
● Rebuild All.
New
Displays the Edit Batch Build dialog box, where you can define new batches of build
configurations, see Edit Batch Build dialog box, page 133.
Edit
Displays the Edit Batch Build dialog box, where you can edit existing batches of build
configurations.
Delete
Removes the selected batch.
AFE1_AFE2-1:1
Building projects
Use this dialog box to create new batches of build configurations, and edit already
existing batches.
Name
Type a name for a batch that you are creating, or change the existing name (if you wish)
for a batch that you are editing.
Available configurations
Select the configurations you want to move to be included in the batch you are creating
or editing, from this list of all build configurations that belong to the workspace.
To move a build configuration from the Available configurations list to the
Configurations to build list, use the arrow buttons.
Configurations to build
Lists the build configurations that will be included in the batch you are creating or
editing. Drag the build configurations up and down to set the order between the
configurations.
133
AFE1_AFE2-1:1
Reference information on building
If you run the application from a command shell without specifying a project file, you
will get a sign-on message describing available parameters and their syntax.
If the build process was successful, the IAR Command Line Build Utility returns 0.
Otherwise it returns a non-zero number and a diagnostic message.
-build
Rebuilds and relinks all files in the specified build configuration(s).
AFE1_AFE2-1:1
Building projects
-clean
Removes any intermediate and output files.
-cstat_analyze
Analyzes the project using C-STAT and generates information about the number of
messages. For more information, see the C-STAT® Static Analysis Guide.
-cstat_clean
Deletes the C-STAT output directory for the project. For more information, see the
C-STAT® Static Analysis Guide.
-cstat_cmds
Generates the file cstatcommands.txt and check files with the selected checks for the
analysis based on the project, in the C-STAT output directory. cstatcommands.txt
contains links to the check files. For more information, see the C-STAT® Static Analysis
Guide.
-cstat_report
Generates a full report in HTML format in the C-STAT output directory, based on the
analysis. For more information, see the C-STAT® Static Analysis Guide.
-jsondb
Generates a JSON description of the project. The format is based on the compiler
database format but also contains the linking, custom, and conversion steps of the build.
Optionally, you can specify the -output option to name the output file, and the -tool
option to run a tool or set of tools. By default, the output is generated in the file
$PROJ_DIR$/config/project_jsondb.json.
The database contains entries on how to build the project on the format:
[
{
"arguments" : [ Comma-separated list of arguments],
"directory" : "The directory in which to perform the
action",
"file" : "The input file",
"output" : "The output file",
"type" : "Name of the tool"
}
]
135
AFE1_AFE2-1:1
Reference information on building
In case of multiple inputs or multiple outputs, the "output" or "file" tag is replaced
by "outputs" or "files" followed by a comma-separated list of the files:
[
{
"arguments" : [ Comma-separated list of arguments],
"directory" : "The directory in which to perform the
action",
"files" : [Comma-separated list of files],
"outputs" : [Comma-separated list of files],
"type" : "Name of the tool"
}
]
-make
Brings the specified build configuration(s) up to date by compiling, assembling, and
linking only the files that have changed since the last build. This is the default operating
mode.
-ninja
Generates a ninja build file based on the project structure. Optionally, you can specify
the -tool option to run a tool or set of tools.
-log
Specifies the level of build message logging. Choose between:
-output
-output filename
Use together with the -jsondb operating mode command to specify the name and the
location of the output file.
AFE1_AFE2-1:1
Building projects
-parallel
-parallel number
Specifies the number of parallel processes to run the compiler in to make better use of
the cores in the CPU.
-tool
-tool type|list
Use together with either the -jsondb or the -ninja operating mode command to run
a specific set of tools. Running iarbuild -tool list lists the available tool options.
For example, iarbuild MyProject.ewp -ninja Debug -tool BuildTools will
generate a ninja file with all the build tools nodes in the project.
-varfile
-varfile filename
137
AFE1_AFE2-1:1
Reference information on building
AFE1_AFE2-1:1
Editing
● Introduction to the IAR Embedded Workbench editor
● Editing a file
● Programming assistance
139
AFE1_AFE2-1:1
Editing a file
Note: If you want the generation of source browse information to halt when you change
focus from the IAR Embedded Workbench IDE to another program, make sure to enable
the No source browser and build status updates when the IDE is not the foreground
process option.
Editing a file
The editor window is where you write, view, and modify your source code.
These tasks are covered:
● Indenting text automatically
● Matching brackets and parentheses
● Splitting the editor window into panes
● Dragging text
● Code folding
AFE1_AFE2-1:1
Editing
● Word completion
● Code completion
● Parameter hint
● Using and adding code templates
● Syntax coloring
● Adding bookmarks
● Using and customizing editor commands and shortcut keys
● Displaying status information
See also:
● Programming assistance, page 147
● Using an external editor, page 39
141
AFE1_AFE2-1:1
Editing a file
The highlight remains in place as long as the insertion point is located next to the
parenthesis.
To select all text between the brackets surrounding the insertion point, choose
Edit>Match Brackets. Every time you choose Match Brackets (grow) or Match
Brackets (shrink) after that, the selection will increase or shrink, respectively, to the
next hierarchic pair of brackets.
Note: Both of these functions—automatic matching of corresponding parentheses and
selection of text between brackets—apply to (), [], {}, and <> (requires Match All
Brackets).
DRAGGING TEXT
To move text within an editor window or to copy between editor windows, select the text
and drag it to the new location.
CODE FOLDING
Sections of code can be hidden and displayed using code folding.
To collapse or expand groups of lines, click on the fold points in the fold margin:
The fold point positions are based on the hierarchical structure of the document
contents, for example, brace characters in C/C++ or the element hierarchy of an XML
file. The Toggle All Folds command (Ctrl+Alt+F) can be used for expanding (or
collapsing) all folds in the current editor window. The command is available from the
Edit menu and from the context menu in the editor window. You can enable or disable
the fold margin from Tools>Options>Editor.
WORD COMPLETION
Word completion attempts to complete the word that you have started to type, basing the
assumption on the contents of the rest of your document.
AFE1_AFE2-1:1
Editing
To make the editor complete the word that you have started to type, press
Ctrl+Alt+Space or choose Complete Word from the context menu. If the suggestion is
incorrect, repeat the command to get new suggestions.
CODE COMPLETION
By default, the editor automatically suggests completions while you type in a C/C++
source file. You can also open the code completion pop-up window manually by
pressing Ctrl+Space.
To insert a suggestion, either click it or select it with the arrow keys, and press Enter. To
close the code completion pop-up window without inserting anything, press Esc.
The suggestions come from the source browse information, and require that source
browse information is enabled and that the source file is part of a project that has been
built at least once.
Many—but not all—of the suggested completions are identified by an icon:
Class
Enumeration
Enumeration constant
Function
Macro
Namespace
Type definition
Variable
To turn off automatic code completion, choose Tools>Options>Editor and deselect the
option.
143
AFE1_AFE2-1:1
Editing a file
PARAMETER HINT
To make the editor suggest function parameters as tooltip information, start typing the
first parenthesis after a function name. A tooltip is also shown when you type a comma
in a parameter list.
When there are several overloaded versions of a function, they are all displayed:
AFE1_AFE2-1:1
Editing
Templates, add your code templates, and save the file with a new name. The syntax
for defining templates is described in the default template file.
A browse button is available for your convenience.
4 To use your new templates in your own template file, you must:
● Delete the filename in the Use Code Templates text box.
● Deselect the Use Code Templates option and click OK.
● Restart the IAR Embedded Workbench IDE.
● Choose Tools>Options>Editor>Setup Files again.
The default code template file for the selected language version of the IDE should
now be displayed in the Use Code Templates text box. Select the checkbox to enable
the template.
To insert a code template into your source code:
1 In the editor window, right-click where you want the template to be inserted and
choose Insert Template (Ctrl+Alt+V).
2 Choose a code template from the menu that appears.
If the code template requires any type of field input, as in the for loop example which
needs an end value and a count variable, an input dialog box appears.
145
AFE1_AFE2-1:1
Editing a file
SYNTAX COLORING
If the Tools>Options>Editor>Syntax highlighting option is enabled, the IAR
Embedded Workbench editor automatically recognizes the syntax of different parts of
source code, for example:
● C and C++ keywords
● C and C++ comments
● Assembler directives and comments
● Preprocessor directives
● Strings.
The different parts of source code are displayed in different text styles.
To change these styles, choose Tools>Options, and use the Colors and Fonts options.
For more information, see Colors and Fonts options, page 51.
To define your own set of keywords that should be syntax-colored
automatically:
1 In a text file, list all the keywords that you want to be automatically syntax-colored.
Separate each keyword with either a space or a new line.
2 Choose Tools>Options to open the IDE Options dialog box.
3 Open the Editor>Setup Files category.
4 Select the Use Custom Keyword File option and specify your newly created text file.
A browse button is available for your convenience.
5 Open the Colors and Fonts category and click the Colors button. Select User
Keyword in the Syntax Coloring list. Specify the color and type style of your choice.
For more information, see Colors and Fonts options, page 51.
In the editor window, type any of the keywords you listed in your keyword file—see how
the keyword is colored according to your specification.
ADDING BOOKMARKS
Use the Edit>Navigate>Toggle Bookmark command to add and remove bookmarks.
To switch between the marked locations, choose Edit>Navigate>Navigate Next
Bookmark or Navigate Previous Bookmark.
AFE1_AFE2-1:1
Editing
context menu that appears when you right-click in the editor window. For more
information about each command, see Edit menu, page 196.
There are also editor shortcut keys for:
● moving the insertion point
● scrolling text
● selecting text.
For more information about these shortcut keys, see Editor shortcut key summary, page
179.
To change the default shortcut key bindings, choose Tools>Options, and click the Key
Bindings tab. For more information, see Key Bindings options, page 56.
Programming assistance
There are several features in the editor that assist you during your software development.
This section describes various tasks related to using the editor.
These tasks are covered:
● Navigating in the insertion point history
● Navigating to a function
● Finding a definition or declaration of a symbol
● Finding references to a symbol
● Finding function calls for a selected function
● Switching between source and header files
● Displaying source browse information
● Text searching
● Accessing online help for reference information
147
AFE1_AFE2-1:1
Programming assistance
and Navigate Backward buttons (or by pressing Alt + Right Arrow or Alt +
Left Arrow).
NAVIGATING TO A FUNCTION
Click the Go to function button in the top-right corner of the editor window to list all
functions defined in the source file displayed in the window. You can then choose to
navigate directly to one of the functions by clicking it in the list. Note that the list is
refreshed when you save the file.
AFE1_AFE2-1:1
Editing
if it is already open. This command is available if the insertion point is located on any
line except an #include line.
TEXT SEARCHING
There are several standard search functions available in the editor:
● Quick search text box
● Find dialog box
● Replace dialog box
● Find in Files dialog box
● Replace in Files dialog box
● Incremental Search dialog box.
To use the Quick search text box on the toolbar:
1 Type the text you want to search for and press Enter.
2 Press Esc to stop the search. This is a quick method of searching for text in the active
editor window.
To use the Find, Replace, Find in Files, Replace in Files, and Incremental
Search functions:
1 Before you use the search commands, choose Tools>Options>Editor and make sure
the Show bookmarks option is selected.
2 Choose the appropriate search command from the Edit menu. For more information
about each search function, see Edit menu, page 196.
3 To remove the blue flag icons that have appeared in the left-hand margin, right-click in
the Find in Files window and choose Clear All from the context menu.
149
AFE1_AFE2-1:1
Reference information on the editor
AFE1_AFE2-1:1
Editing
Editor window
The editor window is opened when you open or create a text file in the IDE.
You can open one or several text files, either from the File menu, or by double-clicking
them in the Workspace window. All open files are available from the drop-down menu
at the upper right corner of the editor window. Several editor windows can be open at
the same time.
151
AFE1_AFE2-1:1
Reference information on the editor
Source code files and HTML files are displayed in editor windows. From an open
HTML document, hyperlinks to HTML files work like in an ordinary web browser. A
link to an eww workspace file opens the workspace in the IDE, and closes any currently
open workspace and the open HTML document.
When you want to print a source file, it can be useful to enable the option Show line
numbers—available by choosing Tools>Options>Editor.
The editor window is always docked, and its size and position depend on other currently
open windows.
For more information about using the editor, see Editing a file, page 140 and
Programming assistance, page 147.
Documentation comments
In addition to regular comments that start with // (in C++) or /* (in C and C++), the
editor supports documentation comments, that start with /**, /*!, /// or //!. The
editor can distinguish these documentation comments from regular comments. By
default, the editor assigns the two types of comments different colors.
Inside a documentation comment, the editor highlights doxygen-style keywords
(keywords that begin with \ or @) and by default uses a different color for them than for
the rest of the comment. The color depends on whether the keyword is identified as an
existing doxygen keyword or not. You can customize the editor’s use of colors on the
Tools>Options>Colors and Fonts page, see Colors and Fonts options, page 51.
Lines inside documentation comment blocks can be shown in tooltips and parameter
hints for variables and functions. A comment block with no doxygen-style keywords
will be shown as a concatenated text string in tooltips and parameter hints. After the
occurrence of a doxygen-style keyword, only text written after a @brief keyword will
be shown in tooltips and parameter hints.
Syntax feedback
The editor is capable of giving feedback on the code in an editor window as you type.
Code that is identified as having suspected or verified syntactic issues will be indicated
by squiggly lines. The issue might or might not be a real compiler problem.
AFE1_AFE2-1:1
Editing
If you hover over a squiggly line, a tooltip will identify the nature of the issue:
If there is a potential simple fix for the identified issue, the tooltip will suggest it. To
apply the suggested fix, choose Apply Syntax Feedback Fix from the Edit menu or the
editor window context menu.
Syntax feedback is based on source browser information and requires that the option
Generate browse information has been selected in the Tools>Options>Project
category. Syntax feedback is not available during a debugging session.
To enable or disable syntax feedback, and to configure the level of feedback provided,
see Editor Syntax Feedback options, page 66.
153
AFE1_AFE2-1:1
Reference information on the editor
Go to function
Click the Go to function button in the top right-hand corner of the editor window to list
all functions of the C or C++ editor window.
Filter the list by typing the name of the function you are looking for. Then click the name
of the function that you want to show in the editor window.
To close the list without moving the cursor from its original position in the editor
window, press Esc.
AFE1_AFE2-1:1
Editing
Context menu
This context menu is available:
The contents of this menu depend on whether the debugger is started or not, and on the
C-SPY driver you are using. Typically, additional breakpoint types might be available
on this menu. For information about available breakpoints, see the C-SPY® Debugging
Guide for Arm.
155
AFE1_AFE2-1:1
Reference information on the editor
AFE1_AFE2-1:1
Editing
157
AFE1_AFE2-1:1
Reference information on the editor
AFE1_AFE2-1:1
Editing
159
AFE1_AFE2-1:1
Reference information on the editor
Use one of these settings if the Auto-detect character encoding option could
not determine the correct encoding or if the option is deselected. For more
information about file encoding, see Editor options, page 59.
Options
Displays the IDE Options dialog box, see Tools menu, page 210.
Note that the contents of the dialog box might be different if you search in an editor
window compared to if you search in the Memory window. This screen shot reflects the
dialog box when you search in an editor window.
Find what
Specify the text to search for. Use the drop-down list to use old search strings.
When you search in the Memory window, the value you search for must be a multiple
of the display unit size. For example, when using the 2 units size in the Memory
window, the search value must be a multiple of two bytes.
Match case
Searches only for occurrences that exactly match the case of the specified text.
Otherwise, specifying int will also find INT and Int. This option is only available
when you perform the search in an editor window.
Search as hex
Searches for the specified hexadecimal value. This option is only available when you
perform the search in the Memory window.
AFE1_AFE2-1:1
Editing
Only in selection
Limits the search operation to the selected lines (when searching in an editor window)
or to the selected memory area (when searching in the Memory window). The option is
only enabled when a selection has been made before you open the dialog box.
Find Next
Searches for the next occurrence of the specified text.
Find Previous
Searches for the previous occurrence of the specified text.
Stop
Stops an ongoing search. This button is only available during a search in the Memory
window.
This window displays the output from the Edit>Find and Replace>Find in Files
command. When opened, this window is, by default, grouped together with the other
message windows.
Double-click an entry in the window to open the corresponding file with the insertion
point positioned at the correct location. That source location is highlighted with a blue
flag icon. Choose Edit>Next Error/Tag or press F4 to jump to the next in sequence.
Context menu
This context menu is available:
161
AFE1_AFE2-1:1
Reference information on the editor
Note that the contents of the dialog box are different if you search in an editor window
compared to if you search in the Memory window.
Find what
Specify the text to search for. Use the drop-down list to use old search strings.
Replace with
Specify the text to replace each found occurrence with. Use the drop-down list to use old
search strings.
Match case
Searches only for occurrences that exactly match the case of the specified text.
Otherwise, specifying int will also find INT and Int. This option is only available
when you perform the search in an editor window.
AFE1_AFE2-1:1
Editing
Search as hex
Searches for the specified hexadecimal value. This option is only available when you
perform the search in the Memory window.
Only in selection
Limits the search operation to the selected lines (when searching in an editor window)
or to the selected memory area (when searching in the Memory window). The option is
only enabled when a selection has been made before you open the dialog box.
Find next
Searches for the next occurrence of the specified text.
Replace
Replaces the searched text with the specified text.
Replace all
Replaces all occurrences of the searched text in the current editor window.
163
AFE1_AFE2-1:1
Reference information on the editor
The result of the search appears in the Find in Files message window—available from
the View menu. You can then go to each occurrence by choosing the Edit>Next
Error/Tag command, alternatively by double-clicking the messages in the Find in Files
message window. This opens the corresponding file in an editor window with the
insertion point positioned at the start of the specified text. A blue flag in the left-hand
margin indicates the line with the string you searched for.
Find what
Specify the string you want to search for, or a regular expression. Use the drop-down list
to use old search strings/expressions. You can narrow the search down with one or more
of these conditions:
Match case
Searches only for occurrences that exactly match the case of the specified text.
Otherwise, specifying int will also find INT and Int.
Match whole word
Searches only for the string when it occurs as a separate word (mnemonic &w).
Otherwise, int will also find print, sprintf and so on.
Match regular expression
Interprets the search string as a regular expression, which must follow the
regular expression syntax of the ECMAScript specification as defined by the
C++ standard for the std::regex library.
Look in
Specify which files you want to search in. Choose between:
For all projects in workspace
Searches all projects in the workspace, not just the active project.
Project files
Searches all files that you have explicitly added to your project.
Project files and user include files
Searches all files that you have explicitly added to your project and all files that
they include, except the include files in the IAR Embedded Workbench
installation directory.
Project files and all include files
Searches all project files that you have explicitly added to your project and all
files that they include.
AFE1_AFE2-1:1
Editing
Directory
Searches the directory that you specify. Recent search locations are saved in the
drop-down list. A browse button is available for your convenience.
Look in subdirectories
Searches the directory that you have specified and all its subdirectories.
File types
A filter for choosing which type of files to search—the filter applies to all Look in
settings. Choose the appropriate filter from the drop-down list. The text field is editable,
to let you add your own filters. Use the * character to indicate zero or more unknown
characters of the filters, and the ? character to indicate one unknown character.
Stop
Stops an ongoing search. This button is only available during an ongoing search.
Use this dialog box to search for a specified string in multiple text files and replace it
with another string.
165
AFE1_AFE2-1:1
Reference information on the editor
The result of the replacement appears in the Find in Files message window—available
from the View menu. You can then go to each occurrence by choosing the Edit>Next
Error/Tag command, alternatively by double-clicking the messages in the Find in Files
message window. This opens the corresponding file in an editor window with the
insertion point positioned at the start of the specified text. A blue flag in the left-hand
margin indicates the line containing the string you searched for.
Find what
Specify the string you want to search for and replace, or a regular expression. Use the
drop-down list to use old search strings/expressions. You can narrow the search down
with one or more of these conditions:
Match case
Searches only for occurrences that exactly match the case of the specified text.
Otherwise, specifying int will also find INT and Int.
Match whole word
Searches only for the string when it occurs as a separate word (mnemonic &w).
Otherwise, int will also find print, sprintf, and so on.
Match regular expression
Interprets the search string as a regular expression, which must follow the
regular expression syntax of the ECMAScript specification as defined by the
C++ standard for the std::regex library.
Replace with
Specify the string you want to replace the original string with. Use the drop-down list to
use old replace strings.
Look in
Specify which files you want to search in. Choose between:
For all projects in workspace
Searches all projects in the workspace, not just the active project.
Project files
Searches all files that you have explicitly added to your project.
Project files and user include files
Searches all files that you have explicitly added to your project and all files that
they include, except the include files in the IAR Embedded Workbench
installation directory.
AFE1_AFE2-1:1
Editing
File types
A filter for choosing which type of files to search—the filter applies to all Look in
settings. Choose the appropriate filter from the drop-down list. The text field is editable,
to let you add your own filters. Use the * character to indicate zero or more unknown
characters of the filters, and the ? character to indicate one unknown character.
Stop
Stops an ongoing search. This button is only available during an ongoing search.
Close
Closes the dialog box. An ongoing search must be stopped first.
Find Next
Finds the next occurrence of the specified search string.
Replace
Replaces the found string and finds the next occurrence of the specified search string.
Replace All
Saves all files and replaces all found strings that match the search string.
Skip file
Skips the occurrences in the current file.
167
AFE1_AFE2-1:1
Reference information on the editor
Use this dialog box to gradually fine-tune or expand the search string.
Find what
Type the string to search for. The search is performed from the location of the insertion
point—the start point. Every character you add to or remove from the search string
instantly changes the search accordingly. If you remove a character, the search starts
over again from the start point.
If a word in the editor window is selected when you open the Incremental Search
dialog box, this word will be displayed in the Find What text box.
Use the drop-down list to use old search strings.
Match case
Searches for occurrences that exactly match the case of the specified text. Otherwise,
searching for int will also find INT and Int.
Find Next
Searches for the next occurrence of the current search string. If the Find What text box
is empty when you click the Find Next button, a string to search for will automatically
be selected from the drop-down list. To search for this string, click Find Next.
Close
Closes the dialog box.
Only in selection
Limits the search operation to the selected lines. The option is only available when more
than one line has been selected before you open the dialog box.
AFE1_AFE2-1:1
Editing
Declarations window
The Declarations window is available by choosing View>Source Browser.
This window displays the result from the Go to Declaration command on the editor
window context menu.
When opened, this window is by default grouped together with the other message
windows.
To find and list declarations for a specific symbol, select a symbol in the editor window,
right-click and choose Go to Declaration from the context menu. All declarations are
listed in the Declarations window.
Double-click an entry in the window to open the corresponding file with the insertion
point positioned at the correct location. Choose Edit>Next Error/Tag or press F4 to
jump to the next in sequence.
Context menu
This context menu is available:
169
AFE1_AFE2-1:1
Reference information on the editor
This window displays the result from the Go to Definition command on the editor
window context menu, if the source browser finds more than one possible definition.
When opened, this window is by default grouped together with the other message
windows.
Double-click an entry in the window to open the corresponding file with the insertion
point positioned at the correct location. Choose Edit>Next Error/Tag or press F4 to
jump to the next entry in sequence.
Context menu
This context menu is available:
AFE1_AFE2-1:1
Editing
References window
The References window is available by choosing View>Source Browser.
This window displays the result from the Find All References commands on the editor
window context menu.
When opened, this window is by default grouped together with the other message
windows.
To find and list references for a specific symbol, select a symbol in the editor window,
right-click and choose Find All References from the context menu. All references are
listed in the References window.
Double-click an entry in the window to open the corresponding file with the insertion
point positioned at the correct location. Choose Edit>Next Error/Tag or press F4 to
jump to the next in sequence.
Context menu
This context menu is available:
171
AFE1_AFE2-1:1
Reference information on the editor
This window displays an hierarchical view in alphabetical order of all symbols defined
in the active build configuration. This means that source browse information is available
for symbols in source files and include files part of that configuration. Source browse
information is not available for symbols in linked libraries.
For more information about how to use this window, see Displaying source browse
information, page 149.
AFE1_AFE2-1:1
Editing
Base class
Class
Configuration
Enumeration
Enumeration constant
(Yellow rhomb) Field of a struct
(Purple rhomb) Function
Macro
Namespace
Template class
Template function
Type definition
Union
(Yellow rhomb) Variable
Context menu
This context menu is available in the display area:
173
AFE1_AFE2-1:1
Reference information on the editor
AFE1_AFE2-1:1
Editing
Progress bar
While the source browse information is generated for a project, a green progress bar is
displayed in the status bar of the IDE window. Clicking on this progress bar opens a
context menu with a command to open the Source Browse Log window, see Source
Browse Log window, page 175.
If the source browser encounters a fatal error, the progress bar turns red.
This window displays the output from the operation of the source browser.
175
AFE1_AFE2-1:1
Reference information on the editor
Context menu
This context menu is available:
AFE1_AFE2-1:1
Editing
This dialog box lists the header files if more than one header file is found when you
choose the Open "header.h" command on the editor window context menu and the IDE
does not have access to dependency information.
This window displays calls to or calls from a function. The window is useful for
navigating between the function calls.
To display a call graph, select a function name in the editor window or in the Source
Browser window, right-click and select either Find All Calls to or Find All Calls from
from the context menu.
Double-click an entry in the window to place the insertion point at the location of the
function call (or definition, if a call is not applicable for the entry). The editor will open
the file that contains the call if necessary.
177
AFE1_AFE2-1:1
Reference information on the editor
Display area
The display area shows the call graph for the selected function, where each line lists a
function. These columns are available:
Function Displays the call graph for the selected function—first the
selected function, followed by a list of all called or calling
functions. The functions calling the selected function are
indicated with left arrow and the functions called by the
selected function are indicated with a right arrow.
File The name of the source file.
Line The line number for the call.
Context menu
This context menu is available:
Use this dialog box to specify any field input that is required by the source code template
you insert.
Note: The figure reflects the default code template that can be used for automatically
inserting code for a for loop.
AFE1_AFE2-1:1
Editing
Text fields
Specify the required input in the text fields. Which fields that appear depends on how
the code template is defined.
Display area
The display area shows the code that would result from the code template, using the
values you submit. For more information about using code templates, see Using and
adding code templates, page 144.
179
AFE1_AFE2-1:1
Reference information on the editor
Selecting text
To select text, press Shift and the corresponding command for moving the insertion
point. In addition, this command is available:
To select Press
A column-based block Shift + Alt + Arrow key
Table 6: Editor shortcut keys for selecting text
Scrolling text
To scroll Press
Up one line. Ctrl + Up arrow
When used in the parameter hints text box,
this shortcut steps up one line through the
alternatives.
Down one line, Ctrl + Down arrow
When used in the parameter hints text box,
this shortcut steps down one line through the
alternatives.
Up one page Page Up
Down one page Page Down
Table 7: Editor shortcut keys for scrolling
Description Press
When used in the parameter hints text box, Ctrl + Enter
this shortcut inserts parameters as text in the
source code.
Bracket matching—Expand selection to next Ctrl + B
level of matching of {}, [], or ().
Bracket matching—Expand selection to next Ctrl + Alt + B
level of matching of {}, [], (), or <>.
Bracket matching—Shrink selection to next Ctrl + Shift + B
level of matching of {}, [], or ().
Bracket matching—Shrink selection to next Ctrl + Alt + Shift + B
level of matching of {}, [], (), or <>.
Change case for selected text to lower Ctrl + u
Change case for selected text to upper Ctrl + U
Table 8: Miscellaneous editor shortcut keys
AFE1_AFE2-1:1
Editing
Description Press
Complete code Ctrl + Space
Complete word Ctrl + Alt + Space
Insert template Ctrl + Alt + V
Parameter hint Ctrl + Shift + Space
Zooming Mouse wheel
Zoom in Ctrl + numeric keypad '+'
Zoom out Ctrl + numeric keypad '-'
Zoom normal Ctrl + numeric keypad '/'
Table 8: Miscellaneous editor shortcut keys (Continued)
Description Press
Scroll window line up or down Ctrl + Up
Ctrl + Down
Select a rectangular block and change its size a Shift + Alt + arrow key
line up or down, or a column left or right
Move insertion point one paragraph up or Ctrl + Alt + Up
down Ctrl + Alt + Down
Grow selection one paragraph up or down Ctrl + Shift + Alt + Up
Ctrl + Shift + Alt + Down
Move insertion point one word left or right Ctrl + Left
Ctrl + Right
Grow selection one word left or right Ctrl + Shift + Left
Ctrl + Shift + Right
Grow selection to next start or end of a word Ctrl + Shift + Alt + Left
Ctrl + Shift + Alt + Right
Move to first non-blank character of the line Home
Move to start of line Alt + Home
Select to start of the line Shift + Alt + Home
Select a rectangular block to the start or end Shift + Alt + Page Up
of page Shift + Alt + Page Down
Delete to start of next word Ctrl + Delete
Delete to start of previous word Ctrl + Backspace
Delete forward to end of line Ctrl + Shift + Delete
Table 9: Additional Scintilla shortcut keys
181
AFE1_AFE2-1:1
Reference information on the editor
Description Press
Delete backward to start of line Ctrl + Shift + Backspace
Zoom in Ctrl + Add (numeric +)
Zoom out Ctrl + Subtract (numeric –)
Restore zoom to 100% Ctrl + Divide (numeric /)
Cut current line Ctrl + L
Copy current line Ctrl + Shift + T
Delete current line Ctrl + Shift + L
Change selection to lower case Ctrl + U
Change selection to upper case Ctrl + Shift + U
Table 9: Additional Scintilla shortcut keys (Continued)
AFE1_AFE2-1:1
Part 2. Reference
information
This part contains these chapters:
● Product files
● Menu reference
● General options
● Compiler options
● Assembler options
● Linker options
183
184
Product files
● Installation directory structure
● File types
ROOT DIRECTORY
The default installation root directory is typically x:\Program Files\IAR
Systems\Embedded Workbench N.n\, where x is the drive where Microsoft
Windows is installed, and the first digit in N.n reflects the first digit in the version
number of the IAR Embedded Workbench shared components.
Note that this version number is not the same as the version number of your IAR
Embedded Workbench product. To find the version number of the IDE and the product,
see Product Info dialog box, page 87.
185
AFE1_AFE2-1:1
Installation directory structure
AFE1_AFE2-1:1
Product files
Directory Description
arm\src Contains source files for some configurable library functions and the
library source code.
For the ILINK linker, the directory also contains the source code for
ELF utilities.
arm\tutorials Contains the files used for the tutorials in the Information Center.
Table 10: The arm directory (Continued)
187
AFE1_AFE2-1:1
Various settings files
The names and locations of these directories can be changed on the page
Project>Options>General Options>Output.
AFE1_AFE2-1:1
Product files
189
AFE1_AFE2-1:1
File types
File types
The IAR development tools use the following default filename extensions to identify the
produced files and other recognized file types:
Ext. Type of file Output from Input to
a Library iarchive ILINK
asm Assembler source code Text editor Assembler
bat Windows command batch file C-SPY Windows
board Configuration file for flash loader Text editor C-SPY
c C source code Text editor Compiler
cfg Syntax coloring configuration Text editor IDE
cgx Call graph file ILINK –
chm Online help system file -- IDE
cpp C++ source code Text editor Compiler
crun C-RUN filter settings IDE IDE
cspy.bat Invocation file for cspybat C-SPY –
dat Macros for formatting of STL containers IDE IDE
dbgdt Debugger desktop settings C-SPY C-SPY
Table 12: File types
AFE1_AFE2-1:1
Product files
191
AFE1_AFE2-1:1
File types
When you run the IDE, some files are created and located in dedicated directories under
your project directory, by default $PROJ_DIR$\Debug, $PROJ_DIR$\Release,
$PROJ_DIR$\settings. None of these directories or files affect the execution of the
IDE, which means you can safely remove them if required.
AFE1_AFE2-1:1
Menu reference
● Menus
Menus
Reference information about:
● File menu
● Edit menu
● View menu
● Project menu
● Tools menu
● Window menu
● Help menu
In addition, a set of C-SPY-specific menus become available when you start the
debugger. For more information about these menus, see the C-SPY® Debugging Guide
for Arm.
File menu
The File menu provides commands for opening workspaces and source files, saving and
printing, and exiting from the IDE.
193
AFE1_AFE2-1:1
Menus
The menu also includes a numbered list of the most recently opened files and
workspaces. To open one of them, choose it from the menu.
Menu commands
These commands are available:
New File (Ctrl+N)
Creates a new text file.
New Workspace
Creates a new workspace.
Open File (Ctrl+O)
Displays an Open dialog box for selecting a text file or an HTML document to
open. See Editor window, page 151.
Open Workspace
Displays an Open Workspace dialog box for selecting a workspace file to open.
Before a new workspace is opened you will be prompted to save and close any
currently open workspaces.
Open Header/Source File (Ctrl+Shift+H)
Opens the header file or source file that corresponds to the current file, and shifts
focus from the current file to the newly opened file. This command is also
available on the context menu in the editor window.
AFE1_AFE2-1:1
Menu reference
Close
Closes the active window. You will be given the opportunity to save any files that
have been modified before closing.
Save Workspace
Saves the current workspace file.
Save Workspace As
Displays a Save Workspace As dialog box for saving the workspace with a new
name.
Close Workspace
Closes the current workspace file.
Save (Ctrl+S)
Saves the current text file or workspace file.
Save As
Displays a Save As dialog box where you can save the current file with a new
name.
Save All
Saves all open text documents and workspace files.
Page Setup
Displays a Page Setup dialog box where you can set printer options.
Print (Ctrl+P)
Displays a Print dialog box where you can print a text document.
Recent Files
Displays a submenu from where you can quickly open the most recently opened
text documents.
Recent Workspaces
Displays a submenu from where you can quickly open the most recently opened
workspace files.
Exit
Exits from the IDE. You will be asked whether to save any changes to text files
before closing them. Changes to the project are saved automatically.
195
AFE1_AFE2-1:1
Menus
Edit menu
The Edit menu provides commands for editing and searching.
Menu commands
These commands are available:
Undo (Ctrl+Z)
Undoes the last edit made to the current editor window.
Redo (Ctrl+Y)
Redoes the last Undo in the current editor window. You can undo and redo an
unlimited number of edits independently in each editor window.
Cut (Ctrl+X)
The standard Windows command for cutting text in editor windows and text
boxes.
Copy (Ctrl+C)
The standard Windows command for copying text in editor windows and text
boxes.
AFE1_AFE2-1:1
Menu reference
Paste (Ctrl+V)
The standard Windows command for pasting text in editor windows and text
boxes.
Select All (Ctrl+A)
Selects all text in the active editor window.
Find and Replace>Find (Ctrl+F)
Displays the Find dialog box where you can search for text within the current
editor window, see Find dialog box, page 160. Note that if the insertion point is
located in the Memory window when you choose the Find command, the dialog
box will contain a different set of options than otherwise. If the insertion point
is located in the Trace window when you choose the Find command, the Find
in Trace dialog box is opened—the contents of this dialog box depend on the
C-SPY driver you are using, see the C-SPY® Debugging Guide for Arm for
more information.
Find and Replace>Find Next (F3)
Finds the next occurrence of the specified string.
Find and Replace>Find Previous (Shift+F3)
Finds the previous occurrence of the specified string.
Find and Replace>Find Next (Selected) (Ctrl+F3)
Searches for the next occurrence of the currently selected text or the word
currently surrounding the insertion point.
Find and Replace>Find Previous (Selected) (Ctrl+Shift+F3)
Searches for the previous occurrence of the currently selected text or the word
currently surrounding the insertion point.
Find and Replace>Replace (Ctrl+H)
Displays a dialog box where you can search for a specified string and replace
each occurrence with another string, see Replace dialog box, page 162.
Note that if the insertion point is located in the Memory window when you
choose the Replace command, the dialog box will contain a different set of
options than otherwise.
Find and Replace>Find in Files
Displays a dialog box where you can search for a specified string in multiple text
files, see Find in Files window, page 161.
197
AFE1_AFE2-1:1
Menus
AFE1_AFE2-1:1
Menu reference
199
AFE1_AFE2-1:1
Menus
View menu
The View menu provides several commands for opening windows in the IDE. When
C-SPY is running you can also open debugger-specific windows from this menu. See
the C-SPY® Debugging Guide for Arm for information about these.
AFE1_AFE2-1:1
Menu reference
Menu commands
These commands are available:
Messages
Displays a submenu which gives access to the message windows—Build, Find
in Files, Source Browse Log, Tool Output, CMSIS-Pack Log, Debug Log—
that display messages and text output from the IAR Embedded Workbench
commands. If the window you choose from the menu is already open, it
becomes the active window.
Workspace
Opens the current Workspace window, see Workspace window, page 108.
Source Browser>Source Browser
Opens the Source Browser window, see Source Browser window, page 172.
Source Browser>References
Opens the References window, see References window, page 171.
Source Browser>Declarations
Opens the Declarations window, see Declarations window, page 169.
Source Browser>Ambiguous Definitions
Opens the Ambiguous Definitions window, see Ambiguous Definitions
window, page 170.
Source Browser>Call Graph
Opens the Call Graph window, see Call Graph window, page 177.
C-STAT>C-STAT Messages
Opens the C-STAT Messages window, see the C-STAT® Static Analysis Guide.
C-RUN>Messages
Opens the C-RUN Messages window, see the C-SPY® Debugging Guide for
Arm.
C-RUN>Messages Rules
Opens the C-RUN Messages Rules window, see the C-SPY® Debugging Guide
for Arm.
Breakpoints
Opens the Breakpoints window, see the C-SPY® Debugging Guide for Arm.
Call Stack
Opens the Call Stack window. Only available when C-SPY is running.
201
AFE1_AFE2-1:1
Menus
Watch
Opens an instance of the Watch window from a submenu. Only available when
C-SPY is running.
Live Watch
Opens the Live Watch window. Only available when C-SPY is running.
Quick Watch
Opens the Quick Watch window. Only available when C-SPY is running.
Auto
Opens the Auto window. Only available when C-SPY is running.
Locals
Opens the Locals window. Only available when C-SPY is running.
Statics
Opens the Statics window. Only available when C-SPY is running.
Memory
Opens an instance of the Memory window from a submenu. Only available
when C-SPY is running.
Registers
Displays a submenu which gives access to the Registers windows—Registers
and Register User Groups Setup. Only available when C-SPY is running.
Disassembly
Opens the Disassembly window. Only available when C-SPY is running.
Stack
Opens an instance of the Stack window from a submenu. Only available when
C-SPY is running.
Symbolic Memory
Opens the Symbolic Memory window. Only available when C-SPY is running.
Terminal I/O
Opens the Terminal I/O window. Only available when C-SPY is running.
Macros>Macro Quicklaunch
Opens the Macro Quicklaunch window. Only available when C-SPY is
running.
Macros>Macro Registration
Opens the Macro Registration window. Only available when C-SPY is
running.
AFE1_AFE2-1:1
Menu reference
Macros>Debugger Macros
Opens the Debugger Macros window. Only available when C-SPY is running.
Symbols
Opens the Symbols window. Only available when C-SPY is running.
Code Coverage
Opens the Code Coverage window. Only available when C-SPY is running.
Images
Opens the Images window. Only available when C-SPY is running.
Cores
Opens the Cores window. Only available when C-SPY is running.
Fault exception viewer
Opens the Fault exception viewer window, see the C-SPY® Debugging Guide
for Arm. This menu command is only available when C-SPY is running.
203
AFE1_AFE2-1:1
Menus
Project menu
The Project menu provides commands for working with workspaces, projects, groups,
and files, and for specifying options for the build tools, and running the tools on the
current project.
AFE1_AFE2-1:1
Menu reference
Menu commands
These commands are available:
Add Files
Displays a dialog box where you can select which files to include in the current
project.
Add Group
Displays a dialog box where you can create a new group. In the Group Name
text box, specify the name of the new group. For more information about groups,
see Groups, page 99.
Import File List
Displays a standard Open dialog box where you can import information about
files and groups from projects created using another IAR toolchain.
To import information from project files which have one of the older filename
extensions pew or prj you must first have exported the information using the
context menu command Export File List available in your current IAR
Embedded Workbench.
Add Project Connection
Displays the Add Project Connection dialog box, see Add Project Connection
dialog box, page 116.
Edit Configurations
Displays the Configurations for project dialog box, where you can define new
or remove existing build configurations. See Configurations for project dialog
box, page 114.
Remove
In the Workspace window, removes the selected item from the workspace.
Create New Project
Displays the Create New Project dialog box where you can create a new project
and add it to the workspace, see Create New Project dialog box, page 113.
Add Existing Project
Displays a standard Open dialog box where you can add an existing project to
the workspace.
Options (Alt+F7)
Displays the Options dialog box, where you can set options for the build tools,
for the selected item in the Workspace window, see Options dialog box, page
129. You can set options for the entire project, for a group of files, or for an
individual file.
205
AFE1_AFE2-1:1
Menus
AFE1_AFE2-1:1
Menu reference
207
AFE1_AFE2-1:1
Menus
AFE1_AFE2-1:1
Menu reference
CMSIS-Manager
Displays the CMSIS Manager dialog box, see CMSIS Manager dialog box,
page 92.
This menu command is only available if your target supports CMSIS-Pack.
Open Device Description File
Opens a submenu where you can choose to open a file from a list of all device
files and SFR definitions files that are in use.
Save List of Registers
Generates a list of all defined registers, including SFRs, with information about
the size, location, and access type of each register. If you are in a debug session,
the list also includes the current value of the register. This menu command is
only available when a project is loaded in the IDE.
Use this dialog box to erase one or more of the flash memories.
Display area
Each line lists the path to the flash memory device configuration file (filename extension
.flash) and the associated memory range. Select the memory you want to erase.
Buttons
These buttons are available:
Erase all
All memories listed in the dialog box are erased, regardless of individually
selected lines.
209
AFE1_AFE2-1:1
Menus
Erase
Erases the selected memories.
Cancel
Closes the dialog box.
Tools menu
The Tools menu provides commands for customizing the environment, such as changing
common fonts and shortcut keys.
It is a user-configurable menu to which you can add tools for use with IAR Embedded
Workbench. Therefore, it might look different depending on which tools you have
preconfigured to appear as menu items.
Menu Commands
These commands are available:
Options
Displays the IDE Options dialog box where you can customize the IDE. See:
● Colors and Fonts options, page 51
● Debugger options, page 76
● Editor options, page 59
● Editor Setup Files options, page 65
● External Analyzers options, page 71
● External Editor options, page 64
● Key Bindings options, page 56
● Language options, page 58
● Messages options, page 67
● Project options, page 69
● Stack options, page 77
● Terminal I/O options, page 79
AFE1_AFE2-1:1
Menu reference
211
AFE1_AFE2-1:1
Menus
Window menu
The Window menu provides commands for manipulating the IDE windows and
changing their arrangement on the screen.
The last section of the Window menu lists the currently open windows. Choose the
window you want to switch to.
Menu commands
These commands are available:
Close Document (Ctrl+W)
Closes the active editor document.
Close Window
Closes the active IDE window.
Split
Splits an editor window horizontally into two panes, which means that you can
see two parts of a file simultaneously.
Move Tab to New Vertical Editor Window
Opens a new empty window next to the current editor window and moves the
active document to the new window.
Move Tab to New Horizontal Editor Window
Opens a new empty window under the current editor window and moves the
active document to the new window.
Move Tab to the Next Window
Moves the active document in the current window to the next window.
AFE1_AFE2-1:1
Menu reference
Help menu
The Help menu provides help about IAR Embedded Workbench. From this menu you
can also find the version numbers of the user interface and of the IDE, see Product Info
dialog box, page 87.
You can also access the Information Center from the Help menu. The Information
Center is an integrated navigation system that gives easy access to the information
resources you need to get started and during your project development—tutorials,
example projects, user guides, support information, and release notes. It also provides
shortcuts to useful sections on the IAR web site.
213
AFE1_AFE2-1:1
Menus
AFE1_AFE2-1:1
General options
● Description of general options
Target
The Target options specify target-specific features for the IAR C/C++ Compiler and
Assembler.
215
AFE1_AFE2-1:1
Description of general options
Processor variant
Selects the processor variant:
Core
The processor core you are using. For a description of the available variants, see
the IAR C/C++Development Guide for Arm.
Device
The device your are using. The choice of device will automatically determine
the default linker configuration file and C-SPY® device description file. For
information about how to override the default files, see the C-SPY® Debugging
Guide for Arm.
CMSIS-Pack
The device you have selected in the CMSIS Manager dialog box. For more
information, see CMSIS Manager dialog box, page 92.
Execution mode
Shows the current execution mode for your project:
32-bit
IAR Embedded Workbench for Arm will generate and debug code for the
instruction sets T32/T and A32.
64-bit
IAR Embedded Workbench for Arm will generate and debug code for the
instruction set A64.
For more information, see Execution modes, page 25.
32-bit
The 32-bit options specify target-specific features for the IAR C/C++ Compiler and
Assembler in 32-bit mode.
AFE1_AFE2-1:1
General options
If a 64-bit device is used in 32-bit mode, it is the 64-bit page that decides the FPU
behavior, not the 32-bit page.
Byte order
Selects the byte order for your project:
Little
The lowest byte is stored at the lowest address in memory. The highest byte is
the most significant—it is stored at the highest address.
Big
The lowest address holds the most significant byte, while the highest address
holds the least significant byte. Choose between two variants of the big-endian
mode:
BE32 to make both data and code big-endian
BE8 to make data big-endian and code little-endian
FPU
Select the floating-point unit:
None (default)
The software floating-point library is used.
VFPv2
A VFP unit that conforms to architecture VFPv2.
VFPv3
A VFP unit that conforms to architecture VFPv3.
217
AFE1_AFE2-1:1
Description of general options
VFPv4
A VFP unit that conforms to architecture VFPv4.
VFPv4 single-precision
A VFP unit that conforms to the VFPv4 architecture, single-precision.
VFPv5 single-precision
A VFP unit that conforms to the VFPv5 architecture, single-precision.
VFPv5 double-precision
A VFP unit that conforms to the VFPv5 architecture, double-precision.
VFP9-S
A VFPv2 architecture that can be used with the ARM9E family of CPU cores.
Selecting this coprocessor is therefore identical to selecting the VFPv2
architecture.
By selecting a VFP coprocessor, you will override the use of the software floating-point
library for all supported floating-point operations.
D registers
Selects the number of D registers to be used by the compiler.
DSP Extension
Select this option to make the compiler use DSP instructions, if available on your device.
TrustZone
Enables TrustZone for your project, if it is available for your device.
If you have set the option Core to either Cortex-M23 or Cortex-M33, the option
TrustZone is automatically selected. If your device does not have TrustZone, deselect
the option TrustZone.
For other cores, this option is automatically deselected, unless your device has
TrustZone or if you have selected a core that always has TrustZone.
AFE1_AFE2-1:1
General options
When the option TrustZone is selected, the compiler and assembler options --cmse
can be used.
For more information about TrustZone, see the IAR C/C++Development Guide for Arm.
Mode
Specifies whether the current project is for secure or non-secure mode.
This option is automatically selected if the option TrustZone is selected.
Secure
Indicates that your project will be built for secure mode.
When you have selected the secure mode, the compiler and assembler options
--cmse are automatically set.
Non-secure
Indicates that your project will be built for non-secure mode.
64-bit
The 64-bit options specify target-specific features for the IAR C/C++ Compiler and
Assembler in 64-bit mode.
Data model
Selects the data model for your project:
ILP32
This data model has 32-bit long and pointer types, and 32-bit wchar_t type. It
uses 32-bit ELF as object and image format.
219
AFE1_AFE2-1:1
Description of general options
LP64
This data model has 64-bit long and pointer types, and 32-bit wchar_t type. It
uses 64-bit ELF as object and image format.
Note: Code generated using the ILP32 data model cannot be linked with code generated
using the LP64 data model.
FPU
Select this option to use a floating-point unit with the data model, if it is
available for your device.
Output
The Output options determine the type of output file. You can also specify the
destination directories for executable files, object files, list files, and build files.
Output file
Selects the type of the output file. Choose between:
Executable (default)
As a result of the build process, the linker will create an application (an
executable output file). When this setting is used, linker options will be available
in the Options dialog box. Before you create the output you should set the
appropriate linker options.
Library
As a result of the build process, the library builder will create a library file.
When this setting is used, library builder options will be available in the Options
dialog box, and Linker will disappear from the list of categories. Before you
create the library you can set the options.
AFE1_AFE2-1:1
General options
Output directories
Specify the paths to the destination directories. Note that incomplete paths are relative
to your project directory. You can specify:
Executables/libraries
Overrides the default directory for executable or library files. Type the name of
the directory where you want to save executable files for the project.
Object files
Overrides the default directory for object files. Type the name of the directory
where you want to save object files for the project.
List files
Overrides the default directory for list files. Type the name of the directory
where you want to save list files for the project.
Browse files
Overrides the default directory for storing source browser information. Type the
name of the directory where you want to store source browser information for
the project. To delete the contents of this directory, choose
Project>Clean Browse Information.
Build files
Overrides the default directory for build files, that is, logs, dependency files, and
other files generated by the build engine. Type the name of the directory where
you want to save build files for the project.
Note that sharing a build file directory between multiple build configurations
can increase the number of rebuilds (as the configurations might use different
command lines).
221
AFE1_AFE2-1:1
Description of general options
Library Configuration
The Library Configuration options determine which library to use.
For information about the runtime library, library configurations, the runtime
environment they provide, and the possible customizations, see IAR
C/C++Development Guide for Arm.
Library
Selects which runtime library to use. For information about available libraries, see the
IAR C/C++Development Guide for Arm.
The names of the library object file and library configuration file that actually will be
used are displayed in the Library file and Configuration file text boxes, respectively.
Configuration file
Displays the library configuration file that will be used. A library configuration file is
chosen automatically depending on the project settings. If you have chosen Custom
DLIB in the Library drop-down list, you must specify your own library configuration
file.
AFE1_AFE2-1:1
General options
CMSIS
To enable CMSIS support, use these options:
Use CMSIS
Adds the CMSIS header files to the compiler include path.
Note that if your application source code includes CMSIS header files explicitly,
then you should not use this option. This option is only available for Cortex-M
devices.
223
AFE1_AFE2-1:1
Description of general options
DSP library
Links your application with the CMSIS DSP library. This option is only
available for Cortex-M devices.
Library Options 1
The options on the Library Options 1 page select the printf and scanf formatters.
For information about the capabilities of the formatters, see the IAR
C/C++Development Guide for Arm.
Printf formatter
If you select Auto, the linker automatically chooses the appropriate formatter for
printf-related functions based on information from the compiler.
To override the default formatter for all printf-related functions, except for wprintf
variants, choose between:
● Printf formatters in the IAR DLIB Library—Full, Large, Small, and Tiny
Choose a formatter that suits the requirements of your application.
Select Enable multibyte support to make the printf formatter support multibytes.
Scanf formatter
If you select Auto, the linker automatically chooses the appropriate formatter for
scanf-related functions based on information from the compiler.
To override the default formatter for all scanf-related functions, except for wscanf
variants, choose between:
● Scanf formatters in the IAR DLIB Library—Full, Large, and Small
AFE1_AFE2-1:1
General options
Library Options 2
The options on the Library Options 2 page select the heap and locale support.
Heap selection
Select the heap to use. For more information about heaps, see the IAR
C/C++Development Guide for Arm. Choose between:
Automatic
Automatically selects the heap to use for your application.
The no-free heap is selected if your code does not contain any calls to free or
realloc. The advanced heap is selected if there are calls to memory allocation
routines in your code. Otherwise, the basic heap is selected.
Advanced heap
Selects the advanced heap.
Basic heap
Selects the basic heap.
225
AFE1_AFE2-1:1
Description of general options
No-free heap
Uses the smallest possible heap implementation. Because this heap does not
support free or realloc, it is only suitable for applications that in the startup
phase allocate heap memory for various buffers etc. This heap memory is never
deallocated.
Locale support
Select the locales that the linker will use in addition to the C locale. (Requires that you
have selected a library configuration that includes the C locale.)
AFE1_AFE2-1:1
Compiler options
● Description of compiler options
Multi-file Compilation
Before you set specific compiler options, you can decide whether you want to use
multi-file compilation, which is an optimization technique.
Multi-file Compilation
Enables multi-file compilation from the group of project files that you have selected in
the Workspace window.
227
AFE1_AFE2-1:1
Description of compiler options
You can use this option for the entire project or for individual groups of files. All C/C++
source files in such a group are compiled together using one invocation of the compiler.
This means that all files included in the selected group are compiled using the compiler
options which have been set on the group or nearest higher enclosing node which has
any options set. Any overriding compiler options on one or more files are ignored when
building, because a group compilation must use exactly one set of options.
For information about how multi-file compilation is displayed in the Workspace
window, see Workspace window, page 108.
Language 1
The Language 1 options determine which programming language to use and which
extensions to enable.
For more information about the supported languages, their dialects, and their extensions,
see the IAR C/C++Development Guide for Arm.
Language
Determines the compiler support for either C or C++. Choose between:
C (default)
Makes the compiler treat the source code as C, which means that features
specific to C++ cannot be used.
AFE1_AFE2-1:1
Compiler options
C++
Makes the compiler treat the source code as C++.
Auto
Language support is decided automatically depending on the filename extension
of the file being compiled:
c, files with this filename extension are treated as C source files.
cpp, files with this filename extension will be treated as C++ source files.
Language conformance
Controls how strictly the compiler adheres to the standard C or C++ language. Choose
between:
Standard with IAR extensions
Accepts Arm-specific keywords as extensions to the standard C or C++
language. In the IDE, this setting is enabled by default.
Standard
Disables IAR extensions, but does not adhere strictly to the C or C++ dialect you
have selected. Some very useful relaxations to C or C++ are still available.
Strict
Adheres strictly to the C or C++ dialect you have selected. This setting disables
a great number of useful extensions and relaxations to C or C++.
C dialect
Selects the dialect if C is the supported language. Choose between:
C89
Enables the C89 standard instead of Standard C.
Standard C
Enables the C18 standard, also known as Standard C. This is the default standard
used in the compiler, and it is stricter than C89. Features specific to C89 cannot
be used. In addition, choose between:
Allow VLA, allows the use of C11 variable length arrays.
C++ inline semantics, enables C++ inline semantics when compiling a
Standard C source code file.
229
AFE1_AFE2-1:1
Description of compiler options
Require prototypes
Forces the compiler to verify that all functions have proper prototypes, which
means that source code containing any of the following will generate an error:
● A function call of a function with no declaration, or with a Kernighan &
Ritchie C declaration.
● A function definition of a public function with no previous prototype
declaration.
● An indirect function call through a function pointer with a type that does not
include a prototype.
C++ options
Selects C++ language options. Choose between:
Enable exceptions
Enables exception support in the C++ language.
Enable RTTI
Enables runtime type information (RTTI) support in the C++ language.
Destroy static objects
Makes the compiler generate code to destroy C++ static variables that require
destruction at program exit.
Language 2
The Language 2 options control the use of some language extensions.
AFE1_AFE2-1:1
Compiler options
Plain 'char' is
Normally, the compiler interprets the plain char type as unsigned char. Plain 'char'
is Signed makes the compiler interpret the char type as signed char instead, for
example for compatibility with another compiler.
Note: The runtime library is compiled with unsigned plain characters. If you select the
Signed option, references to library functionality that uses unsigned plain characters
will not work.
Floating-point semantics
Controls floating-point semantics. Choose between:
Strict conformance
Makes the compiler conform strictly to the C and floating-point standards for
floating-point expressions.
Relaxed
Makes the compiler relax the language rules and perform more aggressive
optimization of floating-point expressions. This option improves performance
for floating-point expressions that fulfill these conditions:
● The expression consists of both single- and double-precision values
● The double-precision values can be converted to single precision without
loss of accuracy
● The result of the expression is converted to single precision.
Note that performing the calculation in single precision instead of double
precision might cause a loss of accuracy.
231
AFE1_AFE2-1:1
Description of compiler options
Code
The Code options control the code generation of the compiler.
For more information about these compiler options, see the IAR C/C++Development
Guide for Arm.
Processor mode
Selects the processor mode for your project:
Arm
Generates code that uses the full 32-bit instruction set.
Thumb
Generates code that uses the reduced 16-bit instruction set. Thumb code
minimizes memory usage and provides higher performance in 8/16-bit bus
environments.
Position-independence
Determines how the compiler should handle position-independent code and data:
Code and read-only data (ropi)
Generates code that uses PC-relative references to address code and read-only
data.
Read/write data (rwpi)
Generates code that uses an offset from the static base register to
address-writable data.
No dynamic read/write initialization
Disables runtime initialization of static C variables.
AFE1_AFE2-1:1
Compiler options
Security
Controls various features that increase the integrity of your application and device:
No data reads in code memory
Use this option to generate code that should run from a memory region where it
is not allowed to read data, only to execute code.
The option also affects the automatic library selection performed by the linker.
An IAR-specific ELF attribute is used for determining whether libraries
compiled with this option should be used.
This option can only be used with Armv6-M and Armv7-M cores (includes
Armv8-M, Armv8.1-M, Armv8-A and Armv8-R cores). For more information,
see the compiler option --no_literal_pool in the IAR C/C++Development
Guide for Arm.
Stack protection
Use this option to enable stack protection for the functions that are considered
to need it.
Pointer authentication
Use this option to make the compiler create the code needed for Pointer
Authentication. For more information, see the IAR C/C++Development Guide
for Arm.
Branch target identification
Use this option to make the compiler create the code needed for Branch Target
Identification. For more information, see the IAR C/C++Development Guide
for Arm.
233
AFE1_AFE2-1:1
Description of compiler options
Optimizations
The Optimizations options determine the type and level of optimization for the
generation of object code.
Level
Selects the optimization level. Choose between:
None
No optimization—provides best debug support.
Low
The lowest level of optimization.
Medium
The medium level of optimization.
High
The highest level of optimization. Choose from:
Balanced, the highest level of optimization, balancing between speed and size.
Size, the highest level of optimization, favoring size.
Speed, the highest level of optimization, favoring speed.
No size constraints
Optimizes for speed, but relaxes the normal restrictions for code size expansion.
This option is only available at the level High, Speed.
By default, a debug project will have a size optimization that is fully debuggable, while
a release project will have a high balanced optimization that generates small code
without sacrificing speed.
AFE1_AFE2-1:1
Compiler options
For a list of optimizations performed at each optimization level, see the IAR
C/C++Development Guide for Arm.
Enabled transformations
Selects which transformations that are available at different optimization levels. When
a transformation is available, you can enable or disable it by selecting its check box.
Choose between:
● Common subexpression elimination
● Loop unrolling
● Function inlining
● Code motion
● Type-based alias analysis
● Static clustering
● Instruction scheduling
● Vectorization
Note: In a debug project the transformations are, by default, disabled. In a release
project the transformations are, by default, enabled.
For a brief description of the transformations that can be individually disabled, see the
IAR C/C++Development Guide for Arm.
Output
The Output options determine the generated compiler output.
235
AFE1_AFE2-1:1
Description of compiler options
List
The List options make the compiler generate a list file and determine its contents.
AFE1_AFE2-1:1
Compiler options
By default, the compiler does not generate a list file. Select any of the following options
to generate a list file or an assembler file. The list file will be saved in the List directory,
and its filename will consist of the source filename, plus the filename extension lst.
If you want to save the list file in another directory than the default directory for list files,
use the Output Directories option in the General Options category, see Output, page
220.
You can open the output files directly from the Output folder which is available in the
Workspace window.
237
AFE1_AFE2-1:1
Description of compiler options
Preprocessor
The Preprocessor options allow you to define symbols and include paths for use by the
compiler.
Preinclude file
Specify a file to include before the first line of the source file.
Defined symbols
Define a macro symbol (one per line), including its value, for example like this:
TESTVER=1
AFE1_AFE2-1:1
Compiler options
This has the same effect as if a line like this appeared before the start of the source file:
#define TESTVER 1
Diagnostics
The Diagnostics options determine how diagnostic messages are classified and
displayed. Use the diagnostics options to override the default classification of the
specified diagnostics.
Note: The diagnostic messages cannot be suppressed for fatal errors, and fatal errors
cannot be reclassified.
Enable remarks
Enables the generation of remarks. By default, remarks are not issued.
The least severe diagnostic messages are called remarks. A remark indicates a source
code construct that might cause strange behavior in the generated code.
239
AFE1_AFE2-1:1
Description of compiler options
AFE1_AFE2-1:1
Compiler options
Encodings
The Encodings options determine the encodings for source files, output files, and input
files.
241
AFE1_AFE2-1:1
Description of compiler options
Extra Options
The Extra Options page provides you with a command line interface to the tool.
AFE1_AFE2-1:1
Compiler options
Use this dialog box to specify or delete include paths, or to make a path relative or
absolute.
To add a path to an include directory:
1 Click the text <Click to add>. A browse dialog box is displayed.
2 Browse to the appropriate include directory and click Select. The include path appears.
To add yet another one, click <Click to add>.
To make the path relative or absolute:
1 Click the drop-down arrow. A context menu is displayed. which shows the absolute
path and paths relative to the argument variables $PROJ_DIR$ and $TOOLKIT_DIR$,
when possible.
2 Choose one of the alternatives.
To change the order of the paths:
1 Use the shortcut key combinations Ctrl+Up/Down.
2 The list will be sorted accordingly.
To delete an include path:
1 Select the include path and click the red cross at the beginning of the line, alternatively
press the Delete key.
2 The selected path will disappear.
243
AFE1_AFE2-1:1
Description of compiler options
AFE1_AFE2-1:1
Assembler options
● Description of assembler options
Language
The Language options control certain behavior of the assembler language.
245
AFE1_AFE2-1:1
Description of assembler options
AFE1_AFE2-1:1
Assembler options
Output
The Output options determine the generated assembler output.
List
The List options make the assembler generate a list file and determine its contents.
247
AFE1_AFE2-1:1
Description of assembler options
220. You can open the output files directly from the Output folder which is available in
the Workspace window.
Include header
Includes the header. The header of the assembler list file contains information about the
product version, date and time of assembly, and the command line equivalents of the
assembler options that were used.
Include listing
Selects which type of information to include in the list file. Choose from:
#included text
Includes #include files in the list file.
Macro definitions
Includes macro definitions in the list file.
Macro expansions
Excludes macro expansions from the list file.
Macro execution info
Prints macro execution information on every call of a macro.
Assembled lines only
Excludes lines in false conditional assembler sections from the list file.
Multiline code
Lists the code generated by directives on several lines if necessary.
Lines/page
Specify the number of lines per page, within the range 10 to 150. The default number of
lines per page is 80 for the assembler list file.
AFE1_AFE2-1:1
Assembler options
Tab spacing
Specify the number of character positions per tab stop, within the range 2 to 9. By
default, the assembler sets eight character positions per tab stop.
Preprocessor
The Preprocessor options allow you to define symbols and include paths for use by the
compiler.
Preinclude file
Specify a file to include before the first line of the source file.
249
AFE1_AFE2-1:1
Description of assembler options
Defined symbols
Define a macro symbol (one per line), including its value, for example like this:
TESTVER=1
This has the same effect as if a line like this appeared before the start of the source file:
#define TESTVER 1
Diagnostics
The Diagnostics options control individual warnings or ranges of warnings.
Warnings
Controls the assembler warnings. The assembler displays a warning message when it
finds an element of the source code that is legal, but probably the result of a
programming error. By default, all warnings are enabled. To control the generation of
warnings, choose between:
Enable
Enables warnings.
Disable
Disables warnings.
All warnings
Enables/disables all warnings.
Just warning
Enables/disables the warning you specify.
AFE1_AFE2-1:1
Assembler options
Warnings from to
Enables/disables all warnings in the range you specify.
For more information about assembler warnings, see the IAR Assembler User Guide for
Arm.
Extra Options
The Extra Options page provides you with a command line interface to the tool.
251
AFE1_AFE2-1:1
Description of assembler options
AFE1_AFE2-1:1
Output converter options
● Description of output converter options
Output
The Output options determine details about the promable output format.
253
AFE1_AFE2-1:1
Description of output converter options
Output Converter and click Edit. In the Edit Filename Extensions dialog box, select
Override and type the new filename extension and click OK. ielftool will now
recognize the new filename extension.
Output format
Selects the format for the output from ielftool. Choose between:
● Motorola S-records
● Intel Extended hex
● Texas Instruments TI-TXT
● Raw binary
● Simple-code
For more information about the converter, see the IAR C/C++Development Guide for
Arm.
Output file
Specifies the name of the ielftool converted output file. By default, the linker will use
the project name with a filename extension. The filename extension depends on which
output format you choose, for example, either srec or hex. To override the default
name, select the Override default option and specify the alternative filename or
filename extension.
AFE1_AFE2-1:1
Custom build options
● Description of custom build options
Filename extensions
Specify the filename extensions for the types of files that are to be processed by the
custom tool. You can type several filename extensions. Use commas, semicolons, or
blank spaces as separators. For example:
.htm; .html
255
AFE1_AFE2-1:1
Description of custom build options
Command line
Specify the command line for executing the external tool.
Output files
Specify the name for the output files from the external tool.
Build order
Specify where in the build process to execute the external tool. Choose between:
Automatic (based on input and output)
The time of execution will be calculated automatically by the build engine.
Run before compiling/assembling
The tool will be executed before the compiler or assembler.
Run before linking
The tool will be executed after the compiler or assembler, but before the linker.
AFE1_AFE2-1:1
Build actions options
● Description of build actions options
If a build action returns a non-zero error code, the entire Build or Make command is
aborted.
Build actions
The display area shows all command lines to be executed at various stages of the build,
when in the build order they will be executed, and which output they produce. Use the
buttons under the display area to create, edit, or remove build actions.
257
AFE1_AFE2-1:1
Description of build actions options
New
Opens a dialog box where you can create a new build action, see New/Edit Build Action
dialog box, page 258.
Edit
Opens a dialog box where you can edit the selected build action, see New/Edit Build
Action dialog box, page 258.
Remove
Deletes the selected build action.
Command line
Specify the command line to be executed, with all options and arguments.
Output files
Specify any files that are created by the command line. Note that output from build
actions should not also be added to the project.
AFE1_AFE2-1:1
Build actions options
Input files
Specify any files that the build action depends on.
Working directory
Specify the directory where the build action is executed. A browse button is available
for your convenience.
Build order
Specify where in the build process to execute the build action. Choose between:
Automatic (based on input and output)
The time of execution will be calculated automatically by the build engine.
Run before compiling/assembling
The build action will be executed before the compiler or assembler.
Run before linking
The build action will be executed after the compiler or assembler, but before the
linker.
Run after linking
The build action will be executed after compiling/assembly, and after the linker.
259
AFE1_AFE2-1:1
Description of build actions options
AFE1_AFE2-1:1
Linker options
● Description of linker options
261
AFE1_AFE2-1:1
Description of linker options
Config
The Config options specify the path and name of the linker configuration file and define
symbols for the configuration file.
AFE1_AFE2-1:1
Linker options
Library
The Library options select the set of used libraries.
For more information about available libraries, see the IAR C/C++Development Guide
for Arm.
Additional libraries
Specify additional libraries that you want the linker to include during the link process.
You can only specify one library per line and you must specify the full path to the library.
Use the browse button to display the Edit Additional Libraries dialog box, where you
can specify libraries using a file browser. For more information, see Edit Additional
Libraries dialog box, page 276.
The argument variables $PROJ_DIR$ and $TOOLKIT_DIR$ can be used, see Argument
variables, page 88.
Alternatively, you can add an additional library directly to your project in the
Workspace window. You can find an example of this in the tutorial for creating and
using libraries.
263
AFE1_AFE2-1:1
Description of linker options
Override default program entry overrides the default entry label. Choose between:
Entry symbol
Specify an entry symbol other than default.
No entry symbol
No entry symbol will be defined and the entry point of the application image
will be 0. For this reason, the application must contain a symbol or section that
has the root attribute and that refers, directly or indirectly, to the rest of the
application, otherwise the image will be empty.
Input
The Input options specify how to handle input to the linker.
Keep symbols
Define the symbol, or several symbols one per line, that shall always be included in the
final application.
By default, the linker keeps a symbol only if your application needs it.
AFE1_AFE2-1:1
Linker options
Section
The section where the binary data is placed.
Align
The alignment of the section where the binary data is placed.
The entire contents of the files are placed in the section you specify, which means they
can only contain pure binary data, for example, the raw binary output format. The
section where the contents of a specified file are placed, is only included if the specified
symbol is required by your application. Use Keep symbols if you want to force a
reference to the symbol. Read more about single output files and the --keep option in
the IAR C/C++Development Guide for Arm.
Optimizations
The Optimizations options control linker optimizations.
For more information about these options, see the IAR C/C++Development Guide for
Arm.
265
AFE1_AFE2-1:1
Description of linker options
Advanced
The Advanced options control some miscellaneous linker features.
For more information about these options, see the IAR C/C++Development Guide for
Arm.
AFE1_AFE2-1:1
Linker options
Do not use this option if you want the linker to check that exceptions are not used by
mistake in your application.
Output
The Output options determine the generated linker output.
267
AFE1_AFE2-1:1
Description of linker options
Output filename
Sets the name of the ILINK output file. By default, the linker will use the project name
with the filename extension out. To override the default name, specify an alternative
name of the output file.
Note: If you change the filename extension for linker output and want to use the output
converter ielftool to convert the output, make sure ielftool will recognize the new
filename extension. To achieve this, choose Tools>Filename Extension, select your
toolchain, and click Edit. In the Filename Extension Overrides dialog box, select
Output Converter and click Edit. In the Edit Filename Extensions dialog box, select
Override and type the new filename extension and click OK. ielftool will now
recognize the new filename extension.
List
The List options control the generation of linker listings.
AFE1_AFE2-1:1
Linker options
#define
The #define options define absolute symbols at link time.
269
AFE1_AFE2-1:1
Description of linker options
Defined symbols
Define absolute symbols to be used at link time. This is especially useful for
configuration purposes. Type the symbols that you want to define for the project, one
per line, and specify their value. For example:
TESTVER=1
Note that there should be no space around the equals (=) sign.
Any number of symbols can be defined in a linker configuration file. The symbol(s)
defined in this manner will be located in a special module called ?ABS_ENTRY_MOD,
which is generated by the linker.
The linker will display an error message if you attempt to redefine an existing symbol.
Diagnostics
The Diagnostics options determine how diagnostic messages are classified and
displayed. Use the diagnostics options to override the default classification of the
specified diagnostics.
Note: The diagnostic messages cannot be suppressed for fatal errors, and fatal errors
cannot be reclassified.
Enable remarks
Enables the generation of remarks. By default, remarks are not issued.
The least severe diagnostic messages are called remarks. A remark indicates a source
code construct that might cause strange behavior in the generated code.
AFE1_AFE2-1:1
Linker options
271
AFE1_AFE2-1:1
Description of linker options
Checksum
The Checksum options control filling and checksumming.
For more information about checksum calculation, see the IAR C/C++Development
Guide for Arm.
Generate checksum
Generates a checksum for the specified range. Choose between:
Checksum size
Selects the size of the checksum, which can be 1, 2, 4, or 8 bytes.
Alignment
Specifies an optional alignment for the checksum. Typically, this is useful when
the processor cannot access unaligned data. If you do not specify an alignment
explicitly, an alignment of 1 is used.
AFE1_AFE2-1:1
Linker options
Algorithm
Selects the algorithm to be used when calculating the checksum. Choose
between:
Arithmetic sum, the simple arithmetic sum algorithm. The result is truncated
to one byte.
CRC16 (default), the CRC16 algorithm (generating polynomial 0x1021).
CRC32, the CRC32 algorithm (generating polynomial 0x4C11DB7).
CRC polynomial, the CRC polynomial algorithm, a generating polynomial of
the value you specify.
CRC64ISO, the CRC64ISO algorithm (generating polynomial 0x1B).
CRC64ECMA, the CRC64ECMA algorithm (generating polynomial
0x42F0E1EBA9EA3693).
Sum32, a word-wise (32 bits) calculated arithmetic sum.
Result in full size
Generates the result of the arithmetic sum algorithm in the size you specify
instead of truncating it to one byte.
Complement
Selects the complement variant. Leave either as is, or select the one’s
complement or two’s complement.
Bit order
Selects the order in which the bits in each byte will be processed. Choose
between:
MSB first, outputs the most significant bit first for each byte.
LSB first, reverses the bit order for each byte and outputs the least significant
bit first.
Reverse byte order within word
Reverses the byte order of the input data within each word of the size specified
in Checksum unit size.
Initial value
Specifies an initial value for the checksum. This is useful if the core you are
using has its own checksum calculation and you want that calculation to
correspond to the calculation performed by the linker.
273
AFE1_AFE2-1:1
Description of linker options
Use as input
Prefixes the input data with a word of size Checksum unit size that contains the
value specified in Initial value.
Checksum unit size
Selects the size of the unit for which a checksum should be calculated. Typically,
this is useful to make the linker produce the same checksum as some hardware
CRC implementations that calculate a checksum for more than 8 bits per
iteration. Choose between:
8-bit, calculates a checksum for 8 bits in every iteration.
16-bit, calculates a checksum for 16 bits in every iteration.
32-bit, calculates a checksum for 32 bits in every iteration.
64-bit, calculates a checksum for 64 bits in every iteration.
Encodings
The Encodings options control the character encodings of the input files to and the
output files from the linker.
AFE1_AFE2-1:1
Linker options
Extra Options
The Extra Options page provides you with a command line interface to the tool.
275
AFE1_AFE2-1:1
Description of linker options
Use this dialog box to specify additional libraries, or to make a path to a library relative
or absolute.
To specify an additional library:
1 Click the text <Click to add>. A browse dialog box is displayed.
2 Browse to the appropriate include directory and click Open. The library is listed.
To add yet another one, click <Click to add>.
To make the path relative or absolute:
1 Click the drop-down arrow. A context menu is displayed, which shows the absolute
path and paths relative to the argument variables $PROJ_DIR$ and $TOOLKIT_DIR$,
when possible.
2 Choose one of the alternatives.
To change the order of the libraries:
1 Use the shortcut key combinations Ctrl+Up/Down.
2 Notice that the list will be sorted accordingly.
To delete a library from the list:
1 Select the library and click the red cross at the beginning of the line, alternatively press
the Delete key.
2 Notice that the selected library will disappear.
AFE1_AFE2-1:1
Linker options
Use this dialog box to specify memory locations for linker sections and blocks in the
linker configuration file.
This dialog box contains these pages:
Vector Table
Specify the start location of the memory block for the reset vector table (.intvec).
Memory Regions
Specify the start and end locations of the ROM and RAM memory regions.
Stack/Heap Sizes
Specify the size (start and end locations) of each of the linker stacks or heaps.
277
AFE1_AFE2-1:1
Description of linker options
AFE1_AFE2-1:1
Library builder options
● Description of library builder options
279
AFE1_AFE2-1:1
Description of library builder options
Output
The Output options control the library builder and as a result of the build process, the
library builder will create a library output file.
Output file
Specifies the name of the output file from the library builder. By default, the linker will
use the project name with a filename extension. To override the default name, select
Override default and specify an alternative name of the output file.
AFE1_AFE2-1:1
Glossary
Assembler language
This is a general glossary for terms relevant to A machine-specific set of mnemonics used to specify
embedded systems programming. Some of the terms do operations to the target processor and input or output registers
not apply to the IAR Embedded Workbench® version or data areas. Assembler language might sometimes be
that you are using. preferred over C/C++ to save memory or to enhance the
execution speed of the application.
A Assembler options
Parameters you can specify to change the default behavior of
the assembler.
Absolute location.
A specific memory address for an object specified in the Attributes
source code, as opposed to the object being assigned a location See Section attributes.
by the linker
Auto variables
Address expression The term refers to the fact that each time the function in which
An expression which has an address as its value. the variable is declared is called, a new instance of the variable
AEABI is created automatically. This can be compared with the
behavior of local variables in systems using static overlay,
Embedded Application Binary Interface for Arm, defined by
Arm Limited. where a local variable only exists in one instance, even if the
function is called recursively. Also called local variables.
Application Compare Register variables.
The program developed by the user of the IAR toolkit and
which will be run as an embedded application on a target
processor. B
Ar Backtrace
The GNU binary utility for creating, modifying, and extracting Information for keeping call frame information up to date so
from archives, that is, libraries. See also Iarchive. that the IAR C-SPY® Debugger can return from a function
correctly. See also Call frame information.
Architecture
A term used by computer designers to designate the structure Bank
of complex information-processing systems. It includes the See Memory bank.
kinds of instructions and data used, the memory organization Bank switching
and addressing, and the methods by which the system is Switching between different sets of memory banks. This
implemented. The two main architecture types used in software technique increases a computer's usable memory by
processor design are Harvard architecture and von Neumann allowing different pieces of memory to occupy the same
architecture. address space.
Archive
See Library.
281
AFE1_AFE2-1:1
Banked code the program variables. Breakpoints can be part of the
Code that is distributed over several banks of memory. Each program itself, or they can be set by the programmer as
function must reside in only one bank. part of an interactive session with a debugging tool for
scrutinizing the program's execution.
Banked data
Data that is distributed over several banks of memory. Each 2 Data breakpoint. A point in memory that, when accessed,
data object must fit inside one memory bank. triggers some special behavior useful to the process of
debugging. Generally, data breakpoints are used to stop
Banked memory program execution when an address location is accessed
Has multiple storage locations for the same address. See also either by a read operation or a write operation.
Memory bank.
3 Immediate breakpoint. A point in memory that, when
Bank-switching routines accessed, trigger some special behavior useful in the
Code that selects a memory bank. process of debugging. Immediate breakpoints are
generally used for halting the program execution in the
Batch files middle of a memory access instruction (before or after the
A text file containing operating system commands which are actual memory access depending on the access type) while
executed by the command line interpreter. In Unix, this is performing some user-specified action. The execution is
called a “shell script” because it is the Unix shell which then resumed. This feature is only available in the
includes the command line interpreter. Batch files can be used simulator version of C-SPY.
as a simple way to combine existing commands into new
commands.
Bitfield
C
A group of bits considered as a unit. Call frame information
Information that allows the IAR C-SPY® Debugger to show,
Block, in linker configuration file without any runtime penalty, the complete stack of function
A continuous piece of code or data. It is either built up of calls—call stack—wherever the program counter is, provided
blocks, overlays, and sections or it is empty. A block has a that the code comes from compiled C functions. See also
name, and the start and end address of the block can be referred Backtrace.
to from the application. It can have attributes such as a
maximum size, a specific size, or a minimum alignment. The Calling convention
contents can have a specific order or not. A calling convention describes the way one function in a
program calls another function. This includes how register
Breakpoint parameters are handled, how the return value is returned, and
1 Code breakpoint. A point in a program that, when reached, which registers that will be preserved by the called function.
triggers some special behavior useful to the process of The compiler handles this automatically for all C and C++
debugging. Generally, breakpoints are used for stopping functions. All code written in assembler language must
program execution or dumping the values of some or all of conform to the rules in the calling convention to be callable
from C or C++, or to be able to call C and C++ functions. The
C calling convention and the C++ calling conventions are not
necessarily the same.
AFE1_AFE2-1:1
Glossary
283
AFE1_AFE2-1:1
embedded systems usually have a set of different data pointer Device driver
types so they can access the available memory efficiently. Software that provides a high-level programming interface to
a particular peripheral device.
Data representation
How different data types are laid out in memory and what Digital signal processor (DSP)
value ranges they represent. A device that is similar to a microprocessor, except that the
internal CPU is optimized for use in applications involving
Declaration discrete-time signal processing. In addition to standard
A specification to the compiler that an object, a variable or microprocessor instructions, digital signal processors usually
function, exists. The object itself must be defined in exactly support a set of complex instructions to perform common
one translation unit (source file). An object must either be signal-processing computations quickly.
declared or defined before it is used. Normally an object that is
used in many files is defined in one source file. A declaration Disassembly window
is normally placed in a header file that is included by the files A C-SPY window that shows the memory contents
that use the object. disassembled as machine instructions, interspersed with the
corresponding C source code (if available).
For example:
DWARF
/* Variable "a" exists somewhere. Function An industry-standard debugging format which supports source
"b" takes two int parameters and returns an
level debugging. This is the format used by the IAR ILINK
int. */
Linker for representing debug information in an object.
extern int a;
Dynamic initialization
int b(int, int);
Variables in a program written in C are initialized during the
Definition initial phase of execution, before the main function is called.
The variable or function itself. Only one definition can exist These variables are always initialized with a static value,
for each variable or function in an application. See also which is determined either at compile time or at link time. This
Tentative definition. is called static initialization. In C++, variables might require
initialization to be performed by executing code, for example,
For example: running the constructor of global objects, or performing
dynamic memory allocation.
int a;
int b(int x, int y) Dynamic memory allocation
{ There are two main strategies for storing variables: statically at
return x + y; link time, or dynamically at runtime. Dynamic memory
} allocation is often performed from the heap and it is the size of
the heap that determines how much memory that can be used
Demangling
for dynamic objects and variables. The advantage of dynamic
To restore a mangled name to the more common C/C++ name.
memory allocation is that several variables or objects that are
See also Mangling.
not active at the same time can be stored in the same memory,
Device description file thus reducing the memory requirements of an application. See
A file used by C-SPY that contains various device-specific also Heap memory.
information such as I/O register (SFR) definitions, interrupt
vectors, and control register definitions.
AFE1_AFE2-1:1
Glossary
285
AFE1_AFE2-1:1
Extended keywords Heap memory
Non-standard keywords in C and C++. These usually control The heap is a pool of memory in a system that is reserved for
the definition and declaration of objects (that is, data and dynamic memory allocation. An application can request parts
functions). See also Keywords. of the heap for its own use; once memory is allocated from the
heap it remains valid until it is explicitly released back to the
heap by the application. This type of memory is useful when
F the number of objects is not known until the application
executes.
Filling
How to fill up bytes—with a specific fill pattern—that exists Note that this type of memory is risky to use in systems with a
between the sections in an executable image. These bytes exist limited amount of memory or systems that are expected to run
because of the alignment demands on the sections. for a very long time.
Format specifiers Heap size
Used to specify the format of strings sent by library functions Total size of memory that can be dynamically allocated.
such as printf. In the following example, the function call
contains one format string with one format specifier, %c, that Host
prints the value of a as a single ASCII character: The computer that communicates with the target processor.
The term is used to distinguish the computer on which the
printf("a = %c", a); debugger is running from the core the embedded application
you develop runs on.
G
General options I
Parameters you can specify to change the default behavior of Iarchive
all tools that are included in the IDE. The IAR utility for creating archives, that is, libraries. Iarchive
is delivered with IAR Embedded Workbench.
Generic pointers
Pointers that have the ability to point to all different memory IDE (integrated development environment)
types in, for example, a core based on the Harvard architecture. A programming environment with all necessary tools
integrated into one single application.
H Ielfdumparm
The IAR utility for creating a text representation of the
Harvard architecture
contents of ELF relocatable or executable image.
A core based on the Harvard architecture has separate data and
instruction buses. This allows execution to occur in parallel. Ielftool
As an instruction is being fetched, the current instruction is The IAR utility for performing various transformations on an
executing on the data bus. Once the current instruction is ELF executable image, such as fill, checksum, and format
complete, the next instruction is ready to go. This theoretically conversion.
allows for much faster execution than a von Neumann
architecture, but adds some silicon complexity. Compare von ILINK
Neumann architecture. The IAR ILINK Linker which produces absolute output in the
ELF/DWARF format.
AFE1_AFE2-1:1
Glossary
Image Interrupts
See Executable image. In embedded systems, the use of interrupts is a method of
detecting external events immediately, for example a timer
Include file overflow or the pressing of a button.
A text file which is included into a source file. This is often
done by the preprocessor. Interrupts are asynchronous events that suspend normal
processing and temporarily divert the flow of control through
Initialization setup in linker configuration file an “interrupt handler” routine. Interrupts can be caused by
Defines how to initialize RAM sections with their initializers. both hardware (I/O, timer, machine check) and software
Normally, only non-constant non-noinit variables are (supervisor, system call or trap instruction). Compare Trap.
initialized but, for example, pieces of code can be initialized as
well. Intrinsic
An adjective describing native compiler objects, properties,
Initialized sections events, and methods.
Read-write sections that should be initialized with specific
values at startup. See also Section. Intrinsic functions
1. Function calls that are directly expanded into specific
Inline assembler sequences of machine code. 2. Functions called by the
Assembler language code that is inserted directly between C compiler for internal purposes (that is, floating-point
statements. arithmetic etc.).
Inlining Iobjmanip
An optimization that replaces function calls with the body of The IAR utility for performing low-level manipulation of ELF
the called function. This optimization increases the execution object files.
speed and can even reduce the size of the generated code.
Instruction mnemonics
A word or acronym used in assembler language to represent a K
machine instruction. Different processors have different Key bindings
instruction sets and therefore use a different set of mnemonics Key shortcuts for menu commands used in the IDE.
to represent them, such as, ADD, BR (branch), BLT (branch if
less than), MOVE, LDR (load register). Keywords
A fixed set of symbols built into the syntax of a programming
Interrupt vector language. All keywords used in a language are reserved—they
A small piece of code that will be executed, or a pointer that cannot be used as identifiers (in other words, user-defined
points to code that will be executed when an interrupt occurs. objects such as variables or procedures). See also Extended
keywords.
287
AFE1_AFE2-1:1
L
L-value
A value that can be found on the left side of an assignment and
that can, therefore, be changed. This includes plain variables The accumulator of the MAC usually has a higher precision
and dereferenced pointers. Expressions like (x + 10) cannot (more bits) than normal registers. See also Digital signal
be assigned a new value and are therefore not L-values. processor (DSP).
AFE1_AFE2-1:1
Glossary
configuration file. The memory is always addressable from references to external symbols (imports). When you compile
0x0 to size -1. C/C++, each translation unit produces one module.
Memory area
A region of the memory.
N
Nested interrupts
Memory bank A system where an interrupt can be interrupted by another
The smallest unit of continuous memory in banked memory. interrupt is said to have nested interrupts.
One memory bank at a time is visible in a core’s physical
address space. Non-banked memory
Has a single storage location for each memory address in a
Memory map core’s physical address space.
A map of the different memory areas available to the core.
Non-initialized memory
Memory model Memory that can contain any value at reset, or in the case of a
Specifies the memory hierarchy and how much memory the soft reset, can remember the value it had before the reset.
system can handle. Your application must use only one
memory model at a time, and the same model must be used by No-init sections
all user modules and all library modules. Read-write sections that should not be initialized at startup.
See also Section.
Microcontroller
A microprocessor on a single integrated circuit intended to Non-volatile storage
operate as an embedded system. In addition to a CPU, a Memory devices such as battery-backed RAM, ROM,
microcontroller typically includes small amounts of RAM, magnetic tape and magnetic disks that can retain data when
PROM, timers, and I/O ports. electric power is shut off. Compare Volatile storage.
Microprocessor NOP
A CPU contained on one (or a few) integrated circuits. A No operation. This is an instruction that does not do anything,
single-chip microprocessor can include other components but is used to create a delay. In pipelined architectures, the NOP
such as memory, memory management, caches, floating-point instruction can be used for synchronizing the pipeline. See also
unit, I/O ports and timers. Such devices are also known as Pipeline.
microcontrollers.
Module
An object. An object file contains a module and library
O
contains one or more objects. The basic unit of linking. A Objcopy
module contains definitions for symbols (exports) and A GNU binary utility for converting an absolute object file in
ELF format into an absolute object file, for example the format
Motorola-std or Intel-std. See also Ielftool.
289
AFE1_AFE2-1:1
Object Peripheral unit
An object file or a library member. A hardware component other than the processor, for example
memory or an I/O device.
Object file, absolute
See Executable image. Pipeline
A structure that consists of a sequence of stages through which
Object file, relocatable a computation flows. New operations can be initiated at the
The result of compiling or assembling a source file. The file start of the pipeline even though other operations are already
format used for an object file is ELF with embedded DWARF in progress through the pipeline.
for debug information.
Placement, in linker configuration file
Operator How to place blocks, overlays, and sections into a region. It
A symbol used as a function, with infix syntax if it has two determines how pieces of code and data are actually placed in
arguments (+, for example) or prefix syntax if it has only one the available physical memory.
(for instance, bitwise negation, ~). Many languages use
operators for built-in functions such as arithmetic and logic. Pointer
An object that contains an address to another object of a
Operator precedence specified type.
Each operator has a precedence number assigned to it that
determines the order in which the operator and its operands are #pragma
evaluated. The highest precedence operators are evaluated During compilation of a C/C++ program, the #pragma
first. Use parentheses to group operators and operands to preprocessing directive causes the compiler to behave in an
control the order in which the expressions are evaluated. implementation-defined manner. This can include, for
example, producing output on the console, changing the
Options declaration of a subsequent object, changing the optimization
A set of commands that control the behavior of a tool, for level, or enabling/disabling language extensions.
example the compiler or linker. The options can be specified
on the command line or via the IDE. Pre-emptive multitasking
An RTOS task is allowed to run until a higher priority process
Output image is activated. The higher priority task might become active as
See Executable image. the result of an interrupt. The term preemptive indicates that
although a task is allotted to run a given length of time (a
Overlay, in linker configuration file
timeslice), it might lose the processor at any time. Each time
Like a block, but it contains several overlaid entities, each built
an interrupt occurs, the task scheduler looks for the highest
up of blocks, overlays, and sections. The size of an overlay is
priority task that is active and switches to that task. If the
determined by its largest constituent. Code in overlaid memory
located task is different from the task that was executing before
areas cannot be debugged in the C-SPY Debugger.
the interrupt, the previous task is suspended at the point of
interruption.
P Compare Round Robin.
Parameter passing
Preprocessing directives
See Calling convention.
A set of directives that are executed before the parsing of the
actual code is started.
AFE1_AFE2-1:1
Glossary
Register constant
Q A register constant is a value that is loaded into a dedicated
processor register when the system is initialized. The compiler
Qualifiers
can then generate code that assumes that the constants are
See Type qualifiers.
present in the dedicated registers.
R Register locking
Register locking means that the compiler can be instructed that
some processor registers shall not be used during normal code
Range, in linker configuration file
A range of consecutive addresses in a memory. A region is generation. This is useful in many situations. For example,
built up of ranges. some parts of a system might be written in assembler language
to gain speed. These parts might be given dedicated processor
Read-only sections registers. Or the register might be used by an operating system,
Sections that contain code or constants. See also Section. or by other third-party software.
291
AFE1_AFE2-1:1
Register variables are much more efficient than other variables ILINK uses the runtime model attributes when automatically
because they do not require memory accesses, so the compiler choosing a library, to verify that the correct one is used.
can use shorter/faster instructions when working with them.
See also Auto variables. R-value
A value that can be found on the right side of an assignment.
Relay This is just a plain value. See also L-value.
A synonym to veneer, see Veneer.
Relocatable sections
Sections that have no fixed location in memory before linking.
S
Saturation arithmetics
Reset Most, if not all, C and C++ implementations use mod–2N
A reset is a restart from the initial state of a system. A reset can 2-complement-based arithmetics where an overflow wraps the
originate from hardware (hard reset), or from software (soft value in the value domain, that is, (127 + 1) = -128. Saturation
reset). A hard reset can usually not be distinguished from the arithmetics, on the other hand, does not allow wrapping in the
power-on condition, which a soft reset can be. value domain, for instance, (127 + 1) = 127, if 127 is the upper
limit. Saturation arithmetics is often used in signal processing,
ROM-monitor where an overflow condition would have been fatal if value
A piece of embedded software designed specifically for use as wrapping had been allowed.
a debugging tool. It resides in the ROM of the evaluation board
chip and communicates with a debugger via a serial port or Scheduler
network connection. The ROM-monitor provides a set of The part of an RTOS that performs task-switching. It is also
primitive commands to view and modify memory locations responsible for selecting which task that should be allowed to
and registers, create and remove breakpoints, and execute your run. Many scheduling algorithms exist, but most of them are
application. The debugger combines these primitives to fulfill either based on static scheduling (performed at compile-time),
higher-level requests like program download and single-step. or on dynamic scheduling (where the actual choice of which
task to run next is taken at runtime, depending on the state of
Round Robin the system at the time of the task-switch). Most real-time
Task scheduling in an operating system, where all tasks have systems use static scheduling, because it makes it possible to
the same priority level and are executed in turn, one after the prove that the system will not violate the real-time
other. Compare Pre-emptive multitasking. requirements.
RTOS Scope
See Real-time operating system (RTOS). The section of an application where a function or a variable can
Runtime library be referenced by name. The scope of an item can be limited to
A collection of relocatable object files that will be included in file, function, or block.
the executable image only if referred to from an object file, in Section
other words conditionally linked. An entity that either contains data or text. Typically, one or
Runtime model attributes more variables, or functions. A section is the smallest linkable
A mechanism that is designed to prevent modules that are not unit.
compatible to be linked into an application. A runtime attribute
is a pair constituted of a named key and its corresponding
value.
AFE1_AFE2-1:1
Glossary
293
AFE1_AFE2-1:1
Stack frames Symbolic location
Data structures containing data objects like preserved A location that uses a symbolic name because the exact
registers, local variables, and other data objects that must be address is unknown.
stored temporary for a particular scope (usually a function).
AFE1_AFE2-1:1
Glossary
U W
UBROF (Universal Binary Relocatable Object Watchpoints
Format) Watchpoints keep track of the values of C variables or
File format produced by some of the IAR programming tools, expressions in the C-SPY Watch window as the application is
if your product package includes the XLINK linker. being executed.
V X
Value expressions, in linker configuration file XAR
A constant number that can be built up out of expressions that An IAR tool that creates archives (libraries) in the UBROF
has a syntax similar to C expressions. format.
Veneer XLIB
A small piece of code that is inserted as a springboard between An IAR tool that creates archives (libraries) in the UBROF
caller and callee when there is a mismatch in mode, for format, listing object code, converting and absolute object file
example Arm and Thumb, or when the call instruction does not into an absolute object file in another format.
reach its destination.
XLINK
Virtual address (logical address) The IAR XLINK Linker which uses the UBROF output
An address that must be translated by the compiler, linker or format.
the runtime system into a physical memory address before it is
used. The virtual address is the address seen by the application,
which can be different from the address seen by other parts of
the system.
295
AFE1_AFE2-1:1
Z
Zero-initialized sections
Sections that should be initialized to zero at startup. See also
Section.
Zero-overhead loop
A loop in which the loop condition, including branching back
to the beginning of the loop, does not take any time at all. This
is usually implemented as a special hardware feature of the
processor and is not available in all architectures.
Zone
Different processors have widely differing memory
architectures. Zone is the term C-SPY uses for a named
memory area. For example, on processors with separately
addressable code and data memory there would be at least two
zones. A processor with an intricate banked memory scheme
might have several zones.
AFE1_AFE2-1:1
Index
Index
Assembled lines only (Include listing setting) . . . . . . . . . 248
A assembler comments, text style in editor . . . . . . . . . . . . . . 146
a (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190 assembler directives
absolute location, definition of . . . . . . . . . . . . . . . . . . . . . 281 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
accelerator keys. See shortcut keys text style in editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146
Add Project Connection dialog box (Project menu) . . . . . 116 assembler language, definition of . . . . . . . . . . . . . . . . . . . 281
Additional include directories (preprocessor option) 238, 250 assembler list files
Additional input files (custom build option) . . . . . . . . . . . 256 compiler call frame information . . . . . . . . . . . . . . . . . . 237
Additional libraries (linker option) . . . . . . . . . . . . . . . . . . 263 conditional information, specifying . . . . . . . . . . . 247–248
address expression, definition of . . . . . . . . . . . . . . . . . . . . 281 cross-references, generating . . . . . . . . . . . . . . . . . . . . . 248
Advanced SIMD (NEON/HELIUM) (general option) . . . 218 generating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
Advanced (linker option) . . . . . . . . . . . . . . . . . . . . . . . . . 266 header, including . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 248
AEABI, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 lines per page, specifying . . . . . . . . . . . . . . . . . . . . . . . 248
Algorithm (Generate checksum setting) . . . . . . . . . . . . . . 273 tab spacing, specifying . . . . . . . . . . . . . . . . . . . . . . . . . 249
Alias (Key bindings option) . . . . . . . . . . . . . . . . . . . . . . . . 57 Assembler mnemonics (Output list file setting) . . . . . . . . 237
Align (Raw binary image setting) . . . . . . . . . . . . . . . . . . . 265 assembler options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
Alignment (Generate checksum setting) . . . . . . . . . . . . . . 272 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
All warnings (Warning setting) . . . . . . . . . . . . . . . . . . . . . 251 Diagnostics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 250
Allow alternative register names, mnemonics Language . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
and operands (assembler option) . . . . . . . . . . . . . . . . . . . . 246 List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
Allow C++ exceptions (linker option) . . . . . . . . . . . . . . . 266 Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
Allow VLA (C dialect setting) . . . . . . . . . . . . . . . . . . . . . 229 assembler output, including debug information . . . . . . . . 247
Always include (linker option) . . . . . . . . . . . . . . . . . . . . . 266 Assembler source file (Workspace window icon) . . . . . . . 109
Ambiguous Definitions (View menu) . . . . . . . . . . . . . . . . 170 assembler, command line version . . . . . . . . . . . . . . . . . . . . 23
ANSI C. See C89 assert, in built applications . . . . . . . . . . . . . . . . . . . . . . . . . 98
application, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . 281 assumptions, programming experience . . . . . . . . . . . . . . . . 15
architecture, definition of . . . . . . . . . . . . . . . . . . . . . . . . . 281 attributes on sections, definition of . . . . . . . . . . . . . . . . . . 293
archive, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 Auto code completion and parameter hints (editor option) . 62
argument variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82 Auto indent (editor option) . . . . . . . . . . . . . . . . . . . . . . . . . 61
custom . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89–90 Auto (Language setting) . . . . . . . . . . . . . . . . . . . . . . . . . . 229
environment variables . . . . . . . . . . . . . . . . . . . . . . . . . . 89 Automatic runtime library selection (linker option) . . . . . 263
in #include file paths . . . . . . . . . . . . . . . . . . . . . . 239, 250
summary of predefined . . . . . . . . . . . . . . . . . . . . . . . . . 88
Arguments (External editor option) . . . . . . . . . . . . . . . . . . 64 B
Arithmetic sum (checksum algorithm) . . . . . . . . . . . . . . . 273 backtrace information, definition of . . . . . . . . . . . . . . . . . 281
Arm (Processor mode setting) . . . . . . . . . . . . . . . . . . . . . . 232 bank switching, definition of . . . . . . . . . . . . . . . . . . . . . . 281
arranging windows. See windows banked code, definition of. . . . . . . . . . . . . . . . . . . . . . . . . 282
ar, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 banked data, definition of . . . . . . . . . . . . . . . . . . . . . . . . . 282
asm (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 190 banked memory, definition of . . . . . . . . . . . . . . . . . . . . . . 282
297
AFE1_AFE2-1:1
bank-switching routines, definition of. . . . . . . . . . . . . . . . 282 the process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
bat (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 190 Button Appearance dialog box . . . . . . . . . . . . . . . . . . . . . . 49
Batch Build dialog box (Project menu) . . . . . . . . . . . . . . . 132 Byte order (general option) . . . . . . . . . . . . . . . . . . . . . . . . 217
batch files
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282
specifying from the Tools menu. . . . . . . . . . . . . . . . . . . 39 C
Big (Endian mode setting) . . . . . . . . . . . . . . . . . . . . . . . . 217 C comments, text style in editor . . . . . . . . . . . . . . . . . . . . 146
bin, arm (subdirectory) . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 C dialect (compiler option) . . . . . . . . . . . . . . . . . . . . . . . . 229
bin, common (subdirectory) . . . . . . . . . . . . . . . . . . . . . . . 187 C keywords, text style in editor. . . . . . . . . . . . . . . . . . . . . 146
Bit order (Generate checksum setting) . . . . . . . . . . . . . . . 273 C source file (Workspace window icon) . . . . . . . . . . . . . . 109
bitfield, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282 c (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190
Block, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282 C (Language setting) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 228
board (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . 190 call frame information
Body (b) (Configure auto indent option) . . . . . . . . . . . . . . . 63 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282
bold style, in this guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 including in assembler list file . . . . . . . . . . . . . . . . . . . 237
bookmarks See also backtrace information
adding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146 Call graph output (linker option). . . . . . . . . . . . . . . . . . . . 267
showing in editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 calling convention, definition of . . . . . . . . . . . . . . . . . . . . 282
branch target identification, enabling in compiler . . . . . . . 233 category, in Options dialog box . . . . . . . . . . . . . . . . 123, 129
breakpoints, definition of . . . . . . . . . . . . . . . . . . . . . . . . . 282 cfg (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 190
@brief (doxygen keyword) . . . . . . . . . . . . . . . . . . . . . . . . 152 cgx (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 190
Browse files (Output directories setting) . . . . . . . . . . . . . . 221 characters, in assembler macro quotes . . . . . . . . . . . . . . . 246
Browse processes (IDE Project option). . . . . . . . . . . . . . . . 70 cheap memory access, definition of . . . . . . . . . . . . . . . . . 283
BrowseInfo (output directory). . . . . . . . . . . . . . . . . . . . . . 187 checksum
Buffered write (linker option) . . . . . . . . . . . . . . . . . . . . . . 225 CRC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
-build (iarbuild command line option) . . . . . . . . . . . . . . . 134 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
Build Actions Configuration (Build Actions options) . . . . 257 generating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 272
build configuration tool for generating . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
creating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 Checksum size (Generate checksum setting) . . . . . . . . . . 272
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Checksum unit size (Generate checksum setting) . . . . . . . 274
Build files (Output directories setting) . . . . . . . . . . . . . . . 221 Checksum (linker options) . . . . . . . . . . . . . . . . . . . . . . . . 272
Build window (View menu) . . . . . . . . . . . . . . . . . . . . . . . 130 chm (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 190
building -clean (iarbuild command line option) . . . . . . . . . . . . . . . 135
batches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126 Clean (Workspace window context menu) . . . . . . . . . . . . 111
commands for . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124 Close Workspace (File menu) . . . . . . . . . . . . . . . . . . . . . . 195
excluding files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110 CMSIS Manager dialog box . . . . . . . . . . . . . . . . . . . . . . . . 92
from the command line . . . . . . . . . . . . . . . . . . . . 127, 134 CMSIS-Pack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 create new project . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104
pre- and post-actions . . . . . . . . . . . . . . . . . . . . . . . . . . 125 example project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
AFE1_AFE2-1:1
Index
299
AFE1_AFE2-1:1
CRC16 (checksum algorithm). . . . . . . . . . . . . . . . . . . . . . 273
CRC32 (checksum algorithm). . . . . . . . . . . . . . . . . . . . . . 273 D
CRC64ECMA (checksum algorithm) . . . . . . . . . . . . . . . . 273 D registers (general option). . . . . . . . . . . . . . . . . . . . . . . . 218
CRC64ISO (checksum algorithm) . . . . . . . . . . . . . . . . . . 273 dark mode in IDE windows . . . . . . . . . . . . . . . . . . . . . . . . 52
Create New Project dialog box (Project menu) . . . . . . . . . 113 dark solarized colors in IDE windows . . . . . . . . . . . . . . . . 52
Cross-reference (assembler option) . . . . . . . . . . . . . . . . . . 248 dat (filename extension) . . . . . . . . . . . . . . . . . . . . . . 190–192
cstartup (system startup code) Data model (general option) . . . . . . . . . . . . . . . . . . . . . . . 219
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283 data model, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . 283
stack pointers not valid until reaching . . . . . . . . . . . . . . 78 data pointers, definition of . . . . . . . . . . . . . . . . . . . . . . . . 283
cstatcommands.txt (command line commands). . . . . . . . . 135 data representation, definition of. . . . . . . . . . . . . . . . . . . . 284
-cstat_analyze (iarbuild command line option) . . . . . . . . . 135 $DATE$ (argument variable) . . . . . . . . . . . . . . . . . . . . . . . 88
-cstat_clean (iarbuild command line option) . . . . . . . . . . . 135 dbgdt (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . 190
-cstat_cmds (iarbuild command line option) . . . . . . . . . . . 135 ddf (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 191
-cstat_report (iarbuild command line option) . . . . . . . . . . 135 debug information
cstat, arm (subdirectory) . . . . . . . . . . . . . . . . . . . . . . . . . . 186 generating in assembler . . . . . . . . . . . . . . . . . . . . . . . . 247
$CUR_DIR$ (argument variable) . . . . . . . . . . . . . . . . . . . . 88 in compiler, generating . . . . . . . . . . . . . . . . . . . . . . . . 236
$CUR_LINE$ (argument variable) . . . . . . . . . . . . . . . . . . . 88 Debugger (IDE Options dialog box) . . . . . . . . . . . . . . . . . . 76
custom build . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119 Declarations window (View menu). . . . . . . . . . . . . . . . . . 169
using . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127 declaration, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . 284
custom tool configuration . . . . . . . . . . . . . . . . . . . . . . . . . 119 Default input file encoding (compiler option) . . . . . . . . . . 242
Custom Tool Configuration (custom build options) . . . . . 255 Default input file encoding (linker option) . . . . . . . . . . . . 274
custom variables, as argument variables . . . . . . . . . . . . . . . 89 default installation path . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
Customize dialog box . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 Default integer format (IDE option) . . . . . . . . . . . . . . . . . . 77
C-RUN runtime error checking, documentation . . . . . . . . . 17 Default source file encoding (compiler option) . . . . . . . . . 241
C-SPY options #define options (linker options) . . . . . . . . . . . . . . . . . . . . 269
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283 define (linker options) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
C-STAT for static analysis, documentation for . . . . . . . . . . 17 Defined symbols option . . . . . . . . . . . . . . . . . . . . . . 239, 250
C-STAT (output directory) . . . . . . . . . . . . . . . . . . . . . . . . 188 Defined symbols (linker option) . . . . . . . . . . . . . . . . . . . . 270
C-style preprocessor, definition of . . . . . . . . . . . . . . . . . . 283 definition, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
C/C++ syntax demangling, definition of . . . . . . . . . . . . . . . . . . . . . . . . . 284
enabling in compiler . . . . . . . . . . . . . . . . . . . . . . . . . . 229 dep (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 191
C++ comments, text style in editor . . . . . . . . . . . . . . . . . . 146 Destroy static objects (C++ options setting) . . . . . . . . . . . 230
C++ inline semantics (C dialect setting) . . . . . . . . . . . . . . 229 development environment, introduction . . . . . . . . . . . . . . . 23
C++ keywords, text style in editor . . . . . . . . . . . . . . . . . . 146 device description files . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
C++ options (compiler option) . . . . . . . . . . . . . . . . . . . . . 230 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
C++ source file (Workspace window icon) . . . . . . . . . . . . 109 device driver, definition of . . . . . . . . . . . . . . . . . . . . . . . . 284
C++ (Language setting) . . . . . . . . . . . . . . . . . . . . . . . . . . 229 device selection files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
C89 (C dialect setting) . . . . . . . . . . . . . . . . . . . . . . . . . . . 229 Device (Processor variant setting). . . . . . . . . . . . . . . . . . . 216
AFE1_AFE2-1:1
Index
301
AFE1_AFE2-1:1
syntax feedback . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152 Enea OSE load module format, definition of . . . . . . . . . . 285
using . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139 enumeration, definition of . . . . . . . . . . . . . . . . . . . . . . . . . 285
word completion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142 environment variables, as argument variables . . . . . . . . . . . 89
Editor Setup Files (IDE Options dialog box) . . . . . . . . . . . 65 EOL character (editor option) . . . . . . . . . . . . . . . . . . . . . . . 61
editor setup files, options . . . . . . . . . . . . . . . . . . . . . . . . . . 65 EPROM, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
Editor Syntax Feedback (IDE Options dialog box) . . . . . . . 66 Erase Memory dialog box . . . . . . . . . . . . . . . . . . . . . . . . . 209
Editor window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 151 error checking (C-RUN), documentation . . . . . . . . . . . . . . 17
See also editor error messages
Editor (External editor option) . . . . . . . . . . . . . . . . . . . . . . 64 compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241
Editor (IDE Options dialog box) . . . . . . . . . . . . . . . . . . . . . 59 linker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
EEPROM, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . 285 errors, correcting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
ELF, converting from . . . . . . . . . . . . . . . . . . . . . . . . . . . . 254 ewd (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 191
Embedded C++ ewp (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 191
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285 ewplugin (filename extension) . . . . . . . . . . . . . . . . . . . . . 191
embedded system, definition of . . . . . . . . . . . . . . . . . . . . 285 eww (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 191
Embedded Workbench the workspace file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139 $EW_DIR$ (argument variable) . . . . . . . . . . . . . . . . . . . . . 88
layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 example projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
main window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 downloading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
reference information . . . . . . . . . . . . . . . . . . . . . . . . . . 193 running. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
running. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 $EXAMPLES_DIR$ (custom argument variable) . . . . . . . 27
version number, displaying . . . . . . . . . . . . . . . . . . . . . 213 examples, arm (subdirectory) . . . . . . . . . . . . . . . . . . . . . . 186
emulator (C-SPY driver), definition of . . . . . . . . . . . . . . . 285 exceptions
Enable exceptions (C++ options setting). . . . . . . . . . . . . . 230 enabling in compiler . . . . . . . . . . . . . . . . . . . . . . . . . . 230
Enable graphical stack display and stack usage tracking exceptions, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . 285
(Stack option) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77 excluding files from build . . . . . . . . . . . . . . . . . . . . . . . . . 110
Enable multibyte support (general option) . . . . . . . . 224–225 Exe (output directory) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
Enable parallel build (IDE Project options) . . . . . . . . . . . . 71 executable image
Enable project connections (IDE Project options) . . . . . . . . 71 analyzing using log file . . . . . . . . . . . . . . . . . . . . . . . . 269
Enable remarks (compiler option) . . . . . . . . . . . . . . . 240, 270 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
Enable RTTI (C++ options setting) . . . . . . . . . . . . . . . . . . 230 Executable (Output file setting) . . . . . . . . . . . . . . . . . . . . 220
Enable stack usage analysis (linker option) . . . . . . . . . . . . 267 Executables/libraries (output directory setting) . . . . . . . . . 221
Enable thread support in library (general option) . . . . . . . 222 execution mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
Enable virtual space (editor option) . . . . . . . . . . . . . . . . . . 62 Execution mode (general option) . . . . . . . . . . . . . . . . . . . 216
Enable (Warning setting) . . . . . . . . . . . . . . . . . . . . . . . . . 251 $EXE_DIR$ (argument variable) . . . . . . . . . . . . . . . . . . . . 88
Enabled transformations (compiler option) . . . . . . . . . . . . 235 expensive memory access, definition of . . . . . . . . . . . . . . 285
Encodings (compiler options) . . . . . . . . . . . . . . . . . . . . . . 241 Export (IDE colors and fonts option) . . . . . . . . . . . . . . . . . 53
encoding, editor options . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 extended command line file . . . . . . . . . . . . . . . . . . . . . . . 192
End address (Fill setting) . . . . . . . . . . . . . . . . . . . . . . . . . 272 extended keywords, definition of . . . . . . . . . . . . . . . . . . . 286
endianness, setting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
AFE1_AFE2-1:1
Index
303
AFE1_AFE2-1:1
64-bit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
Generate additional output (converter option). . . . . . . . . . 253 I
Generate browse information (IDE Project options) . . . . . . 70 i (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
Generate checksum (linker option) . . . . . . . . . . . . . . . . . . 272 iarbuild, building from the command line . . . . . . . . . 127, 134
Generate debug information (assembler option) . . . . . . . . 247 iarbuild.exe
Generate debug information (compiler option) . . . . . . . . . 236 reference information . . . . . . . . . . . . . . . . . . . . . . . . . . 134
Generate linker map file (linker option) . . . . . . . . . . . . . . 269 IarIdePm.exe . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
Generate log file (linker option) . . . . . . . . . . . . . . . . . . . . 269 icf (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 191
Generate #line directives icons
(Preprocessor output to file setting) . . . . . . . . . . . . . . . . . 239 in Workspace window . . . . . . . . . . . . . . . . . . . . . . . . . 109
generic pointers, definition of . . . . . . . . . . . . . . . . . . . . . . 286 SVN states . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118
glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 icons, in this guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Go to function (editor button) . . . . . . . . . . . . . . . . . . 148, 154 IDE
Go to Line dialog box . . . . . . . . . . . . . . . . . . . . . . . . . . . . 198 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
Group excluded from the build logging performance . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
(Workspace window icon) . . . . . . . . . . . . . . . . . . . . . . . . 109
overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Group of files (Workspace window icon) . . . . . . . . . . . . . 109
IDE internal file (Workspace window icon) . . . . . . . . . . . 109
groups, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
ielfdump, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
ielftool, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
H Ignore standard include directories
(compiler option) . . . . . . . . . . . . . . . . . . . . . . . . . . . 238, 249
h (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . . 191 ILINK
Harvard architecture, definition of . . . . . . . . . . . . . . . . . . 286 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
Header file (Workspace window icon) . . . . . . . . . . . . . . . 109 options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261
header files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 ILP32 (data model setting) . . . . . . . . . . . . . . . . . . . . . . . . 219
quick access to . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 148 inc (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 191
heap memory, definition of . . . . . . . . . . . . . . . . . . . . . . . . 286 Include compiler call frame information
heap size, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . 286 (Output assembler file setting) . . . . . . . . . . . . . . . . . . . . . 237
Helium extension, enabling. . . . . . . . . . . . . . . . . . . . . . . . 218 Include debug information in output (linker option) . . . . . 268
Help menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213 include files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
helpfiles (filename extension) . . . . . . . . . . . . . . . . . . . . . . 191 compiler, specifying path . . . . . . . . . . . . . . . . . . . 238, 249
High (Level setting) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234 definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
highly contrasting window colors . . . . . . . . . . . . . . . . . . . . 52 specifying path . . . . . . . . . . . . . . . . . . . . . . . . . . . 238, 250
host, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286 Include header (assembler option) . . . . . . . . . . . . . . . . . . 248
htm (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 191 Include listing (assembler option) . . . . . . . . . . . . . . . . . . . 248
HTML text file (Workspace window icon) . . . . . . . . . . . . 109 Include source (Output assembler file setting) . . . . . . . . . 237
html (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 191 Incremental Search dialog box (Edit menu) . . . . . . . . . . . 168
inc, arm (subdirectory) . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
Indent size (editor option) . . . . . . . . . . . . . . . . . . . . . . . . . . 59
AFE1_AFE2-1:1
Index
305
AFE1_AFE2-1:1
library functions list files
avoid stepping into (Functions with source only) . . . . . . 76 assembler
configurable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187 compiler runtime information . . . . . . . . . . . . . . . . . 237
Library low-level interface implementation conditional information, specifying . . . . . . . . 247–248
(general option). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222 cross-references, generating . . . . . . . . . . . . . . . . . . 248
Library Options 1 (general options) . . . . . . . . . . . . . . . . . 224 header, including . . . . . . . . . . . . . . . . . . . . . . . . . . . 248
Library Options 2 (general options) . . . . . . . . . . . . . . . . . 225 lines per page, specifying . . . . . . . . . . . . . . . . . . . . 248
Library (general option) . . . . . . . . . . . . . . . . . . . . . . . . . . 222 tab spacing, specifying . . . . . . . . . . . . . . . . . . . . . . 249
Library (linker options) . . . . . . . . . . . . . . . . . . . . . . . . . . . 263 compiler
Library (Output file setting) . . . . . . . . . . . . . . . . . . . . . . . 220 assembler mnemonics, including . . . . . . . . . . . . . . 237
library, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292 generating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237
lib, arm (subdirectory) . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 source code, including . . . . . . . . . . . . . . . . . . . . . . 237
lightbulb icon, in this guide. . . . . . . . . . . . . . . . . . . . . . . . . 19 List files (Output directories setting). . . . . . . . . . . . . . . . . 221
#line directives, generating in compiler . . . . . . . . . . . . . . 239 List (assembler options) . . . . . . . . . . . . . . . . . . . . . . . . . . 247
Lines/page (assembler option) . . . . . . . . . . . . . . . . . . . . . 248 List (compiler options) . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
linker List (linker option) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
command line version . . . . . . . . . . . . . . . . . . . . . . . . . . 23 List (output directory) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
setting options for . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261 $LIST_DIR$ (argument variable) . . . . . . . . . . . . . . . . . . . . 88
linker command file. See linker configuration file Little endian (Endian mode setting) . . . . . . . . . . . . . . . . . 217
linker configuration file location counter, definition of . . . . . . . . . . . . . . . . . . . . . . 291
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288 -log (iarbuild command line option) . . . . . . . . . . . . . . . . . 136
in directory. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 log file, generate from linker. . . . . . . . . . . . . . . . . . . . . . . 269
specifying in linker . . . . . . . . . . . . . . . . . . . . . . . . . . . 262 log (filename extension) . . . . . . . . . . . . . . . . . . . . . . 191–192
Linker Configuration File Editor dialog box . . . . . . . . . . . 277 logical address, definition of . . . . . . . . . . . . . . . . . . . . . . . 295
Linker configuration file (linker option) . . . . . . . . . . . . . . 262 Low (Level setting). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234
linker options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261 LP64 (data model setting) . . . . . . . . . . . . . . . . . . . . . . . . . 220
typographic convention . . . . . . . . . . . . . . . . . . . . . . . . . 19 lst (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
Advanced . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266 L-value, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
Checksum . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 272
Config . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262
define . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269 M
Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264 mac (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 191
Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263 Macro definitions (Include listing setting) . . . . . . . . . . . . 248
List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268 Macro execution info (Include listing setting) . . . . . . . . . 248
Optimizations. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 265 Macro expansions (Include listing setting) . . . . . . . . . . . . 248
Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267 Macro quote characters (assembler option) . . . . . . . . . . . . 246
#define . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269 macros, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
linker symbols, defining . . . . . . . . . . . . . . . . . . . . . . . . . . 270 MAC, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
mailbox (RTOS), definition of . . . . . . . . . . . . . . . . . . . . . 288
AFE1_AFE2-1:1
Index
307
AFE1_AFE2-1:1
Open Workspace (File menu) . . . . . . . . . . . . . . . . . . . . . . 194 Output file (library builder options) . . . . . . . . . . . . . . . . . 280
Opening Brace (a) (Configure auto indent option) . . . . . . . 63 Output filename (linker option) . . . . . . . . . . . . . . . . . . . . 268
operator precedence, definition of . . . . . . . . . . . . . . . . . . . 290 Output files (custom build option) . . . . . . . . . . . . . . . . . . 256
operators, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . 290 output image. See executable image
optimization levels, setting . . . . . . . . . . . . . . . . . . . . . . . . 234 Output list file (assembler option) . . . . . . . . . . . . . . . . . . . 247
Optimizations (compiler options) . . . . . . . . . . . . . . . . . . . 234 Output list file (compiler option) . . . . . . . . . . . . . . . . . . . 237
Optimizations (linker option) . . . . . . . . . . . . . . . . . . . . . . 265 Output (assembler option). . . . . . . . . . . . . . . . . . . . . . . . . 247
options Output (compiler options) . . . . . . . . . . . . . . . . . . . . . . . . . 235
assembler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245 Output (converter options) . . . . . . . . . . . . . . . . . . . . . . . . 253
build actions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257 Output (general options) . . . . . . . . . . . . . . . . . . . . . . . . . . 220
compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227 -output (iarbuild command line option) . . . . . . . . . . . . . . 136
converter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253 Output (library builder options) . . . . . . . . . . . . . . . . . . . . 280
custom build . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255 Output (linker options) . . . . . . . . . . . . . . . . . . . . . . . . . . . 267
editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 overlay, definition of. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
library builder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279 Override default program entry (linker option) . . . . . . . . . 263
linker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261
setup files for editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Options dialog box (Project menu) . . . . . . . . . . . . . . . . . . 129 P
using . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121 PACBTI extension, enabling . . . . . . . . . . . . . . . . . . . . . . 218
Options (Workspace window context menu) . . . . . . . . . . 110 -parallel (iarbuild command line option) . . . . . . . . . . . . . . 137
options, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290 parameter hint, in editor . . . . . . . . . . . . . . . . . . . . . . . . . . 144
Other file (Workspace window icon) . . . . . . . . . . . . . . . . 109 parameters
out (filename extension) . . . . . . . . . . . . . . . . . . . . . . 191–192 typographic convention . . . . . . . . . . . . . . . . . . . . . . . . . 19
output when building from command line . . . . . . . . . . . 127, 134
assembler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247 parentheses and brackets, matching (in editor) . . . . . . . . . 141
including debug information . . . . . . . . . . . . . . . . . . 247 part number, of this guide . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235 paths
including debug information . . . . . . . . . . . . . . . . . . 236 compiler include files. . . . . . . . . . . . . . . . . . . . . . 238, 249
converting from ELF . . . . . . . . . . . . . . . . . . . . . . 253–254 include files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238, 250
including debug information . . . . . . . . . . . . . . . . . . . . 268 relative, in Embedded Workbench . . . . . . . . . . . . . 99, 152
linker, specifying filename . . . . . . . . . . . . . . . . . . . . . . 268 source files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152
preprocessor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239 pbd (filename extension). . . . . . . . . . . . . . . . . . . . . . . . . . 192
Output assembler file (compiler option) . . . . . . . . . . . . . . 237 pbi (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 192
Output directories (general option) . . . . . . . . . . . . . . . . . . 221 Perform C++ Virtual Function Elimination
output file encoding (linker option) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266
specifying in linker . . . . . . . . . . . . . . . . . . . . . . . . . . . 275 performance issues, troubleshooting . . . . . . . . . . . . . . . . . . 68
Output file (converter option) . . . . . . . . . . . . . . . . . . . . . . 254 peripheral units, definition of . . . . . . . . . . . . . . . . . . . . . . 290
Output file (custom build option) . . . . . . . . . . . . . . . 256, 259 peripherals register. See SFR
Output file (general option). . . . . . . . . . . . . . . . . . . . . . . . 220 pew (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 192
AFE1_AFE2-1:1
Index
309
AFE1_AFE2-1:1
Reset All (Key bindings option) . . . . . . . . . . . . . . . . . . . . . 57
Q Reset (IDE colors and fonts option) . . . . . . . . . . . . . . . 52–53
qualifiers, definition of. See type qualifiers reset, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
restoring default factory settings . . . . . . . . . . . . . . . . . . . . 124
Result in full size (Generate checksum setting) . . . . . . . . 273
R Reverse byte order within word
(Generate checksum setting) . . . . . . . . . . . . . . . . . . . . . . . 273
range, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
ROM-monitor, definition of . . . . . . . . . . . . . . . . . . . . . . . 292
Raw binary image (linker option) . . . . . . . . . . . . . . . . . . . 264
root directory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
reading guidelines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
ropi, position-independence . . . . . . . . . . . . . . . . . . . . . . . 232
readme files, See release notes
Round Robin, definition of . . . . . . . . . . . . . . . . . . . . . . . . 292
read-only sections, definition of . . . . . . . . . . . . . . . . . . . . 291
rtos
Read/write data (compiler option). . . . . . . . . . . . . . . . . . . 232
arm (subdirectory) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
real-time operating system, definition of. . . . . . . . . . . . . . 291
RTOS, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
real-time system, definition of . . . . . . . . . . . . . . . . . . . . . 291
RTTI
Rebuild All (Workspace window context menu) . . . . . . . 111
enabling in compiler . . . . . . . . . . . . . . . . . . . . . . . . . . 230
reference information, typographic convention . . . . . . . . . . 19
runtime error checking, documentation. . . . . . . . . . . . . . . . 17
References window (View menu) . . . . . . . . . . . . . . . . . . . 171
runtime libraries
region expression, definition of. . . . . . . . . . . . . . . . . . . . . 291
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
region literal, definition of . . . . . . . . . . . . . . . . . . . . . . . . 291
specifying . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
register constant, definition of. . . . . . . . . . . . . . . . . . . . . . 291
runtime model attributes, definition of . . . . . . . . . . . . . . . 292
register locking, definition of . . . . . . . . . . . . . . . . . . . . . . 291
rwpi, position-independence . . . . . . . . . . . . . . . . . . . . . . . 232
register variables, definition of . . . . . . . . . . . . . . . . . . . . . 291
R-value, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
registered trademarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
registers
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
header files for in inc directory . . . . . . . . . . . . . . . . . . 186
S
relative paths . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99, 152 s (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
relay, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292 saturation arithmetics, definition of . . . . . . . . . . . . . . . . . 292
release notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 Save All (File menu) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
Reload last workspace at startup (IDE Project options) . . . 70 Save As (File menu) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
relocatable segments, definition of . . . . . . . . . . . . . . . . . . 292 Save editor windows before building
(IDE Project options) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
remarks, classifying diagnostics as . . . . . . . . . . . . . . 240, 271
Save workspace and projects before building
Remove trailing blanks (editor option) . . . . . . . . . . . . . . . . 62
(IDE Project options) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70
Remove (IDE colors and fonts option) . . . . . . . . . . . . . . . . 53
Save Workspace (File menu) . . . . . . . . . . . . . . . . . . . . . . 195
Rename Group dialog box . . . . . . . . . . . . . . . . . . . . . . . . 112
Save (File menu) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
Rename (IDE colors and fonts option) . . . . . . . . . . . . . . . . 53
Scan for changed files (editor option) . . . . . . . . . . . . . . . . . 61
Replace dialog box (Edit menu) . . . . . . . . . . . . . . . . . . . . 162
Scanf formatter (general option) . . . . . . . . . . . . . . . . . . . . 224
Replace in Files dialog box (Edit menu) . . . . . . . . . . . . . . 165
scheduler (RTOS), definition of . . . . . . . . . . . . . . . . . . . . 292
Require prototypes (C dialect setting) . . . . . . . . . . . . . . . . 230
scope, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
AFE1_AFE2-1:1
Index
311
AFE1_AFE2-1:1
Stop Build (Workspace window context menu) . . . . . . . . 111 templates for code, using . . . . . . . . . . . . . . . . . . . . . . . . . 144
Strict (Language conformance setting) . . . . . . . . . . . . . . . 229 tentative definition, definition of. . . . . . . . . . . . . . . . . . . . 294
strings, text style in editor . . . . . . . . . . . . . . . . . . . . . . . . . 146 Terminal I/O window, definition of . . . . . . . . . . . . . . . . . 294
structure value, definition of . . . . . . . . . . . . . . . . . . . . . . . 294 Terminal I/O (IDE Options dialog box) . . . . . . . . . . . . . . . 79
Subversion states and corresponding icons . . . . . . . . . . . . 118 terminology. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
suc (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 192 testing, of code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
Sum32 (checksum algorithm) . . . . . . . . . . . . . . . . . . . . . . 273 Text file (Workspace window icon) . . . . . . . . . . . . . . . . . 109
Suppress these diagnostics (compiler option) . . . . . . 240, 270 Text output file encoding (compiler option) . . . . . . . . . . . 242
svd (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 192 Text output file encoding (linker option) . . . . . . . . . . . . . 275
Symbol (Raw binary image setting) . . . . . . . . . . . . . . . . . 264 Themes (IDE colors and fonts option) . . . . . . . . . . . . . . . . 51
symbolic location, definition of . . . . . . . . . . . . . . . . . . . . 294 32-bit (general options) . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
symbols thread, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
See also user symbols Thumb (Processor mode setting) . . . . . . . . . . . . . . . . . . . 232
defining in linker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270 timer, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294 timeslice, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
symbols, defining . . . . . . . . . . . . . . . . . . . . . . . . . . . 239, 250 Tool Output window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
syntax coloring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 -tool (iarbuild command line option) . . . . . . . . . . . . . . . . 137
configuration files . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 toolbar, IDE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
in editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146 customizing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
syntax feedback in editor . . . . . . . . . . . . . . . . . . . . . . . . . 152 toolchain
setting up . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 extending . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
Syntax Feedback Level (editor option) . . . . . . . . . . . . . . . . 66 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Syntax highlighting (editor option) . . . . . . . . . . . . . . . . . . . 61 $TOOLKIT_DIR$ (argument variable) . . . . . . . . . . . . . . . 89
syntax highlighting, in editor window. . . . . . . . . . . . . . . . 146 tools icon, in this guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Tools menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
T tools, user-configured . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
trademarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Tab Key Function (editor option) . . . . . . . . . . . . . . . . . . . . 59 transformations, enabled in compiler . . . . . . . . . . . . . . . . 235
Tab size (editor option) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 translation unit, definition of . . . . . . . . . . . . . . . . . . . . . . . 295
Tab spacing (assembler option) . . . . . . . . . . . . . . . . . . . . 249 trap, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
Target (general options) . . . . . . . . . . . . . . . . . . . . . . . . . . 215 Treat all warnings as errors (compiler option) . . . . . . . . . 241
$TARGET_BNAME$ (argument variable) . . . . . . . . . . . . 89 Treat all warnings as errors (linker option) . . . . . . . . . . . . 271
$TARGET_BPATH$ (argument variable) . . . . . . . . . . . . . 89 Treat these as errors (compiler option) . . . . . . . . . . . . . . . 241
$TARGET_DIR$ (argument variable) . . . . . . . . . . . . . . . . 89 Treat these as errors (linker option) . . . . . . . . . . . . . . . . . 271
$TARGET_FNAME$ (argument variable) . . . . . . . . . . . . . 89 Treat these as remarks (compiler option) . . . . . . . . . 240, 271
$TARGET_PATH$ (argument variable) . . . . . . . . . . . . . . 89 Treat these as warnings (compiler option) . . . . . . . . . . . . 241
target, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294 Treat these as warnings (linker option) . . . . . . . . . . . . . . . 271
task, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294 Troubleshooting (IDE Options dialog box) . . . . . . . . . . . . . 68
Template dialog box (Edit menu) . . . . . . . . . . . . . . . . . . . 178 TrustZone import library (linker option) . . . . . . . . . . . . . . 268
AFE1_AFE2-1:1
Index
U Visual State
part of the tool chain . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
UBROF project file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295 volatile storage, definition of . . . . . . . . . . . . . . . . . . . . . . 295
tool for generating . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295 von Neumann architecture, definition of . . . . . . . . . . . . . . 295
Update intervals (IDE option) . . . . . . . . . . . . . . . . . . . . . . . 77 vsp (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . . 192
Use as input (Generate checksum setting). . . . . . . . . . . . . 274
Use Code Templates (editor option) . . . . . . . . . . . . . . . . . . 65
Use command line options (compiler option) . . 243, 252, 275 W
Use Custom Keyword File (editor option) . . . . . . . . . . . . . 65 Warn when exceeding stack threshold (Stack option) . . . . . 78
Use External Editor (External editor option) . . . . . . . . . . . . 64 Warn when stack pointer is out of bounds (Stack option) . . 78
User symbols are case sensitive (assembler option) . . . . . 246 warnings
$USER_NAME$ (argument variable) . . . . . . . . . . . . . . . . 89 assembler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 251
compiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241
V linker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
Warnings from to (Warning setting) . . . . . . . . . . . . . . . . . 251
value expressions, definition of. . . . . . . . . . . . . . . . . . . . . 295 warnings icon, in this guide . . . . . . . . . . . . . . . . . . . . . . . . 19
-varfile (iarbuild command line option) . . . . . . . . . . . . . . 137 Warnings (assembler option) . . . . . . . . . . . . . . . . . . . . . . 251
variable length arrays . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229 watchpoints, definition of . . . . . . . . . . . . . . . . . . . . . . . . . 295
variables, using in arguments . . . . . . . . . . . . . . . . . . . . . . . 82 web sites, recommended . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
veneer, definition of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295 When source resolves to multiple function instances . . . . . 76
Version Control System menu . . . . . . . . . . . . . . . . . . . . . 116 whitespace, showing in editor . . . . . . . . . . . . . . . . . . . . . . . 62
Version Control System Window menu. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212
(Workspace window context menu) . . . . . . . . . . . . . . . . . 112 windows
version number about organizing on the screen . . . . . . . . . . . . . . . . . . . . 25
of Embedded Workbench. . . . . . . . . . . . . . . . . . . . . . . 213 bright colors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
of this guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 dark mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
VFPv2 (FPU setting) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217 default colors and fonts . . . . . . . . . . . . . . . . . . . . . . . . . 51
VFPv3 (FPU setting) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217 high contrast colors . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
VFPv4 single-precision (FPU setting) . . . . . . . . . . . . . . . 218 how to organize on the screen . . . . . . . . . . . . . . . . . . . . 32
VFPv4 (FPU setting) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218 word completion, in editor . . . . . . . . . . . . . . . . . . . . . . . . 142
VFPv5 double-precision (FPU setting) . . . . . . . . . . . . . . . 218 Workspace window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108
VFPv5 single-precision (FPU setting) . . . . . . . . . . . . . . . 218 drag-and-drop of files . . . . . . . . . . . . . . . . . . . . . . . . . 100
VFP9-S (FPU setting) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218 Workspace window icons . . . . . . . . . . . . . . . . . . . . . . . . . 109
313
AFE1_AFE2-1:1
Workspace (Workspace window icon) . . . . . . . . . . . . . . . 109 % stack usage threshold (Stack option) . . . . . . . . . . . . . . . . 78
workspaces $CONFIG_NAME$ (argument variable) . . . . . . . . . . . . . . 88
creating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 $CUR_DIR$ (argument variable) . . . . . . . . . . . . . . . . . . . . 88
using . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 $CUR_LINE$ (argument variable) . . . . . . . . . . . . . . . . . . . 88
wsdt (filename extension) . . . . . . . . . . . . . . . . . . . . . . . . . 192 $DATE$ (argument variable) . . . . . . . . . . . . . . . . . . . . . . . 88
$EW_DIR$ (argument variable) . . . . . . . . . . . . . . . . . . . . . 88
AFE1_AFE2-1:1