Technical data

DOC-01-TELAS-CRG-4 ASTi ACE Studio Components Reference Guide Rev.M
84 Copyright © 2014 Advanced Simulation Technology inc.
5.5. Counter
Summary: The Counter provides a time-based, general purpose event or
continuous ramping function. In single shot mode, the Counter can provide an
externally triggered function lookup suitable for amplitude or frequency control of
dynamically generated audio sources for sound effects such as explosions, or
touchdown thumps that play once for a fixed time duration.
When set to continuous mode, the Counter can provide a table driven modulation of
waveforms, where the modulation rate is slower than the overall model execution
rate (i.e. 0 to 100 Hertz).
The Counter also provides a generic timer function for control logic within the
model.
Description: The operation of the Counter component is as follows:
1. When triggered, the counter counts from Start Val to End Val over the period of
time specified by Duration.
2. The current count value is passed as input X into an f(x) function.
3. The output of the Counter component is the function result.
As described above, the Start Value and End Value fields define the counting
sequence. If these parameters are set to the same value, the counter should output
0.0. If the End Value is less than the Start Value, the counter will count down. If the
End Value is greater than the Start Value, the counter will count up. When the coun-
ter is not counting, its value is 0.0.
Note: The output of the Counter component may not necessarily be 0.0 when the
counter is 0.0. The counter component output depends on the function that has been
specified by the user.
If the Duration input is less than zero, the Counter should use a value of zero for the
counter duration.
When the Continuous Mode flag is set, the counter continuously cycles through the
count sequence. When it reaches the End Value, it waits for the period of time spec-
ified by Delay then begins the count sequence again. If this flag is not set, the coun-
ter resets to 0.0 when it reaches the end of the sequence.
When the Count All flag is set, the counter proceeds to the end of the count
sequence even if the Trigger has been removed. At the end of the sequence, the
counter resets to 0.0. If this flag is not set, the counter resets to 0.0 as soon as the
Trigger is removed.
Control Inputs
Delay
Type Default Value
float32 1.0
Description: The length of time (in seconds) between counting
cycles when the Counter is in Continuous Mode.
Modifier: Multiply
Modifier_default: 0.0
Duration
Type Default Value
Float32 1.0
Description: The length of time (in seconds) for the counter to go
from Start_Value to End_Value.
Modifier: Multiply
Pause
Type Default Value
boolean FALSE
Description: The Counter will pause at its current value when Pause
is True.
Modifier: XOR
Trigger
Type Default Value
boolean FALSE
Description: A Trigger state of TRUE initiates counting. The Con-
tinuous Mode flag determines how the counter behaves when the
Trigger is set to False.
Modifier: XOR
Modifier_default: