Counting Up Or Down The Current Value (2-Phase Input) - Mitsubishi Electric MELSEC iQ-R Series Programming Manual

Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

Counting up or down the current value (2-phase input)

UDCNT2
RnPCPU
RnPCPU
RnCPU RnENCPU
(Process)
(Redundant)
This instruction updates the current value of the counter depending on the status of phases A and B pulses.
Ladder
(s1)
(d)
(s2)
FBD/LD
EN
ENO
s1
d
s2
■Execution condition
Instruction
UDCNT2
Setting data
■Descriptions, ranges, and data types
Operand
Description
(s1)
(s1)+0: Count input number (phase A pulse)
(s1)+1: Count input number (phase B pulse)
(d)
Number of the counter (device name) to be counted by the
UDCNT2 instruction
(s2)
Set value
EN
Execution condition
ENO
Execution result
*1 Only labels assigned to device (X) can be used.
*2 Only labels assigned to device (C) can be used.
■Applicable devices
Operand
Bit
X, Y, M, L,
J\
SM, F, B, SB,
FX, FY
*1
(s1)
(d)
(s2)
*1 Only X can be used. Note, however, that it can be used only within the range of the number of I/O points (the number of points that can
access I/O modules).
*2 Only C can be used.
RnSFCPU RnSFCPU
(Standard)
(Safety)
Execution condition
Word
T, ST, C, D, W,
U\G, J\,
SD, SW, FD, R,
U3E\(H)G
ZR, RD
*2
ST
ENO:=UDCNT2(EN,s1,s2,d);
Range
Data type
Bit
Device name
-32768 to 32767
16-bit signed binary
Bit
Bit
Double word Indirect
specification
Z
LT, LST,
LZ
LC
7 APPLICATION INSTRUCTIONS
7.13 Special Counter Instructions
7
Data type (label)
*1
ANYBIT_ARRAY
(Number of elements: 2)
*2
ANY16
ANY16
BOOL
BOOL
Constant
Others
K, H E
$
881

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents