Mitsubishi Electronics FXCPU Video Game Controller User Manual


 
3 Configuration of Instruction
3.1 Expression and Operation Form of Sequence Instructions
43
FXCPU Structured Programming Manual
[Basic & Applied Instruction]
1
Outline
2
Instruction List
3
Configuration of
Instruction
4
How to Read
Explanation of
Instructions
5
Basic Instruction
6
Step Ladder
Instructions
7
Applied Instructions
(Program Flow)
8
Applied Instructions
(Move and
Compare)
9
Applied Instructions
(Arithmetic and
Logical Operation)
10
Applied Instructions
(Rotation and
Shift Operation)
Instruction mode and Operation form
Instructions are divided into "16-bit instructions" and "32-bit instructions" depending on the size of values they
handle. The instructions also have characteristics of either a "continuous execution" or "pulse execution"
depending on the form of execution.
Some of the instructions have all these combinations.
1. 16-bit and 32-bit instructions
An applied instruction that handles a numeric value is either 16 bits or 32 bits depending on the bit length
of the numeric value data.
Instruction that transfers the D10 contents to D12
Instruction that transfers the contents of (D21, D20) to (D23,
D22).
Where it is a 32-bit instruction, "D" is added to express as "DMOV".
The specified device can be an even number or an odd number and is used in combination with the device
of the next higher number. (In the case of word devices such as T, C and D)
To avoid confusion, it is suggested to give an even number to the low order device specified by the
argument of a 32-bit instruction.
A 32-bit counter can be used as a 32-bit data register. 32-bit counters cannot be handled as target devices
in 16-bit applied instructions.
2. Pulse execution and continuous execution instructions
Pulse operation
In an example shown on the right, when X000 changes from OFF
to ON, the instruction is executed only once. No other execution
takes place.
It is therefore suggested that the instructions of pulse operation be
used if not executed all the time.
Symbol "P" indicates that the instruction is of pulse operation.
The same is applied to DMOVP.
Continuous operation
The instruction in the figure on the right is of continuous operation.
It is executed in each cycle of operation while X001 is ON.
Where continuous execution instructions such as INC and DEC are used, some instructions have the
destination contents be changed in each cycle of operation.
In either cases, the instruction is not executed if the drive input X000 or X001 is OFF. The destination does
not change either if the instruction is not specified otherwise.
MOV
EN
s
ENO
d
D12D10
DMOV
EN
s
ENO
d
Command 1
Command 2
D20 D22
MOVP
EN
s
ENO
d
D12D10
X000
MOV
EN
s
ENO
d
D12D10
X001