Panasonic FP Series Programming Manual page 321

Hide thumbs Also See for FP Series:
Table of Contents

Advertisement

Counter instructions
CTUD
The function block CTUD (count up/down) allows you to program counting procedures (up and
Description
down).
To add an enable input and enable output to the instruction, select [With EN/ENO] from the
"Instructions" pane (LD, FBD or IL editor). To reuse an instruction select "Recently used" from the
context menu or press <Ctrl>+<Shift>+<v> in the programming window.
For CTUD declare the following:
CU
CD
RESET (R)
LOAD (LD)
PV
QU
QD
CV
The names in brackets are the valid parameter names of the ST-editor.
PLC types
Availability of CTUD (see page 1319)
320
Up/down counter
count up
the value 1 is added to the current CV for each rising edge detected at CU,
except when RESET and/or LOAD is/are set.
count down
the value 1 is subtracted from the current CV for each rising edge detected at
CD, except when RESET and/or LOAD is/are set and if CU and CD are
simultaneously set. In the latter case, counting will be upwards.
reset
if RESET is set, CV will be reset
Set
if LOAD is set, PV is loaded to CV. This, however, does not apply if RESET is
set simultaneously. In this case, LOAD will be ignored.
preset value
defines the preset value which is to be attained with the addition or subtraction
(PV = preset value)
signal output - count up
is set if CV is greater than/equal to PV
signal output - count down
is set if CV = zero
current value
is the addition/subtraction result (CV = current value)

Advertisement

Table of Contents
loading

Table of Contents