slyt210.pdf
(
184 KB
)
Pobierz
Data Acquisition
Texas Instruments Incorporated
Simple DSP interface for ADS784x/834x ADCs
By Tom Hendrick
(Email: t-hendrick@ti.com)
Applications Engineer, Data Acquisition Products
Introduction
The 12-bit ADS7841 and 16-bit ADS8341/3 are pin-
compatible, 4-channel analog-to-digital converters (ADCs)
with a synchronous serial interface. Typical power dissipa-
tion is 2 mW at a 200-kHz throughput rate on the ADS7841
and 8 mW at 100 kHz on the ADS8341/3. The 12-bit
ADS7844 and 16-bit ADS8344 are pin-compatible,
8-channel ADCs with the same typical power require-
ments as their 4-channel cousins.
The low power, high speed, and onboard multiplexer of
these devices make them ideal for battery-operated systems
such as personal digital assistants, portable multichannel
data loggers, and measurement equipment.
The datasheets for these devices show various ways to
interface the parts to microcontrollers with a serial periph-
eral interface (SPI), but they do not mention how to use
these parts with high-performance digital signal processors
(DSPs). This article provides an easy way to connect these
parts with any Texas Instruments (TI) DSP that contains
at least one multichannel buffered serial port (McBSP).
The information here pertains to the TMS320F2812 and
all devices in the TMS320C5000
TM
and TMS320C6000
TM
DSP platforms.
Digital interface for microcontrollers
The digital interface section of the datasheet for all five of
these devices shows a typical SPI with burst clock mode of
operation based on 8 or 16 clock cycles. While an SPI
interface is certainly not difficult to implement, there can
be a bit of difficulty associated with getting the received
data into a format that the processor can actually use.
Figure 1 shows a typical 8-bit SPI interface.
The difficulty many users run into with this interface is
in formatting return data with minimal software overhead.
At first glance, it is not always obvious to new users of
these parts that the most significant bit (MSB) is presented
on the 9th clock cycle. With a microcontroller like the
MSP430 series of devices and the SPI interface shown in
Figure 1, the 7 MSBs of data are stored in an 8-bit register,
with the 5 least significant bits (LSBs) stored in a second
8-bit register. In order to store the converted data in a
meaningful fashion, both the upper and lower bytes would
need to be shifted (left or right) and then concatenated
before being stored into a data array for future processing.
In applications such as motor control, the software latency
of these data manipulations proves too costly.
Figure 1. Typical 8-bit SPI interface
CS
DCLK
1
8
1
8
1
8
1
DIN
S
S
Control Bits
Control Bits
BUSY
DOUT
11
10
9
87 65
4
321 0
11
10
9
10
Analog Applications Journal
Analog and Mixed-Signal Products
www.ti.com/aaj
3Q 2005
Texas Instruments Incorporated
Data Acquisition
The process can be simplified a little if the microcontrol-
ler is capable of running with a 16-bit SPI interface, such as
the TMS470 series of devices from TI. For the 12-bit parts,
all returned data can be captured in a single 16-cycle trans-
mission. To accomplish this, simply shift the command byte
to the left by 7 bits as shown in Figure 2. The SPISCS line
shown in Figure 2 could be tied to the chip select line of
the ADC if multiple devices share the SPI bus.
The modified 16-clock SPI interface of Figure 2 sends
the BUSY signal high on the falling edge of the 15th clock.
In some applications, this approach might still require a
data shift. The 12-bit data is MSB-aligned and the MSB is
provided twice. The software overhead becomes less of an
issue in this case since the shift can be done during the
actual data reception in the SPI routine.
There are two drawbacks to this approach—first, the
LSB is lost. The LSB is cut short during the switch from
sample to hold mode and the host processor will always
read it as a “one.” The second issue is latency. These
converters enter their acquisition phase after the A0 bit is
read into the part. The data shown in Figure 2 would be
the conversion results from the previous cycle, which adds
latency to the system.
When the 16-bit parts are used, the problem is aggravated
even further. An 8- or 16-bit SPI device like the MSP430
or TMS470 would need to issue at least 24 SCLKs to
complete a 15-bit transfer. If the entire 16 bits of data are
needed, a total of 32 clocks would be required. Data manipu-
lation would still need to be done, adding software overhead.
Digital interface for TI DSPs
Using the high speed and flexible capabilities of the
McBSP ports found on the TMS320F2812 or the C5000
TM
and C6000
TM
DSP platforms can virtually eliminate the
software overhead associated with the microcontroller and
the SPI interface.
The McBSP ports have independent transmitter and
receiver functions. Since transmit and receive sections are
independent, transmit and receive frame sync (FS) signals
are also independent. If the chip select (/CS) signal is tied
low, the BUSY signal can be used as the frame sync return
(FSr) to indicate that a serial stream is on its way into the
receiver. The data transfer to the DSP is done without any
further need for manipulation. Setting the data transfer
length in the DSP to 16 bits allows exactly the same soft-
ware routine to be used with the 12-bit ADS7841 or the
16-bit ADS834x devices.
Figure 2. Modified 16-clock SPI interface
SPISCS
1
16
SCLK
SIMO
S
A2
A1
A0
X
S/D
PD1
PD0
SOMI
MSB
LSB
BUSY
11
Analog Applications Journal
3Q 2005
www.ti.com/aaj
Analog and Mixed-Signal Products
Data Acquisition
Texas Instruments Incorporated
Figure 3. DSP transfer with 16 clock cycles
1
16
DX
S
A2
A1
A0
X
S/D
PD1
PD0
S
Conversion “N”
BUSY as FSr
16-Bit
LSB
12-Bit
LSB
MSB
Conversion “N-1” Data
Conversion “N” Data
As shown in Figure 3, the output data is actually wrapped
between conversion start commands so that there is mini-
mal latency between conversion cycles. Data is presented
to the DSP MSB first from both the 12-bit and 16-bit
devices. If LSB alignment is required, a 4-bit shift could be
implemented to the received data as it is sampled.
Another added advantage of using the DSP is the possi-
bility to realize simultaneous sampling on up to three
devices on a DSP with multiple serial ports. This would be
done by using a single “master” transmitter tied to all
three ADCs and returning the master clock to all three
“slave” receiver ports. The BUSY signal from each of the
three ADCs would again act as the FSr to each receiver.
Figure 4 shows a potential method for implementing
multiple ADCs in a simultaneous sampling application.
Conclusion
The ADS784x/ADS834x data converters are truly versatile
with their simple serial interface, low power, high-speed
operation, and ease of use. They are ideal for portable and
handheld applications that require excellent performance
capability and upgrade flexibility. For additional information
on the devices mentioned in this article, please contact
your local distributor, the TI Product Information Center
listed on the last page of this document, or the Data
Converter Applications team at dataconvapps@list.ti.com
Related Web sites
dataconverter.ti.com
dsp.ti.com
microcontroller.ti.com
www.ti.com/sc/device/
partnumber
Replace
partnumber
with
ADS7841,
ADS7844,
ADS8341,
ADS8343,
ADS8344,
or
TMS320F2812
Figure 4. Multiple ADC configuration
DX0
SDI
SDO
DR0
SCLK
CLKx0
CLKr0
BUSY
FSr0
SDI
SDO
DR1
SCLK
CLKr1
BUSY
FSr1
SDI
SDO
DR2
SCLK
CLKr2
BUSY
FSr2
12
Analog Applications Journal
Analog and Mixed-Signal Products
www.ti.com/aaj
3Q 2005
TIWorldwide Technical Support
Internet
TI Semiconductor Product Information Center Home Page
support.ti.com
TI Semiconductor KnowledgeBase Home Page
support.ti.com/sc/knowledgebase
Product Information Centers
Americas
Phone
IMPORTANT NOTICE
Texas Instruments Incorporated and its subsidiaries (TI) reserve
the right to make corrections, modifications, enhancements,
improvements, and other changes to its products and services at
any time and to discontinue any product or service without notice.
Customers should obtain the latest relevant information before
placing orders and should verify that such information is current
and complete. All products are sold subject to TI's terms and
conditions of sale supplied at the time of order acknowledgment.
TI warrants performance of its hardware products to the
specifications applicable at the time of sale in accordance with TI's
standard warranty. Testing and other quality control techniques are
used to the extent TI deems necessary to support this warranty.
Except where mandated by government requirements, testing of
all parameters of each product is not necessarily performed.
TI assumes no liability for applications assistance or customer
product design. Customers are responsible for their products and
applications using TI components. To minimize the risks
associated with customer products and applications, customers
should provide adequate design and operating safeguards.
TI does not warrant or represent that any license, either express or
implied, is granted under any TI patent right, copyright, mask work
right, or other TI intellectual property right relating to any
combination, machine, or process in which TI products or services
are used. Information published by TI regarding third-party
products or services does not constitute a license from TI to use
such products or services or a warranty or endorsement thereof.
Use of such information may require a license from a third party
under the patents or other intellectual property of the third party, or a
license from TI under the patents or other intellectual property of TI.
Reproduction of information in TI data books or data sheets is
permissible only if reproduction is without alteration and is
accompanied by all associated warranties, conditions, limitations,
and notices. Reproduction of this information with alteration is an
unfair and deceptive business practice. TI is not responsible or
liable for such altered documentation.
Resale of TI products or services with statements different from or
beyond the parameters stated by TI for that product or service
voids all express and any implied warranties for the associated TI
product or service and is an unfair and deceptive business
practice. TI is not responsible or liable for any such statements.
Following are URLs where you can obtain information on other
Texas Instruments products and application solutions:
+1(972) 644-5580
Fax
+1(972) 927-6377
Internet/Email
support.ti.com/sc/pic/americas.htm
Europe, Middle East, and Africa
Phone
Belgium (English)
+32 (0) 27 45 54 32
Netherlands (English) +31 (0) 546 87 95 45
Finland (English)
+358 (0) 9 25173948
Russia
+7 (0) 95 7850415
France
+33 (0) 1 30 70 11 64
Spain
+34 902 35 40 28
Germany
+49 (0) 8161 80 33 11
Sweden (English)
+46 (0) 8587 555 22
Israel (English)
1800 949 0107
United Kingdom
+44 (0) 1604 66 33 99
Italy
800 79 11 37
Fax
+(49) (0) 8161 80 2045
Internet
support.ti.com/sc/pic/euro.htm
Japan
Fax
International
+81-3-3344-5317
Domestic
0120-81-0036
Internet/Email
International
support.ti.com/sc/pic/japan.htm
Domestic
www.tij.co.jp/pic
Asia
Phone
International
+886-2-23786800
Domestic
Toll-Free Number
Toll-Free Number
Australia
1-800-999-084
New Zealand
0800-446-934
China
800-820-8682
Philippines
1-800-765-7404
Hong Kong
800-96-5941
Singapore
800-886-1028
Indonesia
001-803-8861-1006
Taiwan
0800-006800
Korea
080-551-2804
Thailand
001-800-886-0010
Malaysia 1-800-80-3973
Fax 886-2-2378-6808 Email tiasia@ti.com
Internet
support.ti.com/sc/pic/asia.htm
ti-china@ti.com
C011905
Safe Harbor Statement:
This publication may contain forward-
looking statements that involve a number of risks and
uncertainties. These “forward-looking statements” are intended
to qualify for the safe harbor from liability established by the
Private Securities Litigation Reform Act of 1995. These forward-
looking statements generally can be identified by phrases such
as TI or its management “believes,” “expects,” “anticipates,”
“foresees,” “forecasts,” “estimates” or other words or phrases
of similar import. Similarly, such statements herein that describe
the company's products, business strategy, outlook, objectives,
plans, intentions or goals also are forward-looking statements.
All such forward-looking statements are subject to certain risks
and uncertainties that could cause actual results to differ
materially from those in forward-looking statements. Please
refer to TI's most recent Form 10-K for more information on the
risks and uncertainties that could materially affect future results
of operations. We disclaim any intention or obligation to update
any forward-looking statements as a result of developments
occurring after the date of this publication.
Trademarks:
TMS320C5000, C5000, TMS320C6000, and C6000
are trademarks of Texas Instruments. All other trademarks are
the property of their respective owners.
Products
Amplifiers
amplifier.ti.com
Data Converters
dataconverter.ti.com
DSP
dsp.ti.com
Interface
interface.ti.com
Logic
logic.ti.com
Power Mgmt
power.ti.com
Microcontrollers
microcontroller.ti.com
Applications
Audio
www.ti.com/audio
Automotive
www.ti.com/automotive
Broadband
www.ti.com/broadband
Digital control
www.ti.com/digitalcontrol
Military
www.ti.com/military
Mailing Address:
Texas Instruments
Post Office Box 655303
Dallas, Texas 75265
Optical Networking
www.ti.com/opticalnetwork
Security
www.ti.com/security
Telephony
www.ti.com/telephony
Video & Imaging
www.ti.com/video
© 2005 Texas Instruments Incorporated
Wireless
www.ti.com/wireless
SLYT210
Plik z chomika:
TirNaNog
Inne pliki z tego folderu:
slyt331.pdf
(570 KB)
slyt333.pdf
(771 KB)
slyt335.pdf
(746 KB)
slyt332.pdf
(706 KB)
slyt334.pdf
(626 KB)
Inne foldery tego chomika:
ACE
AcornUser
AmigaComputing
AmigaFormat
AmigaShopper
Zgłoś jeśli
naruszono regulamin