Owning Palette: Timer Function Blocks
Requires: RT Module
Generates output pulses triggered by rising edges on the input signal.
When a rising edge occurs on input, output pulses TRUE for preset time (ms).
| Dialog Box Options |
| Block Diagram Inputs |
| Block Diagram Outputs |
| Parameter | Description |
|---|---|
| Inputs | Contains the following configuration options:
|
| Outputs | Contains the following configuration options:
|
| Parameter | Description |
|---|---|
| error in (no error) | Describes error conditions that occur before this node runs. |
| preset time | Specifies the amount of time for the function block to use in calculations. |
| input | Specifies the digital input signal. |
| Parameter | Description |
|---|---|
| error out | Contains error information. This output provides standard error out functionality. |
| elapsed time (ms) | Returns the amount of time, in milliseconds, elapsed since the start of the current or last pulse. If no pulse has started, this output returns the amount of time elapsed since the first call of the function block. |
| output | Returns the digital output signal. |
This function block does not respond to rising edges on input received while output is TRUE.
The timing of this function block depends on the rate of the Timed Loop or While Loop in which you place the function block. For example, if you need the function block to update with millisecond resolution, you can place the function block in a Timed Loop configured to execute every millisecond.
The following timing diagram illustrates the behavior of this function block.