Typical Digital Signal Processing Operations!: Prof. Shankar Prakriya! Indian Institute of Technology, Delhi!
Typical Digital Signal Processing Operations!: Prof. Shankar Prakriya! Indian Institute of Technology, Delhi!
Processing Operations!
Prof. Shankar Prakriya!
Indian Institute of Technology,
Delhi!
12/9/14
Outline!
Why DSP Processors?!
Typical DSP operations: Dot product,
matrix product, convolution, filtering, FFT
Algorithm!
Typical DSP operations required!
INDEXING ISSUES in typical operations!
12/9/14
12/9/14
12/9/14
12/9/14
Convolution!
Consider two finite length sequences h
and x of length N and Nx (convolution
length N+Nx-1)!
Assume h is stored in program memory
and x in data memory!
Convolutions of long length are often
implemented using FFT in practice!
12/9/14
Convolution!
y[n] = i=0N-1h[i]x[n-i] n=0,.., N+Nx-2!
To compute y[n], x[n]..,x[n-N+1] are used along with
h[0].,,h[N-1]!
To compute y[n+1], x[n+1]..,x[n-N+2] are used along with
h[0].,,h[N-1]!
We need the pointer for h to increase each time and repoint to h[0] for computation of next output!
The pointer to x[n] decreases within a MAC but needs to
increment by 1 in preparation for next output!
This can be achieved without extra computation in DSP
processors like the C5510!
12/9/14
Convolution!
It can be seen that the pointer to h[n] can benefit
from circular buffers!
In circular buffers, the pointer when incremented
beyond the last addresses goes back to the
starting addresses!
When decremented below the start address, it
goes forward to the last address automatically
savings in clock cycles!
12/9/14
10
Filtering!
Filtering is the most common operation in signal
processing!
Same as convolution, but the input x[n] is an
infinite length stream (real-time filtering)!
Used to implement lowpass, highpass,
bandpass or bandstop filters!
These frequency selective filters change the
frequency content of an input signal!
12/9/14
11
Filtering!
y[n] = i=0N-1h[i]x[n-i] is a Finite Impulse
Response (FIR) Filter!
H(ej) = nh[n] e-jn is referred to as the
Frequency Response of the Filter!
Note that H(ej) is complex, and both
magnitude and phase responses should
be studied!
12/9/14
12
Filtering!
FIR Filters are preferred for their
guaranteed stability with finite word-length
effects or in adaptive systems where h[n]
are constantly adapted!
FIR filters require large number of
coefficients but can be designed to have a
linear phase!
12/9/14
13
IIR Filters!
y[n] = i=0N-1h[i]x[n-i] - i=1Mg[i]y[n-i]!
is the difference equation of the Infinite Impulse
Response (IIR) type!
Note the feedback of the output in the filter!
Stability is an issue for these causal filters since
the transfer function B(z) = G(z)/H(z)!
may have poles outside the unit circle!
!
12/9/14
14
12/9/14
15
12/9/14
16
12/9/14
17
18
19
12/9/14
20
21
12/9/14
22
Matrix Products!
Assuming two matrices of size m x n and n x r
are stored in memory (row-wise)!
The first row and the first column of the second
matrix need to be accessed for the first element
of the product!
To access the first column, the pointer needs to
be incremented by r (such pointer manipulation
is provided for in C5510)!
12/9/14
23
24
25
12/9/14
26
12/9/14
27
28
29
12/9/14
30
PN
Sequence
Sequence is periodic, and has
autocorrelation that is periodic impulse!
Periodic sequence has length that is a
maximum of 2n-1!
Used widely in communications to
scramble, spread spectrum etc!
12/9/14
31
PN
sequence
Has
to
tap
selected
registers,
XOR
the
bits
and
nd
parity
in
single
instrucDon!
Should
be
able
to
rotate
logically
ConcatenaDon
of
larger
registers
(accumulators)
desirable
for
larger
length
sequences
12/9/14
32
Viterbi
Algorithm
Used
in
communicaDon
receivers,
decoders
ComputaDonally
ecient
implementaDon
of
ML
receivers
Finite
State
Machines
12/9/14
33
Viterbi Algorithm
12/9/14
34
Viterbi
Algorithm
CalculaDon
of
path
metrics,
rapid
comparisons
of
path
metrics
Useful
to
perform
mulDple
addiDons
simultaneously
Most
DSPs
allow
addiDon
of
mulDple
quanDDes
at
the
same
Dme,
access
mulDple
numbers
simultaneously
12/9/14
35
Summary
DSP
requires
very
specialized
funcDons
to
be
implemented,
with
specic
indexing
and
other
requirements
DSP
processor
are
designed
to
take
care
of
these
Good
programming
requires
a
good
understanding
of
the
DSP
architecture
12/9/14
36