12.07.2015 Views

MAXQ Core Assembly Guide - Maxim

MAXQ Core Assembly Guide - Maxim

MAXQ Core Assembly Guide - Maxim

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>MAXQ</strong> <strong>Core</strong> <strong>Assembly</strong> <strong>Guide</strong>EquatesEquates, which are defined using the EQU directive, are used for numeric replacement in any place that a constantvalue would normally be used. They may use all the formats and constant operators defined above for constants.Labels cannot be used in equate definitions.The syntax for defining an equate is as follows. equ Identifiers in Macro follow the same rules as identifiers in MaxQAsm. They may be from 1 to 127 characters inlength and may consist of the following characters:• Alphabetic characters “A” to “Z” or “a” to “z”. Identifiers in Macro are case-insensitive; that is, “DEF1” and“def1” are considered equivalent.• Numeric characters “0” to “9”. However, a numeric character may not be the first character in an identifier(such as “0DEF”).• The characters “_” (underbar), “?” (question mark), and “$” (dollar sign).Additionally, the value for an equate directive must be one that has not previously been used as anidentifier in a #define or macro definition.The value for an equate directive may use any allowed constant format (binary, hex, decimal) and maycontain constant operators and previously established equates and defines. Note: The value of an equate islimited to 32 bits (00000000h – 0FFFFFFFFh).As an example, the source file shown here:X equ 1Y equ 1000bZ equ 10hS1 equ X + XS2 equ S1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!