INSTITUTE OF ENGINEERING AND MANAGEMENT, KOLKATA Microprocessor Subject Name: Microprocessor and Microcontroller Year: 3 rd Year Subject Code: CS502 Semester: 5 th Module Day Assignment 1 Microprocessor Based Systems: Hardware and Interfacing 1 2 3 4 5 6 1. Draw the functional block diagram of 8085 and discuss the function of each unit in brief. 2. What are tri-state devices and why they are essential in a bus oriented system? 3. What do you mean by 16 bit microprocessor? Write down the steps of execution of an instruction by 8085 microprocessor. 4. What are the functions of INTR, HOLD, READY, RESET, ALE, HLDA pins of 8085 microprocessor? 5. Explain different type of control signals of 8085 microprocessor. 6. Discuss the function of different types of flags and general purpose registers. 7. Draw the diagram for generation of control signals for memory and I/O devices. 1. Why demultiplexing address/data bus is needed? 2. How 8085 microprocessor demultiplexes address/data bus? 3. If the size of a memory chip is 2048 8 bits, how many chips are required to make up 16K-byte memory? 4. Design 16 4 memory chip using 8 4 memory chip and specify memory address range. 5. Explain the difference between absolute memory address decoding and partial memory address decoding. 6. Draw the organization of a memory chip and also mention the lines used by the memory chip to communicate with the MPU. 7. Using 74LS138 (3 8 decoder) draws and explains the interfacing of memory device. 8. Explain the memory address range of 1K-byte R/W memory by using partial memory address decoding for 8085 microprocessor. 1. Using 74LS138 (3 8 decoder) draws and explains the interfacing of memory and I/O devices. 2. In memory mapped I/O, how does microprocessor differentiate between I/O and Memory? Can Memory and I/O have same address?
3. Compare Memory mapped I/O and Peripheral mapped I/O. 4. Why number of output ports in I/O mapped I/O is restricted to 256? Specify the 8085 signals that are used to enable an input and output port. 5. Give hardware and software to interface one seven segment display with 8085 microprocessor whose address is FC23H. Which change is required if address of the display is FCH. 6. How 8085 microprocessor differentiates between input and output ports. 7 8 9 1. What are the addressing modes of 8085 microprocessor? Explain with suitable example. 2. What are the advantages of indirect addressing mode over direct addressing mode? How can microprocessor distinguish between instruction and data? 3. Define machine cycle and instruction cycle. Draw the timing diagram of op-code fetch machine cycle. 4. Discuss the functions of following instructions of 8085 microprocessor (Including machine cycle and T state): LHLD 8050H, RLC, RRC, LDAX B, DAD D, STA 2000H, ADC B, RAR, RAL,SHLD 8080H, DCX, INX,LXI 8050H, STAX 8060H, PUSH B, POP D, CALL 9000, RST. 2 Programming the 8085 10 11 12 1. Explain the instruction execution cycle of MVI B, FFH using timing diagram. 2. Explain the instruction execution cycle of LDA 8000H and STA 8050H using timing diagram. 3. Explain the instruction execution cycle of STA 8050H using timing diagram. 4. If the clock frequency is 5 MHz, how much time is required to execute the instruction MVI B, FFH? 5. Explain the instruction execution cycle of following instructions using timing diagram. IN 01H, OUT 00H 1. Specify the content of Accumulator and Flag when the following instructions are executed. MVI A, 01H MVI B, 02H ADD B XRA A HLT 2. If the system clock is 2MHz, find the time to execute the given instruction code: MVI A, 5AH MVI B, A7H ADD B INR A XRA A HLT
3 Interrupts, Architecture of 8086 Microprocessor and 8051 Microcontroller 13 14 15 16 17 3. Write an assembly language program to set the contents of memory locations 8040H to 804FH as follows. 0, 1, 2 F. 4. A block of 16 bytes data is stored in the memory locations from 8050H to onwards. Transfer the data to the location started from 8080H. 5. Count the number of 1s in an 8 bit number. 6. Find the minimum of a set of numbers. 7. Write an assembly language program to arrange a set of numbers in ascending (descending) order. 8. Write an assembly language program to check a set of signed numbers and reject the negative numbers. 1. What is counter? What is the application of counter? 2. What is the relationship between counter and time delay? 3. How time delay is implemented using one register, using a register pair and using a loop within a loop technique. 4. Write an assembly language program to count continuously in hexadecimal from FFH to 00H in a system with a 0.5 microsecond clock period. 1. Define stack. How 8085 microprocessor implement stack? 2. What is the application of stack? 3. What is subroutine? Briefly discuss the sequence of events that takes place while executing CALL instruction. 4. How stack is used for subroutine? What is the difference between CALL and JMP? 5. What do you mean by conditional and unconditional RET instruction in 8085 microprocessor? 6. Write an assembly language program to find the square of a given number using subroutine. 1. What do you mean by interrupt driven system? Arrange the interrupt according to their priority. 2. Define maskable and non-maskable interrupts. What is interrupt call location? 3. After the execution of RIM instruction, the accumulator contains 49H. Explain the accumulator contents. 4. Set the interrupt mask so that RST-5.5 and RST-7.5 are enabled and RST- 6.5 is masked. 5. What are the different interrupts in 8085? Give their locations? Distinguish between maskable and non-maskable interrupts. Arrange interrupts according their priority. 6. Write the accumulator bit pattern for SIM and RIM instructions. 7. After the execution of RIM instruction, the accumulator contains 49H. Explain the accumulator contents. 8. Write an assembly language program to check if RST 5.5 is pending. If it is pending, enable it without affecting any other interrupt
1. Draw the architecture of 8086 and discuss the function of each unit in brief. 18 2. Discuss register organization of 8086 microprocessor. Explain the function of each register. 3. Explain the operations of BIU and EU present in 8086 microprocessor. What is the function of BHE pin in 8086 microprocessor? 4. Describe MIN/MAX mode operation of 8086 microprocessor. What is the difference between MAX Mode operation and MIN Mode operation in 8086 microprocessor? 5. How is pipelining achieved in 8086 microprocessor? 6. What are important signals of Intel 8086? 19 7. How many operating modes does 8086 have? 8. How many functional units does 8086 contain? 9. What is the function of a segment register in 8086? 10. What are conditional and control flags in 8086? 1. Describe the different addressing modes of 8086 microprocessor. 2. Explain how 20 bit physical address is generated in 8086 microprocessor? 3. What are the advantages of having segmentation? How does 8086 microprocessor support segmentation? 20 4. What is the size of data bus and address bus of 8086 microprocessor? What is the size of addressable memory of 8086 microprocessor? 5. What is the purpose of queue? How many words does the queue store in 8086 microprocessor? 6. How does 8086 microprocessor differentiate between opcode and data? 7. Explain different flags of 8086 microprocessor? 8. Briefly explain the maximum mode configuration of 8086. 9. What physical address is represented by: (i) 4370 : 561E H (ii) 7A32 : 0028 H 21 1. What is the difference between minimum and maximum modes of 8086? 2. How many interrupts are available in 8086? List the predefined software interrupts available in 8086. 3. Briefly explain the maximum mode configuration of 8086. 4. What is the purpose of MN/Mx pin? Explain. 22 5. Explain the concept of segmented memory? What are its advantages? 6. Explain the concept of pipelining in 8086. Discuss its advantages and disadvantages. 7. Discuss the interrupt system of Intel 8086. What is interrupt pointer?
What is 'type' of an interrupt? 23 8. Discuss the various addressing modes of 8086. What are displacement, base and index? What is an effective address or offset? 9. What is the difference between minimum and maximum modes of 8086? How are these modes selected? 10. Draw and explain the architecture of 8086. 24 25 11. Describe the difference between the instructions: (i) MOV AL, 0DB H (ii) MOV AL,DB H 12. Given that the EA = 1234H and CS = 0E100H a) What is the physical address of the code? b) Write 5 possible values of the EA and CS such that it would address the same physical memory address as in 2a. 13. Write an 8086 program to add and subtract two 8-bit numbers. 14. Write an 8086 program to multiply and divide two 8-bit numbers. 15. Write an 8086 program to find 1 s complement and 2 s complement of an 8-bit number. 1. Difference between microprocessor and microcontroller. 26 2. What are the various criteria to choose the microcontroller? 3. List out some of the features of the 8051. 4. Draw the program memory and data memory organization in 8051. 5. List out the various registers in 8051. 6. Draw the structure of a pin in port 1. Why all the pins of the port is loaded with FF before using it. 27 7. Explain the timer and counter operation of 8051. 8. Describe PCON AND SCON register in 8051. 9. What are the Interrupt sources of 8051? 10. Draw the format and explain each bit of IE and IP SFR. 11. State and explain the addressing modes of 8051 with one example each. 12. Develop assembly language programs for the Addition, subtraction of two 8 bit &16 bit signed/unsigned numbers. 28 13. Develop assembly language programs for the Multiplication and division on two 8 bit unsigned numbers 14. Develop assembly language programs to find largest and smallest number integer of an array. 15. Develop assembly language programs to find average of 8 bit numbers.
1. Explain the different modes of operation of 8255. 2. Explain the control word format of 8255 in BSR mode and I/O mode. 29 3. Write the control word to set port A as input in mode 1 and load this control word into control word register. Briefly describe the process of data transfer from input device to processor with handshaking signals. Draw its timing diagram. 4 Support IC Chips 30 31 32 33 34 35 36 4. Write a BSR control word subroutine to set bits PC5 and PC7 and reset them after 15 mile second. Assume that delay subroutine is available. 5. In Mode 1 operation of 8255 PPI, what are the control signals when ports A and B act as input ports? Discuss the control signals. 6. Write a program to initialize 8255 in the configuration given below. Port A: O/P with handshake, Port B: I/P with handshake, Port CL: O/P, Port CU: I/P. Assume address of control word register 23H. 1. Explain in brief the different transfer modes of 8237 DMA controller. 2. What do you mean by DMA operation? 3. With respect to 8237 explain the DMA operation. 4. What are the priorities of DMA request? Enumerate them. 5. Explain the function of EOP signal of 8237. What do you mean by cycle staling? 6. What are the major components of 8259A interrupt controller? Explain their functions. 7. Describe the priority scheme and EOI scheme of 8259. 8. Write down the format of ICW1 and ICW2 of 8259. 9. What is cycle stealing? 10. Draw the pin diagram of 8237 DMA controller and explain the functions of each pin. 11. Draw the pin diagram of 8259A interrupt controller and explain the functions of each pin.