
4-16
Ladder Programming Examples
Section 4-3
Rem
o
te
I
/O
Com
-
m
u
ni
c
a
ti
o
ns
4-3-2
Change SP Sample Programming
The ladder programming example here is for setting and changing SP. The
program is for execution under the following conditions.
• Using simple I/O allocation to allocate data in fixed allocation area 1 of a
CS/CJ-series DeviceNet Unit of CS/CJ-series DeviceNet Unit (OUT Area
= CIO 3200 to CIO 3263, IN Area = CIO 3300 to CIO 3363).
Outline
This ladder program example sets and changes the SP for the E5AR/ER-
DRT.
Output Enable Bit (CIO 320100) is used to write SP.
Operation
• The value used as SP is set in D1000 and D1001 at the start of the ladder
program. In this example, the SP is set to 100.0, so the hexadecimal
number 03E8 is written to D1000.
• Once the execution condition (CIO000000) turns ON, the SP is set to
CIO 3202.
• The Output Enable Bit (CIO320200) is turned ON and the SP is written.
• A timer is used to turn OFF the Output Enable Bit after 0.1 s (see note).
Note: If using this kind of ladder programming, do not use the timer method
shown here. Instead, allocate the SP, check that the setting has changed, and
then turn OFF the Output Enable Bit using the following steps.
1.
Use a Configurator or other Programming Device to allocate the SP to the
IN Area.
2.
Check that the SP has been written and then turn OFF the Output Enable
Bit.
Programming Example
MOV (021)
000000
(000000)
First scan
Flag ON
A200.11
#03E8
D1000
MOV (021)
D1000
3202
ASL (025)
0
SET
3201.00
TIM
0000
䋤
1
0.00
000001
(000002)
T0000
000003
(000008)
Moves #03E8 to D1000.
(Used for setting SP 100.0).
Shifts the contents of CIO 0000
one bit to the left.
Turns ON Output Enable Bit .
END
䋨
001
䋩
Copies the contents of D1000
to CIO 3202.
Uses a timer to wait 0.1 s.
0.02
000004
(000010)
000005
(000013)
Execution
condition
ASL (025)
0
Shifts the contents of CIO 0000
one bit to the left.
RESET
3201.00
0
ASL (025)
Turns OFF Output Enable Bit.
Shifts the contents of CIO 0000
one bit to the left.
0.01
000002
(000005)
Summary of Contents for E5AR
Page 2: ...E5AR ER Digital Controller DeviceNet Communications User s Manual Produced February 2004...
Page 3: ...iv...
Page 29: ...2 6 Functions Supported Only by the E5AR ER DRT Section 2 2 Operating Procedures...
Page 79: ...6 8 Message Communications Performance Section 6 2 Communications Performance...
Page 91: ...B 6 Mounted Objects Appendix B Appendix B...
Page 95: ...C 4 DeviceNet Connection Hardware Appendix C Appendix C...
Page 97: ...G 2 Glossary...
Page 100: ...Index I 3 W wiring 3 10 precautions 3 9 write mode 4 12...
Page 101: ...I 4 Index...