5 - 10 5 - 10
MELSEC-Q
5 BASIC USAGE
5.4 Using the Preset Function
The preset function rewrites the present counter value to any numeric value called the
preset value. The preset function can be used when starting the pulse count from the
preset value.
The preset function has two preset methods: preset using a sequence program and
preset using an external control signal.
(1) Preset using a sequence program
Preset is performed by turning the preset command {Y01(Y09)} ON using the
sequence program.
OFF
ON
0
Buffer memory used for
setting the preset value
{Addresses 0
H
to 1
H
(20
H
to 21
H
)}
Input pulse for counting
Preset command
{Y01 (Y09)}
Count enable command
{Y04 (Y0C)}
1)
100
OFF
ON
1016665
to
210 103
Buffer memory used for storing
the present value
Addresses 2
H
to 3
H
22
H
to 23
H
104 10510067 102
2)
Number Description
1)
Any numeric value is written in 32-bit binary format into the preset value setting
buffer memory (Addresses 0
H to 1H (20H to 21H)) for the QD62 (E/D).
2)
At the start (OFF to ON) of the preset command, the preset value in the preset
value setting buffer memory is preset in the present value storage buffer
memory. Preset can be executed regardless of whether the count enable
command {Y04(Y0C)} is ON or OFF.