Professional Documents
Culture Documents
Microprocessors and Its Applications March06 Nr312001
Microprocessors and Its Applications March06 Nr312001
4. Write a FAR procedure SEARCH that searches a byte array for a given byte and
sets the value of a word parameter to the index of the element in the array if a match
is found; otherwise, it puts a -1 in the index word parameter. The parameters are
to be passed to the procedure via a parameter address table. Give a sequence for
calling SEARCH to search ARY of length LEN for variable ‘ID’ and put the index
in IDX? [16]
5. (a) Write an instruction sequence that converts 8-digit packed BCD number to
its equivalent ASCII coded hex number.
(b) Write a program segment that will copy all ASCII characters in string STG
that are enclosed by single quotes to the string MESG and store the number
of characters moved in COUNT? [8+8]
6. (a) Give the machine language code for each of the following instructions?
i. IN AL, 52H
ii. OUT 0CH, AL
iii. OUT DX, AX
1 of 2
Code No: NR312001 NR
iv. IN AX, DX [2+2+2+2]
(b) Discuss the sequence of events during a maskable interrupt and the subsequent
return? [8]
7. Interface a 12-bit DAC to 8255 with an address map of 0C00H to 0C03H. The DAC
provides output in the range of +5V to −5V. Write the instruction sequence.
(a) For generating a square wave with a peak to peak voltage of 4V and the
frequency will be selected from memory location ‘F 0 .
(b) For generating a triangular wave with a maximum voltage of +3V and a
minimum of −2V. [8+8]
8. (a) A terminal is transmitting asynchronous serial data at 1200 bd. What is the
bit time? Assuming 8 data bits, a parity bit and 1 stop bit how long does it
take to transmit one character?
(b) Draw necessary circuit to interface 8251 to an 8086 based system with an
address 0C0H. Write the sequence of instructions to initialize 8251 for syn-
chronous transmission? (Assume the necessary data) [8+8]
?????
2 of 2