Motorola DSP96002 User Manual
Page 531
B-12
DSP96002 USER’S MANUAL
MOTOROLA
; +Sine value (1/2 cycle) in Y memory
; Table size can be i*points/2, i=1,2,...
;
; Macro Call - metr2a points,data,coef,coefsize
;
; points number of points (2 - 2,147,483,648, power of 2)
; data start of data buffer
; coef start of 1/2 cycle sine/cosine table
; coefsize number of table points in sine/cosine table
; = i*points/2, i=1,2,... (1 - 2,147,483,648)
;
;
; ar Radix 2 ar’
; ai Butterfly ai’
; br A’=A+B*Wk br’
; bi B’=A-B*Wk bi’
;
;
;
; wr wi
;
; wrk = cosine(k*pi/points) table
; wik = sine(k*pi/points) table
;
; ar’ = ar + (wr*br + wi*bi)
; ai’ = ai + (wr*bi - wi*br)
; br’ = ar - wr*br - wi*bi = ar - (wr*br + wi*bi)
; bi’ = ai - wr*bi + wi*br = ai - (wr*bi - wi*br)
;
move #points,d1.l
move #@cvi(@log(points)/@log(2)+0.5),n1
move #data,r2
move #coef,m2
move #coefsize,d2.l
move #0,m6
move #-1,m0
clr d0 m0,m1