|
1. |
|
Start IAR Embedded Workbench
|
|
|
|
Start -> Programs -> IAR Systems -> IAR
Embedded Workbench Kickstart for MSP430 V3 -> IAR Embedded
Workbench.
If the "Embedded Workbench Startup" dialog appears, cancel it.
|
|
2. |
|
Create a new project.
|
|
|
|
Project->create new project...
If you have existing code you wish to incorporate, select the "Empty project" template.
If starting a new assembler or C project,
click on the "+" sign next to the appropriate language and then
select "asm" or "main"
as appropriate.
|
|
3. |
|
Give the project a name
|
|
|
|
In the "Save As" dialog, browse to the directory where your project will reside
and enter a file name for the project.
|
|
4. |
|
Add any existing code.
|
|
|
|
If you have existing code to place in the project,
go to "Add Files" in the "Project" menu
and select the appropriate files.
|
|
5. |
|
Set options
|
|
|
|
Go to Options in the Project menu.
In the General Options category, select the Target tab.
Under Device select MSP430F2012 (for the 332 lab board) or MSP430F2013
(for the TI USB dongle) from the
MSP430x2xx Family.
If appropriate, check the "Assembler-only project" box.
(If you fail to do this, you will get a mysterious "e16" error in the
subsequent link step.)
In the Debugger category, select the Setup tab.
Set the Driver to FET debugger or Simulator, as appropriate.
|
|
6. |
|
Build the project
|
|
|
|
Select Rebuild All from the Project menu.
The first time the project is built you will be asked for the name of the workspace.
Enter the filename for the workspace in "Save Workspace As" dialog.
|
|
7. |
|
Begin debugging.
|
|
|
|
If the build is successful,
select Debug from the Project menu.
With an assembly language program
you may get a Stack Warning message:
"The stack plug-in failed to set a breakpoint on main.
The Stack window will not be able to display stack contents.
(You can change this setting in the Tools>Options dialog box.)"
This is because the debugger is expecting a C program
which will always have a function named "main."
You can either ignore this message, or label the entry point
of your program "main."
|