System Integration Workshop

Download Report

Transcript System Integration Workshop

Analog Interfacing
Chapter 6.5 (Optional)
C6000 Integration Workshop
T TO
Technical Training
Organization
Copyright © 2005 Texas Instruments. All rights reserved.
Learning Objectives

List various families of TI Analog that connect to DSP systems

Demonstrate how to find information on TI Analog components

List key and additional selection criteria for an A2D converter

Identify challenges in adding peripherals to a DSP design

Identify TI support to meet above design challenges

Describe the types of Analog EVMs available from TI

Select and configure a desired analog system from available EVMs

Create driver code with the Data Converter Plug-In

Apply Plug-in generated code to a given system
T TO
Technical Training
Organization
2
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
3
OP-AMPs/Comparators/Support
- High Speed Amplifiers
- Low Power, RRIO Signal Amps
- Instrumentation Amps
- Audio Power Amps
- Power Amps
- Commodity Amps
- Comparators
- Temp Sensors
- References
(Codec)
- Special Functions
TI Analog
DATA
TRANSMISSION
Data Transmission
- Many standards
- SERDES
DAC
Digital
MSP430
TI DSP
etc
ADC
Data Converter
-Standard A/D and D/A
- High Resolution/Precision converters
- High Speed converters
- Touchscreen controllers
- m-Law/A-Law Telecom “SLAC”s
- Communication, Video, & Ultrasound
optimized converters/codecs
- Audio & Voice band converters/Codecs
- Industrial converters
Another
system/
subsystem/
etc.
Clocks
RF
STANDARDS
RS232
RS422
RS485
LVDS
1394/Firewire
USB
PCI
CAN
SONET
Gigabit Ethernet
GTL, BTL, etc.
RF (or Wireless)
Clocking
Solution
• Clock Buffer & fanouts
• PLL based buffers & fanouts
• Multipliers & Dividers
• Jitter cleaners & synchronizers
• Memory specific solutions
• Synthesizers
• Real Time Clocks
POWER
SOLUTION
Power
- Power Modules
- Linear Regulators/ LDOs
- DC-DC controllers
- PFC
- Load Share
- Battery Management
- Charge Pumps & Boost Converters
- Supervisory Circuits
- Power Distribution/Hotswap
- References
4
TI’s High-Performance Analog Portfolio
T TO
Technical Training
Organization
5
Industry Ranking
Data Converters
1. TI
$ 3.45 B
11.0 %
2. STM
$ 3.41 B
10.8 %
3. Infineon
$ 1.62 B
5.1 %
4. ADI
$ 1.49 B
4.7 %
5. Philips
$ 1.39 B
4.4 %
Amplifiers Power Management Interface
ADI
ADI
TI
TI
TI
TI
NSC
Maxim
Maxim
NSC
LTC
NSC
NSC
LTC
FSC
Toshiba
ISL
Maxim
ON
ADI
T TO
Technical Training
Organization
6
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
7
http://analog.ti.com
Booklet :

SSDV004N

DSP Selection Guide
8
On-Line Data Converter App Notes
Most contain downloadable software
examples for use with CCS or Embedded
Workbench!
Click on “Application Notes” from the
Product Folder for links to specific devices
9
Amplifier Design Utilities
10
FilterPro Design Tool
11
SWIFT Design Tool
12
The I-to-V Pro Tool
13
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
14
Application Areas for TI Data Converters
High Speed Comm /
Ultrasound
Pipeline ADCs
Current Steering DACs


Audio



Voiceband Codecs
Consumer
Professional Audio
High Precision
Measurement

Over Sampling ∆Σ ADCs
 Precision ADCs
 Micro Systems
 High Speed ADCs
 Current Input ADC’s
Touch-Screen
Controller
Embedded

High Perf. DSP
 Portable / Low Power
 Micro Systems



Stand-Alone
Intelligent
Integrated Audio
Industrial Control /
Instrumentation
SAR ADCs
 High Speed
 Low Power
 Simultaneous Sampling
 Bipolar
 Data Acquisition Systems
 String / R2R DACs
 Single Supply
 Monitor & Control
 Dual Supply

T TO
Technical Training
Organization
15
TI ADC Technologies
ADS1625
 18 bit Delta Sigma
 1.25 MSPS - Fastest on the market
 (averages and filters out noise)
ADS1605
 16 bit Delta Sigma
ADS8411
 5 MSPS
 16 bit
 2 MSPS
 Market Leader
Converter Resolution
24
20
DS Oversampling
ADS5500
 14 bit
 125 MSPS
 Market Leader
16
SAR
Successive
Approximation
12
Pipeline
8
10
T TO
Technical Training
Organization
100
1K
10K
100K
1M
10M
100M
Conversion Rate
16
TI DAC Technologies
Instrumentation & Measurement
Typically for Calibration
Converter Resolution
20
Industrial
Settling Time (µs)
Number of Out put DACs
Resistor String – Inexpensive
R-2R – More accurate -Trimmed at final test
Typically Voltage out
MDAC’s coming (dig control gain/atten, Waveform gen.)
High Speed Video and Communication
Update rate (MSPS)
Typically 1 Output but a few 2 Output
Current out
DS
16
12
Resistor String
Current
& R-2R
Steering
8
1000
T TO
Technical Training
Organization
100
10
8
6
4
Settling Time- ms
2
1
.05
.001
17
TI Data Converters
DACs – Delta Sigma
High Resolution/Accuracy
DAC122X
ADCs – SAR
High Precision
Medical, Industrial Control,
Data Acquisition
Simultaneous sampling
Motor control
DACs – String / R2R
Low power, Single and
bipolar Suppy, Precision
T TO
Technical Training
Organization
ADCs – Delta Sigma
High Precision Low bandwidth
High Bandwidth
Intelligent / high resolution
8051 core
Touch Screen Controllers
Stand Alone Controllers
Integrated Audio Controllers
Audio
ADCs – Pipeline
Consumer Codecs, ADC/DAC
Voice A/C Codecs
Pro audio DACs, ADCs
PGAs, SRCs, DITs
Versatile, High Speed
Communication, Imaging,
Ultrasound
18
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
19
Selecting a Device

Go to “ti.com” with your browser

In the Products box, hover over Analog and Mixed Signal & select
Data Converters

In the Data Converters Home box in the upper left, hover over Find
a Device and select Parametric Search

Pick a bit resolution and sample rate, and a list of suitable devices
are displayed, comparing numerous additional parameters,
including:
Device name
Status
Resolution
Sample Rate
Architecture
# Channels
SE vs Diff’l
Pwr Consumpt’n
SINAD
SNR
SFDR
ENOB
Voltage ranges
Bandwidth
# supplies
Pins/Pkg
T TO
Technical Training
Organization
20
ADS8361
from : http://focus.ti.com/docs/prod/folders/print/ads8361.html
Resolution (Bits)
Sample Rate (max)
Search Sample Rate (Max) (SPS)
16
500 KSPS
500000
# Input Channels (Diff)
Power Consumption (Typ) (mW)
4
150
SNR (dB)
SFDR (dB)
DNL (Max) (+/-LSB)
INL (Max) (+/-LSB)
INL (+/- %) (Max)
No Missing Codes (Bits)
Analog Voltage AV/DD (Min/Max) (V)
83
94
1.5
4
0.00375
14
4.75 / 5.25
Logic Voltage DV/DD (Min / Max) (V)
Input Type
Input Configuration Range
No. of Supplies
2.7 / 5.5
Voltage
+/-2.5 V at 2.5
2
T TO
Technical Training
Organization
21
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
22
Design Flow…



Product Selection

Key specifications (speed, resolution, …)

Secondary parameters (power, size, price, channels, …)

Research data base of candidate devices

Additional factors: ease of use, cost/value
Hardware Design

ADC / DAC pins, requirements

DSP pin matchup

Layout considerations (noise, supply requirements, etc
Software Authoring

Configuring the (serial) port

Configuring the peripheral

Getting/sending data from/to the peripheral

How? Write it yourself or with the help of an authoring tool…
T TO
Technical Training
Organization
23
I/O Device Development Challenges



Hardware Design

Pinouts, etc

Layout – noise minimization, etc
Software Design

Select modes for serial port

Select modes for ADC / DAC

Write modes to port / peripheral
Debug

Observe / verify performance

Modify design as required
Analog Evaluation Modules
(EVMs) : ADC, DAC, Power, ...
Chip Support Library (CSL)
+ Data Converter Plug-In (DCP)
CCS
T TO
Technical Training
Organization
24
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
25
Signal Chain Prototyping System
Power
Digital
Analog
Interface
Power
A/D
DAC
EVM
EVM
Supply
Board
(THS1206)
(ADS8345)
EVM
T TO
Technical Training
Organization
26
Analog EVMs





5-6K Interface Board
 Compatible with TMS320 C5000 and C6000 series DSP starter kits
 Supports parallel EVM’s up to 24 bits
 Allows multiple clock sources for parallel/Serial converters
 Supports two independent McBSP channels
 Provides complete signal chain prototyping opportunities
Data Converter EVMs
 3 standardized daughter card format (2 serial, 1 parallel)
Serial – support for SPI, McBSP, I2C; 1-16 I/O channels
 Connects to (nearly) any control system
 Stackable
Third Party Interface Boards
 Avnet, SoftBaugh, Spectrum Digital, Insight - Memec Design …
Analog Interface Boards
 Bipolar and single supply
 In development – differential amps, instrumentation amps, active filters
$50 each!
T TO
Technical Training
Organization
27
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
28
Data Converter Plug-In

Allows rapid
application
development

Automatically
generates required
DSP source code

Removes the
necessity to learn
the converter “bit
by bit”

Includes help for
device features

Fully integrated
into Code
Composer Studio
(2, 5, and 6K)
29
Launching the Data Converter Plug-In
30
Adding an Instance of the Desired Converter
31
Specify the Configuration
Define the DSP properties
Set desired ADC modes
Write files…
32
DCP Files Added to CCS Project
“API” file
prototypes the 6
functions
generated by the
DCPin tool

Object file
implements all
device coding
and creates
structures that
manage the
behavior of the
device

33
Files Generated by Data Converter Plug-In

tidc_api.c


tidc_api.h


Configuration data that holds the selections made in the Plug-In
tads8361_ob.c


Header file common to all Data Converter Plug-In generated code
dc_conf.h


Set of API that all Data Converter Plug-In authored code supports
Implementation of the API for the given device instance
tads8361.h

Header file to define the exposed object specific elements
All are fully coded by the Plug-In
All are fully exposed to the user for study/modification as desired
T TO
Technical Training
Organization
34
Data Converter Plug-In Uniform API
DCPAPI TTIDCSTATUS dc_configure(void *pDC);
DCPAPI long dc_read(void *pDC);
DCPAPI void dc_rblock(void *pDC, void *pData,
unsigned long ulCount,
void (*callback) (void *));
DCPAPI void dc_write(void *pDC, long lData);
DCPAPI void dc_wblock(void *pDC, void *pData,
unsigned long ulCount,
void (*callback) (void *));
DCPAPI void dc_power(void *pDC, int bDown);
All objects created with the Data Converter Plug-In share these six API
T TO
Technical Training
Organization
35
Data Converter Plug-In Structures
hADC
TADS8361
*configure // DC API
*power
*read
*write
*rblock
*wblock
0, 0, 0, 0, // unused
*CallBack
serial
iMode
Buffer
// data bk ptr
ulBuffSize // data bk size
iXferInProgress
DCP_SERIAL
port
intnum
hMcBsp
sConfig
MCBSP_Obj
allocated
CSL
Config
Structure
xmtEventId
rcvEventId
*baseAddr
drrAddr
Interacting with the structures...
dxrAddr
TADS8361 * hADC; // make a handle to the DC structure
hADC = &Ads8361_1; // initialize handle to point to our instance
MCBSP_getRcvAddr(hADC->serial->hMcbsp); // obtain info from instance object->substruc
T TO
Technical Training
Organization
36
Data Converter Plug-In Review

Greatly reduces development time

For the DSP software developer: No need to learn
the details of the converter

For the analog designer: No need to learn DSP
programming to test a give data converter

Supports 117 devices on 5 DSP platforms

Where to get the Data Converter Plug-In plug-in :

Included in Code Composer Studio

Download (free of charge) from :
http://www.ti.com/sc/dcplug-in
T TO
Technical Training
Organization
37
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
38
Adapting Lab 6 Code
main.c
#include "dc_conf.h"
#include "t8361_fn.h“
...
initMcBSP();
dc_configure(&Ads8361_1) != TIDC_NO_ERR)
if (dc_configure(&Ads8361_1)
return;
mcbsp.c
...
MCBSP_close(hMcbspControl);
*((unsigned char*)0x90080006) |= 0x01;
edma.c
TADS8361 *
hADC;
hADC = &Ads8361_1;
EDMA_open(EDMA_CHA_REVT0, EDMA_OPEN_RESET);
hEdmaRcv = EDMA_open(EDMA_CHA_REVT1,
gEdmaConfigRcv.src = MCBSP_getRcvAddr(hMcbspData);
MCBSP_getRcvAddr(hADC->serial->hMcbsp);
39
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
40
Observations of Results
Audio sounded ‘scratchy’ - Why?


8361 puts channel number in 2 MSBs

We can adapt the CSL structure to change this

We could mask off those bits before passing data to the algo

In “real life”, we’d probably want these bits to verify channel #
Mismatched data rates between input and output

In real-life situation, one wouldn’t still be using half a codec, so
this problem would not have been encountered normally

If such a case did arise, we could have:

Rewired the ADC to run off the clocks provided by the codec

Adjusted rates to match in software

Sample-rate converted in the DSP
T TO
Technical Training
Organization
41
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
42
Conclusions on TI DSP + TI Analog …




TI offers a large number of low cost analog
EVMs to allow developers to ‘snap together’
a signal chain for ultra-fast test and debug
of proposed components
TI provides CSL and Data Converter Plug-In
to vastly reduce the effort in getting a DSP
to talk to ports and peripherals
Getting to ‘signs of life’ result is now a
matter of minutes instead of days/weeks
Final tuning will sometimes be required, but
amounts to a manageable effort with a
device already easily observed, rather than
‘groping in the dark’ as often was the case
otherwise
T TO
Technical Training
Organization
43
Interfacing TI DSP to TI Analog
TI Analog
Finding Information
Data Converters
Selecting An Example ADC
Development Challenges
Analog EVMs
Data Converter Plug-In
Completing the Code
Build, Run, Evaluate
Lessons Learned
Additional Information…
A/D
11100010011
T TO
Technical Training
Organization
44
Driver Object Details
t8361_ob.c
code to implement the DC API, eg: read fn
long ads8361_read(void *pDC)
{
TADS8361 *pADS = pDC;
if (!pADS) return;
if (pADS->iXferInProgress) return;
while (!MCBSP_rrdy(pADS->serial->hMcbsp));
return MCBSP_read(pADS->serial->hMcbsp);
}
t8361_ob.c make & fill instance obj
TADS8361 Ads8361_1 = {
&ads8361_configure,
&ads8361_power,
&ads8361_read,
&ads8361_write,
&ads8361_rblock,
&ads8361_wblock,
0, 0, 0, 0, 0,
&serial0,
ADC1_MODE,
0, 0, 0
};
t8361_ob.c
typedef struct {
TTIDC
void
DCP_SERIAL
int
int*
unsigned long
volatile int
} TADS8361;
prototype of the DC API
get handle to object
parameter check
verify no bk op in progress
actual SP ops use CSL API
when SP ready, return data rcvd
spin loop – oops ! !
define instance object type
f;
// std DC API
(*CallBack)(void *);
*serial;
iMode;
Buffer;
ulBuffSize;
iXferInProgress;
T TO
Technical Training
Organization
45
Structure Definitions
from TIDC_API.h
from csl_mcbsp.h
typedef struct {
unsigned int
unsigned short
MCBSP_HANDLE
MCBSP_CONFIG
} DCP_SERIAL;
typedef struct {
Uint32 allocated;
Uint32 xmtEventId;
Uint32 rcvEventId;
volatile Uint32 *baseAddr;
Uint32 drrAddr;
Uint32 dxrAddr;
} MCBSP_Obj, *MCBSP_Handle;
T TO
Technical Training
Organization
port;
intnum;
hMcbsp;
sConfig;
Number of serial port used
Which interrupt driver uses
Serial port handle (CSL)
Ptr to CSL ser pt config struc
Is port available?
Which ints port will use
Address of port registers
*Data receive register
*Data transmit register
typedef struct {
TTIDCSTATUS (*configure) (void *pDc);
from TIDC_API.h
void (*power) (void *pDc, int bDown);
long (*read) (void *pDc);
void (*write) (void *pDc, long lData);
void (*rblock) (void *pDC, void *pData, unsigned long ulCount, void (*callback) (void *));
void (*wblock) (void *pDC, void *pData, unsigned long ulCount, void (*callback) (void *));
void* reserved[4];
} TTIDC;
46
Analog Design Tools in Development
OpAmpPro - Input data selects IC





Input data contains transfer function
Input data selects the appropriate circuit
Program enables adjustment resistor & worst case calculations
Op Amp Pro selects IC by analyzing applications and input data
Calculates error due to external component & IC tolerances
Tina-TI Spice Simulation Program





To be offered free on www.ti.com
Uses TI’s SPICE macromodels
Allows general spice circuit simulation
Analysis
Circuit optimization
T TO
Technical Training
Organization
47
Example Analysis Circuit
C3 100p
+/- 10V Signal Conditioning
for
5V ADC's
Vcommon-mode
R2 100k
R1 20k
"Fly w heel"
Conditioning Netw ork
-
V1 5
+
+
U1 OPA364
analog input
C2 25p Vsample
R6 100
C1 1n
+
Vout
Vsample
ADS7829 12-bit
1/2 lsb = 610uV
taq < 750nS
Cin = 25pF
ADS8325 16-bit
1/2 lsb = 38uV
taq < 1.875uS
Cin = 20pf
Vinput
R4 40k
ADS Reference
Vreference 5
+
Vinput
C4 100p
R5 40k
+
R3 100k
Vcommon-mode
T TO
Technical Training
Organization
48
Technical Training
Organization
ti
49
Lab Setup - DSK
usb
DSK
pwr
T TO
Technical Training
Organization
50
Lab Setup - I/F Bd
Parallel Bus I/F
Serial “A”
Analog I/O 1
5-6K Interface Board
Serial “B”
Serial I/F
Analog I/F
Analog I/O 2
pwr
usb
DSK
pwr
T TO
Technical Training
Organization
51
Lab Setup - EVMs
Amplifier EVM
ADC8361 EVM
Parallel Bus I/F
Serial “A”
Analog I/O 1
5-6K Interface Board
Serial “B”
Serial I/F
Analog I/F
Analog I/O 2
pwr
usb
DSK
pwr
T TO
Technical Training
Organization
52
Signal Chain Prototyping System
53