Table of Contents
Sleep
Sleeps for the specified number of seconds.
Library
MATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
qc_open_library('quarc_library/Advanced/Timing')Description
The Sleep block sleeps for the specified number of seconds. The number of seconds may be a real number. It uses very little CPU time while it sleeps. Only the thread to which the block belongs actually sleeps. In a multirate model in multitasking mode, QUARC executes each sampling rate in a separate thread.
Limitations
The resolution of the sleep interval depends on the system timer of the target. For example, on the Windows target, the sleep interval is only accurate to the nearest millisecond since the Windows system timer has millisecond resolution (as opposed to the QUARC system timebase for Windows, which has submillisecond resolution when using the fast system timer option on multiprocessor or multicore platforms). On the QNX x86 target, the resolution of the sleep interval depends on the maximum timer resolution specified on the Code Generation/QUARC pane of the Configuration Parameters dialog.
Input Ports
This block has no input ports.
Output Ports
This block has no output ports.
Parameters and Dialog Box
Sleep interval
The amount of time in seconds for which the block should sleep. A fractional number of seconds may be specified. The resolution of the sleep interval depends on the target type.
Targets
Target Name |
Compatible* |
Model Referencing |
Comments |
---|---|---|---|
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
Last fully supported in QUARC 2018. |
|
Rapid Simulation (RSIM) Target |
Yes |
Yes |
|
S-Function Target |
No |
N/A |
Old technology. Use model referencing instead. |
Normal simulation |
Yes |
Yes |
Copyright ©2024 Quanser Inc. This page was generated 2024-10-17. Submit feedback to Quanser about this page.
Link to this page.