■External public label
No.
Name
(10)
Rotation speed
■Global label (using latch label)
Refer to Page 26 Global Labels.
Function overview
Item
Applicable hardware and
software
Programming language
Number of basic steps
Used label amount
Function description
FB compiling method
FB operation type
Application example
3 SPECIFICATION
22
3.1 Details of the FB Library
Variable name
Data type
pbo_uRevolvingSpeed
Word [Unsigned]/
Bit string [16-bit]
Description
Target CPU
Applicable engineering tool
Ladder
1,555 step
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 option settings of GX Works3, refer to the GX Works3 Operating Manual.
■Label
2.34 K point [WORD]
■Latch label
0 K point [WORD]
The used label amount integrated in the program varies depending on the device specified as a parameter and the option settings
of GX Works3. For the option settings of GX Works3, refer to the GX Works3 Operating Manual.
(1) By turning on i_bEN (Execution command), o_bOK (Normal completion) is turned on when the specified input label is in the
setting range.
(2) When i_bEN (Execution command) is turned off, o_b48CamOutput (Cam output) is all off and the FB stops.
(3) The cam output data at the position of i_dCounterValue (Current value) is output to the specified o_b48CamOutput (Cam
output) as follows.
• Only the number that is set to ON in i_b48CamOutputNo (Cam output number) is the cam output control target. (When this label
is off, the cam output is always off.)
*1
• The speed
is calculated from the difference between the previous current value and present current value. The cam output
data after ON angle advance amount / OFF angle advance amount that is set in st4AngleAdvFunc (Angle advance function
setting) from i_dCounterValue (Current value) is output to o_b48CamOutput (Cam output).
o_b48CamOutput (Cam output) of each i_uCh (Channel number) is independent.
(4) The calculated speed is stored in pbo_uRevolvingSpeed (Rotation speed).
(5) When the setting value of i_uCh (Channel number) is out of range, o_bErr (Error completion) turns on, the error code 100
(hexadecimal) is stored in o_uErrId (Error code), and FB processing stops.
For details of the error code, refer to Page 25 Error code.
(6) When the input value of i_uCounterValue (Current value) is out of range, o_bErr (Error completion) turns on, the error code 101
(hexadecimal) is stored in o_uErrId (Error code), and FB processing stops.
For details of the error code, refer to Page 25 Error code.
Macro type
Real-time execution
Refer to Page 33 Program Example.
Default value
Description
0
Stores the calculation result of rotation speed.
(Unit: rpm)
FX5U CPU, FX5UC CPU
GX Works3 Version 1.050C or later