Software Library API naibrd 2.24.0
See all documentation at naii.docs.com
|
Functions | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_SetRangePolarity (int32_t cardIndex, int32_t module, int32_t channel, naibrd_ad_polarity_t polarity, float64_t range) |
Sets the range and polarity for the specified A/D channel as follows: | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_GetRangePolarity (int32_t cardIndex, int32_t module, int32_t channel, naibrd_ad_polarity_t *p_outpolarity, float64_t *p_outrange) |
Retrieves the range and polarity for the specified A/D channel as follows: | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_SetSampleRate (int32_t cardIndex, int32_t module, uint32_t rate) |
Sets the sampling clock rate for the specified A/D module as follows: | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_GetSampleRate (int32_t cardIndex, int32_t module, uint32_t *p_outrate) |
Retrieves the sampling clock rate for the specified A/D module as follows: | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_SetMode (int32_t cardIndex, int32_t module, int32_t channel, naibrd_ad_mode_t mode) |
Sets the VI control (voltage/current mode) for the specified A/D channel. | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_GetMode (int32_t cardIndex, int32_t module, int32_t channel, naibrd_ad_mode_t *p_outmode) |
Retrieves the VI control (voltage/current mode) for the specified A/D channel. | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_SetFloatingPointAttribute (int32_t cardIndex, int32_t module, int32_t channel, naibrd_ad_floating_point_attribute_t attribute, float64_t value) |
Sets the HW floating point offset for the specified A/D channel. This feature is only applicable when the HW floating point conversion mode is enabled (See naibrd_SetFloatingPointModeEnable()). Not all modules support HW floating point conversions, please refer to the module's HW specification for details. | |
NAIBRDFUNC nai_status_t NAIAPI | naibrd_AD_GetFloatingPointAttribute (int32_t cardIndex, int32_t module, int32_t channel, naibrd_ad_floating_point_attribute_t attribute, float64_t *p_outvalue) |
Retrieves the HW floating point offset for the specified A/D channel. This feature is only applicable when the HW floating point conversion mode is enabled (See naibrd_SetFloatingPointModeEnable()). Not all modules support HW floating point conversions, please refer to the module's HW specification for details. | |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_GetFloatingPointAttribute | ( | int32_t | cardIndex, |
int32_t | module, | ||
int32_t | channel, | ||
naibrd_ad_floating_point_attribute_t | attribute, | ||
float64_t * | p_outvalue ) |
Retrieves the HW floating point offset for the specified A/D channel. This feature is only applicable when the HW floating point conversion mode is enabled (See naibrd_SetFloatingPointModeEnable()). Not all modules support HW floating point conversions, please refer to the module's HW specification for details.
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
channel | : (Input) Channel Number of the channel to access (1 - [max channels for module]). |
attribute | : (Input) Floating-point attribute to read. |
p_outvalue | : (Output) Floating-point value read from register. |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_GetMode | ( | int32_t | cardIndex, |
int32_t | module, | ||
int32_t | channel, | ||
naibrd_ad_mode_t * | p_outmode ) |
Retrieves the VI control (voltage/current mode) for the specified A/D channel.
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
channel | : (Input) Channel Number of the channel to access (1 - [max channels for module]). |
p_outmode | : (Output) NAIBRD_AD_MODE_VOLTAGE or NAIBRD_AD_MODE_CURRENT. |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_GetRangePolarity | ( | int32_t | cardIndex, |
int32_t | module, | ||
int32_t | channel, | ||
naibrd_ad_polarity_t * | p_outpolarity, | ||
float64_t * | p_outrange ) |
Retrieves the range and polarity for the specified A/D channel as follows:
* --------- Voltage -------- -- Current -- Register Value * AD1/AD4/ADE AD5 AD2/AD6/ADF ADG/AD4/AD3* Unipolar Mode Bipolar Mode * ----------------------------------------------------------------------------- * N/A N/A N/A N/A 0x0A 0x1A * N/A N/A N/A N/A 0x09 0x19 * 10.00 50.00 100.00 25.00mA 0x00 0x10 * 5.00 25.00 50.00 12.50mA 0x01 0x11 * 2.50 12.50 25.00 6.250mA 0x02 0x12 * 1.25 6.25 12.50 3.125mA 0x03 0x13 * ----------------------------------------------------------------------------- * *Notes: AD3 only supports the 25mA range. * ADG only supports the 25mA and 12.5mA ranges * *
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
channel | : (Input) Channel Number of the channel to access (1 - [max channels for module]). |
p_outpolarity | : (Output) NAIBRD_AD_POLARITY_UNIPOLAR or NAIBRD_AD_POLARITY_BIPOLAR. |
p_outrange | : (Output) Voltage range in volts. |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_GetSampleRate | ( | int32_t | cardIndex, |
int32_t | module, | ||
uint32_t * | p_outrate ) |
Retrieves the sampling clock rate for the specified A/D module as follows:
Module Min Rate Max Rate
AD1/AD2/AD3 1000 256000 AD4/AD5/AD6 1000 400000 ADE/ADF/ADG 1000 200000
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
p_outrate | : (Output) A/D sampling rate in Hz (valid clock rate is 2000Hz to 200 KHz). |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_SetFloatingPointAttribute | ( | int32_t | cardIndex, |
int32_t | module, | ||
int32_t | channel, | ||
naibrd_ad_floating_point_attribute_t | attribute, | ||
float64_t | value ) |
Sets the HW floating point offset for the specified A/D channel. This feature is only applicable when the HW floating point conversion mode is enabled (See naibrd_SetFloatingPointModeEnable()). Not all modules support HW floating point conversions, please refer to the module's HW specification for details.
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
channel | : (Input) Channel Number of the channel to access (1 - [max channels for module]). |
attribute | : (Input) Floating-point attribute to set. |
value | : (Input) Floating-point value to set. |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_SetMode | ( | int32_t | cardIndex, |
int32_t | module, | ||
int32_t | channel, | ||
naibrd_ad_mode_t | mode ) |
Sets the VI control (voltage/current mode) for the specified A/D channel.
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
channel | : (Input) Channel Number of the channel to access (1 - [max channels for module]). |
mode | : (Input) NAIBRD_AD_MODE_VOLTAGE or NAIBRD_AD_MODE_CURRENT. |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_SetRangePolarity | ( | int32_t | cardIndex, |
int32_t | module, | ||
int32_t | channel, | ||
naibrd_ad_polarity_t | polarity, | ||
float64_t | range ) |
Sets the range and polarity for the specified A/D channel as follows:
* --------- Voltage -------- -- Current -- Register Value * AD1/AD4/ADE AD5 AD2/AD6/ADF ADG/AD4/AD3* Unipolar Mode Bipolar Mode * ----------------------------------------------------------------------------- * N/A N/A N/A N/A 0x0A 0x1A * N/A N/A N/A N/A 0x09 0x19 * 10.00 50.00 100.00 25.00mA 0x00 0x10 * 5.00 25.00 50.00 12.50mA 0x01 0x11 * 2.50 12.50 25.00 6.250mA 0x02 0x12 * 1.25 6.25 12.50 3.125mA 0x03 0x13 * ----------------------------------------------------------------------------- * *Notes: AD3 only supports the 25mA range. * ADG only supports the 25mA and 12.5mA ranges * *
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
channel | : (Input) Channel Number of the channel to access (1 - [max channels for module]). |
polarity | : (Input) NAIBRD_AD_POLARITY_UNIPOLAR or NAIBRD_AD_POLARITY_BIPOLAR. |
range | : (Input) Voltage range in volts, or Current range in Amps (AD4 only). |
NAIBRDFUNC nai_status_t NAIAPI naibrd_AD_SetSampleRate | ( | int32_t | cardIndex, |
int32_t | module, | ||
uint32_t | rate ) |
Sets the sampling clock rate for the specified A/D module as follows:
Module Min Rate Max Rate
AD1/AD2/AD3 1000 256000 AD4/AD5/AD6 1000 400000 ADE/ADF/ADG 1000 200000
cardIndex | : (Input) Logical Card Index assigned to connection with the NAI_BOARD (0 - NAI_MAX_CARDS-1). |
module | : (Input) Module Number of the module to access (1 - [max modules for board]). |
rate | : (Input) A/D sampling rate in Hz (valid clock rate is 2000Hz to 200 KHz). |