Simulink Reference Previous page   Next Page
Rate Transition

Handle transfer of data between blocks operating at different rates

Library

Signal Attributes

Description


The Rate Transition block transfers data from the output of a block operating at one rate to the input of another block operating at a different rate. The Rate Transition block's parameters allows you to specify options that trade data integrity and deterministic transfer for faster response and/or lower memory requirements.

In particular, the block supports the following options:

See Sample Rate Transitions in the online Real-Time Workshop documentation for more information.

Data Type Support

The Rate Transition block accepts signals of any data type supported by Simulink, including fixed-point data types.

For a discussion on the data types supported by Simulink, refer to Data Types Supported by Simulink in the online Simulink documentation.

Parameters and Dialog Box

Ensure data integrity during data transfer
Selecting this option results in generation of code that ensures the integrity of data transferred by the Rate Transition block. If you select this option and the transfer is nondeterministic (see Ensure deterministic data transfer option below), the generated code uses double-buffering to prevent the fast block from interrupting the data transfer. Otherwise the generated code uses a copy operation to effect the data transfer. The copy operation consumes less memory than double-buffering but is also interruptible and hence can lead to loss of data during nondeterministic data transfers. Thus, you should select this option if you want the generated code to operate both with maximum responsiveness (i.e., nondeterministically) and assured data integrity. See Rate Transition Block Options in the online Real-Time Workshop documentation for more information.
Ensure deterministic data transfer (maximum delay)
Selecting this option causes code generation to generate code that transfers data at the sample rate of the slower block, i.e., deterministically. If this option is not selected, data transfers occur as soon as new data is available from the source block and the receiving block is ready to receive the data. This avoids the need to delay transfers, thus ensuring that the system operates with maximum responsiveness. However, it also means that transfers can occur unpredictably, which is undesirable in some applications. See Rate Transition Block Options in the online Real-Time Workshop documentation for more information.
Initial conditions
This parameter applies only to Slow to fast transitions. It specifies the Rate Transition's initial output at the beginning of a transition when there is not yet any output from the slow block connected to the Rate Transition block's input. Simulink does not allow the initial output of this block to be inf or NaN.
Output port sample time
Specifies the output rate to which the input rate is converted. The default value (-1) specifies that the output rate is inherited from the block to which the Rate Transition block's output port is connected. See Specifying Sample Time in the online documentation for information on how to specify the output rate.

Characteristics

Direct Feedthrough
No for slow-to-fast transitions that are protected, i.e., for which you have checked the Ensure data integrity during data transfer option; otherwise, yes.
Sample Time
This block supports discrete-to-discrete and discrete-to-continuous transitions.
Scalar Expansion
Yes, of input.
Dimensionalized
Yes
Zero Crossing
No


Previous page  Rate Limiter Dynamic Real-Imag to Complex Next page

© 1994-2005 The MathWorks, Inc.