Sunteți pe pagina 1din 31

INTRODUCTION TO

Microprocessors
Dr. Hugh Blanton

ENTC 4337/5337
Objectives

Build intuition for signal processing


concepts
Translate signal processing concepts into
real-time digital communications software
in laboratory

Dr.BlantonENTC4337Introduction
General Information

Contact Information
Emailblanton@etsu.edu
Phone(423) 439-4177
Web Page
http://faculty.etsu.edu/blanton
Office Hours
MWF10:15-11:45

Dr.BlantonENTC4337Introduction
Grading

Calculation of numeric grades


15% midterm #1
25% final #2 (semi-cumulative)
20% homework
50% laboratory

Dr.BlantonENTC4337Introduction
Laboratory component
Students work in teams of two on lab
assignments/reports
Assign team members same lab report
grade and then apply individual
deductions for attendance/participation
Lowest lab report dropped

Dr.BlantonENTC4337Introduction
Academic Integrity

Homework/Exam assignments
Discuss homework/exam questions with
others
Be sure to submit your own independent
solution
Turning in two identical (or nearly identical)
homework sets is considered academic
dishonesty

Dr.BlantonENTC4337Introduction
Laboratory reports
Should only contain work of those
named on report
If any other work is included, then
reference source
Copying information from another
source without giving proper reference
and quotation is plagiarism
Source code must be original work

Dr.BlantonENTC4337Introduction
Topics

The TMS320C6X (1 week)


Programming (4 weeks)
C
Code Composer
Assembly Language
Hardware (4 weeks)
architecture

Dr.BlantonENTC4337Introduction
Applications
FIR Filters
IIR Filters
Fast Fourier Transforms

Dr.BlantonENTC4337Introduction
TMS320C6x Manuals

You need to refer to various TMS320C6000


manuals, which are only available
electronically:
Code Composer Users Guide
http://focus.ti.com/lit/ug/spru301c/spru301c.pdf
Optimizing C Compiler
http://www-s.ti.com/sc/psheets/spru187k/spru187k.pdf
Programmers Guide
http://www-s.ti.com/sc/psheets/spru198g/spru198g.pdf
CPU and Instruction Set Reference Guide
http://www-s.ti.com/sc/psheets/spru189f/spru189f.pdf

Dr.BlantonENTC4337Introduction
Microprocessors

General-purpose processors or
microcontrollers (GPPs/MCUs for
short) are either
not specialized for a specific kind of
applications (in the case of general-
purpose processors), or
they are designed for control-oriented
applications (in the case of
microcontrollers).

Dr.BlantonENTC4337Introduction
Digital Signal Processors

DSP processors have features designed to


support high-performance, repetitive,
numerically intensive tasks.
Mostly designed with the same few basic
operations in mind
They share the same set of basic characteristics
These characteristics fall into three categories:
specialized high speed arithmetic
data transfer to and from the real world
multiple access memory architecture

Dr.BlantonENTC4337Introduction
DSP Features

Features that accelerate performance in DSP


applications include:
Single-cycle multiply-accumulate (MAC) capability;
high-performance DSPs often have two multipliers that
enable two multiply-accumulate operations per instruction
cycle;
some DSP have four or more multipliers
Specialized addressing modes, for example,
pre- and post-modification of address pointers,
circular addressing, and
bit-reversed addressing

Dr.BlantonENTC4337Introduction
DSP Features

Most DSPs provide various configurations of


on-chip memory and peripherals tailored for
DSP applications.
DSPs generally feature multiple-access memory
architectures that enable DSPs to complete several
accesses to memory in a single instruction cycle
Specialized execution control.
Usually, DSP processors provide a loop instruction
that allows tight loops to be repeated without
spending any instruction cycles
for updating and testing the loop counter or
for jumping back to the top of the loop

Dr.BlantonENTC4337Introduction
DSP Features

DSP processors are known for their irregular instruction


sets, which generally allow several operations to be
encoded in a single instruction.
For example, a processor that uses 32-bit instructions may
encode
two additions,
two multiplications, and
four 16-bit data moves into a single instruction.
In general, DSP processor instruction sets allow a data
move to be performed in parallel with an arithmetic
operation.
GPPs/MCUs, in contrast, usually specify a single operation
per instruction

Dr.BlantonENTC4337Introduction
DSP Features

It is worth noting that the difference


between DSPs and GPPs/MCUs is
fading:
many GPPs/MCUs now include DSP
features, and DSPs are increasingly adding
microcontroller features.

Dr.BlantonENTC4337Introduction
What is a DSP?

Digital Signal Processors (DSP) process digital


signals
An alternative method to process analog world signals

ADC DSP DAC


Once the signal is in digital form, the DSP can easily
process it
After the DSP has processed the signal, the output
signal must be converted back to analog so that we can
sense it.

Dr.BlantonENTC4337Introduction
Why DSP?

Advantages of digital signal processing


Programmabilityone hardware does many tasks
Flexibility and upgradeabilitydevelop a new code
RepeatabilityA CD player always plays the same music
quality
Advantages of analog signal processing
low cost in some applicationsattenuators, amplifiers
wide bandwidth (GHz)
Infinite resolution (no quantization error) and low signal
levels

Dr.BlantonENTC4337Introduction
The DSP System

DSP chip
Arithmetic Logic Unit (ALU) Memory
TMS320C6X
Memory
Converters
ADC DSP DAC
Analog-to-Digital
Digital-to-Analog
Communication Ports
Ports
Serial
Parallel

Dr.BlantonENTC4337Introduction
Review: Signals

Continuous-time (analog) signals are functions


of a real argument
x(t) where t can take any real value
Discrete-time (digital) signals are functions of
an argument that takes values from a discrete
set x[n]
n {...-3,-2,-1,0,1,2,3...}
Integer index n instead of time t for discrete-time
systems
Value for x may be real or complex

Dr.BlantonENTC4337Introduction
Analog and Digital Signals

Amplitude of an analog signal can take


any real or complex value at each time
(sample)

Amplitude of a digital signal takes


values from a discrete set

Dr.BlantonENTC4337Introduction
Analog and Digital Signals

A system is a transformation from one signal


(called the input) to another signal (called the
output or the response).
Continuous-time systems with input signal x and
output signal y (a.k.a., the response):
y (t ) x(t ) x(t 1)
2
y (t ) x (t )

Discrete-time system examples


y[n] x[n] x[n 1]
y[n] x 2 [n]

Dr.BlantonENTC4337Introduction
Audio Compact Discs

Human hearing is from about 20 Hz to 20 kHz


Sampling theorem: sample analog signal at a rate of
more than twice the highest analog frequency
Apply a lowpass filter to pass frequencies up to 20 kHz;
e.g. a coffee filter water (small particles) through a coffee
filter but not coffee grounds (large particles)
Lowpass filter needs 10% of maximum passband frequency
to roll off to zero (2 kHz rolloff in this case).
Sampling at 44.1 kHz captures analog frequencies that are
less than 22.05 kHz

Dr.BlantonENTC4337Introduction
Signal Processing Systems

Speech synthesis and speech recognition


Audio CD players
Audio compression (MP3, AC3)
Image compression (JPEG, JPEG 2000)
Optical character recognition
Video CDs (MPEG 1)
DVD, digital cable, and HDTV (MPEG 2)
Wireless video (MPEG 4/H.263)

Dr.BlantonENTC4337Introduction
Communication Systems

Voiceband Dialup/Fax modems


Digital subscriber line (DSL) modems
ISDN: 144 kilobits per second (kbps)
Business/symmetric: HDSL and HDSL2
Home/symmetric: ADSL and VDSL
Cable modems
Cell phones
First generation (1G): AMPS
Second generation (2G): GSM, IS-95 (CDMA)
Third generation (3G): cdma2000, WCDMA

Dr.BlantonENTC4337Introduction
DSP Architectures

Multiply-Add-Accumulate (MAC) instruction


Most common operation in DSP,
A=B*C+D
Typically 70 clock cycles with ordinary processors
Single instruction cycle
Havard architecture
Separate data memory/bus and program memory/bus
Multiple memory accesses per instruction cycle
Modified von Neuman architecture
multiple memory accesses per instruction cycle by the
simple trick of running the memory clock faster than the
instruction cycle.

Dr.BlantonENTC4337Introduction
DSP Architectures

Deterministic interrupt service routine


latency
Special addressing modes supported in
hardware
Modulo addressing for circular buffers (e.g. FIR
filters)
Bit-reversed addressing (e.g. fast Fourier
transforms)
DSP needs a program that is a series of
instructions that perform certain functions.

Dr.BlantonENTC4337Introduction
Digital vs Analog
Digital Signal Processing

Advantages Limitations

More flexible. A/D & signal processors speed:


wide-band signals still difficult to
Often easier system upgrade. treat (real-time systems).
Data easily stored. Finite word-length effect.
Better control over accuracy Obsolescence (analog
requirements. electronics has it, too!).
Reproducibility.

Dr.BlantonENTC4337Introduction
Impact of DSP on Modern Living
Cellular/mobile telephony Digital audio
Speech and channel coding Stereo and surround sound
Voice and data processing Audio equalization and
Power management mixing
Multipath equaliztion Electronic music

Medical electronics
Automotive
Critical/intensive care
Digital Audio
monitors
Digital Radio
Digital X-rays
Personal communication
ECG analyzers
systems
Cardiac monitors
Active suspension
Medical imaging

Personal computer
Sound cards
Data storage and retrieval
Error correction/concealment
Multimedia
Modems

Dr.BlantonENTC4337Introduction
Analog & digital signals
Analog Digital
Continuous function V of Discrete function Vk of
continuous variable t (time, discrete sampling variable tk,
space etc) : V(t). with k = integer: Vk = V(tk).

0.3 0.3
0.2 0.2
Voltage [V]

Voltage [V]
0.1 0.1
0 0
-0.1 -0.1 ts ts
-0.2 -0.2
0 2 4 6 8 10 0 2 4 6 8 10
time [ms] sampling time, tk [ms]

Uniform (periodic) sampling.


Sampling frequency fS = 1/ tS

Dr.BlantonENTC4337Introduction
DSP: aim & tools
Predicting a systems output.
Applications Implementing a certain processing task.
Studying a certain signal.

General purpose processors (GPP), -controllers.


Hardware Digital Signal Processors (DSP). Fast real-time
Faster DSPing
Programmable logic ( PLD, FPGA ).

Programming languages: Pascal, C / C++ ...


Software High level languages: Matlab, Mathcad, Mathematica
Dedicated tools (ex: filter design s/w packages).

Dr.BlantonENTC4337Introduction

S-ar putea să vă placă și