Omron CP - PROGRAMMING MANUAL 05-2007 Programming Manual page 1003

Cp1h/cp1l cpu unit
Table of Contents

Advertisement

Other Instructions
Flags
Examples
• CV-series program
(Program using indirect DM
binary mode addressing)
0.00
MOV
S
D
PLC Setup
Indirect DM data:
When indirect DM addresses are in binary, the content of
the DM word is treated as a PLC memory address and
specifies the corresponding address in I/O memory.
In this case, the value in D0 is 200 hex. The
corresponding data area address is CIO 512, so
#1234 is transferred to CIO 512.
Word address:
CVM1/CV-series PLC
D0
memory address
0200 Hex
CVM1/CV-series PLC
Word address:
memory address
CIO 512
#1234
0200 Hex
MOV(021)
#1234
970
Area
Index Registers
Indirect addressing
using Index Registers
Name
Error Flag
Example 1: Converting a CV-series Program with *DM Indirect Binary
Mode DM Addressing
In this FRMCV(284) example, a DM word is specified in S, the PLC memory
address there is stored in an Index Register, and the Index Register is used
for indirectly addressed.
Equivalent program
#1234
*D0
S
---
,IR0 to ,IR15
–2048 to +2047 ,IR0 to –2048 to
+2047 ,IR15
DR0 to DR15, IR0 to IR15
Label
ER
ON if S specifies one of the following PLC memory
addresses that do not exist in the CP-series:
Temporary Relay (TR) Area (09FF hex)
CPU Bus Link (G) Area (0A00 to 0AFF hex)
SFC Areas (0D00 to 0E3F hex)
OFF in all other cases.
• CP-series program
0.00
In this case, the value in D0 is 200 hex. The
corresponding CV-series data area address is CIO 512.
The CP-series PLC memory address for CIO 512 is
0000C200 hex, so this value is stored in IR0. The
destination operand in MOV(021) indirectly addresses the
content of IR0, so #1234 is transferred to CIO 512.
CP-series word
address: D0
CV-series word
address: CIO 512
Equivalent
CP-series word
address: CIO 512
CP-series word
address: IR0
CP-series word
address: CIO 512
Section 3-29
IR0 to IR15
---
Operation
FRMCV
S
D0
D
IR0
MOV
S
#1234
D
,IR0
0200 Hex
CP-series PLC
memory address:
0200 Hex
CP-series PLC
memory address:
OC0200 Hex
0000C0200 Hex
CP-series PLC
memory address:
0C0200 Hex
#1234
MOV(021)
#1234
D
FRMCV
(284)
MOV
(021)

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents