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.

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

Library

RT-EVENTS Signal Attributes

Block

Description

The RTE Period Meter block measures the period and frequency of its input signals. It can also measure the duty cycle and the duration of its high state (Ton) or low state (Toff).

The period and frequency output signals can be measured between consecutive rising edges or consecutive falling edges. The measurement between consecutive parameters allows the user to select one of these two modes.

The duty cycle, Ton and Toff outputs can be calculated during one calculation step or during one signal period interval. When the calculation step is selected, the times Ton and Toff are valued between 0 and the calculation step. The duty cycle is the ratio of the time Ton on the calculation step. When the signal period interval is selected, the Ton and Toff outputs are values between 0 and the signal period. The duty cycle is the ratio of the time Ton on the signal period. The measurement during one parameter allows the selection of these two modes. The following two figures present the difference between Signal Period and Calcultaiton Step modes.

Signal Period Operation Mode of the RTE Period Meter Block

Calculation Step Operation Mode of the RTE Period Meter Block

The minimum frequency parameter is used when the inputs signal is at very low frequency. When the block has not detected edges since a time greater than the inactive period condition, the measured period and frequency are set respectively to infinity and zero.

When the frequency of the input is lower than the minimum frequency parameter, also note that the value of the duty cycle changes instantaneously between 0 and 1 depending of the logic level (Low or High) of the input signal. In some systems, this behavior can cause problems. The RTE Frequency Meter block has a different algorithm to treat the duty cycle when the frequency is lower than the minimum frequency.

Mask

 RTE Period Meter Mask

Parameters

Display Period

Outputs the period of the input signal.

Display Frequency

Outputs the frequency of the input signal.

Measurement between consecutive

Determines if the period and frequency outputs are measured between the consecutive rising or falling edges.

Display Ton

Outputs the duration of the high state.

Display Toff

Outputs the duration of the low state.

Display Duty Cycle

Outputs the duty cycle.

Measurement during one

Determines if the Ton, Toff and Duty Cycle are calculated relative to one calculation step or relative to one completed signal period.

Minimum frequency

When the input signal frequency is lower than this value, the output frequency and period are 0 and Inf.


Input

Input (RTE Boolean)

RTE Boolean signals to measure.

Output

Period (Double)

Signal periods in seconds.

Frequency (Double)

Signal frequencies in Hz.

Ton (Double)

Duration of its high state in seconds.

Toff (Doule)

Duration of its low state in seconds.

Duty Cycle (Double)

The duty cycle in the range: [0..1].

Characteristics

Direct Feedthrough

Yes

Sample time

Inherited and fixed discrete.

Work Offline

Yes

Dimensionalized

Yes

Examples

The rte_encoder.mdl model demonstrates how to use RT-EVENTS blocks to simulate an incremental encoder connected to a rotating object. This example also shows how to use blocks of the library to insert fault, to filter noise and to measure some characteristics of RTE Boolean signal. In this example, the RTE Period Meter block is used to measure the frequency of the incremental encoder.

  • No labels