HP 48gII Advanced User's Reference Manual page 511

Graphing calculator
Hide thumbs Also See for 48gII:
Table of Contents

Advertisement

4.3.2
Skips
Skips are a first step from ML to a third generation language, even if they are only another way to write ASM
instructions.
Skips are wonderful as they allow you to:
-
structure your program
-
avoid using gotos
-
make programs and piece of code that can be easily copied and past (because there is no label)
The foundation of Skips is the Block structure.
A block is enclosed in
and
{
The following instructions deal with blocks.
SKIPS instructions
...
{
}
...
SK<Cond> {
}
...
SKUB<Cond> {
}
Once blocks are defined, special instructions can be used in them. The instructions called EXIT and UP allow
jumping to the end or to the beginning of a block.
These instructions
{
EXIT<Cond>
UP<Cond>
}
EXIT and UP can jump to the beginning or to the end of an upper-level block by specifying the number of blocks
to exit, after the UP or EXIT instructions.
These instructions
{
{
{
UP<Cond>2
UP<Cond>3
EXIT<Cond>1
EXIT<Cond>3
}
}
}
Note 1: EXIT1 is equivalent to EXIT, and UP1 is equivalent to UP.
4.3.3
Instruction set
Note: for instruction names, the case does not matter.
Register names are:
R0, R1, R2, R3, R4, R5, R6, R7, R8, R9, R10, R11, R12, R13 (or SP), R14 (or LP or LR) and R15 (or PC).
Setting the S flag on an instruction causes the instruction to modify the flags.
Every instruction is evaluated ONLY if the attached condition is true. By default, the instruction is always evaluated.
Separation between arguments can be either ',' or spaces.
, and can be nested within another block.
}
Equivalents
Defines a block (generates no code)
...
B<cond> .S
*.S
...
BL<cond> .S
are equivalent to
*.Beginning
B<Cond> .End
B<Cond>.Beginning
*.End
Are equivalent to
*.Beg3
*.Beg2
*.Beg1
B<Cond> .Beg2
B<Cond> .Beg3
B<Cond> .End1
B<Cond> .End3
*.End1
*.End2
*.End3
*.S
The Development Library 6-25

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

49g+

Table of Contents