Timing Considerations for C Series Devices
- Updated2024-10-22
- 7 minute(s) read
Timing Considerations for C Series Devices
Analog Input Timing Considerations for C Series Devices
You can use multiple analog input devices of different types in the same task, and NI-DAQmx automatically synchronizes them.
NI-DAQmx supports:
- Only one analog input task at a time per NI cDAQ-9171, 9181, and 9191 chassis.
- Up to three analog input tasks at a time per cDAQ-9132, 9133, 9134, 9135, 9136, 9137, 9174, 9178, 9179, 9184, 9185, 9188, 9188XT, and 9189 chassis.
- Up to eight analog input tasks at a time per supported CompactRIO[1]1 cRIO-9040, 9041, 9042, 9043, 9045, 9046, 9047, 9048, 9049, 9053, 9054, 9055, 9056, 9057, and 9058. controller.
- One analog input task at a time per slot or onboard IO module, per CompactRIO Single-Board[2]2 sbRIO-9603, 9608, 9609, 9628, 9629, and 9638 controller.
AI Convert Clock Considerations
C Series Scanned devices, such as the NI 9201, NI 9204, NI 9205, and NI 9221, use multiplexed sampling controlled by a per-slot AI Convert Clock.
If you have multiple devices in one task, their AI Convert Clocks run in parallel, which may cause channels on multiple devices to be sampled at the same time. You can set the AI Convert Rate and the Delay From Sample Clock differently on each device. When setting AI Convert instances of the DAQmx Timing attribute/property, you must use the ActiveDev attribute/property to specify the device to which you are referring. External clocking of the AI Convert Clock is not supported.
Reference Clock Considerations
Devices with a reference clock, such as the NI 9775, do not support on-demand timing.
These devices require hardware timing from a continuous clock. This clock synchronizes the onboard oscillators using a phase-locked loop and serves as the Sample Clock Timebase. When devices with reference clocks are in a task, you cannot set an external SampClk.Src or SampClkTimebase. Similar to DSA devices, devices with a reference clock do not support external sample clocks from arbitrary signal sources.
For the NI 9775, the reference clock must be 12.8 MHz.
Sampling Rate Considerations
The default AI Convert Clock rate for the C Series Scanned devices uses 10 µs of additional settling time between channels, compared to the fastest AI Convert Clock rate for the device. When the Sample Clock rate is too high to allow for 10 µs of additional settling time, the default AI Convert Clock rate uses as much settling time as is allowed by the Sample Clock rate. If there are multiple C Series Scanned devices in the same task, the same amount of additional settling time is used for all devices in the task, even if their maximum AI Convert Clock rates differ.
In a CompactDAQ chassis with C Series Slow Sample devices, such as the NI 9211, if the sampling rate of a hardware-timed acquisition exceeds the maximum sampling rate of the module, the most recently acquired sample may be read multiple times and no warning or error is generated. Exceeding the maximum sampling rate of other devices in the same task generates warnings or errors. The first sample of a hardware-timed acquisition with C Series Slow Sample devices is sampled when the task is committed. Software-timed acquisitions with C Series Slow Sample devices always wait for a new sample to be acquired.
In a CompactRIO or Single-Board RIO controller with C Series Slow Sample devices, such as the NI 9211, if the sampling rate of a hardware-timed acquisition exceeds the maximum sampling rate of the module, DAQmx generates warning or errors. When a Slow Sample device is in the same task as a non-Slow Sample device, exceeding the maximum sampling rate of the Slow Sample device results in the most recently acquired sample being read multiple times. In this scenario, the first sample of a hardware-timed acquisition with C Series Slow Sample devices is sampled when the task is committed.
The NI 9213/9214 maximum sample rate of 100 S/s applies to tasks with 13 or less analog input channels per module. To determine the maximum sample rate for an NI 9213/9214, query the AI.MaxMultiChanRate attribute/property and divide that returned value by the number of channels. For instance, if your analog input task uses 14 channels and AI.MaxMultiChanRate returns 1360.54, the maximum sample rate would be 97.18 S/s. You can also query the maximum sample rate used in the task with the SampClk.MaxRate attribute/property.
The maximum sampling rate of the NI 9215 depends on which channel(s) you are acquiring from. For instance, a task acquiring from any combination of ai0, ai1, and ai2 can sample at faster rates than a task that includes ai3. The maximum sampling rates are attainable only when sampling from ai0. If you have multiple NI 9215 devices in the same task, they sample in parallel. For instance, multiple NI 9215 devices acquiring from ai0 may be able to achieve a faster sampling rate than a single NI 9215 acquiring from ai3.
The C Series Delta-Sigma devices, such as the NI 9225, NI 9227, NI 9235, and NI 9239, have both a maximum and a minimum sampling rate. Refer to the specifications for your device to determine the sampling rate range.
When you set a sampling rate for the NI 9230, NI 9231, NI 9232, or NI 9234, NI-DAQmx selects the highest possible decimation rate. Refer to the operating instructions for your device for more information about available sampling rates.
When C Series Delta Sigma devices, such as the NI 9230, NI 9231, NI 9232, NI 9234, NI 9250, or NI 9251 are in a task with a C Series device that has a different sample clock timebase, NI-DAQmx always chooses the sample clock timebase with the highest frequency. To override this selection, you can set the sample clock timebase in the SampClk.Timebase.Src attribute/property.
Hardware and On-Demand Timing for C Series Delta-Sigma Devices
C Series Delta-Sigma devices do not support the on-demand timing type.
All acquisitions and generations for C Series Delta-Sigma devices require hardware timing from a steady clock. You cannot set the SampClk.Src attribute/property to an external source when a C Series Delta-Sigma device is in the task. With C Series Delta-Sigma devices, external clocking from arbitrary external signal sources such as encoders and tachometers is not supported.
Analog Output Timing Considerations for C Series Devices
Only one hardware-timed analog output task per CompactDAQ chassis at a given time is supported, but the number of concurrent software-timed analog output tasks is limited only by the available channels. A single C Series analog output device cannot be used for hardware-timed and software-timed tasks at the same time.
CompactRIO and Single-Board RIO controllers can support more than one hardware-timed AO task per controller. Refer to CompactRIO Timing Engines.
Digital Input/Output Timing Considerations for C Series Devices
Only one hardware-timed digital input task and one hardware-timed digital output task per CompactDAQ chassis at a given time is supported, but the number of concurrent software-timed digital I/O tasks is limited only by the available lines.
Refer to Digital I/O Considerations for C Series for more information about hardware-timed digital input/output.
CompactRIO and Single-Board RIO controllers can support more than one hardware-timed digital input task and one hardware-timed digital output task per controller. Refer to CompactRIO Timing Engines.
Configurable Timing for C Series Devices
On the NI 9207, NI 9208, NI 9209, NI 9212, NI 9213, NI USB-9213, NI 9214, NI 9216, NI 9217, NI 9219, NI 9224, NI 9226, NI 9228, and NI 9775, you can configure high-speed or high-resolution measurements using the AI.ADCTimingMode attribute/property.
On the NI 9212, NI 9219, and NI USB-9219 you can also configure low-noise measurements using the AI.ADCTimingMode attribute/property.
Default Settings for the AI.ADCTimingMode Attribute/Property
For all modules in the CompactRIO and Single-Board RIO controllers, the default value in hardware-timed mode is automatically determined based on Sample Clock Rate.
For the NI 9207, NI 9208, NI 9209, NI 9212, NI 9213, NI USB-9213, NI 9214, NI 9216, NI 9217, NI 9219, and NI 9226 in CompactDAQ, the AI.ADCTimingMode attribute/property is set to High Resolution by default. To increase the conversion rate, set this attribute/property to High Speed.
For the NI USB-9219, this attribute/property is set to High Resolution by default in on-demand mode, and the default value in hardware-timed mode is automatically determined based on Sample Clock Rate. To increase power line noise rejection on the NI 9212 and NI 9219, set this attribute/property to Best 60 Hz Rejection or Best 50 Hz Rejection.
For the NI 9224 and NI 9228, this attribute/property is set by default to Automatic, which causes the module to sample with the highest resolution timing mode that is faster than the rate you specified.
For the NI 9775, this attribute/property has a default timing mode of Automatic. The Automatic timing mode automatically configures the module to sample with the highest resolution timing mode that is compatible with the user-specified rate. If the AI.Lowpass.Enable attribute/property is set to false, the timing mode will remain in High Speed regardless of the user-specified sample rate.
Slow sample modules are able to sample just fast enough to avoid returning repeated data. If the user-specified rate is above the maximum rate, the module will enter background convert and return repeated data. Slow sample modules on the cDAQ-9171 and cDAQ-9191 chassis have a default timing mode of Automatic.
The AI.ADCTimingMode attribute/property affects both the maximum and default values for AIConv.Rate attribute/property in the DAQmx Timing property node. For instance, if the ADC timing mode corresponds to a conversion time of 200 ms, the maximum conversion rate is 5 Hz.
Counter Input Timing Considerations for C Series Devices
For the NI 9361, you can use multiple counter input devices in the same task, and NI-DAQmx automatically synchronizes them. A single NI 9361 cannot be used for hardware-timed and software-timed tasks at the same time. The CompactDAQ chassis and CompactRIO controllers support up to four of the onboard chassis counters at a time.
Implicit timing is not supported on the NI 9361.