![National Instruments AT-MIO-64F-5 Скачать руководство пользователя страница 155](http://html1.mh-extra.com/html/national-instruments/at-mio-64f-5/at-mio-64f-5_user-manual_3417320155.webp)
Chapter 5
Programming
© National Instruments Corporation
5-11
AT-MIO-64F-5 User Manual
Programming Multiple Analog Input Channel Configurations
During a scanning data acquisition operation, a selected number of locations in the channel
configuration memory are sequenced through by the acquisition circuitry. A new channel
configuration value is selected after each A/D conversion. The first conversion is performed on
the first channel setting in the memory. The second conversion is performed on the second
channel and gain setting, and so on. The last entry written to the channel configuration memory
must have the CHAN_LAST bit set. This bit marks the end of the scan sequence. After the last
conversion is performed, the scan sequence starts over. If there are
N
entries in the channel
configuration memory, every
N
th conversion in the data collected is performed on the same
channel, gain, mode, and range setting.
Multiple conversions can be performed on each entry in the channel configuration memory
before incrementing to the next entry in the scan sequence. If the SCANDIV bit in Command
Register 1 is set, the channel configuration memory increments to the next entry when an active
low pulse is detected on the Am9513A Counter/Timer OUT1 signal. If the SCANDIV bit is
cleared, the channel configuration memory is incremented to the next entry after every
conversion.
The channel configuration memory must be loaded with the desired scan sequence before data
acquisition begins. To load the channel configuration memory, perform the following write
operations where
N
is the number of entries in the scan sequence:
¥
Strobe the CONFIGMEMCLR Register.
¥
For
i
= 0 to
N
-1, use the following steps:
a. Write the desired analog channel selection and gain setting to the CONFIGMEM Register
(this loads the configuration memory at location
i
).
b. If
i
=
N
-1, also set the CHAN_LAST bit when writing to the CONFIGMEM Register.
¥
Strobe the CONFIGMEMLD Register.
Programming the Sample-Interval Counter
Counter 3 of the Am9513A Counter/Timer is used as the sample-interval counter. Counter 3 can
be programmed to generate an active low pulse once every
N
counts.
N
is referred to as the
sample interval, that is, the time between successive A/D conversions.
N
can be between 2 and
65,536. One count is equal to the period of the timebase clock used by the counter. The
following internal clocks are available to the Am9513AÐ5 MHz, 1 MHz, 100 kHz, 10 kHz,
1 kHz, and 100 Hz. In addition, the sample-interval timer can use signals connected to any of
the Am9513A SOURCE input pins.
Using the EXTCONV* signal from the I/O connector to control multiple A/D conversions
involves disabling the sample-interval counter. This counter should be left in the high-
impedance state, see the
Resetting a Single Am9513A Counter/Timer
section later in this chapter.
Conversions are generated by the falling edge of the EXTCONV* signal. Although
EXTCONV* may be pulsing, conversions do not begin until after an active low pulse on DAQ
Start or the EXTTRIG* signal. Conversions are automatically halted irrespective of the
EXTCONV* signal when the sample counter reaches zero.
Содержание AT-MIO-64F-5
Страница 13: ......
Страница 16: ......
Страница 200: ......
Страница 201: ......
Страница 202: ......
Страница 203: ......
Страница 204: ......
Страница 205: ......
Страница 206: ......
Страница 207: ......
Страница 208: ......
Страница 209: ......
Страница 210: ......
Страница 211: ......
Страница 212: ......
Страница 213: ......
Страница 214: ......
Страница 215: ......
Страница 216: ......
Страница 217: ......
Страница 218: ......
Страница 219: ......
Страница 220: ......
Страница 221: ......
Страница 222: ......
Страница 223: ......
Страница 224: ......
Страница 225: ......
Страница 226: ......
Страница 227: ......
Страница 228: ......
Страница 229: ......
Страница 230: ......
Страница 231: ......
Страница 232: ......
Страница 233: ......
Страница 234: ......
Страница 235: ......
Страница 236: ......
Страница 237: ......
Страница 238: ......