117
Sample Programming
Appendix B
Programming Example
When the execution input turns ON, settings are made in the Special I/O Unit Area using the MOV and MOVL
instructions and the command is executed. When communications with the Data Carrier have been completed,
the Normal End Flag (word (n + 7), bit 01) or Error End Flag (word (n + 7), bit 02) is turned ON.
MOV
2551
#0101
MOV
2552
#0010
Execution
input
Command Execution Bit
ID Busy
MOV
2553
#0008
MOVL
2554
#00001100
Normal End Flag
Error End Flag
Normal end
Specification of command,
communications specifications
and write data storage order.
Specification of first write address.
Specification of number of write bytes.
Write data storage location
2550.00
0010.01
0010.01
2557.01
2557.02
2557.00
Waiting for command execution
(work bit)
0010.01
Waiting for command
execution (work bit)
Waiting for command
execution (work bit)
Error end
Used to time getting
resulting information.
Test Mode
2557.14
Unit Busy
2557.15
Summary of Contents for CJ - 12-2004
Page 2: ...SYSMAC CS CJ Series ID Sensor Units Operation Manual Revised December 2004...
Page 3: ...iv...
Page 11: ...xii...
Page 55: ...36 Connections and Wiring Section 3 4...
Page 69: ...50 I O Data Allocations Section 4 3...
Page 91: ...72 Data Check Section 5 7...
Page 141: ...122 Sample Programming Appendix B...
Page 147: ...128 Revision History...