EasyManua.ls Logo

Mitsubishi MELSEC-A series - Page 149

Mitsubishi MELSEC-A series
508 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
6. BASIC INSTRUCTIONS
6 37
MELSEC-A
Program Examples DINC
(1) Program which adds 1 to the data of D0 and 1when X0 turns on.
(2) Program which adds 1 to the data of X10 to 27 and stores the result to D3 and 4
when X0 turns on.
DDEC
(1) Program which subtracts 1 from the data of D0 and 1 when X0 turns on.
(2) Program which subtracts 1 from the data of X10 to 27 and stores the result to
D3 and 4 when X0 turns on.
X000
0
P
DINC DO
Coding
0 LD X000
1 DINCP D0
4 END
Coding
0 LD X000
1 DMOVP K6X010 D3
8 DINCP D3
11 END
X000
0
P K6
DMOV X010 D3
P
DINC D3
X000
0
P
DDEC D0
Coding
0 LD X000
1 DDECP D0
4 END
Coding
0 LD X000
1 DMOVP K6X010 D3
8 DDECP D3
11 END
X000
0
P K6
DMOV X010 D3
P
DDEC D3

Table of Contents

Other manuals for Mitsubishi MELSEC-A series

Related product manuals