![]() |
![]() |
![]() |
Functions | |
int | ccurGen_addGenerator (const char *pointName, int endConditionType, int sigtype, float freq, float amplitude, float phase, float offset, float duty, float noise, double duration, void *userArg) |
int | ccurGen_addGeneratorP (const RTDBItem *pItem, int endConditionType, int sigtype, float freq, float amplitude, float phase, float offset, float duty, float noise, double duration, void *userArg) |
int | ccurGen_addAsamGenerator (const char *pointName, const char *asamFile) |
int | ccurGen_addSegmentGenerator (const char *pointName, const char *sigName, int repeat) |
int | ccurGen_addAsamGeneratorP (const RTDBItem *pItem, const char *asamFile) |
int | ccurGen_addSegmentGeneratorP (const RTDBItem *pItem, const char *sigName, int repeat) |
int | ccurGen_startGenerator (int genNumber) |
int | ccurGen_startAllGenerators () |
int | ccurGen_stopGenerator (int genNumber) |
int | ccurGen_removeGenerator (int genNumber) |
int | ccurGen_stopAllGenerators () |
int | ccurGen_removeAllGenerators () |
int | ccurGen_appendGenerator (int first, int second) |
int | ccurGen_rampToValue (const char *pointName, double endValue, double rate, int initCondition, double initialValue) |
int | ccurGen_rampToValueP (const RTDBItem *pItem, double endValue, double rate, int initCondition, double initialValue) |
int | ccurGen_rampRate (const char *pointName, double duration, double rate, int initCondition, double initialValue) |
int | ccurGen_rampRateP (const RTDBItem *pItem, double duration, double rate, int initCondition, double initialValue) |
int | ccurGen_getGeneratorInfo (int genNumber, GeneratorInfo *info) |
This API is used by program running on the Real-Time host to access and configure signal generators.
Typically, those programs are script program that initialize signal generator at start-up time and attach an RTDB item value to it.
int ccurGen_addGenerator | ( | const char * | pointName, | |
int | endConditionType, | |||
int | sigtype, | |||
float | freq, | |||
float | amplitude, | |||
float | phase, | |||
float | offset, | |||
float | duty, | |||
float | noise, | |||
double | duration, | |||
void * | userArg | |||
) |
Attach a wave form generator to a RTDB point value for a specified duration or terminate with a user specified callback.
A test must be running before you can create and start a signal generator.
pointName | The name of the RTDB item to assign value to. | |
endConditionType | One of TDL_SiggenEndCondition. Either terminate when user specified time has expired or when the user supplied callback routine returns true; | |
sigtype | One of SigType i.e. SIG_TYPE_SINE, SIG_TYPE_SQUARE, SIG_TYPE_TRIANGLE, SIG_TYPE_SAWTOOTH, SIG_TYPE_NOISE but NOT SIG_TYPE_RAMP reserved for ramp only. | |
freq | The frequency in Hz for the signal generator. | |
amplitude | The amplitude in Engineering for the generator. | |
phase | The phase in degree for the generator. | |
offset | The offset in engineering units for the generator. | |
duty | The duty cycle in % (0 to 100 %) for the generator. | |
noise | Additional white component to add to the signal generator. | |
duration | The duration in seconds . Use -1 to run forever until the test is stopped. | |
userArg | Pointer to pass to the user callback routine at each call. Callback is not supported at this time. |
int ccurGen_addGeneratorP | ( | const RTDBItem * | pItem, | |
int | endConditionType, | |||
int | sigtype, | |||
float | freq, | |||
float | amplitude, | |||
float | phase, | |||
float | offset, | |||
float | duty, | |||
float | noise, | |||
double | duration, | |||
void * | userArg | |||
) |
Attach a wave form generator to a RTDB point value for a specified duration or terminate with a user specified callback.
A test must be running before you can create and start a signal generator.
pItem | Pointer to the RTDB item. | |
endConditionType | One of TDL_SiggenEndCondition. Either terminate when user specified time has expired or when the user supplied callback routine returns true; | |
sigtype | One of SigType i.e. SIG_TYPE_SINE, SIG_TYPE_SQUARE, SIG_TYPE_TRIANGLE, SIG_TYPE_SAWTOOTH, SIG_TYPE_NOISE but NOT SIG_TYPE_RAMP reserved for ramp only. | |
freq | The frequency in Hz for the signal generator. | |
amplitude | The amplitude in Engineering for the generator. | |
phase | The phase in degree for the generator. | |
offset | The offset in engineering units for the generator. | |
duty | The duty cycle in % (0 to 100 %) for the generator. | |
noise | Additional white component to add to the signal generator. | |
duration | The duration in seconds . Use -1 to run forever until the test is stopped. | |
userArg | Pointer to pass to the user callback routine at each call. Callback is not supported at this time. |
int ccurGen_addAsamGenerator | ( | const char * | pointName, | |
const char * | asamFile | |||
) |
Attach an ASAM wave form generator to an RTDB point value.
A test must be running before you can create and start a signal generator.
pointName | The name of the RTDB item to be driven. | |
asamFile | The name of the ASAM signal definition file. |
int ccurGen_addSegmentGenerator | ( | const char * | pointName, | |
const char * | sigName, | |||
int | repeat | |||
) |
Attach an segemented wave form generator to an RTDB point value.
This is similar to a ASAM generator but the signal generator file is In the SigGenerators directory.
A test must be running before you can create and start a signal generator.
pointName | The name of the RTDB item to be driven. | |
sigName | The name of the generator ; i.e. 'sig1', 'mysig', etc.. | |
repeat | The number of time to repeat the segment when generating data. |
int ccurGen_addAsamGeneratorP | ( | const RTDBItem * | pItem, | |
const char * | asamFile | |||
) |
Attach an ASAM wave form generator to an RTDB point value.
A test must be running before you can create and start a signal generator.
pItem | Pointer to the RTDB item to be driven. | |
asamFile | The name of the ASAM signal definition file. |
int ccurGen_addSegmentGeneratorP | ( | const RTDBItem * | pItem, | |
const char * | sigName, | |||
int | repeat | |||
) |
Attach an segemented wave form generator to an RTDB point value.
This is similar to a ASAM generator but the signal generator file is In the SigGenerators directory.
A test must be running before you can create and start a signal generator.
pItem | Pointer to the RTDB item to be driven. | |
sigName | The name of the generator ; i.e. 'sig1', 'mysig', etc.. | |
repeat | The number of time to repeat the segment when generating data. |
int ccurGen_startGenerator | ( | int | genNumber | ) |
Start the generator number genNum.
genNumber | A valid generator number returned by a call to ccurTDL_addGenerator. |
int ccurGen_startAllGenerators | ( | ) |
Start all the generators that have been defined.
This does not start generators that are appended.
int ccurGen_stopGenerator | ( | int | genNumber | ) |
Stop the generator genNum.
genNumber | The number of the generator to stop. |
int ccurGen_removeGenerator | ( | int | genNumber | ) |
Stop the generator genNum and remove it from the list of existing generators.
genNumber | The number of the generator to stop. |
int ccurGen_stopAllGenerators | ( | ) |
Stop all the generators that have been defined.
int ccurGen_removeAllGenerators | ( | ) |
Stop all the generators that have been defined and remove them from the list of existing generators.
int ccurGen_appendGenerator | ( | int | first, | |
int | second | |||
) |
Append a second generator that starts running when the first has finished executing.
Both generators must have been created by a call to _addGenerator or _rampToValue or _rampRate.
first | The number of the first generator. | |
second | The number of the generator that will start when first finished. |
int ccurGen_rampToValue | ( | const char * | pointName, | |
double | endValue, | |||
double | rate, | |||
int | initCondition, | |||
double | initialValue | |||
) |
Ramp up/down a RTDB point value to a specified value.
The function will keep running until the end value is attained.
A test must be running before you can create and start a ram signal.
pointName | The name of the RTDB item to assign value to. | |
endValue | The target end value. | |
rate | The rate in Units/Seconds at which to ramp the value of the item up or down. | |
initCondition | The initial value type for the ramp. |
initialValue | This is the initial value for the point when initCondition is GEN_SIGGENINIT_USER. |
int ccurGen_rampToValueP | ( | const RTDBItem * | pItem, | |
double | endValue, | |||
double | rate, | |||
int | initCondition, | |||
double | initialValue | |||
) |
Ramp up/down a RTDB point value to a specified value.
The function will keep running until the end value is attained.
A test must be running before you can create and start a ram signal.
pItem | Pointer to the RTDB item. | |
endValue | The target end value. | |
rate | The rate in Units/Seconds at which to ramp the value of the item up or down. | |
initCondition | The initial value type for the ramp. |
initialValue | This is the initial value for the point when initCondition is GEN_SIGGENINIT_USER. |
int ccurGen_rampRate | ( | const char * | pointName, | |
double | duration, | |||
double | rate, | |||
int | initCondition, | |||
double | initialValue | |||
) |
Ramp up/down a RTDB point value for a specified duration.
The function will keep running for the duration specified by the call.
pointName | The name of the RTDB item to assign value to. | |
duration | The duration in seconds. Must be > 0. | |
rate | The rate in Units/Seconds at which to ram the value of the item up or down. | |
initCondition | The initial value type for the ramp. |
initialValue | This is the initial value for the point when initCondition is GEN_SIGGENINIT_USER. |
int ccurGen_rampRateP | ( | const RTDBItem * | pItem, | |
double | duration, | |||
double | rate, | |||
int | initCondition, | |||
double | initialValue | |||
) |
Ramp up/down a RTDB point value for a specified duration.
The function will keep running for the duration specified by the call.
pItem | Pointer to the RTDB item. | |
duration | The duration in seconds. Must be > 0. | |
rate | The rate in Units/Seconds at which to ram the value of the item up or down. | |
initCondition | The initial value type for the ramp. |
initialValue | This is the initial value for the point when initCondition is GEN_SIGGENINIT_USER. |
int ccurGen_getGeneratorInfo | ( | int | genNumber, | |
GeneratorInfo * | info | |||
) |
Get the running status of the generator genNum .
genNumber | The number of the generator to stop. | |
info | A pointer to a GeneratorStatus structure where the information is returned. |