Logic

EdgeDetect Block

Detects rising, falling, or any change in the input signal. Outputs 1 on detected edge, 0 otherwise.

Open EdgeDetect in BlockWerk →

# EdgeDetect Block

Description

Detects changes in the input signal. Can detect rising edges (input increases), falling edges (input decreases), or any change.

Mathematical Model

rising:  y[n] = 1  if u[n] > u[n-1], else 0
falling: y[n] = 1  if u[n] < u[n-1], else 0
either:  y[n] = 1  if u[n] ≠ u[n-1], else 0

First sample: y[0] = 0 for all modes.

Parameters

mode

Detection mode:

Remarks

See Also