EasyManua.ls Logo

Omron CJ - INSTRUCTIONS

Omron CJ - INSTRUCTIONS
1308 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...
907
3. Instructions
CS/CJ/NSJ Series Instructions Reference Manual (W474)
Network Instructions
3
Network Instructions
Communications Flags
The operation of the communications flags is outlined below.
The Communications Port Enabled Flag is turned OFF when communications are in progress and
turned ON when communications are completed (normally or not).
The status of the Communications Port Error Flag is maintained until the next time that data is
transmitted or received.
The Communications Port Error Flag will be turned OFF the next time that data is transmitted or
received, even if there was an error in the previous operation.
Note Here, “communications port” indicates an internal logical port, not a physical port.
Example
Address Bits Name Description
A202 00 to 07 Communications Port
Enabled Flags
Turns ON when a communications instruction can be executed. Bits 00 to 07 correspond to
communications ports 0 to 7. You can tell when communications have been completed
because the Communications Port Enabled Flag will turn ON again after the completing
execution of the communications instruction. The Communications Port Enabled Flag will be
OFF while the communications instruction is being executed.
15 Communications Port
Allocation Enabled Flag
Turns ON when there is a communications port available for automatic allocation.
Note Use this flag to see if all eight communications ports have already been allocated before
executing communications instructions.
A203 to
A210
--- Communications Port
Completion Codes
These words contain the completion codes for the corresponding port numbers when network
instructions have been executed.
A214 00 to 07 First Cycle Flags after
Network Communications
Finished
Each flag will turn ON for just one cycle after communications have been completed. Bits 00 to
07 correspond to ports 0 to 7.
Note These flags are not effective until the next cycle after the communications instruction is
executed. Delay accessing them for at least one cycle.
Note Use the Used Communications Port Number stored in A218 to determine which flag to
access.
08 to 15 Do not use. ---
A215 00 to 07 First Cycle Flags after
Network Communications
Error
Each flag will turn ON for just one cycle after a communications error occurs. Bits 00 to 07
correspond to ports 0 to 7. If the flag turns ON, refer to the Communications Port Completion
Code (A203 to A210) to identify the cause of the error.
Note These flags are not effective until the next cycle after the communications instruction is
executed. Delay accessing them for at least one cycle.
Note Use the Used Communications Port Number stored in A218 to determine which flag to
access.
08 to 15 Do not use. ---
A216 and
A217
--- Communications Port
Completion Code Storage
Address
The completion code for a communications instruction is automatically stored at the address
with the PLC I/O memory address given in these words.
Note Place this address into an index register and use indirect addressing through the index
register to reach the communications completion code.
A218 --- Used Communications Port
Number
When a communications instruction is executed, the number of the communications port that
was used is stored in this word. Values 0000 to 0007 hex correspond to communications ports
0 to 7.
A219 00 to 07 Communications Port Error
Flags
Turns ON when a communications error occurs during execution of network communications. If
the Communications Port Error Flag turns ON, refer to the Communications Port Completion
Code in (A203 to A210) to identify the cause of the error. Bits 00 to 07 correspond to
communications ports 0 to 7. The Communications Port Error Flag will be OFF while the
communications instruction is being executed.
0204
(Busy)
Communications Port Enabled
Flag
Network instruction
(SEND/SEND2, RECV/RECV2,
or CMND/CMND2)
Communications Port Error
Flag
Communications Port
Completion Code
Instruction 1
executing
Previous
completion
(Normal
completion)
Instruction 2
executing
Instruction 3
executing
0000
0000
(Normal completion)

Table of Contents

Related product manuals