Functions | |
int | InitParamFile (void) |
int | CloseParamFile (void) |
int | GetParam (char *ParamName, void *ParamValue, int ParamType, int ParamLen) |
As this parametrization can't be performed at real-time, a special initialization phase is defined (INIT) so the object can take its time to perform such parametrization.
An example of this can be computing filter coefficients given a band of pass. It is obvious that this operation can't be performed at real-time.
Before obtaining this values, STATSMAN daemons must read the file (system file) where this parameters are kept. This operation has to explicity be done by the object calling the InitParamFile() function.
int CloseParamFile | ( | void | ) |
Close Parameter Configuration File.
Deallocates resources regarding parameter usage. Any more parameter can be obtained after this function has been called.
int GetParam | ( | char * | ParamName, | |
void * | ParamValue, | |||
int | ParamType, | |||
int | ParamLen | |||
) |
Obtain a parameter value.
Get an initialization parameter value.
ParamName | Name of the parameter. | |
ParamValue | Pointer where to save data. | |
ParamType | One of the following (STAT_TYPE_INT, _FLOAT, _CHAR) | |
ParamLen | Length of the expected parameter, in bytes. |
int InitParamFile | ( | void | ) |
Initiates Parameter Configuration File.
Initiates the procedure to read the configuration file and allocate resources. After the object has called this function, it can obtain parameter values using the GetParam function.