8 RECEIVING DATA WITH AN INTERRUPT PROGRAM
8.5 Considerations when Receiving Data with an Interrupt Program
223
8
8.5 Considerations when Receiving Data with an
Interrupt Program
This section describes the considerations when receiving data with an interrupt program.
• Create an interrupt program for data reception for each interface.
• Do not use the INPUT and BIDIN instructions during execution of the interrupt program.
Always use the BUFRCVS instruction to receive data.
• Do not turn the 'CH reception data read completion' (Y1/Y8) ON/OFF during execution of the interrupt program since C24
turns OFF the 'CH reception data read request' (X3/XA) and the 'CH reception abnormal detection' (X4/XB) for data
reception with an interrupt program.
• Use always ON (SM400) or direct input signal (DX3, DX4) as the contact signal when executing the BUFRCVS instruction.
• After the power supply turns OFF ON or the CPU module is reset, data cannot be received because the interrupt
program is invalid during the initial processing of the CPU module. For asynchronous data communication with C24 from
the target device without communication procedure setting, refer to the program example shown below.
Program example
The following shows an example of program for asynchronous data communications from the target device side to C24
without communication procedure settings on the target device side.
For information on the module FB to be used, refer to the following manual.
MELSEC iQ-R Serial Communication Module Function Block Reference
Category Label name Description Device
Module label C24_1 Target module
C24_1.stnCH1.bSet_Req_ReceptionRead CH1 Reception data read request X3
C24_1.stnCH1.bSts_ReceptionAbnormalDetection CH1 Reception abnormal detection X4
C24_1.stnCH1.bSts_Error CH1 Error occurrence XE
C24_1.bSet_Req_ErrorInitialization Error initialization request YE
C24_1.stnCH1.uSet_ReceiveInterruptIssued_D CH1_Receive interrupt-issued designation U0\G8208
Label to be defined Define the global label as shown below.