nidaqmx.system.device
- class nidaqmx.system.device.Device(name, *, grpc_options=None)[source]
Bases:
object
Represents a DAQmx device.
- __init__(name, *, grpc_options=None)[source]
- Parameters:
name (str) – Specifies the name of the device.
grpc_options (Optional[
GrpcSessionOptions
]) – Specifies the gRPC session options.
- property accessory_product_nums
Indicates the unique hardware identification number for accessories connected to the device. Each list element corresponds to a connector. For example, index 0 corresponds to connector 0. The list contains 0 for each connector with no accessory connected.
- Type:
List[int]
- property accessory_product_types
Indicates the model names of accessories connected to the device. Each list element corresponds to a connector. For example, index 0 corresponds to connector 0. The list contains an empty string for each connector with no accessory connected.
- Type:
List[str]
- property accessory_serial_nums
Indicates the serial number for accessories connected to the device. Each list element corresponds to a connector. For example, index 0 corresponds to connector 0. The list contains 0 for each connector with no accessory connected.
- Type:
List[int]
- static add_network_device(ip_address, device_name='', attempt_reservation=False, timeout=10.0, *, grpc_options=None)[source]
Adds a Network cDAQ device to the system and, if specified, attempts to reserve it.
- Parameters:
ip_address (str) – Specifies the string containing the IP address (in dotted decimal notation) or hostname of the device to add to the system.
device_name (Optional[str]) – Indicates the name to assign to the device. If unspecified, NI-DAQmx chooses the device name.
attempt_reservation (Optional[bool]) – Indicates if a reservation should be attempted after the device is successfully added. By default, this parameter is set to False.
timeout (Optional[float]) – Specifies the time in seconds to wait for the device to respond before timing out.
grpc_options (Optional[
GrpcSessionOptions
]) – Specifies the gRPC session options.
- Returns:
Specifies the object that represents the device this operation applied to.
- Return type:
- property ai_bridge_rngs
Indicates pairs of input voltage ratio ranges, in volts per volt, supported by devices that acquire using ratiometric measurements. Each pair consists of the low value followed by the high value.
- Type:
List[float]
- property ai_charge_rngs
Indicates in coulombs pairs of input charge ranges for the device. Each pair consists of the low value followed by the high value.
- Type:
List[float]
- property ai_couplings
Indicates the coupling types supported by this device.
- Type:
- property ai_current_int_excit_discrete_vals
Indicates the set of discrete internal current excitation values supported by this device.
- Type:
List[float]
- property ai_current_rngs
Indicates the pairs of current input ranges supported by this device. Each pair consists of the low value, followed by the high value.
- Type:
List[float]
- property ai_dig_fltr_lowpass_cutoff_freq_discrete_vals
Indicates the set of discrete lowpass cutoff frequencies supported by this device. If the device supports ranges of lowpass cutoff frequencies, use AI.DigFltr.Lowpass.CutoffFreq.RangeVals to determine supported frequencies.
- Type:
List[float]
- property ai_dig_fltr_lowpass_cutoff_freq_range_vals
Indicates pairs of lowpass cutoff frequency ranges supported by this device. Each pair consists of the low value, followed by the high value. If the device supports a set of discrete lowpass cutoff frequencies, use AI.DigFltr.Lowpass.CutoffFreq.DiscreteVals to determine the supported frequencies.
- Type:
List[float]
- property ai_dig_fltr_types
Indicates the AI digital filter types supported by the device.
- Type:
- property ai_freq_rngs
Indicates the pairs of frequency input ranges supported by this device. Each pair consists of the low value, followed by the high value.
- Type:
List[float]
- property ai_gains
Indicates the input gain settings supported by this device.
- Type:
List[float]
- property ai_lowpass_cutoff_freq_discrete_vals
Indicates the set of discrete lowpass cutoff frequencies supported by this device. If the device supports ranges of lowpass cutoff frequencies, use ai_lowpass_cutoff_freq_range_vals to determine supported frequencies.
- Type:
List[float]
- property ai_lowpass_cutoff_freq_range_vals
Indicates pairs of lowpass cutoff frequency ranges supported by this device. Each pair consists of the low value, followed by the high value. If the device supports a set of discrete lowpass cutoff frequencies, use ai_lowpass_cutoff_freq_discrete_vals to determine the supported frequencies.
- Type:
List[float]
- property ai_max_multi_chan_rate
Indicates the maximum sampling rate for an analog input task from this device. To find the maximum rate for the task, take the minimum of ai_max_single_chan_rate or the indicated sampling rate of this device divided by the number of channels to acquire data from (including cold-junction compensation and autozero channels).
- Type:
float
- property ai_max_single_chan_rate
Indicates the maximum rate for an analog input task if the task contains only a single channel from this device.
- Type:
float
- property ai_meas_types
Indicates the measurement types supported by the physical channels of the device. Refer to ai_meas_types for information on specific channels.
- Type:
- property ai_min_rate
Indicates the minimum rate for an analog input task on this device. NI-DAQmx returns a warning or error if you attempt to sample at a slower rate.
- Type:
float
- property ai_num_samp_timing_engines
Indicates the number of Analog Input sample timing engines supported by the device.
- Type:
int
- property ai_num_sync_pulse_srcs
Indicates the number of Analog Input synchronization pulse sources supported by the device.
- Type:
int
- property ai_physical_chans
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the analog input physical channels available on the device.
- property ai_resistance_rngs
Indicates pairs of input resistance ranges, in ohms, supported by devices that have the necessary signal conditioning to measure resistances. Each pair consists of the low value followed by the high value.
- Type:
List[float]
- property ai_samp_modes
Indicates sample modes supported by devices that support sample clocked analog input.
- Type:
- property ai_simultaneous_sampling_supported
Indicates if the device supports simultaneous sampling.
- Type:
bool
- property ai_trig_usage
Indicates the triggers supported by this device for an analog input task.
- Type:
- property ai_voltage_int_excit_discrete_vals
Indicates the set of discrete internal voltage excitation values supported by this device. If the device supports ranges of internal excitation values, use ai_voltage_int_excit_range_vals to determine supported excitation values.
- Type:
List[float]
- property ai_voltage_int_excit_range_vals
Indicates pairs of internal voltage excitation ranges supported by this device. Each pair consists of the low value, followed by the high value. If the device supports a set of discrete internal excitation values, use ai_voltage_int_excit_discrete_vals to determine the supported excitation values.
- Type:
List[float]
- property ai_voltage_rngs
Indicates pairs of input voltage ranges supported by this device. Each pair consists of the low value, followed by the high value.
- Type:
List[float]
- property anlg_trig_supported
Indicates if the device supports analog triggering.
- Type:
bool
- property ao_current_rngs
Indicates pairs of output current ranges supported by this device. Each pair consists of the low value, followed by the high value.
- Type:
List[float]
- property ao_gains
Indicates the output gain settings supported by this device.
- Type:
List[float]
- property ao_max_rate
Indicates the maximum analog output rate of the device.
- Type:
float
- property ao_min_rate
Indicates the minimum analog output rate of the device.
- Type:
float
- property ao_num_samp_timing_engines
Indicates the number of Analog Output sample timing engines supported by the device.
- Type:
int
- property ao_num_sync_pulse_srcs
Indicates the number of Analog Output synchronization pulse sources supported by the device.
- Type:
int
- property ao_output_types
Indicates the generation types supported by the physical channels of the device. Refer to ao_output_types for information on specific channels.
- Type:
- property ao_physical_chans
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the analog output physical channels available on the device.
- property ao_samp_clk_supported
Indicates if the device supports the sample clock timing type for analog output tasks.
- Type:
bool
- property ao_samp_modes
Indicates sample modes supported by devices that support sample clocked analog output.
- Type:
- property ao_trig_usage
Indicates the triggers supported by this device for analog output tasks.
- Type:
- property ao_voltage_rngs
Indicates pairs of output voltage ranges supported by this device. Each pair consists of the low value, followed by the high value.
- Type:
List[float]
- property bus_type
Indicates the bus type of the device.
- property cal_acc_connection_count
Specifies the number of times a particular connection that results in tangible wear and tear of onboard components has been made on the accessory. This connection count is useful for tracking accessory life and usage.
- Type:
int
- property cal_dev_temp
Indicates in degrees Celsius the current temperature of the device.
- Type:
float
- property cal_recommended_acc_connection_count_limit
Indicates the recommended connection count limit for an accessory. If the accessory connection count exceeds this limit, the accessory could require maintenance.
- Type:
int
- property cal_user_defined_info
Specifies a string that contains arbitrary, user-defined information. This number of characters in this string can be no more than cal_user_defined_info_max_size.
- Type:
str
- property cal_user_defined_info_max_size
Indicates the maximum length in characters of cal_user_defined_info.
- Type:
int
- property carrier_serial_num
Indicates the serial number of the device carrier. This value is zero if the carrier does not have a serial number.
- Type:
int
- property chassis_module_devices
Indicates a list containing the names of the modules in the chassis.
- Type:
- property ci_max_size
Indicates in bits the size of the counters on the device.
- Type:
int
- property ci_max_timebase
Indicates in hertz the maximum counter timebase frequency.
- Type:
float
- property ci_meas_types
Indicates the measurement types supported by the physical channels of the device. Refer to ci_meas_types for information on specific channels.
- Type:
- property ci_physical_chans
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the counter input physical channels available on the device.
- property ci_samp_clk_supported
Indicates if the device supports the sample clock timing type for counter input tasks.
- Type:
bool
- property ci_samp_modes
Indicates sample modes supported by devices that support sample clocked counter input.
- Type:
- property ci_trig_usage
Indicates the triggers supported by this device for counter input tasks.
- Type:
- property co_max_size
Indicates in bits the size of the counters on the device.
- Type:
int
- property co_max_timebase
Indicates in hertz the maximum counter timebase frequency.
- Type:
float
- property co_output_types
Indicates the generation types supported by the physical channels of the device. Refer to co_output_types for information on specific channels.
- Type:
- property co_physical_chans
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the counter output physical channels available on the device.
- property co_samp_clk_supported
Indicates if the device supports Sample Clock timing for counter output tasks.
- Type:
bool
- property co_samp_modes
Indicates sample modes supported by devices that support sample clocked counter output.
- Type:
- property co_trig_usage
Indicates the triggers supported by this device for counter output tasks.
- Type:
- property compact_daq_chassis_device
Indicates the name of the CompactDAQ chassis that contains this module.
- property compact_daq_slot_num
Indicates the slot number in which this module is located in the CompactDAQ chassis.
- Type:
int
- property compact_rio_chassis_device
Indicates the name of the CompactRIO chassis that contains this module.
- property compact_rio_slot_num
Indicates the slot number of the CompactRIO chassis where this module is located.
- Type:
int
- delete_network_device()[source]
Deletes a Network DAQ device previously added to the host. If the device is reserved, it is unreserved before it is removed.
- property dev_is_simulated
Deprecated since version 0.7.0: Use is_simulated instead.
- property dev_serial_num
Deprecated since version 0.7.0: Use serial_num instead.
- property device_supports_cal
Indicates if the device supports calibration.
- property di_lines
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the digital input lines available on the device.
- property di_max_rate
Indicates the maximum digital input rate of the device.
- Type:
float
- property di_num_samp_timing_engines
Indicates the number of Digital Input sample timing engines supported by the device.
- Type:
int
- property di_ports
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the digital input ports available on the device.
- property di_trig_usage
Indicates the triggers supported by this device for digital input tasks.
- Type:
- property dig_trig_supported
Indicates if the device supports digital triggering.
- Type:
bool
- property do_lines
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the digital output lines available on the device.
- property do_max_rate
Indicates the maximum digital output rate of the device.
- Type:
float
- property do_num_samp_timing_engines
Indicates the number of Digital Output synchronization pulse sources supported by the device.
- Type:
int
- property do_ports
List[nidaqmx.system._collections.PhysicalChannelCollection]: Indicates a collection that contains all the digital output ports available on the device.
- property do_trig_usage
Indicates the triggers supported by this device for digital output tasks.
- Type:
- property ext_cal_last_date_and_time
Indicates the last date and time that the device underwent an external calibration.
- Type:
datetime
- property ext_cal_last_temp
Indicates in degrees Celsius the temperature of the device at the time of the last external calibration. Compare this temperature to the current onboard temperature to determine if you should perform another calibration.
- Type:
float
- property ext_cal_recommended_interval
Indicates in months the National Instruments recommended interval between each external calibration of the device.
- Type:
int
- property field_daq_bank_devices
Indicates a list containing the names of the banks in the FieldDAQ.
- Type:
- property field_daq_device
Indicates the parent device which this bank is located in.
- property hwteds_supported
Indicates whether the device supports hardware TEDS.
- Type:
bool
- property id_pin_mem_family_codes
Indicates the family code of the memory connected to each ID Pin. Each list element corresponds to an ID Pin. The list contains 0 for each ID Pin with no memory connected.
- Type:
List[int]
- property id_pin_mem_serial_nums
Indicates the serial number of the memory connected to each ID Pin. Each list element corresponds to an ID Pin. The list contains an empty string for each ID Pin with no memory connected.
- Type:
List[str]
- property id_pin_mem_sizes
Indicates the size in bytes of the memory connected to each ID Pin. Each list element corresponds to an ID Pin. The list contains 0 for each ID Pin with no memory connected.
- Type:
List[int]
- property id_pin_pin_names
Indicates the names of all the ID Pins on this device.
- Type:
List[str]
- property id_pin_pin_statuses
Indicates status of each ID Pin.
- Type:
- property is_simulated
Indicates if the device is a simulated device.
- Type:
bool
- property name
Specifies the name of this device.
- Type:
str
- property num_dma_chans
Indicates the number of DMA channels on the device.
- Type:
int
- property num_time_trigs
Indicates the number of time triggers available on the device.
- Type:
int
- property num_timestamp_engines
Indicates the number of timestamp engines available on the device.
- Type:
int
- property pci_bus_num
Indicates the PCI bus number of the device.
- Type:
int
- property pci_dev_num
Indicates the PCI slot number of the device.
- Type:
int
- property product_category
Indicates the product category of the device. This category corresponds to the category displayed in MAX when creating NI-DAQmx simulated devices.
- property product_num
Indicates the unique hardware identification number for the device.
- Type:
int
- property product_type
Indicates the product name of the device.
- Type:
str
- property pxi_chassis_num
Indicates the PXI chassis number of the device, as identified in MAX.
- Type:
int
- property pxi_slot_num
Indicates the PXI slot number of the device.
- Type:
int
- read_id_pin_memory(id_pin_name)[source]
Reads and returns the data stored in the memory attached to the specified ID Pin.
- Parameters:
id_pin_name (str) – Is the name of the ID Pin to access (ex: id0)
- Returns:
Contains the data read from the memory and the format code.
- Return type:
- reserve_network_device(override_reservation=None)[source]
Reserves the Network DAQ device for the current host. Reservation is required to run NI-DAQmx tasks, and the device must be added in MAX before it can be reserved.
- Parameters:
override_reservation (Optional[bool]) – Indicates if an existing reservation on the device should be overridden by this reservation. By default, this parameter is set to false.
- reset_device()[source]
Immediately aborts all active tasks associated with a device, disconnects any routes, and returns the device to an initialized state. Aborting a task immediately terminates the currently active operation, such as a read or a write. Aborting a task puts the task into an unstable but recoverable state. To recover the task, use DAQmx Start to restart the task or use DAQmx Stop to reset the task without starting it.
- restore_last_ext_cal_const()[source]
Sets the self-calibration constants of the device to the external calibration constants. NI sets the external calibration constants at the factory, and those constants remain in effect until you perform a new external calibration on the device.
- self_cal()[source]
Measures the onboard reference voltage of the device and adjusts the self-calibration constants to account for any errors caused by short-term fluctuations in the operating environment. When you self-calibrate a device, no external signal connections are necessary.
- property self_cal_last_date_and_time
Indicates the last date and time that the device underwent a self-calibration.
- Type:
datetime
- property self_cal_last_temp
Indicates in degrees Celsius the temperature of the device at the time of the last self-calibration. Compare this temperature to the current onboard temperature to determine if you should perform another calibration.
- Type:
float
- property self_cal_supported
Indicates whether the device supports self-calibration.
- Type:
bool
- self_test_device()[source]
Performs a brief test of device resources. If a failure occurs, refer to your device documentation for more information.
- property serial_num
Indicates the serial number of the device. This value is zero if the device does not have a serial number.
- Type:
int
- property tcpip_ethernet_ip
Indicates the IPv4 address of the Ethernet interface in dotted decimal format. This property returns 0.0.0.0 if the Ethernet interface cannot acquire an address.
- Type:
str
- property tcpip_hostname
Indicates the IPv4 hostname of the device.
- Type:
str
- property tcpip_wireless_ip
Indicates the IPv4 address of the 802.11 wireless interface in dotted decimal format. This property returns 0.0.0.0 if the wireless interface cannot acquire an address.
- Type:
str
- property tedshwteds_supported
Deprecated since version 0.7.0: Use hwteds_supported instead.
- property terminals
Indicates a list of all terminals on the device.
- Type:
List[str]
- property time_trig_supported
Indicates whether the device supports time triggering.
- Type:
bool
- unreserve_network_device()[source]
Unreserves or releases a Network DAQ device previously reserved by the host.
- write_id_pin_memory(id_pin_name, data, format_code)[source]
Writes the supplied data and format code to the EEPROM connected to the specified ID pin.
- Parameters:
id_pin_name (str) – Is the name of the ID Pin to access (ex: id0)
data (List[int]) – Is the 1D list of 8-bit unsigned integers to write to the memory
format_code (int) – Specifies the type and structure of the data being written. User to define the meaning of the format code.