1700
20 SERIAL COMMUNICATION INSTRUCTIONS
20.9 Sending Data by Using User Frames
■Control data
• By using the nonprocedural protocol of the module specified by (U), the data in the user frames is sent according to the
control data stored in the device specified by (s) and later and the user frame specification area for sending of the module.
• The completion status of the G(P).PRR instruction can be checked with the completion device (d) and the completion
status indication device (d)+1.
• The following figure shows how the G(P).PRR instruction operates when completing its execution.
Operand: (s)
Device Item Description Setting range Set by
+0 Send channel Specifies the send channel.
• 1: Channel 1 (CH1 side)
• 2: Channel 2 (CH2 side)
1, 2 User
+1 Result of sending Used to store the result of sending with the G(P).PRR instruction.
•0: Normal
• Other than 0: Error (error code)
System
+2 CR/LF append
specification
Specifies whether to append CR or LF to send data. 0, 1 User
+3 Send pointer Specifies the frame number that indicates the start position of send data within the
user frame specification area for sending.
1 to 100 User
+4 Amount of output Specifies the number of user frames to be sent. 1 to 100 User
• Completion device (d)
This device turns on during END processing of the scan where the G(P).PRR instruction completes, and turns off during the next END processing.
• Completion status indication device (d)+1
This device turns on or off depending on the completion status of the G(P).PRR instruction.
When completed successfully: The device remains off.
When completed with an error: The device turns on during END processing of the scan where the G(P).PRR instruction completes, and turns off during the next
END processing.
END0 0 END0ENDEND 0 END0
OFF
OFF
OFF
OFF
ON
ON
Sequence scan
G(P).PRR instruction
Completion device (d)
1 scan
Completion of
the instruction
Completed successfully
Completed with an error
Execution of the instruction
Completion status
indication device (d)+1