NI DMM Values And Attribute Functions - ni/grpc-device GitHub Wiki
- niDMM_GetAutoRangeValue
- niDMM_GetApertureTimeInfo
- niDMM_GetMeasurementPeriod
- niDMM_SetAttributeViBoolean
- niDMM_SetAttributeViInt32
- niDMM_SetAttributeViReal64
- niDMM_SetAttributeViSession
- niDMM_SetAttributeViString
- niDMM_GetAttributeViBoolean
- niDMM_GetAttributeViInt32
- niDMM_GetAttributeViReal64
- niDMM_GetAttributeViSession
- niDMM_GetAttributeViString
- niDMM_CheckAttributeViBoolean
- niDMM_CheckAttributeViInt32
- niDMM_CheckAttributeViReal64
- niDMM_CheckAttributeViSession
- niDMM_CheckAttributeViString
- niDMM_ImportAttributeConfigurationFile
- niDMM_ExportAttributeConfigurationFile
- niDMM_ImportAttributeConfigurationBuffer
ViStatus = niDMM_GetAutoRangeValue(ViSession Instrument_Handle, ViReal64 *Actual_Range)
Returns the Actual_Range that the DMM is using, even when Auto Range is off.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Output | ||
Name | Type | Description |
Actual_Range | ViReal64* | Indicates the Actual_Range the DMM is using. Returns the value of the NIDMM_ATTR_AUTO_RANGE_VALUE attribute. The units of the returned value depend on the function. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_GetApertureTimeInfo(ViSession Instrument_Handle, ViReal64 *Aperture_Time, ViInt32 *Aperture_Time_Units)
Returns the DMM Aperture_Time and Aperture_Time_Units.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Output | ||
Name | Type | Description |
Aperture_Time | ViReal64* | Specifies the amount of time the DMM digitizes the input signal for a single measurement. This parameter does not include settling time. Returns the value of the NIDMM_ATTR_APERTURE_TIME attribute. The units of this attribute depend on the value of the NIDMM_ATTR_APERTURE_TIME_UNITS within the minimum and maximum ranges is allowed on the NI 4070/4071/4072. On the NI 4065 the minimum aperture time is 333 µs, and the maximum aperture time is 78.2 s. If setting the number of averages directly, the total measurement time is aperture time X the number of averages, which must be less than 72.8 s. The aperture times allowed are 333 µs, 667 µs, or multiples of 1.11 ms—for example 1.11 ms, 2.22 ms, 3.33 ms, and so on. If you set an aperture time other than 333 µs, 667 µs, or multiples of 1.11 ms, the value will be coerced up to the next supported aperture time. On the NI 4060, when the powerline frequency is 60, the PLCs allowed are 1 PLC, 6 PLC, 12 PLC, and 120 PLC. When the powerline frequency is 50, the PLCs allowed are 1 PLC, 5 PLC, 10 PLC, and 100 PLC. |
Aperture_Time_Units | ViInt32* | Indicates the units of aperture time as powerline cycles (PLCs) or seconds. Returns the value of the NIDMM_ATTR_APERTURE_TIME_UNITS attribute. |
NIDMM_VAL_SECONDS | 0 | Seconds |
---|---|---|
NIDMM_VAL_POWER_LINE_CYCLES | 1 | Powerline Cycles |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_GetMeasurementPeriod(ViSession Instrument_Handle, ViReal64 *Period)
Returns the measurement Period, which is the amount of time it takes to complete one measurement with the current configuration. Use this function right before you begin acquiring data—after you have completely configured the measurement and after all configuration functions have been called.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Output | ||
Name | Type | Description |
Period | ViReal64* |
Returns the number of seconds it takes to make one measurement. The first measurement in a multipoint acquisition requires additional settling time. This function does not include this additional time or any NIDMM_ATTR_TRIGGER_DELAY associated with the first measurement. Time required for internal measurements, such as NIDMM_ATTR_AUTO_ZERO, is included. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_SetAttributeViBoolean(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViBoolean Attribute_Value)
This function sets the value of a ViBoolean attribute.
This is a low-level function that you can use to set the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid or is different than the value you specify.
This instrument driver contains high-level functions that set most of the instrument attributes. It is best to use the high-level driver functions as much as possible. They handle order dependencies and multithread locking for you. In addition, they perform status checking only after setting all of the attributes.
In contrast, when you set multiple attributes using the SetAttribute functions, the functions check the instrument status after each call. Also, when state caching is enabled, the high-level functions that configure multiple attributes perform instrument I/O only for the attributes whose value you change. Thus, you can safely call the high-level functions without the penalty of redundant instrument I/O.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViBoolean | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_SetAttributeViInt32(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViInt32 Attribute_Value)
This function sets the value of a ViInt32 attribute.
This is a low-level function that you can use to set the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid or is different than the value you specify.
This instrument driver contains high-level functions that set most of the instrument attributes. It is best to use the high-level driver functions as much as possible. They handle order dependencies and multithread locking for you. In addition, they perform status checking only after setting all of the attributes.
In contrast, when you set multiple attributes using the SetAttribute functions, the functions check the instrument status after each call. Also, when state caching is enabled, the high-level functions that configure multiple attributes perform instrument I/O only for the attributes whose value you change. Thus, you can safely call the high-level functions without the penalty of redundant instrument I/O.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViInt32 | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_SetAttributeViReal64(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViReal64 Attribute_Value)
This function sets the value of a ViReal64 attribute.
This is a low-level function that you can use to set the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid or is different than the value you specify.
This instrument driver contains high-level functions that set most of the instrument attributes. It is best to use the high-level driver functions as much as possible. They handle order dependencies and multithread locking for you. In addition, they perform status checking only after setting all of the attributes.
In contrast, when you set multiple attributes using the SetAttribute functions, the functions check the instrument status after each call. Also, when state caching is enabled, the high-level functions that configure multiple attributes perform instrument I/O only for the attributes whose value you change. Thus, you can safely call the high-level functions without the penalty of redundant instrument I/O.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViReal64 | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_SetAttributeViSession(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViSession Attribute_Value
This function sets the value of a ViSession attribute.
This is a low-level function that you can use to set the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid or is different than the value you specify.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViSession | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_SetAttributeViString(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViString Attribute_Value[])
This function sets the value of a ViString attribute.
This is a low-level function that you can use to set the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid or is different than the value you specify.
This instrument driver contains high-level functions that set most of the instrument attributes. It is best to use the high-level driver functions as much as possible. They handle order dependencies and multithread locking for you. In addition, they perform status checking only after setting all of the attributes.
In contrast, when you set multiple attributes using the SetAttribute functions, the functions check the instrument status after each call. Also, when state caching is enabled, the high-level functions that configure multiple attributes perform instrument I/O only for the attributes whose value you change. Thus, you can safely call the high-level functions without the penalty of redundant instrument I/O.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViString | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_GetAttributeViBoolean(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViBoolean *Attribute_Value)
Queries the value of a ViBoolean attribute. You can use this function to get the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Output | ||
Name | Type | Description |
Attribute_Value | ViBoolean* | Returns the current value of the attribute. Pass the address of a ViBoolean variable. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_GetAttributeViInt32(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViInt32 *Attribute_Value)
Queries the value of a ViInt32 attribute. You can use this function to get the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Output | ||
Name | Type | Description |
Attribute_Value | ViInt32* | Returns the current value of the attribute. Pass the address of a ViInt32 variable. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_GetAttributeViReal64(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViReal64 *Attribute_Value)
Queries the value of a ViReal64 attribute. You can use this function to get the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Output | ||
Name | Type | Description |
Attribute_Value | ViReal64* | Returns the current value of the attribute. Pass the address of a ViReal64 variable. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_GetAttributeViSession(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViSession *Attribute_Value)
Queries the value of a ViSession attribute. You can use this function to get the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Output | ||
Name | Type | Description |
Attribute_Value | ViSession* | Returns the current value of the attribute. Pass the address of a ViSession variable. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_GetAttributeViString(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViInt32 Buffer_Size, ViChar Attribute_Value[])
Queries the value of a ViString attribute. You can use this function to get the values of instrument-specific attributes and inherent IVI attributes.
If the attribute represents an instrument state, this function performs instrument I/O in the following cases:
- State caching is disabled for the entire session or for the particular attribute.
- State caching is enabled, and the currently cached value is invalid. You must provide a ViChar array to serve as a buffer for the value. You pass the number of bytes in the buffer as the Array Size parameter.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Buffer_Size | ViInt32 |
Pass the number of bytes in the ViChar array you specify for the Attribute_Value parameter. If the current value of the attribute, including the terminating NULL byte, contains more bytes that you indicate in this parameter, the function copies Buffer_Size—1 bytes into the buffer, places an ASCII NUL byte at the end of the buffer, and returns the buffer size you must pass to get the entire value. For example, if the value is "123456" and the Buffer_Size is 4, the function places "123" into the buffer and returns 7. If you pass a negative number, the function copies the value to the buffer regardless of the number of bytes in the value. If you pass 0, you can pass VI_NULL for the Attribute_Value buffer parameter. |
Output | ||
Name | Type | Description |
Attribute_Value | ViChar[ ] |
The buffer in which the function returns the current value of the attribute. The buffer must be of type ViChar and have at least as many bytes as indicated in the Buffer_Size parameter. If you specify 0 for the Buffer_Size parameter, you can pass VI_NULL for this parameter. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_CheckAttributeViBoolean(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViBoolean Attribute_Value)
This function checks the validity of a value you specify for a ViBoolean attribute.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViBoolean | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_CheckAttributeViInt32(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViInt32 Attribute_Value)
This function checks the validity of a value you specify for a ViInt32 attribute.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViInt32 | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_CheckAttributeViReal64(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViReal64 Attribute_Value)
This function checks the validity of a value you specify for a ViReal64 attribute.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViReal64 | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_CheckAttributeViSession(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViSession Attribute_Value)
This function checks the validity of a value you specify for a ViSession attribute.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViSession | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus = niDMM_CheckAttributeViString(ViSession Instrument_Handle, ViConstString Channel_Name, ViAttr Attribute_ID, ViChar Attribute_Value[])
This function checks the validity of a value you specify for a ViString attribute.
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Channel_Name | ViConstString |
This parameter is ignored. National Instruments DMMs do not support channel names since they only have a single channel. This parameter is included in order to support interchangeability and upgradability to multiple channel DMMs. The default value is " " (an empty string). |
Attribute_ID | ViAttr | Pass the ID of an attribute. |
Attribute_Value | ViChar[] | Pass the value that you want to set the attribute to. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus niDMM_ImportAttributeConfigurationFile (ViSession Instrument_Handle, ViConstString File_Path);
Imports an attribute configuration to the session from the specified file.
You can export and import session attribute configurations only between devices with identical model numbers.
*Note You cannot call this function while the session is in a running state, such as while acquiring a waveform.
*Note Not supported on the PCMCIA4050 or the PXI/PCI4060.
Coercion Behavior for Certain Devices
Imported and exported attribute configurations contain coerced values for the following NIDMM devices:
- PXI/PCI/PCIe/USB4065
- PXI/PCI4070
- PXI4071
- PXI4072
NIDMM coerces attribute values when the value you set is within the allowed range for the attribute but is not one of the discrete valid values the attribute supports. For example, for an attribute that coerces values up, if you choose a value of 4 when the adjacent valid values are 1 and 10, the attribute coerces the value to 10.
Related Topics:
Using Attributes and Properties with NIDMM
Setting Attributes Before Reading Attributes
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
File_Path | ViConstString | Specifies the absolute path to the file containing the attribute configuration to import. If you specify an empty or relative path, this function returns an error. Default File Extension: .nidmmconfig |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus niDMM_ExportAttributeConfigurationBuffer (ViSession Instrument_Handle, ViInt32 Size, ViAddr Configuration);
Exports the attribute configuration of the session to the specified configuration buffer.
You can export and import session attribute configurations only between devices with identical model numbers.
This function verifies that the attributes you have configured for the session are valid. If the configuration is invalid, NIDMM returns an error.
*Note Not supported on the PCMCIA4050 or the PXI/PCI4060. Coercion Behavior for Certain Devices
Imported and exported attribute configurations contain coerced values for the following NIDMM devices:
- PXI/PCI/PCIe/USB4065
- PXI/PCI4070
- PXI4071
- PXI4072
NIDMM coerces attribute values when the value you set is within the allowed range for the attribute but is not one of the discrete valid values the attribute supports. For example, for an attribute that coerces values up, if you choose a value of 4 when the adjacent valid values are 1 and 10, the attribute coerces the value to 10.
Related Topics:
Using Attributes and Properties with NIDMM
Setting Attributes Before Reading Attributes
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Size | ViInt32 | Specifies the size, in bytes, of the byte array to export. If you enter 0, this function returns the needed size. |
Configuration | ViAddr | Specifies the byte array buffer to be populated with the exported attribute configuration. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |
ViStatus niDMM_ImportAttributeConfigurationBuffer (ViSession Instrument_Handle, ViInt32 Size, ViAddr Configuration);
Imports an attribute configuration to the session from the specified configuration buffer.
You can export and import session attribute configurations only between devices with identical model numbers.
*Note You cannot call this function while the session is in a running state, such as while acquiring a waveform. *Note Not supported on the PCMCIA4050 or the PXI/PCI4060.| Coercion Behavior for Certain Devices
Imported and exported attribute configurations contain coerced values for the following NIDMM devices:
- PXI/PCI/PCIe/USB4065
- PXI/PCI4070
- PXI4071
- PXI4072
NIDMM coerces attribute values when the value you set is within the allowed range for the attribute but is not one of the discrete valid values the attribute supports. For example, for an attribute that coerces values up, if you choose a value of 4 when the adjacent valid values are 1 and 10, the attribute coerces the value to 10.
Related Topics:
Using Attributes and Properties with NIDMM
Setting Attributes Before Reading Attributes
Input | ||
---|---|---|
Name | Type | Description |
Instrument_Handle | ViSession | Identifies a particular instrument session. You obtain the Instrument_Handle parameter from niDMM_init or niDMM_InitWithOptions. The default is None. |
Size | ViInt32 | Specifies the size, in bytes, of the byte array to import. If you enter 0, this function returns the needed size. |
Configuration | ViAddr | Specifies the byte array buffer that contains the attribute configuration to import. |
Name | Type | Description |
---|---|---|
Status | ViStatus | Reports the Status of this operation. To obtain a text description of the status code, call niDMM_GetErrorMessage. To obtain additional information concerning the error condition, use niDMM_GetError. |