Detect Falling Edge Using the Detect Fall Nonpositive Block
This example shows how to use the Detect Fall Nonpositive block to detect a falling edge in the input signal. The block detects a falling edge when the signal value decreases from a strictly positive value to a nonpositive value. In this example, the Initial condition of the Detect Fall Nonpositive block is set to
1. This means that the Boolean expression
U/z <= 0 evaluates to true and the block assumes the initial value of the input signal is nonpositive.