Mitsubishi Electronics FXCPU Video Game Controller User Manual


 
14 Applied Instructions (External FX I/O Device)
14.6 ARWS / Arrow Switch
372
FXCPU Structured Programming Manual
[Basic & Applied Instruction]
14.6 ARWS / Arrow Switch
Outline
This instruction enters data by arrow switches for digit move and increase and decrease of numerical value of
each digit.
1. Format and operation, execution form
2. Set data
3. Applicable devices
S: Refer to "Cautions".
Function and operation explanation
Four arrow switches are connected to the input of the device specified by , the 7-segment display unit
with BCD decoder is connected to the output of the device specified by , and the numeric value is
entered in the device specified by .
1. 16-bit operation (ARWS)
In the device specified by , 16-bit BIN value of 0 to 9,999 is stored, but for the convenience of
explanation, BCD converted value is expressed.
When the command input is ON, then ARWS instruction operates as follows.
FX3U(C) FX3G(C) FX3S FX2N(C) FX1N(C) FX1S FXU/FX2C FX0N FX0(S)
Instruction
name
Operation
Execution
form
Expression in each language
Structured ladder/FBD ST
ARWS 16 bits Continuous ARWS(EN, s, n, d1, d2);
Variable Description Data type
Input
variable
EN Execution condition Bit
Head bit device to be entered (4 points occupied) ARRAY [0..3] OF Bit
Digit number specification of 7-segment display ANY16
Output
variable
ENO Execution state Bit
Word device in which BCD converted data is stored ANY16
Head bit device (Y) for connecting 7-segment display unit (8 points
occupied)
ARRAY [0..7] OF Bit
Operand
type
Bit Devices Word Devices Others
System user Digit designation
System
user
Special
unit
Index
Cons
tant
Real
Number
Character
String
Pointer
XYMTCS
D.b
KnX KnY KnM KnS T C D R
U\G
VZ
Modifier
KH E
""
P
zzz z
S1
z
zz
zzz
S2 S2
zz z
zz
ARWS
EN
s
n
ENO
d1
d2
Command input
ARWS
EN
s
n
ENO
d1
d2
Head bit device to
be entered
Digit number
specification
of 7-segment
display.
Word device in which BCD
converted data is stored
Head bit device for connecting
7-segment display unit