TI to IAR 2.x/3.x Assembler Migration
E.2.9 | Macro Directives |
|
|
|
Description |
| Asm430 Directive (TI) | A430 Directive (IAR) |
|
Define a macro | .macro | MACRO |
| |
Exit prematurely from a macro | .mexit | EXITM |
| |
End macro definition | .endm | ENDM |
| |
Additional A430 Directives (IAR) |
| A430 Directive (IAR) |
| |
Create symbol, local to a macro |
| LOCAL 1) |
|
1)In Asm430 local symbols are suffixed by a question mark (?).
E.2.10 Miscellaneous Directives
Description | Asm430 Directive (TI) | A430 Directive (IAR) |
Send | .emsg | #error |
output device |
|
|
Send | .mmsg | #message 1) |
device |
|
|
Send | .wmsg | 2) |
the output device |
|
|
Define a load address label | .label | 3) |
Directive produced by absolute lister | .setsect | ASEG 4) |
Directive produced by absolute lister | .setsym | EQU or = 4) |
Program end | .end | END |
1)The syntax of the #message directive is: #message “<string>”
This causes ‘#message <string>’ to be output to the project build window during assemble/compile time.
2)Warning messages cannot be
3)The concept of
; Asm430 code | ; A430 code | ||
.label | load_start | load_start: |
|
Run_start: |
| <code> |
|
<code> |
| load_end: |
|
Run_end: |
| run_start:EQU | 240H |
.label | load_end | run_end: EQU |
4)Although not produced by the absolute lister ASEG defines absolute segments and EQU can be used to define absolute symbols.
MYFLAG | EQU | 23EH | ; MYFLAG is located at 23E |
| ASEG | 240H | ; Absolute segment at 240 |
MAIN: | MOV | #23CH, SP | ; MAIN is located at 240 |
| ... |
|
|
Additional A430 Directives (IAR) | A430 Directive (IAR) |
Set the default base of constants | RADIX |
Enable case sensitivity | CASEON |
Disable case sensitivity | CASEOFF |
E.2.11 Preprocessor Directives
The A430 assembler includes a preprocessor similar to that used in C programming. The following preprocessor directives can be used in include files which are shared by assembly and C programs.