hit counter script
Mitsubishi Electric MELSEC iQ-F FX5 Reference Manual
Mitsubishi Electric MELSEC iQ-F FX5 Reference Manual

Mitsubishi Electric MELSEC iQ-F FX5 Reference Manual

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

Advertisement

MELSEC iQ-F
FX5 CPU Module Function Block Reference

Advertisement

Table of Contents
loading

Summary of Contents for Mitsubishi Electric MELSEC iQ-F FX5

  • Page 1 MELSEC iQ-F FX5 CPU Module Function Block Reference...
  • Page 3: Table Of Contents

    CONTENTS CHAPTER 1 FUNCTION BLOCK (FB) LIST CHAPTER 2 INPUT/OUTPUT FB M+FX5UCPU-IO_OutputOnTimes............4 M+FX5UCPU-IO_CompareRelayOnTimes .
  • Page 4: Chapter 1 Function Block (Fb) List

    FUNCTION BLOCK (FB) LIST This chapter lists the FBs for the MELSEC iQ-F series FX5U, FX5UC CPU module. Input/Output FB Name Description M+FX5UCPU-IO_OutputOnTimes This FB counts (cumulatively) the number of ON times of the specified relay device number within the range from 0 to 4294967295.
  • Page 5 MEMO 1 FUNCTION BLOCK (FB) LIST...
  • Page 6 INPUT/OUTPUT FB M+FX5UCPU-IO_OutputOnTimes Name M+FX5UCPU-IO_OutputOnTimes Overview Item Description Overview This FB counts (cumulatively) the number of ON times of the specified relay device number within the range from 0 to 4294967295. Symbol M+FX5UCPU-IO_OutputOnTimes i_bEN o_bENO i_stModule o_udOutputOnTotal i_uRaNo o_bOK o_bErr o_uErrId Labels ■Input label...
  • Page 7 GX Works3 when the program is compiled. In such a case, correct the program in accordance with the contents of the message. • Set the module parameters in GX Works3 in accordance with the connected equipment and system. For the module parameters, refer to the MELSEC iQ-F FX5 User's Manual (Application). Error code Error code (hexadecimal)
  • Page 8: M+Fx5Ucpu-Io_Comparerelayontimes

    M+FX5UCPU-IO_CompareRelayOnTimes Name M+FX5UCPU-IO_CompareRelayOnTimes Overview Item Description Overview • This FB counts (cumulatively) the number of ON times of the specified relay device number within the range from 0 to 4294967295. • This FB compares the counted number of ON times with the set value, and outputs the comparison result. Symbol M+FX5UCPU-IO_CompareRelayOnTimes i_bEN...
  • Page 9 ■Output label Variable name Name Data type Default value Description o_bENO Execution status ON: The execution command is ON. OFF: The execution command is OFF. o_udOutputOnTotal Integration value of Double Word Stores the counted integration value of the number of number of relay ON [Unsigned] times the specified relay device number has turned...
  • Page 10 GX Works3 while the program is converted. In such a case, correct the program in accordance with the contents of the message. • Set the module parameters in GX Works3 in accordance with the connected equipment and system. For the module parameters, refer to the MELSEC iQ-F FX5 User's Manual (Application). Error code Error code (hexadecimal)
  • Page 11: Chapter 3 Positioning Fb

    POSITIONING FB M+FX5UCPU-Positioning_ABRST Name M+FX5UCPU-Positioning_ABRST Overview Item Description Overview This FB reads the absolute position (ABS) data from the servo amplifier, and writes the read value to the current address (pulse unit) of the target axis. Symbol M+FX5UCPU-Positioning_ABRST i_bEN o_bENO i_stModule o_bOK i_uAxis...
  • Page 12 • When the absolute position restoration (ABS current value read) is completed with an error, o_bAbsNG (ABS error) turns ON and an error code is stored in o_uAbsErrId (ABS error code). For the error codes, refer to MELSEC iQ-F FX5 User's Manual (Positioning Control - CPU module built-in, High-speed pulse input/output module).
  • Page 13: M+Fx5Ucpu-Positioning_Abrst

    Item Description Timing chart of I/O signals [When the operation is completed with an error] (Out of the target axis setting range) i_bEN o_bENO ABS current value read Unexecuted (DABS) instruction o_bOK o_bAbsNG o_uAbsErrId o_bErr o_uErrId Error code [When the operation is completed with an error] (When the ABS current value read (DABS) instruction completes with an error) i_bEN o_bENO...
  • Page 14 • Set the pulse output mode, external I/O signal logic, etc. in accordance with the connected equipment and system. Set the module parameters in GX Works3 in accordance with the application. For the module parameter setting method, refer to the MELSEC iQ-F FX5 User's Manual (Positioning Control - CPU module built-in, High-speed pulse input/output module). Error code...
  • Page 15: M+Fx5Ucpu-Positioning_Startpositioning

    M+FX5UCPU-Positioning_StartPositioning Name M+FX5UCPU-Positioning_StartPositioning Overview Item Description Overview This FB uses the table data set using the module parameters to activate the positioning operation. Symbol M+FX5UCPU-Positioning_StartPositioning i_bEN o_bENO i_stModule o_bOK i_uAxis o_bErr UW : i_uStartNo o_uErrId (9) pbi_uEndNo (10) pbi_bTableExeMethod Labels ■Input label Variable name Name...
  • Page 16 FB details Item Description Available device CPU module FX5U CPU, FX5UC CPU Engineering tool GX Works3 Version 1.025B or later Language Ladder diagram Number of basic steps 187 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.
  • Page 17 Item Description Timing chart of I/O signals [When the operation is completed successfully] (For continuous operation) i_bEN o_bENO Multiple table operation (DRVTBL) instruction Positioning instruction Stop Table 1 Table 2 Table 3 Stop activation (SM device) Instruction execution complete (SM device) Positioning complete flag Positioning abnormal completion flag...
  • Page 18 • To control the system, input the required signal to the input terminal by the set control method or use a user program. For the required signals, refer to the MELSEC iQ-F FX5 User's Manual (Positioning Control - CPU module built-in, High-speed pulse input/output module).
  • Page 19 Positioning has been activated for the target axis. Try executing the FB again after stopping activation of the target axis. Refer to the MELSEC iQ-F FX5 User's Manual Positioning error code This is the same as the error code that occurs in the multiple table operation (DRVTBL) instruction.
  • Page 20: Chapter 4 Serial Communication Fb

    SERIAL COMMUNICATION FB M+FX5UCPU-SerialComm_InputOutput Name M+FX5UCPU-SerialComm_InputOutput Overview Item Description Overview This FB sends the specified number of data points using the non-protocol in serial communication. Symbol M+FX5UCPU-SerialComm_InputOutput i_bEN o_bENO i_stModule o_bSendComp i_uCh o_bRecvComp (10) i_uSendDataLength o_bErr (11) i_uSendData o_uErrId (12) B : i_bSendReq o_uRecvDataLength (13)
  • Page 21 *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...
  • Page 22: M+Fx5Ucpu-Serialcomm_Inputoutput

    Item Description Timing chart of I/O signals [When the operation is completed successfully] <ch1 example> i_bEN Turns OFF after 1 scan time o_bENO i_bSendReq SM8561 (ch1 send request) Sending Receiving Serial data transfer o_bSendComp SM8562 (ch1 receive completion) o_bRecvComp o_bErr o_uErrId *1 Sending complete turns OFF when the next sending request is sent.
  • Page 23 • Set the module parameters of the used communication channel in GX Works3 in accordance with the application. For the module parameter setting method, refer to the MELSEC iQ-F FX5 User's Manual (Serial Communication). • To validate the change of the setting value of allowable number of receive data, restart this FB.
  • Page 24 M+FX5UCPU-SerialComm_Input Name M+FX5UCPU-SerialComm_Input Overview Item Description Overview This FB stores the data received using the non-protocol in serial communication. Symbol M+FX5UCPU-SerialComm_Input i_bEN o_bENO i_stModule o_bOK i_uCh o_bErr UW : i_uMaxRecvData o_uErrId o_uRecvDataLength o_uRecvData UW (10) (11) pb_bSerialComErrUndetection Labels ■Input label Variable name Name Data type...
  • Page 25 *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...
  • Page 26: M+Fx5Ucpu-Serialcomm_Input

    • Set the module parameters of the used communication channel in GX Works3 in accordance with the application. For the module parameter setting method, refer to the MELSEC iQ-F FX5 User's Manual (Serial Communication). • Restart this FB to allow changes to the number of allowable receive data points.
  • Page 27 Try again after checking the setting. mode. The serial communication operation mode is not set to "Non- protocol communication". Refer to the MELSEC iQ-F FX5 User's Manual Serial communication error The contents are same as the error code occurred in the serial communication (RS2) instruction.
  • Page 28: M+Fx5Ucpu-Serialcomm_Output

    M+FX5UCPU-SerialComm_Output Name M+FX5UCPU-SerialComm_Output Overview Item Description Overview This FB sends the specified number of data points using the non-protocol in serial communication. Symbol M+FX5UCPU-SerialComm_Output i_bEN o_bENO i_stModule o_bOK i_uCh o_bErr UW : i_uSendDataLength o_uErrID UW : i_uSendData (10) pb_bSerialComErrUndetection Labels ■Input label Variable name Name...
  • Page 29: M+Fx5Ucpu-Serialcomm_Output

    *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...
  • Page 30 • Set the module parameters of the used communication channel in GX Works3 in accordance with the application. For the module parameter setting method, refer to the MELSEC iQ-F FX5 User's Manual (Serial Communication). • FX5UC CPU does not have serial communication port ch2. When using this FB in FX5UC CPU, set a channel of one of ch1, ch3, ch4.
  • Page 31: M+Fx5Ucpu-Serialcomm_Execommonprotocol

    M+FX5UCPU-SerialComm_ExeCommonProtocol Name M+FX5UCPU-SerialComm_ExeCommonProtocol Overview Item Description Overview This FB executes the protocol registered with GX Works3. Symbol M+FX5UCPU-SerialComm_ExeCommonProtocol i_bEN o_bENO i_stModule o_bOK i_uCh o_bErr i_uNumberOfExecutions o_uErrId i_uExeProtocolNo o_uNumberOfExecutions (10) o_uMatchPacketNo UW (11) (12) pb_bSerialComErrUndetection Labels ■Input label Variable name Name Data type Range Description...
  • Page 32 *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...
  • Page 33 Item Description Timing chart of I/O signals [When the operation is completed successfully] i_bEN o_bENO Communication protocol support (SP.CPRTCL) instruction In communication Serial data transfer o_uNumberOfExecutions Number of executions Number of executions o_uMatchPacketNo Receive packet No. Receive packet No. o_bOK o_bErr o_uErrId [When the operation is completed with an error]...
  • Page 34 • Set the module parameters of the used communication channel in GX Works3 in accordance with the application. For the module parameter setting method, refer to the MELSEC iQ-F FX5 User's Manual (Serial Communication). • FX5UC CPU does not have serial communication port ch2. When using this FB in FX5UC CPU, set a channel of one of ch1, ch3, ch4.
  • Page 35: Chapter 5 High-Speed Counter Fb

    HIGH-SPEED COUNTER FB M+FX5UCPU-Counter_PulseMeasure Name M+FX5UCPU-Counter_PulseMeasure Overview Item Description Overview This FB starts the pulse measurement function, and stores the pulse measured value. Symbol M+FX5UCPU-Counter_PulseMeasure i_bEN o_bENO i_stModule o_bOK i_uCh o_bUpdate o_dResult o_bErr o_uErrId UW (10) pb_bPulseMeasuringIntervalSetting Labels ■Input label Variable name Name Data type...
  • Page 36 • If an error occurs when starting pulse measurement, o_bErr (Error completion) turns on and the processing of this FB is aborted. In addition, the error code is stored in o_uErrId (Error code). For the error codes, refer to MELSEC iQ-F FX5 User's Manual (Application).
  • Page 37: M+Fx5Ucpu-Counter_Pulsemeasure

    • This FB supports only consecutive measurement mode. Set the measurement mode to consecutive measurement mode. • When executing the pulse measurement function, set the module parameters in GX Works3 in accordance with the connected equipment and system. For the module parameter setting method, refer to the MELSEC iQ-F FX5 User's Manual (Application).
  • Page 38 Try again after checking the setting. range. The target channel is set to a value outside the range from 1 to 12. Refer to the MELSEC iQ-F FX5 User's Manual Self-diagnostics error This may occur in the pulse measurement start (HIOEN) instruction.
  • Page 39 MEMO 5 HIGH-SPEED COUNTER FB 5.1 M+FX5UCPU-Counter_PulseMeasure...
  • Page 40: Instruction Index

    INSTRUCTION INDEX ..33 M+FX5UCPU-Counter_PulseMeasure ..6 M+FX5UCPU-IO_CompareRelayOnTimes ... . 4 M+FX5UCPU-IO_OutputOnTimes ... . 9 M+FX5UCPU-Positioning_ABRST .
  • Page 41 MEMO...
  • Page 42: Revisions

    Chapter 1, 2, 3, 4, 5 This manual confers no industrial property rights or any rights of any other kind, nor does it confer any patent licenses. Mitsubishi Electric Corporation cannot be held responsible for any problems involving industrial property rights which may occur as a result of using the contents noted in this manual.
  • Page 44 Manual number: JY997D62701E When exported from Japan, this manual does not require application to the Ministry of Economy, Trade and Industry for service transaction permission. HEAD OFFICE: TOKYO BUILDING, 2-7-3 MARUNOUCHI, CHIYODA-KU, TOKYO 100-8310, JAPAN Specifications are subject to change without notice.

Table of Contents