Panasonic FP Series Programming Manual page 314

Hide thumbs Also See for FP Series:
Table of Contents

Advertisement

F_TRIG
The function block F_TRIG (falling edge trigger) allows you to recognize a falling edge at an input.
Description
To add an enable input and enable output to the instruction, select [With EN/ENO] from the
"Instructions" pane (LD, FBD or IL editor). To reuse an instruction select "Recently used" from the
context menu or press <Ctrl>+<Shift>+<v> in the programming window.
For F_TRIG declare the following:
CLK
Q
PLC types
Availability of F_TRIG (see page 1320)
The output Q of a function block F_TRIG remains set for a complete PLC cycle
after the occurrence of a falling edge (status change TRUE -> FALSE) at the CLK
input and is then reset in the following cycle.
Data types
Data type
BOOL
In this example, the same POU header is used for all programming languages. For an example
Example
using IL (instruction list), please refer to the online help.
POU header
All input and output variables which are used for programming the function block F_TRIG are
declared in the POU header. This also includes the function block (FB) itself. By declaring the FB
you create a copy of the original FB. This copy is saved under copy_name, and a separate data
area is reserved.
Body
Signal_output will be set, if a falling edge is detected at signal_input.
LD
ST
When programming with structured text, enter the following:
copy_name( CLK:=
Q=>
Falling edge trigger
signal input
the output Q is set for each falling edge at the signal input (clk = clock)
signal output
is set if a falling edge is detected at CLK.
I/O
Function
input CLK
detects falling edge at input clock
output Q
is set if falling edge is detected at
input
signal_input
signal_output
);
,
Edge detection instructions
313

Advertisement

Table of Contents
loading

Table of Contents