4 comment field, 5 symbols, 1 user-defined symbols – Motorola HC12 User Manual

Page 145: Comment field, Symbols, User-defined symbols

Advertising
background image

Assembler Syntax

Symbols

MCUez HC12 Assembler

User’s Manual

MOTOROLA

Assembler Syntax

145

Inside a relocatable section, expressions specified in an indexed PC relative
addressing mode may be:

A label defined in any absolute section

A label defined in any relocatable section

An external label, defined in an XREF directive

7.4.4 Comment Field

The last field in a source statement is an optional comment field. A semicolon
(;) is the first character in the comment field.

Example:

NOP

; Comment following an instruction

7.5 Symbols

The following sections describe symbols used by the assembler.

7.5.1 User-Defined Symbols

Symbols identify memory locations in program or data sections in an assembly
module.

A symbol has two attributes:

The section in which the memory location is defined

The offset from the beginning of that section.

Symbols can be defined with an absolute or relocatable value, depending on the
section in which the labeled memory location is found. If the memory location
is located within a relocatable section (defined with the SECTION directive),
the label has a relocatable value relative to the section start address.

Advertising