beautypg.com

Motorola DSP96002 User Manual

Page 660

background image

MOTOROLA

DSP96002 USER’S MANUAL

B-141

fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+n4,d7.s 1 1
fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+n4,d7.s 1 1
fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+n4,d7.s 1 1
fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+n4,d7.s 1 1
fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+n4,d7.s 1 1
fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+n4,d7.s 1 1
fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+n4,d7.s 1 1
fmpy d4,d7,d3 fadd.s d3,d2 x:(r0)+,d4.s y:(r4)+,d1.s
;junk to d1.s 1 1
fadd.s d3,d2 y:(r4)+n4,d7.s 1 1
move d2.s,y:(r5)+n5 d5.s,d1.s 1 1
move (r5)+ 1 1
endall --- ---
Totals: 286 4399

B.1.58

Sine Wave Oscillators

Program Icycles
Double Integrator Oscillator Words

page 132,60,1,1
fs equ 8192.0 ;sampling frequency
f0 equ 256.0 ;center frequency
mag equ 1.0 ;magnitude
scale equ (2.0*@sin(3.14159*f0/fs))*(2.0*@sin(3.14159*f0/fs))
output equ $ffff ;output file

org p:$100
move #scale,d7.s ;init scale factor
fclr d6 #mag,d5.s ;init magnitudes
do #100,_gen ;do 100 points
fmpy.x d7,d6,d0 1 1
fadd.s d0,d5 1 1
fsub.x d5,d6 1 1

move d5.s,y:output ;output signal
_gen --- ---
Totals: 3 3

Program Icycles
Second Order Oscillator Words