Mitsubishi Electric MELSEC iQ-F FX5 Reference Manual page 32

Cpu module function block reference
Hide thumbs Also See for MELSEC iQ-F FX5:
Table of Contents

Advertisement

■Output label
No.
Variable name
(6)
o_bENO
(7)
o_bOK
(8)
o_bErr
(9)
o_uErrId
(10)
o_uNumberOfExecutions
(11)
o_uMatchPacketNo
■Public label
No.
Variable name
(12)
pb_bSerialComErrUndetection
*1 Even if a serial communication error occurs in the used communication channel, error completion and error code are not output and the
FB does not stop. Use a user program to detect the error. For serial communication error and serial communication error code, refer to
the following manual.
MELSEC iQ-F FX5 User's Manual (Serial Communication)
FB details
Item
Available device
Language
Number of basic steps
Processing
FB compilation method
FB operation
4 SERIAL COMMUNICATION FB
30
4.4 M+FX5UCPU-SerialComm_ExeCommonProtocol
Name
Data type
Execution status
Bit
Normal completion
Bit
Error completion
Bit
Error code
Word [Unsigned]
Number of protocol
Word [Unsigned]
executions
Matched receive
Word [Unsigned]
packet number
(0..7)
Name
Serial communication
error undetection
mode
Description
CPU module
Engineering tool
Ladder diagram
216 steps
The number of FB steps integrated in the program varies depending on the CPU module used, the input/output definition, and
the setting options of GX Works3. For the setting options of GX Works3, refer to GX Works3 Operating Manual.
• Executes the registered protocol by the communication protocol support function (predefined protocol support function) on
GX Works3 using the communication protocol support (SP.CPRTCL) instruction, by turning i_bEN (Execution command) on.
After executing the protocols specified with i_uExeProtocolNo (Execution protocol number) and i_uNumberOfExecutions
(Number of consecutively-executed protocols), o_bOK (Normal completion) turns on.
• This FB checks the following input values when started up. If an error occurs, o_bErr (Error completion) turns on, and
o_uErrId (Error code) stores the error code.
(1) Communication channel
(2) Number of consecutive protocol executions
• If an error occurs during data communication processing, o_bErr (Error completion) turns on, and the serial communication
error code is stored to o_uErrId (Error code). For the error code, refer to Page 32 Error code. When
pb_bSerialComErrUndetection (Serial communication error undetection mode) is turned on by a user program, this FB does
not detect serial communication errors for error codes 7F67H to 7F6AH (the FB continues to operate). Detect serial
communication errors using a user program.
Macro type
Pulsed execution (multiple scan execution type)
Default value
OFF
OFF
OFF
0
0
0
Data type
Range
Bit
ON, OFF
FX5U CPU (Version 1.015 or later), FX5UC CPU (Version 1.015 or later)
GX Works3 Version 1.015R or later
Description
ON: The execution command is on.
OFF: The execution command is off.
When this bit is ON, it indicates that data communication
is completed normally.
When this label is ON, it indicates that an error has
occurred in the FB.
Stores the error code that occurred in the FB.
The number of protocol executions is stored. The
protocol in which an error has occurred is included in the
number of executions. If the setting data and the setting
details of the control data are incorrect, 0 is stored.
1st word: Matched receive packet No. 1
8th word: Matched receive packet No. 8
A value is stored in the area corresponding to the
execution protocol number. When the communication
type of the executed protocol is "Send only" or "Send
and receive", the receive packet number that matches
with the executed protocol, is stored.
In the following cases, 0 is stored.
• When the communication type is "Receive only"
• When an error occurs in the executed protocol
• The area is greater than or equal to the number of
protocol executions
When it is specified using a label, use "ARRAY" for the
data type.
Description
ON: FB does not detect serial communication error.
OFF: FB detects serial communication error.
*1

Advertisement

Table of Contents
loading

Table of Contents