3.5 STEP 5 Operations with Examples
A STEP 5 operation consists of the operation and an operand. The
operation specifies what the CPU is to do (operation). The operand
specifies with what an operation is to be executed.
STEP 5 operations can be divided into the following groups:
•• basic operations (can be used in all logic blocks),
•• supplementary operations,
•• executive operations (can only be used in FB/FX function blocks),
•• semaphore operations (can only be used in FB/FX function blocks).
Accumulators as working
registers
The CPU 948 has four accumulators, ACCU 1 to ACCU 4. Most
STEP 5 operations use two 32-bit registers (ACCU 1 and ACCU 2) as
the source of operands and the destination for results.
The STEP 5 operation to be carried out affects the accumulators, e.g.:
•• ACCU 1 is always the destination in load operations. A load
operation shifts the old contents of ACCU 1 to ACCU 2 (stack
lift). Accumulators 3 and 4 are not changed by any load operations.
1)
analogous for ACCU 2 to ACCU 4
ACCU-1-H
High byte Low byte
High byte
Low byte
ACCU 1
1)
High word Low word
31
24 23 16 15
8 7
0
ACCU-1-HL
ACCU-1-LH ACCU-1-LL
ACCU-1-L
ACCU-1-HH
STEP 5 Operations with Examples
CPU 948 Programming Guide
C79000-G8576-C848-04
3 - 15