Start
Start
Copyright © 1983-2016 by Green Hills Software. All rights reserved. No part of this publication may be reproduced, stored
in a retrieval system, or transmitted, in any form or by any means, electronic, mechanical, photocopying, recording, or
otherwise, without prior written permission from Green Hills Software.
Green Hills, the Green Hills logo, CodeBalance, GMART, GSTART, INTEGRITY, MULTI, and Slingshot are registered
trademarks of Green Hills Software. AdaMULTI, Built with INTEGRITY, EventAnalyzer, G-Cover, GHnet, GHnetLite,
Green Hills Probe, Integrate, ISIM, u-velOSity, PathAnalyzer, Quick Start, ResourceAnalyzer, Safety Critical Products,
SuperTrace Probe, TimeMachine, TotalDeveloper, DoubleCheck, and velOSity are trademarks of Green Hills Software.
All other company, product, or service names mentioned in this book may be trademarks or service marks of their respective
owners.
For a listing of Green Hills Software's periodically updated patent marking information, please visit
http://www.ghs.com/copyright_patent.html.
PubID: start_no_wmaade-558975
Branch: http://toolsvc/branches/release-branch-70
Date: May 6, 2016
Contents
Preface v
About This Book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vi
The MULTI 7 Document Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii
Conventions Used in the MULTI Document Set . . . . . . . . . . . . . . . . . . . . viii
1. Introduction 1
The MULTI Integrated Development Environment . . . . . . . . . . . . . . . . . . . 2
MULTI Launcher . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Editing Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Building Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Debugging Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Administrative Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
The MULTI Launcher . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
MULTI Workspaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Accessing Online Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Full Online Manuals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Context-Sensitive Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Command, Configuration Option, and Keyword Help . . . . . . . . . . . . . 7
The Help Viewer Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Navigating Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Searching Manuals in the Help Viewer . . . . . . . . . . . . . . . . . . . . . . . . . 12
2. MULTI Tutorial 15
Creating Your First Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Building Your Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Starting the Debugger . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Connecting to a Simulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Debugging Your Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Connecting to Your Target Hardware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Index 27
Contents
About This Book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vi
The MULTI 7 Document Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii
Conventions Used in the MULTI Document Set . . . . . . . . . . . . . . . . . . . . . . . . viii
Preface
This preface discusses the purpose of this manual, the MULTI documentation set,
and typographical conventions used.
Note
New or updated information may have become available while this book
was in production. For additional material that was not available at press
time, or for revisions that may have become necessary since this book
was printed, please check your installation directory for release notes,
README files, and other supplementary documentation.
For a comprehensive list of the books provided with your MULTI installation, see
the Help → Manuals menu accessible from most MULTI windows.
• Print
• Online help, accessible from most MULTI windows via the Help → Manuals
menu
• PDF, available in the manuals subdirectory of your IDE or Compiler installation
• gxyz is a command.
• The option -option should either be replaced with one or more appropriate
options or be omitted.
• The word filename should be replaced with the actual filename of an
appropriate file.
The square brackets and the ellipsis should not appear in the actual command you
enter.
Introduction
Contents
The MULTI Integrated Development Environment . . . . . . . . . . . . . . . . . . . . . . . 2
The MULTI Launcher . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
Accessing Online Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Chapter 1. Introduction
The MULTI IDE includes the following tools, most of which can be launched from
within the IDE or as a separate stand-alone program. Parenthetical text indicates
corresponding executable files, which are located in your MULTI IDE installation.
MULTI Launcher
• MULTI Launcher (mstart) — The gateway to the MULTI IDE, which allows
you to quickly launch any of the primary MULTI tools, access open windows,
and manage MULTI workspaces. For more information, see “The MULTI
Launcher” on page 4.
Editing Tools
• MULTI Editor (me) — A graphical editor for modifying text files. See Chapter
4, “Editing Files with the MULTI Editor” in the MULTI: Managing Projects
and Configuring the IDE book.
• Checkout Browser (mcobrowse) — A graphical viewer for files managed
under a version control system. See “The Checkout Browser” in Chapter 6,
“Using MULTI's Version Control Tools and Capabilities” in the MULTI:
Managing Projects and Configuring the IDE book.
• Diff Viewer (diffview) — A graphical viewer that displays differences between
two text files. See “The Diff Viewer” in Chapter 6, “Using MULTI's Version
Control Tools and Capabilities” in the MULTI: Managing Projects and
Configuring the IDE book.
Building Tools
Debugging Tools
Administrative Tools
The MULTI Launcher provides a convenient way to launch frequently used tools,
to create or access files and projects, and to manage MULTI workspaces. To open
the MULTI Launcher:
• Windows — From the Windows Start menu, select the MULTI menu item.
Alternatively, use Windows Explorer to navigate to the directory where you
installed the MULTI IDE, and double-click multi.exe.
• Linux/Solaris — Run the multi executable from your MULTI IDE installation
directory.
Tip
If you cannot obtain a license to use MULTI, see Chapter 1, “Licensing
for End Users” in the MULTI: Licensing book.
All of the main MULTI components can be accessed from the Launcher toolbar:
You can also launch the Green Hills License Administrator and, if installed, the
Green Hills Probe Administrator from the Utilities menu.
During development, you can use the MULTI Launcher as a convenient, centralized
window manager. You can access any of your open MULTI windows from the
Windows menu of the Launcher.
MULTI Workspaces
The MULTI Launcher allows you to create and use workspaces. A MULTI
workspace is a virtual area where the tools, files, and actions required for a particular
project can be organized, accessed, and executed.
A workspace is typically created for each Top Project, and includes a working
directory and a group of related actions—for example, opening a project in the
MULTI Project Manager, connecting to a target, or performing a shell command.
Actions are grouped into action sequences, so that a single mouse click can perform
all the actions in the specified action sequence.
For more information, see Chapter 3, “Managing Workspaces and Shortcuts with
the Launcher” in the MULTI: Managing Projects and Configuring the IDE book.
You can also access manuals from the command line. Ensure that the IDE installation
directory is in your path, and enter the following command:
where:
• pathname opens the .chm file specified in pathname. You must provide a
full path.
• -m manual_name opens the manual manual_name. An example manual name
is "MULTI: Debugging". If the manual name contains a space as in the
preceding example, you must enclose it in quotation marks.
Context-Sensitive Help
Many MULTI windows and dialog boxes are linked to specific topics in the online
manuals. To view the topic for an active window or dialog box, press F1.
If you are using the MULTI Editor, you can also open context-sensitive help about
a button or a menu item by selecting Help → Identify and then clicking the button
or selecting the menu item.
To print the basic syntax of a MULTI Debugger command to the command pane,
type usage command_name.
The Help Viewer toolbar contains the following buttons, from left to right:
• Back ( ) and Forward ( ) — Returns to pages you have visited during the
current help session. Click the button once for each page you want to revisit.
Click and hold the button to select from a list of pages you have visited. These
buttons function across books.
• View All Subtrees ( ) — Toggles the display of the current selection's
sub-topics (if any) in the view pane. When you open the Help Viewer, this
button defaults to its last value.
• Contract All Unselected ( ) — Collapses expanded topics in the Contents
tab if the topics do not contain any selections.
• Print ( ) — Prints the help page displayed in the view pane. To create a help
page consisting of mixed topics, hold down the Ctrl key while clicking separate
topics. MULTI combines the separate topics and orders them by their location
in the Contents tab.
• Previous Page ( ) and Next Page ( ) (located at far right) — Displays the
previous or following topic as ordered in the Contents tab. If the previous or
next topic includes sub-topics and the View All Subtrees button is enabled,
the Help Viewer displays the sub-topics along with the section.
The MULTI Help Viewer contains two panes. The right-hand pane, or the view
pane, displays the help page for your selection. The left-hand pane contains the
following three tabs:
• Contents — Displays topics in the manual you are viewing. Click a plus or
minus icon to show or hide nested topics. Click a topic to display it in the view
pane.
• Index — Displays index entries for the manual. To search the index entries,
enter a word or words in the text box located at the top of the pane. MULTI
returns results that contain the word(s) you typed. Click an index entry to
display the associated topic in the view pane.
• Search — Allows you to search for specific words in the current manual or in
all manuals. For information about searching from this tab, see “Searching
Manuals in the Help Viewer” on page 12.
Navigating Help
Navigating manuals in the MULTI Help Viewer is easy. This section describes
different ways to find information.
• Click the or button located in the upper-right corner of the Help Viewer
window.
• Select View → Previous Contents Entry or View → Next Contents Entry.
If the previous or next topic includes sub-topics and the View All Subtrees button
( ) is enabled, the Help Viewer displays the sub-topics along with the topic.
• Click the or button located in the left corner of the toolbar. Click the
button once for each page you want to revisit. Click and hold the button to
select from a complete list of pages you have visited during the current help
session. These buttons function across books.
• Select View → Back or View → Forward from the menu bar. This feature
functions across books.
If you click a link and see a dialog box stating that documentation is not available,
one of the following factors may be the cause:
• The documentation that the link points to may not be included with your
distribution.
Note
If you are using MULTI with multiple target architectures (such as ARM
and Power Architecture), you may install tools of the same version number
into a single directory. If you click a link to a target-specific book in this
case, MULTI chooses which version of the book to link to (ARM or
Power Architecture in this example).
You can bookmark a help page consisting of mixed topics by holding down the
Ctrl key while clicking separate topics. MULTI combines the separate topics in
the view pane and orders them by their location in the Contents tab. Bookmark the
page as usual.
The Bookmarks menu lists all your bookmarks from across MULTI manuals and
sessions. To return to a bookmarked page, do one of the following:
Managing Bookmarks
You can use the Bookmark Manager to rename or delete bookmarks, navigate to
bookmarks, or modify the ordering of bookmarks in the Bookmarks menu.
The list on the left side of the Bookmark Manager displays the names of all the
bookmarks you have created. When a bookmark is selected, the topic(s) and the
manual marked by that bookmark are displayed in the right side of the window.
The bookmark may reference multiple topics if, for example, you created the
bookmark with multiple entries selected in the Contents tab or if you selected an
index entry associated with multiple topics. Double-clicking a bookmark or a topic
displays that bookmark or topic in the Help Viewer.
The toolbar buttons in the Bookmark Manager allow you to perform the following
operations on bookmarks:
Note
The and buttons are available for use on multiple bookmarks. You
can select multiple bookmarks from the left side of the window by
dragging to select rows or by using Shift or Ctrl to select items.
• Select File → Open Manual and choose from the list of installed manuals.
For information about how the list is populated, see “Full Online Manuals”
on page 6.
• Select File → Open Manual File and navigate to a particular file in the file
chooser that appears.
To open a new manual in a new window, select View → Open Other Manuals in
New Window and then open the manual as usual. When you open the Help Viewer,
the Open Other Manuals in New Window toggle option defaults to its last value.
To search for a phrase, put quotation marks around the phrase. To exclude a
word from the search, prefix it with an exclamation point (!). For example,
typing help !MULTI displays all the search results for help that do not contain
the word MULTI in their content. To search for an exclamation point at the
beginning of a word, you must enter a plus sign followed by an exclamation
point (+!). Full regular expressions are not supported.
2. To search for all keywords — Select all from the Find pages matching
drop-down list. The search function returns results that contain all the search
words; however, they may not occur as a phrase unless you enclosed them in
quotation marks.
To search for any keywords — Select any from the Find pages matching
drop-down list. The search function returns results that contain one of the
words, a combination of the words, or all of the words.
3. Select the Match whole word only check box if you want the search results
to contain the keyword as you typed it. For example, if you select this option,
search results for a singular word do not contain the plural form of the word.
4. To search all installed manuals, select the Search all manuals check box. For
information about what installations the manuals are pulled from, see “Full
Online Manuals” on page 6. To search only the current manual, clear this
check box.
5. Press Enter to display a list of search results. Click any entry in the list to
display the entry's help page in the view pane. If no results appear, no matches
were found.
MULTI Tutorial
Contents
Creating Your First Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Building Your Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Starting the Debugger . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Connecting to a Simulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Debugging Your Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Connecting to Your Target Hardware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Preparing Your Target . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Setting Up a Workspace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Additional Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
Configuring MULTI for Use with INTEGRITY or u-velOSity . . . . . . . . . . . . . 26
Chapter 2. MULTI Tutorial
This chapter introduces you to the basic components of the MULTI IDE, and leads
you through creating and building a simple Hello World program. You will then
run and debug this program on both a simulator and your target hardware.
2. Select File → Create Workspace to open the Select Workspace Type dialog.
3. Enter Hello World in the Name field. Click OK to create a workspace and
launch the Project Wizard.
4. Click Next to accept the default settings for the project directory.
5. Select the Stand-alone operating system. Click Next.
6. If only one processor family is available, the Project Wizard automatically
selects it and continues to the next screen. Otherwise, select your processor
family and click Next.
7. Select your target board. If it is not listed or if you have not yet decided on
one, expand the Generic list and select the processor you intend to target.
Click Finish.
8. In the Top Project Created dialog box that appears next, click OK.
9. The Project Manager: Select Item to Add screen appears next. This screen
allows you to add an example or executable to the framework just created by
the Project Wizard.
For this tutorial, select Hello World (C) and click Finish to accept the defaults
for the remaining settings. The Project Manager will open on your new project.
For comprehensive information about the Project Wizard, see “Creating a Project”
in Chapter 1, “Creating a Project” in the MULTI: Managing Projects and
Configuring the IDE book.
The project is ready to build at this point. Click (Build) to build the executable
program, hello. You can follow the progress of the build in the Status pane at the
bottom of the Project Manager window.
For more information about the MULTI Project Manager, see Chapter 2, “Managing
and Building Projects with the Project Manager” in the MULTI: Managing Projects
and Configuring the IDE book.
For information about the MULTI Debugger, see Chapter 2, “The Main Debugger
Window” in the MULTI: Debugging book.
Connecting to a Simulator
Before debugging the program in the MULTI Debugger, you must connect to a
hardware target or simulator that will run the program. The simulators provide an
easy-to-use platform to develop and debug your application before you begin
working with actual hardware. Perform the following steps to connect to a Green
Hills simulator:
2. MULTI creates several Connection Methods for your target board as part of
your project. Select the simulator connection from the drop-down list and click
Connect.
• To step into the program, click (Step (into Functions) on Selected Items)
on the Debugger toolbar.
Note
MULTI will automatically download your program to the simulator
when you first begin executing the code.
For more information about debugging your program, see the MULTI: Debugging
book.
For a quick reference to the commands available in the MULTI Debugger, see the
Quick Reference Card (only available in print).
If your debug device is not listed, click (Create a new Connection Method)
and enter a name and type for your connection.
Click Create and review the information to verify that this Connection Method
is configured correctly for your board setup. Double-check the connection
type and name (or address), and any other relevant settings. Click OK when
all of the settings are correct.
1. Select the hello executable in the target list (located on the left side of the
Debugger window, beside the source pane).
2. Click (Prepare Target) on the Debugger toolbar to open the Prepare
Target dialog box.
3. MULTI recommends settings for preparing your target based on the executable
you are debugging. Click OK to accept the recommended settings and
download the hello executable to your target.
Note
Some target boards may require modifications to the setup script provided
by Green Hills. For more information, see “Configuring Your Target
Hardware for Debugging” in Chapter 6, “Configuring Your Target
Hardware” in the MULTI: Debugging book.
You are now ready to debug your program on your target board.
Once you are finished debugging, click (Disconnect) to disconnect from your
target hardware. Then close the MULTI Debugger and the MULTI Project Manager.
Setting Up a Workspace
MULTI workspaces allow you to easily associate actions with a project and perform
those actions from within the Launcher. You will now add actions to the workspace
created at the beginning of this tutorial.
Follow the steps below to add additional actions that connect to your target and
open your program in the MULTI Debugger:
1. Switch to or start the Launcher, and select the Hello World workspace from
the drop-down list.
2. Right-click the Startup action sequence and select Add Action from the
shortcut menu.
3. Select Connection in the Action drop-down list.
4. Select your hardware target Connection Method in the Target drop-down list
and click OK.
5. Right-click the Startup action sequence and select Add Action from the
shortcut menu.
6. Select Debug Program in the Action drop-down list.
7. Select your hello executable in the Prog drop-down list and click OK.
The Startup action sequence in your workspace now contains two additional actions,
one each of type Connection and Debug Program. Now, whenever you run the
Startup action sequence, MULTI will open your project in the MULTI Project
Manager, connect to your target, and open your program in the MULTI Debugger.
Run the Startup action sequence by clicking the (Run Action Sequences or
Shortcuts) button and selecting Hello World: Startup.
Additional Examples
There are a number of example projects that highlight particular features of the
MULTI Debugger. To access these examples, perform the following steps:
1. Switch to or start the Launcher, and select the Hello World workspace from
the drop-down list.
2. Double-click the Project Manager action.
3. In the Project Manager, select the default.gpj file for the Hello World project
you created earlier, and click (Add Item into default.gpj).
4. Select one of the demo projects in the Project Manager: Select Item to Add
dialog box. The Basic Debugging project is a good one to start with. Click
Finish.
5. Select the demo project you just added, and click (Build).
6. Click (Debug), and follow the Cmd pane directions, which lead you through
the example.
The dialog box that appears is an interface to the per-user file integrity.dist
or uvelosity.dist.
2. Type the path to your INTEGRITY or u-velOSity installation directory, or use
the browse button to navigate to the directory.
3. Click Save.
B I
Integrated Development Environment (IDE) (see MULTI
breakpoints Integrated Development Environment (IDE))
setting, 21 INTEGRITY
building projects, 19 using with MULTI IDE, 26
interlaced assembly
C viewing, 22
command help, 7
commands K
help regarding, 7 keyword help, 7
helpview, 6
configuration options
help regarding, 7
L
connecting Launcher (see MULTI Launcher)
to hardware, 22
to simulator, 20 M
context-sensitive help, 6 MULTI Integrated Development Environment (IDE)
conventions document set, vii
typographical, viii online help, 6
creating overview, 2
projects, 16 using with INTEGRITY or u-velOSity, 26
workspaces, 17 MULTI Launcher
overview, 4
D
Debugger O
starting, 20 online help, 6
using, 21 (see also Help Viewer)
document set, vi, vii for commands, 7
for configuration options, 7
E context-sensitive, 6
example projects, 25 for keywords, 7
limitations, 10
online manuals, 6
F overview, 6
F1 key, for help, 6
preparing your target
P
preparing your target, 23
programs
stepping into, 21
Project Wizard, 17
projects
building, 19
creating, 16
examples, 25
R
registers
viewing, 21
S
setting breakpoints, 21
simulator
connecting to, 20
starting
Debugger, 20
stepping into programs, 21
T
target
preparing, 23
typographical conventions, viii
U
u-velOSity
using with MULTI IDE, 26
V
viewing
interlaced assembly, 22
registers, 21
W
workspaces
adding actions to, 24
creating, 17
overview, 5