SLAU131V October 2004 – February 2020
To invoke the assembler, enter the following:
cl430input file [options] |
cl430 | is the command that invokes the assembler through the compiler. The compiler considers any file with an .asm extension to be an assembly file and invokes the assembler. |
input file | names the assembly language source file. |
options |
identify the assembler options that you want to use. Options are case sensitive and can appear anywhere on the command line following the command. Precede each option with one or two hyphens as shown. |
The valid assembler options are listed in Table 4-1.
Some runtime model options such as --code_model and --silicon version influence the behavior of the assembler. These options are passed to the compiler, assembler, and linker from the shell utility, which is detailed in the MSP430 Optimizing C/C++ Compiler User's Guide.
Option | Alias | Description |
---|---|---|
--absolute_listing | -aa | Creates an absolute listing. When you use --absolute_listing, the assembler does not produce an object file. The --absolute_listing option is used in conjunction with the absolute lister. |
--asm_define=name[=def] | -ad | Sets the name symbol. This is equivalent to defining name with a .set directive in the case of a numeric value or with an .asg directive otherwise. If value is omitted, the symbol is set to 1. See Section 4.8.5. |
--asm_dependency | -apd | Performs preprocessing for assembly files, but instead of writing preprocessed output, writes a list of dependency lines suitable for input to a standard make utility. The list is written to a file with the same name as the source file but with a .ppa extension. |
--asm_includes | -api | Performs preprocessing for assembly files, but instead of writing preprocessed output, writes a list of files included with the .include directive. The list is written to a file with the same name as the source file but with a .ppa extension. |
--asm_listing | -al | Produces a listing file with the same name as the input file with a .lst extension. |
--asm_listing_cross_reference | -ax | Produces a cross-reference table and appends it to the end of the listing file; it also adds cross-reference information to the object file for use by the cross-reference utility. If you do not request a listing file but use the --asm_listing_cross_reference option, the assembler creates a listing file automatically, naming it with the same name as the input file with a .lst extension. |
--asm_undefine=name | -au | Undefines the predefined constant name, which overrides any --asm_define options for the specified constant. |
--cmd_file=filename | -@ | Appends the contents of a file to the command line. You can use this option to avoid limitations on command line length imposed by the host operating system. Use an asterisk or a semicolon (* or ;) at the beginning of a line in the command file to include comments. Comments that begin in any other column must begin with a semicolon. Within the command file, filenames or option parameters containing embedded spaces or hyphens must be surrounded with quotation marks. For example: "this-file.asm" |
--include_file=filename | -ahi | Includes the specified file for the assembly module. The file is included before source file statements. The included file does not appear in the assembly listing files. |
--include_path=pathname | -I | Specifies a directory where the assembler can find files named by the .copy, .include, or .mlib directives. There is no limit to the number of directories you can specify in this manner; each pathname must be preceded by the --include_path option. See Section 4.5.1. |
--quiet | -q | Suppresses the banner and progress information (assembler runs in quiet mode). |
--silicon_version={msp|mspx} | Selects the instruction set version. Using --silicon_version=mspx generates code for MSP430x devices (20-bit code addresses). Using --silicon_version=msp generates code for 16-bit MSP430 devices.
Modules assembled/compiled for 16-bit MSP devices are not compatible with modules that are assembled/compiled for 20-bit MSPx devices. The linker generates errors if an attempt is made to combine incompatible object files. |
|
--symdebug:dwarf or
--symdebug:none |
-g | (DWARF is on by default) Enables assembler source debugging in the C source debugger. Line information is output to the object module for every line of source in the assembly language source file. You cannot use this option on assembly code that contains .line directives. See Section 4.12. |