/* ************************************************************** */ /* * Module SENMEASPARAM * This module contains functions to assist in parameter handling * for the SENMEAS module. * * Zachary Wolf * 2/7/03 */ /* ************************************************************** */ /* INCLUDES */ #include #include #include "senmeas.h" /* ************************************************************** */ /* PUBLIC FUNCTIONS */ /* ************************************************************** */ /* * senmeasparam_fill_param_struct * This function fills the parameter structure using # defined * parameters. * * Zachary Wolf * 2/7/03 */ void senmeasparam_fill_param_struct(struct senmeas_param_struct* senmeas_param) { /* Include parameter definitions */ #include "param.h" /* Declare variables */ int i; /* Set the SENMEAS parameters */ senmeas_param->num_sensor = SENMEAS_NUM_SENSOR; /* Check */ if (SENMEAS_NUM_SENSOR > SENMEAS_MAX_NUM_SENSOR) { /* Notify the operator of the error */ printf("\nSENMEAS ERROR: Too many sensors, exiting...\n"); Beep(); Delay(.5); Beep(); Delay(2.); /* Terminate the program */ exit(0); } /* Continue setting the SENMEAS parameters */ for (i = 0; i < SENMEAS_NUM_SENSOR; i++) { senmeas_param->sensor_info[i] = SENSOR_INFO[i]; } /* Done */ return; }