Defines a name having an absolute-expression or relative-expression value.
Symbol field |
Mnemonic field |
Operand field |
Comment field |
name |
.EQU |
expression[.bit-position] |
[; comment] |
name |
.EQU |
PSW[.bit-position] |
[; comment] |
Defines a name having an absolute-expression or relative-expression value specified by the operand field.
You can use this directive to define names for numerical data that can be used instead of the actual numbers in the operands of machine-language instructions and directives in source code. |
We recommend defining frequently used numerical values as names. Even if a given value in the source program is to be changed, you will only need to change the value corresponding to the name. |
The name generated by the .EQU directive can be externally defined by the .PUBLIC directive. |
If the name is externally defined by the .PUBLIC directive, a symbol defined in any other module cannot be specified as the operand. |
The absolute expression should be in accordance with "(a) Absolute expression".
The relative expression should be in accordance with "(b) Relative expressions".
When PSW is specified, the value is 0xFFFFA.
An illegal operand will cause an error.
A value between 0x00000000 and 0xFFFFFFFF can be specified as the operand, and a value between 0 and 7 can be specified as the bit position. |