Software Library API naibrd 2.24.0
See all documentation at naii.docs.com
ad_common_utils.c File Reference

Functions

bool_t ADUtils_getInput (uint32_t *inputValue)
 ADUtils_getInput assigns "value" the decimal value the user input.
 
void ADUtils_getModuleIDName (uint32_t modid, char *moduleIDName)
 ADUtils_getModuleIDName assigns char* moduleIDName the corresponding string value of the current module's name.
 
bool_t ADUtils_validRangeCode (uint32_t modid, uint32_t Range)
 ADUtils_validRangeCode checks if the user input is equal to one of the AD Module's raw range data codes. Returns NAI_TRUE if a valid raw data code was entered.
 
bool_t ADUtils_isGeneration5 (uint32_t modid)
 ADUtils_isGeneration5 checks if the passed modid is a generation 5 AD module.
 
bool_t ADUtils_isGeneration3 (uint32_t modid)
 ADUtils_isGeneration3 checks if the passed modid is a generation 3 AD module.
 
void ADUtils_GetRangePolarityHex (uint32_t cardIndex, int32_t module, naibrd_ad_mode_t mode, naibrd_ad_range_polarity_t *p_rawRangePolarity)
 ADUtils_GetRangePolarityHex displays the polarity and range settings available for the ADUtils_GetPolarityRange and handles the user input.
 
void ADUtils_GetRangePolarity (uint32_t cardIndex, int32_t module, naibrd_ad_mode_t mode, naibrd_ad_polarity_t *p_polarity, float64_t *p_range)
 
void ADUtils_printRangeOptions (uint32_t modid, naibrd_ad_mode_t mode)
 ADUtils_printRangeOptions prints the range options for the current module.
 
void ADUtils_getRangeOptions (uint32_t modid, naibrd_ad_mode_t mode, float64_t **pp_ranges, int32_t *p_numRanges)
 ADUtils_getRangeOptions returns a pointer to an array of [4] containing the current module's range options.
 
void ADUtils_printC3RangeOptions ()
 ADUtils_printC3RangeOptions() prints to stdout the various range options available for the C3 module. Can have its range set up to 2.5V for 25mA full scale, unipolar only.
 
void ADUtils_printKARangeOptions ()
 ADUtils_printKARangeOptions() prints to stdout the various range options available for the KA module.
 

Variables

static float c1_module_ranges [] = {10.00, 05.00, 02.50, 01.25}
 
static float c2_module_ranges [] = {40.00, 20.00, 10.00, 05.00}
 
static float c4_module_ranges [] = {50.00, 25.00, 12.50, 06.25}
 
static float ca_module_ranges [] = {10.00, 5.00, 2.50, 1.25}
 
static float cx_module_ranges [] = {10.00, 5.00, 2.50, 1.25}
 
static float64_t ad1_module_ranges [] = {10.00, 05.00, 02.50, 01.25}
 
static float64_t ad2_module_ranges [] = {100.0, 50.00, 25.00, 12.50}
 
static float64_t ad3_module_ranges [] = {25.00}
 
static float64_t ad4_module_ranges [] = {10.00, 05.00, 02.50, 01.25}
 
static float64_t ad4_module_current_ranges [] = {25.00}
 
static float64_t ad5_module_ranges [] = {50.00, 25.00, 12.50, 06.25}
 
static float64_t ad6_module_ranges [] = {100.0, 50.00, 25.00, 12.50}
 
static float64_t ade_module_ranges [] = {10.00, 05.00, 02.50, 01.25}
 
static float64_t adf_module_ranges [] = {100.0, 50.00, 25.00, 12.50}
 
static float64_t adg_module_ranges [] = {25.00}
 

Function Documentation

◆ ADUtils_getInput()

bool_t ADUtils_getInput ( uint32_t * inputValue)

ADUtils_getInput assigns "value" the decimal value the user input.

◆ ADUtils_getModuleIDName()

void ADUtils_getModuleIDName ( uint32_t modid,
char * moduleIDName )

ADUtils_getModuleIDName assigns char* moduleIDName the corresponding string value of the current module's name.

◆ ADUtils_getRangeOptions()

void ADUtils_getRangeOptions ( uint32_t modid,
naibrd_ad_mode_t mode,
float64_t ** pp_ranges,
int32_t * p_numRanges )

ADUtils_getRangeOptions returns a pointer to an array of [4] containing the current module's range options.

◆ ADUtils_GetRangePolarity()

void ADUtils_GetRangePolarity ( uint32_t cardIndex,
int32_t module,
naibrd_ad_mode_t mode,
naibrd_ad_polarity_t * p_polarity,
float64_t * p_range )

◆ ADUtils_GetRangePolarityHex()

void ADUtils_GetRangePolarityHex ( uint32_t cardIndex,
int32_t module,
naibrd_ad_mode_t mode,
naibrd_ad_range_polarity_t * p_rawRangePolarity )

ADUtils_GetRangePolarityHex displays the polarity and range settings available for the ADUtils_GetPolarityRange and handles the user input.

◆ ADUtils_isGeneration3()

bool_t ADUtils_isGeneration3 ( uint32_t modid)

ADUtils_isGeneration3 checks if the passed modid is a generation 3 AD module.

◆ ADUtils_isGeneration5()

bool_t ADUtils_isGeneration5 ( uint32_t modid)

ADUtils_isGeneration5 checks if the passed modid is a generation 5 AD module.

◆ ADUtils_printC3RangeOptions()

void ADUtils_printC3RangeOptions ( )

ADUtils_printC3RangeOptions() prints to stdout the various range options available for the C3 module. Can have its range set up to 2.5V for 25mA full scale, unipolar only.

◆ ADUtils_printKARangeOptions()

void ADUtils_printKARangeOptions ( )

ADUtils_printKARangeOptions() prints to stdout the various range options available for the KA module.

◆ ADUtils_printRangeOptions()

void ADUtils_printRangeOptions ( uint32_t modid,
naibrd_ad_mode_t mode )

ADUtils_printRangeOptions prints the range options for the current module.

◆ ADUtils_validRangeCode()

bool_t ADUtils_validRangeCode ( uint32_t modid,
uint32_t Range )

ADUtils_validRangeCode checks if the user input is equal to one of the AD Module's raw range data codes. Returns NAI_TRUE if a valid raw data code was entered.

Variable Documentation

◆ ad1_module_ranges

float64_t ad1_module_ranges[] = {10.00, 05.00, 02.50, 01.25}
static

◆ ad2_module_ranges

float64_t ad2_module_ranges[] = {100.0, 50.00, 25.00, 12.50}
static

◆ ad3_module_ranges

float64_t ad3_module_ranges[] = {25.00}
static

◆ ad4_module_current_ranges

float64_t ad4_module_current_ranges[] = {25.00}
static

◆ ad4_module_ranges

float64_t ad4_module_ranges[] = {10.00, 05.00, 02.50, 01.25}
static

◆ ad5_module_ranges

float64_t ad5_module_ranges[] = {50.00, 25.00, 12.50, 06.25}
static

◆ ad6_module_ranges

float64_t ad6_module_ranges[] = {100.0, 50.00, 25.00, 12.50}
static

◆ ade_module_ranges

float64_t ade_module_ranges[] = {10.00, 05.00, 02.50, 01.25}
static

◆ adf_module_ranges

float64_t adf_module_ranges[] = {100.0, 50.00, 25.00, 12.50}
static

◆ adg_module_ranges

float64_t adg_module_ranges[] = {25.00}
static

◆ c1_module_ranges

float c1_module_ranges[] = {10.00, 05.00, 02.50, 01.25}
static

◆ c2_module_ranges

float c2_module_ranges[] = {40.00, 20.00, 10.00, 05.00}
static

◆ c4_module_ranges

float c4_module_ranges[] = {50.00, 25.00, 12.50, 06.25}
static

◆ ca_module_ranges

float ca_module_ranges[] = {10.00, 5.00, 2.50, 1.25}
static

◆ cx_module_ranges

float cx_module_ranges[] = {10.00, 5.00, 2.50, 1.25}
static