Dsp Program Flowchart - Motorola DSP56156 Manual

Table of Contents

Advertisement

mac
y0,x0,a
macr -y1,x0,a
move x:(r1)+n1,x0 x:(r3)+,x1
mac
y0,x0,a
mac
y1,x1,a
_end1
rnd
a
move x:(r1)+,y0
bfclr
#$800,sr
;****************************
; decimation/interpolation
;****************************
move #flag,r2
move a,x:outbuf
bfchg #$0001,x:(r2)
jcc
chan2
move x:pre_out,a
jmp
intpol
chan2
move a,x:inbuf
move a,x:pre_out
;******************************
; start interpolation filter
;******************************
intpol
bfset #$800,sr
move a,y0
mpy
y0,x0,a
move x:(r0)+,y0
do
#nstages,_end2
mac
y0,x0,a
macr -y1,x0,a
move x:(r1)+n1,x0 x:(r3)+,x1
mac
y0,x0,a
mac
y1,x1,a
_end2
rnd
a
move a,x:ctx
bfclr
#$800,sr
nop
rti
end
6.7

DSP PROGRAM FLOWCHART

The last A/D section decimation-compensation filter as well as the first D/A section interpolation/
compensation filters are performed by the DSP core of the DSP56156 processor. The same in-
MOTOROLA
DSP PROGRAM FLOWCHART
x:(r0)+n0,y1
y1,x:(r0)+
a,x:(r0)+
x:(r0)+,y0
(r0)-
x:(r3)+,x0
x:(r0)+n0,y1
y1,x:(r0)+
a,x:(r0)+
x:(r0)+,y0
DSP56156 ON-CHIP SIGMA/DELTA CODEC
x:(r3)+n3,x0
;=a2/2w(n-2)y1=w(n-1)x0=a1/2
;a-=a1/2 * w(n-1);w'(n-2)=w(n-1)
;x0 = b2/2; x1=b1/2
;a+= b2/2*w(n-2);w'(n-1) = <a>
x:(r3)+,x0
;a+= b1/2 * w(n-1)
;dummy move for r1 address to next filter
;for loop back test purpose only
;check flag for 2:1 decimation 1:2 interpolation
;get previous output for interpolation
;jump intpol without storing input sample
;store decimated input data to input buffer
;save sample for next interpolated output
; y0 = x(n)
; a = g/2 * x(n)
; y0 = w(n-2), x0 = a2/2
x:(r3)+n3,x0
;=a2/2w(n-2)y1=w(n-1)x0=a1/2
;a-=a1/2 * w(n-1);w'(n-2)=w(n-1)
;x0 = b2/2; x1=b1/2
;a+= b2/2*w(n-2);w'(n-1) = <a>
x:(r3)+,x0
;a+= b1/2 * w(n-1)
;output it to the d/a
6 - 65

Advertisement

Table of Contents
loading

Table of Contents