Page 376 - Analog and Digital Filter Design
P. 376
Introduction to Digital Filters 373
16 1
S 1
X ., Multiply two Q15 numbers
16
II
32 30 Q30 Result I
I
16 bit (Q15) result
\G Shift left, then save bits 17 to 32
16 1
]SI j I I I I I I I I 1 I I I Q15 Result
Figure 15.9
Multiplication of Q15 Numbers
Division
Division is usually accomplished by repeated subtraction. It is not required very
often in signal processing, except during result scaling. Scaling is usually done
by a left or right shift of the data, thus multiplying or dividing by a power of
two.
Signal Handling
n a fixed-point processor the maximum value is 32767, or 7FFF in hexadeci-
mal (normally written as 7FFFhj. Negative values are given by a two’s com-
plement number where the most significant bit is a logic 1. For example, 8000 h
is -32768. Decimal numbers can be multiplied by 2 to the power of 15 to
find their hexadecimal equivalent. A filter coefficient value of 0.2 will thus be
32767 x 0.2 = 6553 or 1999h.
There are two types of memory used in a DSP; program memory and data
memory. The program memory address is abbreviated to pma and the data
memory address is abbreviated to dma. The advantage of having separate
memory is that separate busses are used within the processor to access the data.
This enables multiplication operations to be carried out quickly by reading in
two sets of data simultaneously. The disadvantage is that data in program space
cannot be modified during the running of a program. Program space is suitable
for storing fixed FIR filter coefficients, but not digitized signal data.
Two instructions perform the FIR fiIter routine (for a Texas Instruments
TMS32OC52j. Program memory FFOOh to FFlOh has been allocated for storing

