RS (Functionblock) |
Top Previous Next |
RS is a function block that acts as a Reset/Set flip flop. On a leading edge on the "S" input, the "q" output will stay active. On a leading edge on the "R1" input, the "out" will stay inactive. If a leading edge is seen at the same time on both "S" and "R1", the reset function "wins" and the '"out" will stay inactive. Please see the SR function block for a "Set" dominant flip-flop.
Input: S : BOOL (true/false) A leading edge on this signal will set the "out" to active.
R1 : BOOL (true/false) A leading edge on this signal will set the "out" to inactive.
Output: q : BOOL (true/false) This signal will be active if a leading edge is seen on "S", and it will be inactive if a leading edge is seen on "R1".
Declaration: FUNCTION_BLOCK RS;
Example: INCLUDE rtcu.inc |