blockAfterFor
Output is true, after rising edge of input for defined duration (flat version)
Information
Syntax
condition = AfterFor(u=..., duration=...).y;
Description
Output y = true, after a rising edge of the input u for the defined duration (if a previous duration was not yet completed, it is implicitely canceled by a new rising edge of u; this has the effect to make the y=true phase longer; see time = 7 s - 9.5 s in the example below). Otherwise, y = false. If u = true at initialization, y = true for the defined duration.
Example
This block is demonstrated with the following example:
results in
![]() |
|
| simulation result |
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Units.SI.Time | duration | Duration after rising edge of u |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Blocks.Interfaces.BooleanOutput | y | = true, after rising edge of u for given duration |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| Boolean | u | Boolean input |
