nidaqmx.task.ao_channel

class nidaqmx._task_modules.channels.ao_channel.AOChannel(task_handle, virtual_or_physical_name, interpreter)[source]

Bases: nidaqmx._task_modules.channels.channel.Channel

Represents one or more analog output virtual channels and their properties.

property ao_common_mode_offset

Specifies the common-mode offset of the AO channel. Use the property only when Terminal Configuration is set to Differential.

Type

float

property ao_current_units

Specifies in what units to generate current on the channel. Write data to the channel in the units you select.

Type

nidaqmx.constants.CurrentUnits

property ao_custom_scale

Specifies the name of a custom scale for the channel.

Type

nidaqmx.system.scale.Scale

property ao_dac_offset_ext_src

Specifies the source of the DAC offset voltage if ao_dac_offset_src is SourceSelection.EXTERNAL. The valid sources for this signal vary by device.

Type

str

property ao_dac_offset_src

Specifies the source of the DAC offset voltage. The value of this voltage source determines the full-scale value of the DAC.

Type

nidaqmx.constants.SourceSelection

property ao_dac_offset_val

Specifies in volts the value of the DAC offset voltage. To achieve best accuracy, the DAC offset value should be hand calibrated.

Type

float

property ao_dac_ref_allow_conn_to_gnd

Specifies whether to allow grounding the internal DAC reference at run time. You must set this property to True and set ao_dac_ref_src to SourceSelection.INTERNAL before you can set ao_dac_ref_conn_to_gnd to True.

Type

bool

property ao_dac_ref_conn_to_gnd

Specifies whether to ground the internal DAC reference. Grounding the internal DAC reference has the effect of grounding all analog output channels and stopping waveform generation across all analog output channels regardless of whether the channels belong to the current task. You can ground the internal DAC reference only when ao_dac_ref_src is SourceSelection.INTERNAL and ao_dac_ref_allow_conn_to_gnd is True.

Type

bool

property ao_dac_ref_ext_src

Specifies the source of the DAC reference voltage if ao_dac_ref_src is SourceSelection.EXTERNAL. The valid sources for this signal vary by device.

Type

str

property ao_dac_ref_src

Specifies the source of the DAC reference voltage. The value of this voltage source determines the full-scale value of the DAC.

Type

nidaqmx.constants.SourceSelection

property ao_dac_ref_val

Specifies in volts the value of the DAC reference voltage. This voltage determines the full-scale range of the DAC. Smaller reference voltages result in smaller ranges, but increased resolution.

Type

float

property ao_dac_rng_high

Specifies the upper limit of the output range of the device. This value is in the native units of the device. On E Series devices, for example, the native units is volts.

Type

float

property ao_dac_rng_low

Specifies the lower limit of the output range of the device. This value is in the native units of the device. On E Series devices, for example, the native units is volts.

Type

float

property ao_data_xfer_mech

nidaqmx.constants.DataTransferActiveTransferMode: Specifies the data transfer mode for the device.

property ao_data_xfer_req_cond

nidaqmx.constants.OutputDataTransferCondition: Specifies under what condition to transfer data from the buffer to the onboard memory of the device.

property ao_dev_scaling_coeff

Indicates the coefficients of a linear equation that NI-DAQmx uses to scale values from a voltage to the native format of the device. Each element of the list corresponds to a term of the equation. The first element of the list corresponds to the y-intercept, and the second element corresponds to the slope. Scaling coefficients do not account for any custom scales that may be applied to the channel.

Type

List[float]

property ao_enhanced_image_rejection_enable

Specifies whether to enable the DAC interpolation filter. Disable the interpolation filter to improve DAC signal-to- noise ratio at the expense of degraded image rejection.

Type

bool

property ao_filter_delay

Specifies the amount of time between when the sample is written by the host device and when the sample is output by the DAC. This value is in the units you specify with ao_filter_delay_units.

Type

float

property ao_filter_delay_adjustment

Specifies an additional amount of time to wait between when the sample is written by the host device and when the sample is output by the DAC. This delay adjustment is in addition to the value indicated by ao_filter_delay. This delay adjustment is in the units you specify with ao_filter_delay_units.

Type

float

property ao_filter_delay_units

Specifies the units of ao_filter_delay and ao_filter_delay_adjustment.

Type

nidaqmx.constants.DigitalWidthUnits

property ao_func_gen_amplitude

Specifies the zero-to-peak amplitude of the waveform to generate in volts. Zero and negative values are valid.

Type

float

property ao_func_gen_fm_deviation

Specifies the FM deviation in hertz per volt when ao_func_gen_modulation_type is ModulationType.FM.

Type

float

property ao_func_gen_freq

Specifies the frequency of the waveform to generate in hertz.

Type

float

property ao_func_gen_modulation_type

Specifies if the device generates a modulated version of the waveform using the original waveform as a carrier and input from an external terminal as the signal.

Type

nidaqmx.constants.ModulationType

property ao_func_gen_offset

Specifies the voltage offset of the waveform to generate.

Type

float

property ao_func_gen_square_duty_cycle

Specifies the square wave duty cycle of the waveform to generate.

Type

float

property ao_func_gen_start_phase

Specifies the starting phase in degrees of the waveform to generate.

Type

float

property ao_func_gen_type

Specifies the kind of the waveform to generate.

Type

nidaqmx.constants.FuncGenType

property ao_gain

Specifies in decibels the gain factor to apply to the channel.

Type

float

property ao_idle_output_behavior

Specifies the state of the channel when no generation is in progress.

Type

nidaqmx.constants.AOIdleOutputBehavior

property ao_load_impedance

Specifies in ohms the load impedance connected to the analog output channel.

Type

float

property ao_max

Specifies the maximum value you expect to generate. The value is in the units you specify with a units property. If you try to write a value larger than the maximum value, NI- DAQmx generates an error. NI-DAQmx might coerce this value to a smaller value if other task settings restrict the device from generating the desired maximum.

Type

float

property ao_mem_map_enable

Specifies for NI-DAQmx to map hardware registers to the memory space of the application, if possible. Normally, NI- DAQmx maps hardware registers to memory accessible only to the kernel. Mapping the registers to the memory space of the application increases performance. However, if the application accesses the memory space mapped to the registers, it can adversely affect the operation of the device and possibly result in a system crash.

Type

bool

property ao_min

Specifies the minimum value you expect to generate. The value is in the units you specify with a units property. If you try to write a value smaller than the minimum value, NI- DAQmx generates an error. NI-DAQmx might coerce this value to a larger value if other task settings restrict the device from generating the desired minimum.

Type

float

property ao_output_impedance

Specifies in ohms the impedance of the analog output stage of the device.

Type

float

property ao_output_type

Indicates whether the channel generates voltage, current, or a waveform.

Type

nidaqmx.constants.UsageTypeAO

property ao_reglitch_enable

Specifies whether to enable reglitching. The output of a DAC normally glitches whenever the DAC is updated with a new value. The amount of glitching differs from code to code and is generally largest at major code transitions. Reglitching generates uniform glitch energy at each code transition and provides for more uniform glitches. Uniform glitch energy makes it easier to filter out the noise introduced from glitching during spectrum analysis.

Type

bool

property ao_resolution

Indicates the resolution of the digital-to-analog converter of the channel. This value is in the units you specify with ao_resolution_units.

Type

float

property ao_resolution_units

Specifies the units of ao_resolution.

Type

nidaqmx.constants.ResolutionType

property ao_term_cfg

Specifies the terminal configuration of the channel.

Type

nidaqmx.constants.TerminalConfiguration

property ao_usb_xfer_req_count

Specifies the maximum number of simultaneous USB transfers used to stream data. Modify this value to affect performance under different combinations of operating system and device.

Type

int

property ao_usb_xfer_req_size

Specifies the maximum size of a USB transfer request in bytes. Modify this value to affect performance under different combinations of operating system and device.

Type

int

property ao_use_only_on_brd_mem

Specifies whether to write samples directly to the onboard memory of the device, bypassing the memory buffer. Generally, you cannot update onboard memory directly after you start the task. Onboard memory includes data FIFOs.

Type

bool

property ao_voltage_current_limit

Specifies the current limit, in amperes, for the voltage channel.

Type

float

property ao_voltage_units

Specifies in what units to generate voltage on the channel. Write data to the channel in the units you select.

Type

nidaqmx.constants.VoltageUnits

property chan_type

Indicates the type of the virtual channel.

Type

nidaqmx.constants.ChannelType

property channel_names

Specifies the unflattened list of the virtual channels.

Type

List[str]

property description

Specifies a user-defined description for the channel.

Type

str

property is_global

Indicates whether the channel is a global channel.

Type

bool

property name

Specifies the name of the virtual channel this object represents.

Type

str

property physical_channel

nidaqmx.system.physical_channel.PhysicalChannel: Specifies the name of the physical channel upon which this virtual channel is based.

save(save_as='', author='', overwrite_existing_channel=False, allow_interactive_editing=True, allow_interactive_deletion=True)

Saves this local or global channel to MAX as a global channel.

Parameters
  • save_as (Optional[str]) – Is the name to save the task, global channel, or custom scale as. If you do not specify a value for this input, NI-DAQmx uses the name currently assigned to the task, global channel, or custom scale.

  • author (Optional[str]) – Is a name to store with the task, global channel, or custom scale.

  • overwrite_existing_channel (Optional[bool]) – Specifies whether to overwrite a global channel of the same name if one is already saved in MAX. If this input is False and a global channel of the same name is already saved in MAX, this function returns an error.

  • allow_interactive_editing (Optional[bool]) – Specifies whether to allow the task, global channel, or custom scale to be edited in the DAQ Assistant. If allow_interactive_editing is True, the DAQ Assistant must support all task or global channel settings.

  • allow_interactive_deletion (Optional[bool]) – Specifies whether to allow the task, global channel, or custom scale to be deleted through MAX.

property sync_unlock_behavior

Specifies the action to take if the target loses its synchronization to the grand master.

Type

nidaqmx.constants.SyncUnlockBehavior