User manual

ST Assembler-Linker Introduction
Doc ID 11392 Rev 4 9/89
Generally, the instruction sets are similar, with the following notable differences:
The STM8 instruction set supports several new addressing modes.
The Stack Pointer (SP) can be used as an index.
Long pointers have been added.
There is a new 3-byte addressing mode called extended.
Altogether there are 6 new addressing modes:
short offset SP indexed,
extended direct,
extended offset X or Y indexed,
long pointer to long data,
long pointer to long data X indexed,
long pointer to 24-bit data X or Y indexed.
Several new instructions have been added.
The STM8 instruction set allows for longer instructions which may span 5 bytes,
instead of 4 for the ST7.
1.2 Tools
The ST Assembler-Linker includes the following tools:
Assembler (ASM): translates your source code (.ASM) written in assembly language,
into object code (.OBJ) specific to the target machine and a listing file with relative
addresses(.LSR).
Linker (LYN): processes the object files (.OBJ) produced by the assembler, resolves
all cross-references between object files and locates all the modules in memory. The
resulting code is output in an object code file (.COD).
Converter (OBSEND): translates the object code file to produce the final executable in
a format that you specify (Motorola S-record, Intel Hex).
List file postprocessor (ABSLIST): patches the list file generated by the assembler to
produce a new list file with absolute addresses (.LST).
Librarian (LIB): The librarian enables you to store frequently used subroutines in one
location for use with any number of ST microcontroller applications.
Note: The utility file asli.bat automatically runs ASM, LYN, OBSEND and ABSLIST one after
the other for you. Use this batch file only if you have only one assembly source file .ASM.
1.3 Host PC system requirements
Please see the release notes to ensure you have the most up-to-date information.
1.4 Getting assistance
For more information, application notes, FAQs and software updates for all the ST
microcontroller development tools, check out the CD-ROM or our web site: www.st.com.