Справочник Пользователя для Mitsubishi Electronics FX0
FX Series Programmable Controlers
Applied Instructions 5
5-57
5.6.6
HSZ (FNC 55)
Operation 1 - Standard: (Applicable to all units)
This instruction works in exactly the same way as
the standard ZCP (FNC11). The only difference is
that the device being compared is a high speed
counter (specified as S
This instruction works in exactly the same way as
the standard ZCP (FNC11). The only difference is
that the device being compared is a high speed
counter (specified as S
3
).
Also, all of the outputs (D) are updated immediately due to the interrupt operation of the DHSZ.
It should be remembered that when a device is specified in operand D it is in fact a head
address for 3 consecutive devices. Each one is used to represent the status of the current
comparison, i.e. using the above example as a basis,
It should be remembered that when a device is specified in operand D it is in fact a head
address for 3 consecutive devices. Each one is used to represent the status of the current
comparison, i.e. using the above example as a basis,
Y10
(D)
C251 is less than S
1,
K1000 (S
3
< S
1)
Y11 (D
+1)
C251 is greater than S
1,
K1000 but less than S
2,
K1200 (S
3
> S
1
, S
3
< S
2
)
Y12 (D
+2)
C251 is greater than S
2,
K1200 (S
3
> S
2)
Operation 2 - Using HSZ With A Data Table: (Applicable units: FX
(2C)
and FX
2N
)
Operation 2 is selected when the destination device (D) is assigned special M coil M8130. This
then allows devices (S
then allows devices (S
1
, S
2
) to be used to define a data table using (S
1
) as the head address
and (S
2
) as the number of records in the table - maximum number of records is 128. Each
record occupies 4 consecutive data registers proportioned in
the following manner (for a
single record of data registers D through D
+3
):
Mnemonic
Function
Operands
Program steps
S
1
S
2
S
3
D
HSZ
FNC 55
(High
speed zone
compare)
FNC 55
(High
speed zone
compare)
Operation 1:
The current value
of a high speed
counter is checked
against a specified
range
The current value
of a high speed
counter is checked
against a specified
range
K, H,
KnX, KnY,
KnM, KnS,
T, C, D, V, Z
KnX, KnY,
KnM, KnS,
T, C, D, V, Z
C
Note:
C = 235 to
255,
Note:
C = 235 to
255,
Y, M, S
Note:
3 consecutive
devices are
used
Note:
3 consecutive
devices are
used
DHSZ:
17 steps
17 steps
Operation 2:
The designated
range is held in a
data table driving
‘Y’ outputs directly
The designated
range is held in a
data table driving
‘Y’ outputs directly
D
K,H
Using
values
from
1 to
128
(deci-
mal)
Using
values
from
1 to
128
(deci-
mal)
M8130 (only)
This flag can
only be used
with one
DHSZ
instr’ at a time
This flag can
only be used
with one
DHSZ
instr’ at a time
Operation 3:
The designated
range is held in a
data table driving
PLSY frequencies
directly using
D8132
The designated
range is held in a
data table driving
PLSY frequencies
directly using
D8132
M8132 (only)
This flag can
only be used
with one
This flag can
only be used
with one
Single Record
Data
registers
registers
D,
D
D
+1
Used as a double (32 bit) data register to contain the comparison data
D
+2
Stores the I/O device number, in HEX, of the ’Y’ Output device to be controlled, i.e.
H10=Y10. Note: Hex digits A through F are not used.
H10=Y10. Note: Hex digits A through F are not used.
D
+3
Stores the action (SET/RESET) to be performed on the Output device D
+2
. Note:
For a SET (ON) operation D
+3
must equal 1, for a RESET (OFF) D
+3
must equal 0.
FX
0(S)
FX
0N
FX FX
(2C)
FX
2N(C)
FX
(2C)
FX
FX
2N(C)
FX
0N
FX
0(s)
PULSE-P
FX
(2C)
FX
FX
2N(C)
FX
0N
FX
0(s)
16 BIT OPERATION
FX
FX
0N
FX
0(s)
FX
(2C)
FX
2N(C)
32 BIT OPERATION
M8000
C251 Y10
K1000
DHSZ
K1200
[ S1 ] [ S2 ] [ S3 ] [ D ]
For further, general points, about using high speed counter functions please see the
subsection ‘Points to note’ under the HSCS (FNC 52). Relevant points are; a, b, and c. Please
also reference the note about the number of high speed instructions allowable.