Reception With Interrupt Program (Procedure Exists) - Mitsubishi Electric MELSEC iQ-RJ71EN71 User Manual

Ethernet
Hide thumbs Also See for MELSEC iQ-RJ71EN71:
Table of Contents

Advertisement

Reception with interrupt program (procedure exists)

Use the BUFRCVS instruction for receiving data with the interrupt program. The interrupt program is started when data is
received from the external device. It enables the reading of receive data to the CPU module.
The interrupt settings are required to use the interrupt program. ( Page 273 Interrupt Settings)
The following figure shows the receive processing for the fixed buffer No.2 area corresponding to the connection No.2.
Initial processing Open processing
'Initial status' (Un\G1900024.0)
'Open completion signal
(connection No.2)'
(Un\G1900000.1)
BUFRCVS instruction
In interrupt processing
Program
 Normal completion of the initial processing is checked. ('Initial status' (Un\G1900024.0): On)
 A connection is established between the external device and the RJ71EN71 or the RnENCPU (network part), and normal completion of the connection No.2
open processings is checked. ( Page 378 TCP/IP Communications, UDP/IP Communications)
 The CPU module is requested to start the interrupt program, and data is received from the external device. ('Socket/fixed buffer reception status signal
(connection No.2)' (Un\G1900016.1): On)
 The interrupt program starts. The BUFRCVS instruction is executed, and the receive data length and receive data are read from the fixed buffer No.2.
('Socket/fixed buffer reception status signal (connection No.2)' (Un\G1900016.1): Off)
 When reading of the receive data length and receive data is completed, a response is returned to the external device.
 Execution of the interrupt program ends, and execution of the main program resumes.
*1 A response is not returned when the execution completes abnormally.
Receiving data
Ò
Ó
Receiving data
Ô
Cycle
END
Scan
Scan
processing
Sending a response
Õ
×
ACK
(TCP only)
ACK
Response
(TCP only)
Ö
Cycle
Interrupt processing
Scan
1.5 Communications Using the Fixed Buffer
END
processing
*1
1 FUNCTIONS
1
75

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents