Documentation Home Page RT-LAB Home Page
Pour la documentation en FRANÇAIS, utilisez l'outil de traduction de votre navigateur Chrome, Edge ou Safari. Voir un exemple.

RTE Conversion

Page Content

Library

RT-EVENTS Signal Attributes

Block


FIG 1: Block

Description

The RTE Conversion block converts an input signal to the data type specified by the block's Data Types parameter.

The following table explains all output data type conversion available:

Double

Convert the input signal to a Double signal. The output is Low when the input is less than 0.5. Otherwise, the output is High. The changes in the input cause only transitions at the beginning of the calculation step. Only one transition can be output at each calculation step.

Double with Compensation

Convert the input signal to a Double signal. The output is equal to the average of the input signal.

RTE Boolean

Convert the input signal to an RTE Boolean. The output is Low when the input is less than 0.5. Otherwise, the output is High. The changes in the input cause only transitions at the beginning of the calculation step. Only one transition can be output at each calculation step.

RTE Boolean with Compensation

Convert the input signal to an RTE Boolean signal.

  • If the input signal is a Double signal, the output is Low when the input is less than 0.5. Otherwise, the output is High. Also note that the transition between High and Low state depends on the level value of the input signal, i.e that the average of the output during a calculation step is equal to the input signal.

  • If the input signal is an RTE Double, the output is Low when the input is less than 0.5. Otherwise, the output is High. Events during the calculation step are supported.

RTE Double

Convert the input signal to an RTE Double. The output is equal to the input signal at the end of the last event. The changes in the input cause only transitions at the beginning of the calculation step. Only one transition can be output at each calculation step.

RTE Double with Compensation

Convert the input signal to an RTE Double signal.

  • If the input signal is a Double signal, the output is equal to the input signal at the end of the last step. The changes in the input cause only transitions at the beginning of the calculation step. Only one transition can be output at each calculation step.

  • If the input signal is an RTE Boolean, the output is 1 when the input is High. Otherwise, the output is Low. Events during the calculation step are supported.

Mask

FIG 2: Mask

Parameters

Input Data Type

Specify the input data types of the input ports: double, RTE Boolean or RTE Double.

Output Data Type

Specify the output data types of the output ports: Double, RTE Boolean, RTE Double.

RT-EVENTS Compensation

Specify if the RT-EVENTS compensation is enabled or disabled. When enabled, an event can occur between two calculation steps.

Maximum number of events

The maximum number of events or transitions that can occur during a single step. Over this number, events are ignored and not output.

Sample Time [s]

The time interval between samples in seconds. Only available when the input data type is double.

Input

Input

The signal to convert. The data type of this signal must be Double, RTE Boolean or RTE Double.

Output

Output

The converted signals. The data type of this signal must match the data type specified in the Output Data Type parameters.

Characteristics

Direct Feedthrough

Yes

Sample Time

Inherited and fixed discrete

Work offline

Yes

Dimensionalized

Yes

Example

The rte_basic1.mdl model shows how to do simple operations on RTE signals. It also demonstrates how to use the RTE Conversion block to convert an RTE Boolean signal to an RTE Double signal.

OPAL-RT TECHNOLOGIES, Inc. | 1751, rue Richardson, bureau 1060 | Montréal, Québec Canada H3K 1G6 | opal-rt.com | +1 514-935-2323