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 Queue

Library

RT-EVENTS Math Operations

Block

Description

The RTE Queue block stores in memory the times and states of all events that occur on the RTE Boolean-type input signal. It can also store values of Double-type input signals when events occur on the RTE Boolean signal. The block capacity is set by Queue size.

When a value of 1 is received at the Pop port, the block pops all elements off the queue at the next simulation step and holds the outports at that values until the next pop trigger.

The following figure shows how the queue works.

Pushing and Popping Operations of the RTE Queue Block

A value of 1 at the optional Clr port (enabled by the Clear queue input checkbox) empties the queue contents at the next simulation step.

When two or more of the control input ports are triggered at the same time step, the operations are executed in the following order: Push, Clr, Pop.

The block allows the user to output signals indicating the states of the queue. When the Empty Queue Output parameter is selected the block output 1 when the queue is empty. When the Full Queue Output parameter is selected the block outputs 1 when the queue is full. When the Output Number of Queued Events has selected the block outputs the number of events stored in the queue.

The block can store the values of Double-type input signals when the value of the Number of Input parameters is greater than 0. The block can interpolate the inputs at the time that the events occur (enabled by the Interpolate Input checkbox). If this option is not selected the block stores the value of the input signal at the beginning of the time step.

Mask

RTE Queue Mask

Parameters

Queue Size

The size of the queue.

Empty Queue Output

When selected, outputs the empty state of the queue.

Full QueueOutput

When selected, outputs the full state of the queue.

Number of queued events

When selected, outputs the number of events stored in the queue.

Clear queue input

When selected, adds a port to clear the queue.

Number of Inputs

Number of Double-type signals to store in the queue with event properties.

Interpolate Inputs

When selected, interpolates the inputs at the time of each event.

Input

RTE (RTE Boolean)

RTE Boolean signals to store in the queue.

Pop (Double)

Trigger signal used to pop out all events of the queue (1=Pop, 0=No effect).

Clr (Double)

Trigger signal used to clear all events of the queue (1=Clear, 0=No effect).

Signal N (Double)

Input signal N to store in the queue when events occur.

Output

Times (Double)

The times of the events stored in the queue.

States (Double)

The states of the events stored in the queue.

Empty (Double)

The empty state of the queue.

Full (Double)

The full state of the queue.

Num (Double)

The number of events stored in the queue.

Signal N (Double)

The values of the input signal N stored in the queue.

Characteristics

Direct Feedthrough

Yes

Sample time

Inherited and fixed discrete.

Work offline

Yes

Dimensionalized

No

Examples

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