VISHVESHWARAIAH TECHNOLOGICAL UNIVERSITY, BELAGAUM
Branch : Electronoics and communication Engineering Semester : V
Subject Code : EC5Li Duration of Exam : 3 hrs
Subject Title : Microprocessor & DSP Lab Max. Exam Marks : 100
QUESTION BANK
PART A
[Note : The examiner should set any 7 questions from part A and any 3 questions from part B for a batch of 10 students during practical examinations]
1. a. Write a program to move a data block starting at location X to location Y without overlap, X, Y and the block length are to be specified.
b. Write a program to add two multibyte (at least 32 bits) binary numbers stored starting at location X and location Y. Store the result starting at location Z.
2. a. Write a program to move a data block starting at location X to location Y with overlap, X, Y and the block length are to be specified.
b. Write a program to generate Square Wave of given duty cycle using a DAC. Display the waveform on a CRO and veryfy the same.
3. a. Write a program to check whether the 8 bit number stored at location X belongs to 2 ut of 5 code or not (code is valid if first three MSBs are 0's & number of 1's in the remaining 5 bits are 2 )
b. Find the product of two unsigned binary numbers stored at location X and X+1 by shift left and add method and display the product in the adress field.
4. a. Write a program to divide a 16 bit number stored at location X, X+1 by a 8 bit number stored at location Y. Display the quotient in address field and the remainder in the data field.
b. Write a program to generate a triangular wave using a DAC. Display the waveform on a CRO and measure the slope (The examiner to specify amplitute and frequency of the triangular wave)
5. a. Write a program to arrange a set of 8 - bit numbers starting at location X in
acsending order. Display the stored vector in the address / data field.
b. Write a program to generate a square wave of a given frequency using a Timer(8253)
in Mode. 3. (Examiner to specify the frequency)
6. a. Write a program to arrange a set of 8 - bit numbers starting at location X in
decsending order. Display the stored vector in the address / data field.
b. Two unsigned binary numbers are stored at location X and X+1. Find their product
and display the result in address field. Use successive addition.
7. a. Write a program to add 'N', 1-byte binary numbers stored from location (X+1)
where 'N', is stored at location X. Store the result in location Y and (Y+1). Display the
result in the address field.
b. Write a program to interchange the N bytes of data stored from location X with N
bytes of data starting from location Y.
8. a. Write a program to subtract a 16 bit binary number stored at location X and X+1
from another 16 bit number stored at location Y and Y+1. Display the result in the
address field.
b. Write an ALP to generate a triangular waveform using DAC. (Examiner to specify
the amplitude and frequency)
9. a. Write a program to implement a counter to count from 00-99 in BCD. Use a
subroutine too generate a delay of _______ seconds between the counts.. The counter
should stop when any key is pressed.
b. Write an ALP to generate a staircase waveform using DAC.
10. a. Write an ALP to convert an 8 bit binary number to its equivalent BCD value.
b. Write a program to display the ACSII equivalent of the key pressed by using 8279.
11. a. Write an ALP too convert a 2 digit BCD number to its equivalent binary value.
b. Write a program to convert DC voltage (0-5V) to its equivalent digital value using
ADC and display the same in data field.
12. a. Write a program to divide a 16 bit number stored at location X and X+1 by an 8 bit
number at location Y using successive subtraction method. Display the result in address
field.
b. Write a program to diplay a message on the display unit (on - board display unit) by
suitable programming the 8279 chip.
PART- B
[Note : The questions related to Digital Signal Processing should be done using MATLAB / code composer studio / Octave / any equivalent]
Realize an IIR filter with pass edge at 1500 Hz stop band edge at 2000 Hz for a sampling frequency of 8000 Hz. Variation of gain within passband is 1dB and stop band attenuation of ___db. Use butterworth or chebshev type 1 prototype design. Use belinear transformation.
Design a digital FIR low pass filter with the following specifications.
Pass band cutoff frequency Wp = 0.2 p (rad)
Pass band ripple Rd=0.25 dB
Stop band cutoff frequency Ws= 0.3 p rad
Stop band attenuation A2= 50 dB
Choose an appropriate window function and determine impulse response and provide a plot of the frequency response of the designed filter. (The figures in this question is only for illustrative purpose)
Let x1(n) = ( 1, 2, 2) and x2 (n) = { 1, 2, 3, 4 } compute 4 point circular convolution, x1(n)
(N) x2(n) and show that the DFT of the circularly convolved sequence i.e.. DFT [x1(n) (N) x2(n)] = X1(k). X2(k), where k X1(k) and X2(k) are the 4 point DFT's of x1(n) and x2(n) respectively. (The figures in this question is only for illustration)
Compute the circular and linear convolution of two sequences x(n) and y(n). Compute the linear convolution using the circular convolution. ( Examiner to specify the x(n) and y(n). The length of the sequences not exceeding 8 points each)
a. Write a program to find the smallest of the N, 1 byte numbers.. Value of N is stored at location X & numbers from location X+1. Display the number in the data field & its address in the address field.
b. Sample a band limited continuous time signall band limited to fm = ____ Hz,, under the following conditions.
a. Write a program to add 'N', 2 digit BCD number. Display the result in the address field.
b. Find the impulse response h(n) of the system whose response y(n) to an input x(n) is given below :
y(n) = [............................]
x(n) = [...........................]
a. Write a program to realise a real time clock. Display seconds in data field, minutes and hours in the address field.
b. Find the linear and circular convolution of the following two sequences :
x1(n) = [........................]
x2(n) = [........................]
a. Write a program to check whether a one byte number stored in location X is a palindreme or not. Store FF or 00 accordingly in location Y.
b. Given a difference equation, obtain H(z) of LT1 system and hence calculate h(n). Obtain the response to an input sequence, x(n).
For a given sequence x(n) compute the N-point DFT using decimation in time or decimation in frequency FFT. Plot the amplitude and phase spectrum.. From the DFT calculated obtain the IDFT, use function files. (N should not exceed 8 points)
a. Solve the given differential equetion by writing a function file,,, (Second order or third order differential equations are to be given by the examiner).
b. Obtain the impulse response of a system described by the difference equation (Second order or third order difference equations are to be given by the examiner)
The following Experiments to be done using DSP Starter Kits
Design a Butter worth IIR LPF to meet the following specifications :
a. Cut-off frequency = ______Hz
b. Sampling Frequency =______Hz
c. Stop-band attenuation =______Hz
Show the response of the filter using Digital Scope or Spectrum Analyser or Personal Computer
Design a IIR Chebshev LPF to meet the following specifications :
a. Cut-off frequency = ______Hz
b. Sampling Frequency =______Hz
c. Pass band ripple =______Hz
d. Stop-band edge frequency =______Hz
e. Stop-band attenuation =______Hz
Show the response of the filter using Digital Scope or Spectrum Analyser or Personal Computer
Design a FIR Filter to meet the following specifications choosing an appropriate window.
a.. Window length , N = _______
b. Stop-band edge frequency =______Hz
c. Cut-off frequency = ______Hz
d. Sampling Frequency =_______Hz
Show the response of the filter using Digital Scope or Spectrum Analyser or Personal Computer