Skip to Main Content Skip to Search
Product Documentation

Async Rate Transition - Async Rate Transition block

Library

xPC Target Library for Asynchronous Event

Description

Use the Asynchronous Rate Transition block to double buffer data between the function call subsystem and the rest of the model which executes rate-monotonically in real-time.

Normally, the interrupt service routine writes to the first buffer. When the next model step executes, the first buffer is copied to the second buffer and its value is used for model calculations.

If a second interrupt occurs while the buffer is being copied, data is corrupted. This corruption happens when part of the data is copied from the first buffer, the interrupt occurs and writes over the entire first buffer, and then the transition block continues the copy operation from the first buffer that now has data from the second interrupt.

To prevent data corruption, use Async Buffer Write and Read blocks. See Async Buffer Write and Read blocks.

Block Parameters

Sample time

Enter a base sample time or a multiple of the base sample time.

See Also

Asynchronous Event Support

  


Related Products & Applications

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS