SKILLED REPORT EC6511 – DIGITA D IGITAL L SIGNAL PROCESSING LABORATORY
DEPARTMENT OF ELECTRONICS AND COMMUNICATION ENGINEERING
GANESH COLLEGE OF ENGINEERING, METTUPATTY, SALEM – 111.
1
1. Writ Writ ! M!t "!# $r%&r! $r%&r!' ' t% $r $r(%r (%r' ' Li)!r Li)!r !)* Cir+"!r Cir+"!r +%)-% +%)-%"t "ti%) i%) %( t *i/+r *i/+rt t ti' /0)+/ 2)3 4 ,1,,17 !)* 2)3 4 1,8,1,87 /i)& DFT. AIM9
To write write the program for finding the linear and circular convolution of two signals using MATLAB 7.0. APPARATUS APPARATUS RE:UIRED9 RE:UI RED9 System with MATLAB 7.0. L!"A# $%!&%L'T%!( ALGORITHM9 1. )et )et the the num num*e *err of sampl samples es.. +. )enerate )enerate the output output se,uence se,uence of the given given two input input signals signals using -conv -conv command command /. lo lot the the grap raph. PROGRAM9
clc clear all close all 23input45"nter the first sample56 !13length426 h3input45"nter the second sample56 !+3length4h6 n30(1(!11 su*plot4+8+816 stem4n826 2la*el45Time56 yla*el45Amplitude56 title459 Se,uence #esponse56 n30(1(!+1
su*plot4+8+8+6 stem4n8h6 2la*el45Time56 yla*el45Amplitude56 title45: Se,uence #esponse56 y3conv428h6 !3!1;!+1 n30(1(!1 su*plot4+8+8/6 stem4n8y6 2la*el45Time56 yla*el45Amplitude56 title45$onvolution title45$onvolution of 9<: #esponse56
CIRCULAR CON;OLUTION9 ALGORITHM9 1. )et the num*er of samples. +. )enerate the se,uence for the given two input signals using -=eros and -ones matri2 command. /. )enerate )enerate the convolut convoluted ed output output se,uence se,uence of the given two two input signals signals using using -conv -conv command. >. lo lot the the grap raph. PROGRAM9 < PROGRAM FOR CIRCULAR CON;OLUTION clc clear all close all 23input45"nter 23input45"nter the first se,uence56 !13length426 h3input45"nter h3input45"nter the second
se,uence56 !+3length4h6 n30(1(!11 su*plot4+8+816 stem4n826 2la*el45Time56
+
yla*el45Amplitude56 title459 Se,uence #esponse56 n30(1(!+1 su*plot4+8+8+6 stem4n8h6 2la*el45Time56 yla*el45Amplitude56 title45: Se,uence #esponse56 !3ma24!18!+6 23?28=eros418!!16@ h3?h8=eros418!!+6@ for n31(! y4n630 for i31(! 3ni;1
if4306 3!; end y4n63y4n6;24i6Ch46 end end disp45$onvolution of 2 < h is56 su*plot4+8+8/6 stem4y6 2la*el45Time56 yla*el45Amplitude56 title45$onvolution of 9<: #esponse56
OUTPUT FOR LINEAR CON;OLUTION9
OUTPUT FOR CIRCULAR CON;OLUTION9
/
RESULT9 Thus the program for finding the linear and circular convolution of two signals using MATLAB 7.0. was verified successfully@. 8. Writ ! M!t "!# $r%&r!' t% *tr'i) t i'$"/ r/$%)/ %( FIR "%= $!// (i"tr !)* Hi& $!// (i"tr #> F%rir /ri/ 't%* !)* )+ $"%t t (r0)+> r/$%)/. AIM9
To design a D# filter using Dourier series method with MATLAB 7.0. APPARATUS RE:UIRED9 System with MATLAB 7.0 ALGORITHM9 1. )et the pass *and and stop *and ripple and fre,uency. +. )et the sampling fre,uency. /. Dind the order of filter !. >. Eesign the lowpass and :igh pass filter. F. lot the magnitude response of all the filters. PROGRAM9 clc
.HC4fsfp6Gf m3+0Clog104a*s4h66 n3ceil4numGdem6 su*plot4+8+8+6 n13n;1 plot4oGpi8m85J56 if4rem4n8+6I306 yla*el45)ain in d*K56 n13n 2la*el45!ormali=ed fre,uencyK56 n3n1 title45:): ASS DLT"#56 end OUTPUT9
>
RESULT9 Thus the D# filter using Dourier series method with MATLAB 7.0. was designed and verified successfully
. ?. Writ ! M!t "!# $r%&r!' t% */i&) !) IIR (i"tr 2C#>/-?r* %r*r LPF3 t% /!ti/(> t (%""%=i)& /$+i(i+!ti%)/ 2A//' T4 1/+%)*/3 /i)& BLT 't%*. .@H 23 1, (%r .8 H 23 .8, (%r .?8 AIM9
To design a digital # filter using $he*yshev filter with MATLAB 7.0. APPARATUS RE:UIRED9 System with MATLAB 7.0. ALGORITHM9 1. )et the pass *and and stop *and ripples. +. )et the pass *and and stop *and fre,uencies. /. )et the sampling fre,uency. >. $alculate the order of the filter using F.Dind the filter coefficient. H.Eraw the magnitude and phase response. PROGRAM9
clear all clc close all rp3input4-enter the pass *and ripple6 rs3input4-enter the stop *and ripple6 wp3input4-enter the pass *and fre,uency -6 ws3input4-enter the stop *and fre,uency -6 fs3input4-enter the sampling fre,uency -6 w13+CwpGfs
w+3+CwsGfs
F
lot4omGpi8an6 9la*el4-4*6normali=ed
la*el4-phase in radiansNK6
fre,uencyNK6 OUTPUT9 OUTPUT FOR CHEBYSHE; IIR DIGITAL FILTER9 "nter the pass *and ripple(0.0+ "nter the stop *and ripple(.0/ "nter the pass *and fre,uency(1+00 "nter the stop *and fre,uency(+>00 "nter the sampling fre,uency(O000 Dilter order 1 $utoff fre,uency 0./00000000000000
RESULT9
Thus the digital # filter using $he*yshev filter with MATLAB 7.0 was designed and verified successfully.
. Writ ! M!t "!# $r%&r!' t% *tr'i) t i'$"/ r/$%)/ %( FIR L%= $!// (i"tr !)* Hi& $!// (i"tr #> /i)& R+t!)&"!r =i)*%= 't%* !)* )+ $"%t t (r0)+> r/$%)/. AIM9
To design a D# filter using #ectangular window with MATLAB 7.0. APPARATUS RE:UIRED9
H
System with MATLAB 7.0. ALGORITHM9
1. )et the pass *and and stop *and ripple and fre,uency. +. )et the sampling fre,uency. /. Dind the order of filter -!. >. Eesign the low pass8 high pass8 *and pass and *and stop filter. F. lot the magnitude response of all filters. PROGRAM9
clc clear all close all rp3input45ass *and ripple356 rs3input45Stop *and ripple356 fs3input45Stop *and fre,uency in radGsec356 fp3input45ass *and fre,uency in radGsec356 f3input45Sampling fre,uency in radGsec356 wp3+CfpGf ws3+CfsGf num3+0Clog104s,rt4rpCrs661/ dem31>.HC4fsfp6Gf n3ceil4numGdem6 n13n;1 if4rem4n8+6I306 n13n n3n1
end y3*o2car4n16
OUTPUT
"nter the pass*and ripple( .0F "nter the stop*and ripple( .0/ "nter the pass*and fre,uency( 1/00 "nter the stop*and fre,uency( 1H00 "nter the sampling fre,uency( 7>00 The order is(n 3 +H
7
RESULT9 Thus the matla* program to design a D# filter using rectangular window was written and the output was verified.
5. Writ ! M!t "!# $r%&r!' t% *tr'i) t i'$"/ r/$%)/ %( FIR L%= $!// (i"tr !)* Hi& $!// (i"tr #> /i)& K!i/r =i)*%= 't%* !)* )+ $"%t t (r0)+> r/$%)/ A IM
To write a matla* program to design a D# filter using Paiser window and to verify the output. ALGORITHM
1. Start the program. +. $lear the command window using -clc function. /. )et the pass *and and stop *and ripples. >. )et the pass *and and stop *and fre,uencies. F. )et the sampling fre,uency. H. $alculate the order of filter. 7. $alculate the transfer function of the filter using the co efficients. O. lot magnitude and phase responses. Q. "nd the program. ROGRAM P
RJaiser window computation clc close all clear all
rp3input45"nter the pass*and ripple( 5 6 rs3input45"nter the stop*and ripple( 56 fp3input45"nter the pass*and fre,uency( 5 6 fs3input45"nter the stop*and fre,uency( 5 6 f3input45"nter the sampling fre,uency( 5 6
O
*eta3input45"nter the *eta value( wp3+CfpGf ws3+CfsGf num3+0Clog104s,rt4rpCrs661/ dem31>.HC4fsfp6Gf n3ceil4numGdem6 n13n;1 if 4rem4n8+6I306 n13n n3n1 end disp45The order is(56n y3Jaiser4n18*eta6 Rlowpass filter *3fir14n8wp8y6
56
?h8om@3fre,=4*818+FH6 m3+0Clog104a*s4h66 su*plot4+8+816 plot4omGpi8m6 yla*el45)ain in dBK56 2la*el45Dre,uency in radGsecK56 Rhighpass filter *3fir14n8wp85high58y6 ?h8om@3fre,=4*818+FH6 m3+0Clog104a*s4h66 su*plot4+8+8+6 plot4omGpi8m6 yla*el45)ain in dBK56 2la*el45Dre,uency in radGsecK56
OUTPUT
"nter the pass*and ripple( .0F "nter the stop*and ripple( .0/ "nter the pass*and fre,uency( 1/00 "nter the stop*and fre,uency( 1H00 "nter the sampling fre,uency( 7>00 "nter the *eta value( 7 The order is( n 3 +H
R ESULT
Thus the matla* program to design a D# filter using Paiser window was written and the output was verified.
Q
6. Writ ! M!t "!# $r%&r!' t% *tr'i) t i'$"/ r/$%)/ %( FIR L%= $!// (i"tr !)* Hi& $!// (i"tr #> /i)& tri!)&"!r =i)*%= 't%* !)* )+ $"%t t (r0)+> r/$%)/ AM( To write a matla* program to design a D# filter using triangular window and to verify the output. ALGORITHM
1. Start the program. +. $lear the command window using -clc function. /. )et the pass *and and stop *and ripples. >. )et the pass *and and stop *and fre,uencies. F. )et the sampling fre,uency. H. $alculate the order of filter. 7. $alculate the transfer function of the filter using the co efficients. O. lot magnitude and phase responses. Q. "nd the program. ROGRAM P
RTriangular window computation
y3Jaiser4n18*eta6
clc close all clear all rp3input45"nter the pass*and ripple( 56 rs3input45"nter the stop*and ripple( 56 fp3input45"nter the pass*and fre,uency( 5 6 fs3input45"nter the stop*and fre,uency( 5 6 f3input45"nter the sampling fre,uency( 5 6 *eta3input45"nter the *eta value( 56 wp3+CfpGf ws3+CfsGf num3+0Clog104s,rt4rpCrs661/ dem31>.HC4fsfp6Gf n3ceil4numGdem6 n13n;1 if 4rem4n8+6I306 n13n n3n1 end disp45The order is(56n
Rlowpass filter *3fir14n8wp8y6 ?h8om@3fre,=4*818+FH6 m3+0Clog104a*s4h66 su*plot4+8+816 plot4omGpi8m6 yla*el45)ain in dBK56 2la*el45Dre,uency in radGsecK56 Rhighpass filter *3fir14n8wp85high58y6 ?h8om@3fre,=4*818+FH6 m3+0Clog104a*s4h66 su*plot4+8+8+6 plot4omGpi8m6 yla*el45)ain in dBK56 2la*el45Dre,uency in radGsecK56
OUTPUT9 enter pass*and ripple0.0+ enter the stop*and ripple0.01 enter pass*and fre,1000 enter stop*and fre,1F00
10
enter sampling fre, 10000 enter your choice of window function 1. rectangular +. triangular /.Jaiser( + Triangular window filter response GRAPH9 L PF > -
0
B d
2 0
n i n i a
4 0
G
6 0 0
> B d
0 . 1
0 . 2
0 . 3 0 . 4 0 . 5 0 . 6 0 . 7 ( a )No r ma l i z e df r e q u e n c y > HPF
0 . 8
0 . 9
1
0 . 1
0 . 2
0 . 3 0 . 4 0 . 5 0 . 6 0 . 7 ( b )No r ma l i z e df r e q u e n c y >
0 . 8
0 . 9
1
0
1 0
n i
n i a 2 0 G
3 0 0
RESULT9 The L and : D# Dilter response for the given se,uence is generated *ased upon the choice of the windowing function and the filter characteristics are plotted. . Writ ! M!t "!# $r%&r!' t% */i&) !) IIR (i"tr 2Bttr=%rt 8 )* %r*r LPF HPF3 t% /!ti/(> t (%""%=i)& /$+i(i+!ti%)/ 2A//' T4 .1/+%)*/3 /i)& BLT 't%*. .6H 23 1, (%r . H 23 .1, (%r .?5 AIM9 To design a Butterworth digital # filter using MATLAB 7.0. APPARATUS RE:UIRED9 System with MATLAB 7.0. ALGORITHM9 1. )et the pass *and and stop *and ripples. +. )et the pass *and and stop *and fre,uencies. /. )et the sampling fre,uency. >. $alculate the order of the filter using F.Dind the filter coefficient. H.Eraw the magnitude and phase response. PROGRAM9
clear all clc close all format long rp3input4-enter the pass *and ripple6 rs3input4-enter the stop *and ripple6 wp3input4-enter the pass *and fre,uency -6 ws3input4-enter the stop *and fre,uency -6 fs3input4-enter the sampling fre,uency -6 w13+CwpGfs
w+3+CwsGfs
11
9la*el4-4a6normali=ed fre,uencyNK6 Rfigure416 Su*plot4+818+6 lot4omGpi8an6 9la*el4-4*6normali=ed fre,uencyNK6 la*el4-phase in radiansNK6
an3angle4h6 figure4+6 Su*plot4+81816 lot4omGpi8m6 la*el4-gain in d*NK6 9la*el4-4a6normali=ed fre,uencyNK6 figure4+6 Su*plot4+818+6 lot4omGpi8an6 9la*el4-4*6normali=ed fre,uencyNK6 la*el4-phase in radiansNK6
OUTPUT9
"nter the ripple of pass *and 4rp63 .F "nter the ripple of stop *and 4rs63 F0 "nter the fre,uency of pass *and 4fp63 1+00 "nter the fre,uency of stop *and 4fs63 +>00 "nter the sampling fre,uency 4D63 10000 Dilter order O $utoff fre,uency 0.+7/0>77>OH0Q1+0
1+
RESULT9
The L and : # Dilter response for the given se,uence is generated and the filter characteristics are plotted.
@. .
Writ ! MATLAB $r%&r!' t% &)r!t t CT !)* DT "')t!r> /i&)!"/ !)* $"%t it.
AIM
To write a MATLAB program to generate various type of signals.
ALGORITHM
1. Start the program. +. $lear the command window using -clc function. /. $reate the array of time se,uence *y assigning values of-t. >. )et the input value using the -input function for generating various se,uences. F. rovide matri2 values *y giving =ero and ones values in -y. H. 'sing -su*plot function plot the graph and use -stem to o*tain discrete se,uence. 7. La*el in the 9 and a2is using -la*el function. O. "nd the program. ROGRAM P
clc clear all close all R)eneration of cosine se,uence t130(.01(pi
y13cos4+CpiCt16 figure416 su*plot4/8+816 plot4t18y16 yla*el45AmplitudeK56
1/
2la*el454a6nK56 R)eneration of sine se,uence y+3sin4+CpiCt16 su*plot4/8+8+6 plot4t18y+6 yla*el45AmplitudeK56 2la*el454*6nK56 R)eneration of e2ponential se,uence n+3input45"nter the length of e2ponential se,uence( 5 6 t/30(n+ a3input45"nter the value( 56 y/3e2p4aCt/6 su*plot4/8+8/6 stem4t/8y/6 yla*el45AmplitudeK56 2la*el454c6nK56 R)eneration of unit impulse signal t>3+(1(+ y>3?=eros418+68ones418168=eros418+6@ su*plot4/8+8>6
stem4t>8y>6 yla*el45AmplitudeK56 2la*el454d6nK56 R)eneration of unit step se,uence nF3input45"nter the ! value for unit step se,uence( 56 tF30(1(nF1 yF3ones418nF6 su*plot4/8+8F6 stem4tF8yF6 yla*el45AmplitudeK56 2la*el454e6nK56 R)eneration of unit ramp se,uence nH3input45"nter the length of ramp se,uence( 56 tH30(nH su*plot4/8+8H6 stem4tH8tH6 yla*el45AmplitudeK56 2la*el454f6nK56
OUTPUT
"nter the length of e2ponential se,uence( > "nter the value( > "nter the ! value for unit step se,uence( H "nter the length of ramp se,uence( F
1>
. Writ ! M!t "!# $r%&r!' t% $r(%r' At% C%rr"!ti%) !)* Cr%// +%rr"!ti%) %( t *i/+rt ti' /0)+/ 2)3 4 1,8,?,7 !)* 2)3 4 ,?,8,17 /i)& DFT. AIM9
To perform auto correlation and cross correlation of given se,uences in MATLAB. ALGORITHM9 • • • • •
Start MATLAB. "nter the input se,uence. )ive 9‐la*el and ‐la*el and title it. Save and run the program. StopG:alt the program.
PROGRAM9
1F
1H
RESULT9
Thus8 the auto correlation and cross correlation was performed using MATLAB
1. Writ ! $r%&r!' t% /t*> t -!ri%/ !**r//i)& '%*/ %( DSP /i)& DSP $r%+//%r. AIM9
To study a*out direct8 indirect and immediate addressing modes in TMS/+0$F0 de*ugger. APPARATUS RE:UIRED9 1.System with TMS /+0$F0 de*ugger software +.TMS /+0$F0 Pit. ALGORITHM9 IMMEDIATE ADDRESSING MODE9 1. nitiali=e data pointer with 100: data. +. Load the accumulator with first data. /. Add the second data with accumulator content. >. Store the accumulator content in specified address location. F. E#"$T AEE#"SS!) M%E"( H. nitiali=e data pointer with 100: data. 7. Load the accumulator with first data8 whose address is specified in the O. instruction. Q. Add the accumulator content with second data8 whose address is specified 10. in the instruction. 11. Store the accumulator content in specified address location. INJDIRECT ADDRESSING MODE9 1. Load the au2iliary register with address location of first data.
17
+. The au2iliary register 4A#06 is modified indirectly as sym*ol. /. Load the second data into accumulator and perform addition operation. >. Store the result. PROGRAM9 $r%&r!' (%r i''*i!t !**r//i)& '%* .mmregs .te2t STA#T( LE 100: AEE 1+00: SA$L +: :( B : $r%&r!' (%r *ir+t !**r//i)& '%* .mmregs .te2t STA#T( LE 100: LA$$ 0: AEE 1: SA$L +: :( B : $r%&r!' (%r !**i)& t=% )'#r/ =it i)*ir+t !**r//i)& '%*. .mmregs .te2t STA#T( LA# A#08O000: MA# C8A#0 LA$$ C;80 T: "#% S:DT AEE C; SA$L C; :( B : RESULT9
Thus The addressing modes of ES using ES processor was studied.
11. Writ !)* +t ! DSP Pr%+//%r $r%&r!' t% t Li)!r+ir+"!r +%)-%"ti%) %( t !)> t=% /0)+/. AIM9
To write a program to find the $onvolution of two se,uences 94n6 and :4n6 using TMS/+0$F0 de*ugger. APPARATUS RE:UIRED9 1.System with TMS /+0$F0 de*ugger software +.TMS /+0$F0 Pit. LINEAR CON;OLUTION ALGORITHM9 1. Start the program.
1O
+. LE will load the QLSBs of address data memor y. Location or immediate value into the data pointer 4E6 register. /. Load au2iliary register 4LA#6 loads the content of the address data memory location into the designated au2ilary register. >. Then $ clears the content of accumulator too. F. MA# modify current A# and A# as specified. H. The #T load the O *it LSBs of the addressed value of the #T. 7. The SA$L store the 1H LSBs of the accumulator into the addressed data memory. O. M'L is used to multiply the content of T register. Q. The LT would load the contents of the addressed data memory location into T register. 10. AEE will add the content of the memory. 11. LA$$ is used to load the content of the addressed data memory into accumulator. PROGRAM9 Pr%&r!' (%r Li)!r C%)-%"ti%) . MM#")S .T"9T STA#T( LE 100: LA# A#184O100:;>:6 A$ MA# C8A#1 #T+: SA$LC; LA# A#184O+00:;>:6 A$ MA# C8A#1 #T+: SA$LC; LA# A#/84O/00:;H:6 LA# A#>80H: Multiply < Accumulate( !e2tU!( LA# A#18O100: LA# A#+84O+00:;H:6 LA# A#080H: A$ SA$L 0: MA# C8A#1 LT C;8A#+ LoopUMA$(
M C8A#1 LT C;8A#0 AEE 0: SA$L 0: BA! LoopUMA$8C8A#+ LA$$ 0: MA# C8A#/ SA$L C Shift24n6 &alues( LA# A#184O100:;H:6 LA# A#+8F: LA# A#08+: MA# C8A#1 LA$$ C SA$L 1: ShiftU9!( LA$$ C; SA$L C08A#+ BA! ShiftU9!8C8A#1 MA# C; LA$$ 1: SA$L C8A#> BA! !e2tU!8C !% :1( B :1
CIRCULAR CON;OLUTION ALGORITHM9
1Q
1. Start the rogram. +. Load the LSBs of the address data memor y location. /. Load the contents of the address data memory location into au2iliary register. >. Modify the current A# as specified. F. Load the content of addressed data me mory location. H. Store the 1H LSBs of the accumulator into the address data memory location. 7. Load the content in A#L .0 O. Branch the contents of entire au2iliary register. Q. Load the content A#.18A#.+8A#.0 10. Store the content of the accumulator 11. Modify the current A# as specified. 1+. Stop the program. PROGRAM9 Pr%&r!' (%r Cir+"!r C%)-%"ti%)
.MM#")S .T"9T LE 100: LA$$ 0: S'B 1: SA$L 1: LA# A#081: LA# A#+8O010: L%%/( LA# A#18O0H0: LA# A#/8O0F0: LA# A#>81: A L%%(MA# C8A#/ LT C;8A#1 M C; SL F: AEE F: MA# C8A#> BA! L%%8C8A#+ SA$L C; $ALL #%TAT" L%%+(MA# C8A#0 BA! L%%/8C :( B :
#%TAT"( LE 100: LA$$ 1: S'B 1: SA$L +: LA$$ 00F0: SA$B LA# A#/8O0F1: LA# A#F8O070: LA# A#H8+: L%%1(MA# C8A#/ LA$$ C;808A#F SA$L C;808A#H BA! L%%18C LA$B MA# C8A#F SA$L C; LA$$ O070: SAMM BMA# LA# A#/8O0F0: MA# C8A#/ #T 0: BLEE BMA#8C; #"T
RESULT9
Thus the program to find the $onvolution of two se,uences 94n6 and :4n6 using TMS/+0$F0 de*ugger was designed and verified successfully.
. 18. Writ !)* +t ! DSP PROCESSOR $r%&r!' t% G)r!t ! S0!r =!- /i)& TMS?8C5.
+0
AIM9
To write a program to generate Triangle ave8Sine ave8S,uare ave and SawTooth ave using TMS/+0$F0 de*ugger. APPARATUS RE:UIRED9
1.System with TMS /+0$F0 de*ugger software +.TMS /+0$F0 Pit. /.$#0 >.Dunction )enerator. ALGORITHM9 TRIANGLE WA;E GENERATION( 1. Start the program. +. Load the LSBs of the address data memory location. /. rite full 1H *it pattern into address data memory location. >. Load the content of address data memory location. F. Add the content of address data memory location. H. Store the data of accumulator into address data memory location. 7. Modify the current A# as specified. O. #epeat the step +8/. Q. Su*tract the contents of address data memory location. 10. #epeat the steps F8H87. 11. Stop the program. SINE WA;E GENERATION9 1. Start the program +. Load the LSBs of the address data memory location /. rite full 1H *it pattern into address data memory location. >. Load the content of address data memory location.Specify the address of a
su*routine. F. Multiply the content of the register. H. Load the content of the register into accumulator. 7. Store the 1H LSBs of the accumulator into the address data memory location. Q. Branch the contents of entire au2iliary register. 10. Load the content of address data memory location. 11. #epeat the Step. 1+. Stop the program. S:UARE WA;E GENERATION9 1. Start the program +. Load the content of address data memory location. /. Store the 1H LSBs of the accumulator into the address data memory location. >. Load the content of address data memory location. F. $omplement the contents of the accumulator. H. Stop the program.
Pr%&r!' (%r Si) W!- G)r!ti%)
!$D#"V .S"T 10 E"$D#"V .S"T 0 L"!)T: .S"T /H0 AMLT'E" .S"T F E"LA1 .S"T 7 T"M .S"T 0 T"M1 .S"T 1 .mmregs
.te2t STA#T(LE 100: SLP BF008T"M LA# A#+844L"!)T:G!$D#"V6; 4L"!)T:CE"$D#"V661 LA# A#/8E"$D#"V $%!T($ALL E"LA LA$$ T"M TBL# T"M1
+1
LT T"M1 M AMLT'E" A$ SA$L T"M1 MA# C8A#/ BA! #""AT8C LA# A#/8E"$D#"V LA$$ T"M AEE !$D#"V SA$L T"M %'T T"M18> MA# C8A#+ BA! $%!T8C B STA#T E"LA(LA# A#78E"LA1 MA# C8A#7 BA$P(BA! BA$P8C #"T TABL" .word 100 .word 1>F .word 101 .word 1>H .word 10/ .word 1>O .word 10F .word 1F0
.word 10H .word 1F1 .word 10O .word 1F+ .word 110 .word 1F> .word 11+ .word 1FF .word 11/ .word 1F7 .word 11F .word 1FO .word 117 .word 1H0 .word 11Q .word 1H1 .word 1+0 .word 1H+ .word 1++ .word 1H> .word 1+> .word 1HF .word 1+F .word 1HH .word 1+7 .word 1HO .word 1+Q .word 1HQ .word 1/0 .word 170 .word 1/+ .word 171 .word 1/> .word 17/ .word 1/F .word 17> .word 1/7 .word 17F .word 1/Q .word 17H .word 1>0 .word 177 .word 1>+ .word 17O .word 1>/ .word 17Q
RESULT9
Thus the program to generate Triangle ave8Sine ave8S,uare ave and SawTooth ave using TMS/+0$F0 de*ugger.
1?. Writ ! $r%&r!' t% *tr'i) t i'$"/ r/$%)/ %( FIR L%= $!// (i"tr !)* B!)* $!// (i"tr #> F%rir /ri/ 't%* !)* )+ $"%t t (r0)+> r/$%)/ #> /i)& DSP Pr%+//%r. AIM9
To design a D# low pass filter in serial mode. APPARATUS RE:UIRED9 1.System with & de*ugger software +.TMS /+0$F0 Pit. /.$#0 ALGORITHM9 1. Start the program. +. nitiali=e the $ ta*le value. /. Load the au2illary register with 0+00:. >. Modify the au2illary register =ero. F. BlocJ the $ ta*le to the program. H. Set configuration control *it.
7. Load the data pointer with 0A:. O. nitiali=e the analog to digital conversion. Q. Load the au2illary register 1 with 0/00 content. 10. Load the accumulator in O000:. 11. A!E the accumulator with 0DDD:.
++
1+. Su*tract the accumulator content with data O00:. 1/. Modify the au2illary register 1. 1>. Store the accumulator data in O000:. 1F. Load the au2illary register 1 with content 0///:. 1H. ero the accumulator register. 17. Multiply the accumulator with data. PROGRAM9 CAppro2imation type(indow design BlacJmann indow CDilter type(Low ass Dilter CDilter %rder(F+ C$utoff fre,uency in P:3/.000000 .mmregs .te2t B STA#T $TABL"( .word 0DD"7: .word 0DDE/: .word 0DD$H: .word 0DD$>: .word 0DDE0: .word 0DD"$: .word 01O: .word 0F1: .word 0O$: .word 0BQ: .word 0$+: .word 0Q+: .word 01A: .word 0DDFD: .word 0D"7O: .word 0DEQA: .word 0DE10: .word 0DE/0: .word 0D">+: .word 071: .word 0/BF: .word 07$A: .word 0$/>: .word 010F>: .word 01/O7: .word 01F>7: .word 01F>7: .word 01/O7: .word 010F>: .word 0$/>: .word 07$A:
1O. Load the program register8 with M *its to accumulator. 1Q. Load the au2illary register 1 with content 0/00:. +0. Add accumulator content with O00:. +1. Shift the accumulator right 1 *it. ++. Store the accumulator content in O+00 location. +/. Branch the program to step 7.
.word 0/BF: .word 071: .word 0D">+: .word 0DE/0: .word 0DE10: .word 0DEQA: .word 0D"7O: .word 0DDFD: .word 01A: .word 0Q+: .word 0$+: .word 0BQ: .word 0O$: .word 0F1: .word 01O: .word 0DD"$: .word 0DDE0: .word 0DD$>: .word 0DD$H: .word 0DDE/: .word 0DD"7: C Move the Dilter coefficients C from program memory to data memory STA#T( LA# A#080+00: MA# C8A#0 #T //: BLP $TABL"8C; S"T$ $!D C nput data and perform convolution S#( LE 0A: ! 080H: ! 080>: !% !% !% !% LA# A#180/00: LA$$ 0 A!E 0DDD:
+/
S'B O00: MA# C8A#1 SA$L C LA# A#180///: A #T //: MA$E 0DD00:8C AA$ LA# A#180/00:
SA$: C give as SA$: C8 1 in case of overflow LA$$ C AEE O00: SD# remove if output is less amplitude SA$L C %'T C8> pulse to find sampling fre,uency !% B S# .end
RESULT9 Thus the program for D# low pass filter was designed and verified successfully using TMS processor. 1. Writ !)* +t ! DSP PROCESSOR $r%&r!' t% */i&) ! t!$ FIR L%= $!// Fi"tr /i)& TMS?8C5.
Dor Answer #efer ,uestion no(1/ 15. Writ ! M!t "!# $r%&r!' t% *tr'i) t i'$"/ r/$%)/ %( IIR Hi& $!// (i"tr !)* B!)* /t%$ (i"tr #> F%rir /ri/ 't%* !)* )+ $"%t t (r0)+> r/$%)/ #> /i)& DSP $r%+//%r. AIM9
To design a D# high pass filter in serial mode. APPARATUS RE:UIRED9 1.System with & de*ugger software +.TMS /+0$F0 Pit. /.$#0 ALGORITHM9 1. Start the program. +. nitiali=e the $ ta*le value. /. Load the au2illary register with 0+00:. >. Modify the au2illary register =ero. F. BlocJ the $ ta*le to the program. H. Set configuration control *it. 7. Load the data pointer with 0A:. O. nitiali=e the analog to digital conversion. Q. Load the au2illary register 1 with 0/00 content. 10. Load the accumulator in O000:. 11. A!E the accumulator with 0DDD:. 1+. Su*tract the accumulator content with data O00:. 1/. Modify the au2illary register 1. PROGRAM9 CAppro2imation type(indow design BlacJmann indow
1>. Store the accumulator data in O000:. 1F. Load the au2illary register 1 with content 0///:. 1H. ero the accumulator register. 17. Multiply the accumulator with data. 1O. Load the program register8 with M *its to accumulator. 1Q. Load the au2illary register 1 with content 0/00:. +0. Add accumulator content with O00:. +1. Shift the accumulator right 1 *it. ++. Store the accumulator content in O+00 location. +/. Branch the program to step 7.
CDilter type(high ass Dilter CDilter %rder(F+
+>
C$utoff fre,uency in P:3/.000000 .te2t B STA#T $TABL"( .word 0D$E/: .word 0F: .word 0D$BQ: .word 0O7: .word 0DE/D: .word 01AE: .word 0D"/E: .word 0///: .word 0DDF+: .word 0>AB: .word 0DDDO: .word 0FQF: .word 0DDA$: .word 0FQ0: .word 0D"11: .word 0>7$: .word 0DB0B: .word 0+QE: .word 0DHBA: .word 0A": .word 0D1>7: .word 01$: .word 0"QDE: .word 0>$F: .word 0EOO+: .word 0>>B$: .word 0EOO+: .word 0>$F:
.word 0"QDE: .word 01$: .word 0D1>7: .word 0A": .word 0DHBA: .word 0+QE: .word 0DB0B: .word 0>7$: .word 0D"11: .word 0FQ0: .word 0DDA$: .word 0FQF: .word 0DDO: .word 0>AB: .word 0DDF+: .word 0///: .word 0D"/E: .word 01AE: .word 0DE/D: .word 0O7: .word 0D$BQ: .word 0F: .word 0D$E/: C Move the Dilter coefficients C from program memory to data memory STA#T( LA# A#080+00: MA# C8A#0 #T //: BLP $TABL"8C; S"T$ $!D
C nput data and perform convolution S#( LE 0A: ! 080H: ! 080>: !% !% !% !% LA# A#180/00: LA$$ 0 A!E 0DDD: S'B O00: MA# C8A#1 SA$L C LA# A#180///: A #T //: MA$E 0DD00:8C AA$ LA# A#180/00: SA$: C give as SA$: C8 1 in case of overflow LA$$ C AEE O00: SD# remove if output is less amplitude SA$L C %'T C8> pulse to find sampling fre,uency !% B S# .end
+F
RESULT9 Thus the program for designing a D# high pass filter in serial mode was performed
SKILLED ASSISTANT
INTERNAL EAMINER
ETERNAL EAMINER