EasyManua.ls Logo

HP 48GII

HP 48GII
653 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
6-12 The Development Library
l!6G&!OZp=$o)8!OZp=$o)3!ddd!OZp=$o)=03!l!
Defines N constants OZp=$o)
?
with a value of CP+x*Inc and then changes the CP value to CP+N*Inc.
By default, Inc is a decimal number or an expression that can be immediately evaluated.
These features are extremely useful to define area of memory for storage of ASM program variables.
Note 1: If the entry point library (see related section) is installed on your calculator, all the values in the constant
library will be available in your programs the same way than constants are.
Note 2: You can define a constant in your program to override the value of an entry in the equation library.
4.1.10 Expressions
An expression is a mathematical operation that is calculated at compilation time. Terms of this operation are
hexadecimal or decimal values, constants or labels. An expression stops on a separation character or a ‘
ƒ’.
4OO2!Q!x4$p$!
ddd!
43[-Q/x4$p$'…38,gH!
48[-Q/…Q'452!
EO-Q/I452I'gQ!
are correct expressions (provided that the entry point library is installed).
Notes:
A hexadecimal value must begin with a
.
A decimal value may begin with a
g or a number directly.
A
or!-./ equals the offset of the current instruction in the program (This value has no meaning in
itself, but may be used to calculate the distance between a label and the current instruction). In absolute
mode, this represents the final address of the instruction.
The value of a label is the offset of the label in the program (This value has no meaning in itself, but may
be used to calculate the distance between a label and the current instruction). In absolute mode, this
represents the final address of the instruction.
Entries from the EXTABLE may be used. As the EXTABLE does not have the label names limitations
with operators, in ambiguous case (
452'gQ may either be an addition 452!'!Q, or an entry
452'gQ‘), add II around the word: I452I'gQ.
Calculations are done with 64 bits.
X divide by 0 = $FFFFFFFFFFFFFFFF.
In order to avoid wasting memory, MASD tries to compile expressions as soon as it sees them. If MASD
is not able to compile an expression directly, it’s compiled at the end of the compilation. In order to use
less memory, it’s a good idea to define your constants at the beginning of the sources so MASD can
compile expression using the constants directly.
The only operator symbols not allowed in labels are +, -, * and /; therefore, if you want to use a symbol
operator after a label, you must put the symbol between " in order to ‘limit’ the symbol. Meaningless
Example:
I452IzzQ.
A label/constant with strange char may be ‘protected’ between " chars.
The evaluation stack of MASD allows you to have around 10 pending computations (parenthesis,
operator priority).
MASD only works with integers. You can represent signed values using standard 2’s complement, but be
careful as all operators are unsigned.
MASD recognizes the following operators:

Table of Contents

Other manuals for HP 48GII

Related product manuals