...
Code Block |
---|
typedef struct _ModuleImpulseMsecSourceFract32ModuleImpulseSourceFract32 { ModuleInstanceDescriptor instance; // Common Audio Weaver module instance structure INT32 periodMsec; // Period or rate of the impulse generator (in msec). INT32 period; // Period or rate of the impulse generator (in samples). INT32 sampleIndex; // Specifies the index of the next non-zero value. } ModuleImpulseMsecSourceFract32ClassModuleImpulseSourceFract32Class; |
Variables
Properties
Name | Type | Usage | isHidden | Default value | Range | Units | |||||||
periodMsecperiod | int | parameter | 0 | 1000 | 0:10000 | msec | period | int | derived | 1 | 48000 | 0:240000 | samples |
sampleIndex | int | state | 1 | 0 | Unrestricted |
...
MATLAB Usage
File Name: impulse_msec_source_fract32_module.m
Code Block |
---|
M=impulse_msec_source_fract32_module(NAME, BLOCKSIZE, SAMPLERATE) Source module which periodically outputs an impulse. An impulse is a single non-zero sample of value 1. The period is specified in msec and can be adjusted at run-time. Arguments: NAME - name of the module. BLOCKSIZE - number of samples per output channel. If By emptydefault, then the blockSize is taken from the system input pin. By default, BLOCKSIZE = []32. SAMPLERATE - sample rate of the output signal, in Hz. IfBy emptydefault, then the sample rate is taken from the system input pin. By default, SAMPLERATE = []48000. |