BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  ·...

22
BHARATHIDASAN ENGINEERING COLLEGE DEPARTMENT OF CSE/IT EC6504 MICRORPOCESSOR AND MICROCONTROLLER FREQUENTLY ASKED QUESTIONS UNIT 1 THE 8086 MICROPROCESSOR PART A 1. What is Microprocessor? A microprocessor is a semiconductor component that incorporates the functions of a central processing unit (CPU) on a Single Integrated Circuit (IC). The central Processing Unit (CPU) built on a single IC is called microprocessor and which can fetch, decode and executes instructions. 1. What is the function of Accumulator? APR/MAY-14 Accumulator is an 8-bit register. It holds one of the data to be processed by Arithmetic Logic Unit (ALU). It also stores the result of the operation performed by the ALU. It is also called as A-register. 2. Name the 3 main units of the Microprocessor. APR/MAY-14 (i) ALU Arithmetic Logic Unit. (ii) Register Array. (iii) Control. 3. What is a BUS? Various input/output devices and memory devices are connected to a CPU by groups of lines called Buses. There are three types of buses are available. (i) Address Bus. (ii) Data Bus. (iii) Control Bus. 4. Explain the function of address bus, data bus and control bus. MAY/JUNE-15 Function of Address Bus: It carries the address of a memory location or I/O device that the CPU wants to access. It is an unidirectional bus and shortly it is called as A-Bus. Function of Data Bus: The data bus is used to transfer data between the processor, memory and I/O devices. It is a bidirectional bus. Function of Control Bus: Control bus is used to transfer data between the CPU and memory and I/O devices. It provides necessary timing and control signals to any part of the microprocessor and its peripherals. It is a bidirectional bus.

Transcript of BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  ·...

Page 1: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

BHARATHIDASAN ENGINEERING COLLEGE

DEPARTMENT OF CSE/IT EC6504 –MICRORPOCESSOR AND MICROCONTROLLER

FREQUENTLY ASKED QUESTIONS

UNIT 1

THE 8086 MICROPROCESSOR

PART A

1. What is Microprocessor?

A microprocessor is a semiconductor component that incorporates the functions of a

central processing unit (CPU) on a Single Integrated Circuit (IC).

The central Processing Unit (CPU) built on a single IC is called microprocessor and which

can fetch, decode and executes instructions.

1. What is the function of Accumulator? APR/MAY-14

Accumulator is an 8-bit register. It holds one of the data to be processed by Arithmetic

Logic Unit (ALU). It also stores the result of the operation performed by the ALU. It is

also called as A-register.

2. Name the 3 main units of the Microprocessor. APR/MAY-14

(i) ALU – Arithmetic Logic Unit.

(ii) Register Array.

(iii) Control.

3. What is a BUS?

Various input/output devices and memory devices are connected to a CPU by groups of

lines called Buses. There are three types of buses are available.

(i) Address Bus.

(ii) Data Bus.

(iii) Control Bus.

4. Explain the function of address bus, data bus and control bus. MAY/JUNE-15

Function of Address Bus:

It carries the address of a memory location or I/O device that the CPU wants to access. It

is an unidirectional bus and shortly it is called as A-Bus.

Function of Data Bus:

The data bus is used to transfer data between the processor, memory and I/O devices. It is

a bidirectional bus.

Function of Control Bus:

Control bus is used to transfer data between the CPU and memory and I/O devices. It

provides necessary timing and control signals to any part of the microprocessor and its

peripherals. It is a bidirectional bus.

Page 2: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

5. Why address bus is unidirectional?

The address is an identification number used by the microprocessor to identify or access a

memory location or I/O device. It is an output signal from the processor. So the address

bus is unidirectional.

6. Why are the data bus and control bus bi-directional? MAY/JUNE-15

In data bus and control bus the transfer of data between the microprocessor and memory

I/O device must take place in both directions. So both the buses are bi-directional.

7. List the advantages of microprocessor.

1. It simplifies system design.

2. It reduces development time.

3. It reduces cost and size.

4. It is flexible in operation.

5. It is very fast to perform operation.

8. List few applications of microprocessor.

1. It is used for speed control of machines.

2. It is used for traffic control and industrial tool control.

3. It is used for measurement, display and control of current, voltage, pressure,

temperature, etc.

9. What is the function of BIU in 8086 microprocessor? MAY/JUNE-2016

The BIU-Bus Interface Unit will have the following functions.

1. Sends out addresses

2. Reset the queue

3. Fetches instructions from memory

4. Reads data from Port and memory and

5. Writes data to memory and Ports.

10. What are the Functions of EU is 8086?

The Execution Unit is responsible for

1. Execution of all instructions.

2. Providing address to the BIU for Fetching data/instruction.

3. Manipulating various registers as well as the Flag register.

11. What are the Segment Registers of 8086? NOV/DEC-2015

8086 has the following segment registers.

1. CS – Code Segment Register

2. DS – Data Segment Register

3. SS – Stack Segment Register and

4. ES – Extra Segment Register.

Page 3: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

12. Write the special functions carried by the general purpose Registers of 8086. NOV/DEC-

14

The special functions carried by the registers of 8086 are the following.

1. AX 16-bit Accumulator.

2. AL 8-bit Accumulator.

3. BX Base Register.

4. CX Count Register.

5. DX Data Register.

13. What is the difference between logical address and physical address?

S.NO. Logical Address Physical Address

1. Logical address consists of

16 address lines.

Physical address is the

actual address and consists

of 20 address lines.

2.

The 16 bit logical address

lines in the logical unit

will be combined with

segment registers to

generate the 20 bit

physical address.

It is not combined with

segment registers.

14. What are the flags of 8086? MAY/JUNE-16

The 8086 has the following flag registers.

1. Carry Flag (CF) 6. Overflow Flag (OF).

2. Parity Flag (PF) 7. TRAP Flag (TF)

3. Auxiliary Carry Flag (AF) 8. Interrupt Flag (IF)

4. Zero Flag (ZF) 9. Direction Flag (DF).

5. Sign Flag (SF).

15. What is the function of auxiliary Carry Flag in 8086?

In an arithmetic operation, auxiliary Carry Flag is set (i.e., AC = 1). When a carry is

generated by the digit D3 and passed on the digit D4. This flag is used only internally for

BCD operation.

16. What are interrupts available in 8086? NOV/DEC-2015

The interrupts of 8086 are NMI and INTR. The NMI is non markable interrupt and INTR

is general maskable interrupt.

17. What is pipelined Architecture?

Page 4: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

In pipelined architecture, the processor will have number of functional units and the

execution time of functional units is overlapped. Each functional unit works independently

most of the time.

18. What is an instruction?

An instruction is a binary pattern entered through an input device to command the

microprocessor to perform that specific function.

19. What is assembler? ( Nov.Dec.2013)

The assembler translates the assembly language program text which is given as input to

the assembler to their binary equivalents known as object code.

The time required to translate the assembly code to object code is called access time. The

assembler checks for syntax errors and displays them before giving the object code.

20. What is subroutine? How it is useful? NOV/DEC-2015

A subroutine is a group of instructions written separately from the main program to

perform a function that occurs repeatedly in the main program. To avoid a repetition of the

same delay instructions, the subroutine technique is used. The 8085 has two instructions

to implement subroutines.

1. CALL: Call a subroutine.

2. RET: Return to main program from subroutine.

21. What do you meant by opcode and the operand?

Opcode is a mnemonic i.e., abbreviation of English like words indicating the type of

operation to be performed.

Example: ADD for addition.

Operand may be an address or register or data on which the operation is to be performed.

It may be 8-bit or 16-bit depending upon the type of data.

22. What is meant by programming?

Programming is a logical approach to instruct to the microprocessor to perform operations

in a given sequence.

23. Define Interrupt. NOV/DEC-13

Interrupt is an action used to break the sequence of operation. While the CPU is executing

a program, an interrupt breaks the normal sequence of execution of instructions.

Types:

1. Internal Interrupt

2. External Interrupt.

Page 5: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

24. Define Stack. MAY/JUNE-16

Stack is a block of memory that may be used for temporarily storing the content of the

registers inside the CPU. The stack is a block of memory locations which is accessed using

the SP and SS registers.

PART B

1. (i)Explain the internal hardware architecture of 8086 microprocessor with neat diagram?

NOV/DEC-2015,APR/MAY-2015

(ii) Write short note about assembler directives? NOV/DEC-14

2. Explain the various addressing modes of 8086 microprocessor with examples? NOV/DEC-2015

, MAY/JUNE-15 3. (i) Explain Data transfer, arithmetic and branch instructions ? MAY/JUNE-2016

(ii)Write an 8086 ALP to find the sum of numbers in the array of 10 elements? MAY/JUNE-

2016 4. Explain modular programming in detail?

5. Write a note about stack, procedures and macros? MAY/JUNE-15 6. Define interrupt and their two classes? Write in detail about interrupt service routine?

NOV/DEC-2015 7. Explain byte and string manipulation with examples?

8. Write in detail about instruction formats and instruction execution timing?

9. Write an ALP to find the largest number and smallest number in the array? APR/MAY-14

10. Write a short note about APR/MAY-14 (i)Loop, NOP and HLT instructions

(ii) Flag manipulation, logical and shift& rotate instructions?

Page 6: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

UNIT 2

SYSTEM BUS STRUCTURE

PART A

25. Define Machine Cycle. APR/MAY-14

Machine Cycle is defined as the time required to complete one operation of accessing

memory, I/O or acknowledging an external request. This cycle may consist of three to six

T-states.

26. What is meant by DMA? MAY/JUNE-15

The direct data transfer between I/O device and memory is called DMA (Direct Memory

Access). In DMA CPU does not participate.

27. Explain the difference between a JMP instruction and CALL instruction. MAY/JUNE-

15

A JMP instruction permanently changes the program counter. A CALL instruction leaves

information on the stack so that the original program execution sequence can be resumed.

28. What is the difference between the shifts and rotate instructions? APR/MAY-14

A rotate instruction is a closed loop instruction. That is, the data moved out at one end is

put back in at the other end. The shift instruction loses the data that is moved out of the

last bit locations.

29. What is meant by wait state? APR/MAY-14

Wait state is used by slow peripheral devices. The peripheral devices can transfer the data

to or from the microprocessor by using READY input line.

The microprocessor remains in wait state as long as READY line is low. During the wait

state, the contents of the address, address/data and control buses are held constant.

30. What is an instruction?

An instruction is a binary pattern entered through an input device to command the

microprocessor to perform that specific function.

31. What is the use of ALE? MAY/JUNE-16

The ALE is used to latch the lower order address so that it can be available in T2 and T3

and used for identifying the memory address. During T1, the ALE goes high, the latch is

transparent i.e., the output changes according to the input data. So the output of the latch

is the lower order address. When ALE goes low, the lower order address is latched until

the next ALE.

32. What is subroutine? How it is useful? NOV/DEC-14

A subroutine is a group of instructions written separately from the main program to

perform a function that occurs repeatedly in the main program. To avoid a repetition of the

same delay instructions, the subroutine technique is used. The 8085 has two instructions

to implement subroutines.

1. CALL: Call a subroutine.

2. RET: Return to main program from subroutine.

Page 7: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

33. What is lookup table? NOV/DEC-13

Lookup table is an array that replaces runtime computation with a simpler array indexing

operation.

A lookup table is used extensively to validate input values by matching against a list of

valid or invalid items in an array.

34. What do you meant by opcode and the operand?

Opcode is a mnemonic i.e., abbreviation of English like words indicating the type of

operation to be performed.

Example: ADD for addition.

Operand may be an address or register or data on which the operation is to be performed.

It may be 8-bit or 16-bit depending upon the type of data.

35. What is meant by PSW? APR/MAY-13

PSW - Program Status Word is a 16-bit register. The higher order 8 bits contain

accumulator contents and the lower order 8 bits have 5 condition flags.

36. What is meant by programming?

Programming is a logical approach to instruct to the microprocessor to perform

operations in a given sequence.

37. What are three basic multiprocessor configurations that the 8086 can support?

1. Coprocessor configuration.

2. Closely coupled configuration.

3. Loosely coupled configuration.

38. What are the advantages of loosely coupled configuration in a multiprocessor system?

APR/MAY-13

1. Each processor may have a local bus to access local memory or I/O devices so that a

greater degree of parallel processing can be achieved.

2. More flexible.

3. Better system throughput by having more than one processor.

4. If any fault occurs in a module, that faculty module can be detected and replaced. So

the breakdown of the entire system is avoidable.

39. Name the three bus allocation schemes used in loosely coupled multiprocessor system.

1. Daisy chaining.

2. Polling method.

3. Independent Request.

Page 8: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

40. What do you mean by numeric processor? NOV/DEC-14

8087 is the numeric processor or numeric co-processor. It adds arithmetic, trigonometric,

exponential and logarithmic instructions to 8086/8088 instruction set for all data types. It

supports 16, 32, 64 bit integers 32, 64, 80 bit floating point and 16 digit BCD data types.

41. How many I/O channels are available in 8089?

Two I/O channels are available in 8089.

1. I/O channel 1

2. I/O channel 2

42. What is the function of Bus controller 8288?

It is able to originate the address latch enable signal to the 8082.

The interrupt acknowledge signal to the interrupt controller.

43. Write down various principal of I/O programming?

There are three principle types of I/O programming is,

1. Programming I/O.

2. Interrupt I/O.

3. Block transfer.

44. What is meant by Multiprogramming? MAY/JUNE-16

Two or more processes code is stored in memory at the same time and is executed in a

time multiplexed manner that system is called as multiprogramming.

45. What is meant by Mutual Exclusion?

Mutual exclusion is a method used to preventing two or more processes from

simultaneously entering their critical sections for accessing a shared resource.

22. What is meant by Multiprocessing system? ( Nov.Dec.2013)

If a system includes two or more components that can execute instructions simultaneously

it is called a multiprocessing system.

46. Write a drawback of daisy chaining. APR/MAY-13

It is limited to only a few modules.

The priority of each module is fixed by its physical location.

The failure of a module causes the whole system to tail

47. What are the errors in 8087? NOV/DEC-14

The 8087 recognizes six error types.

1. IM (invalid operation)

2. DM (denormalized operand)

3. ZM (divide by zero)

4. OM (overflow)

5. UM (underflow)

Page 9: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

6. PM (precision error)

48. Write instruction set of 8087? MAY/JUNE-14

The 8087 has following instruction set

1. Data transfer instruction

2. Arithmetic instruction

3. Comparison instruction

4. Transcendental instruction

5. Constant instruction

6. Processor control groups instruction

49. What are the addressing modes of 8089? APR/MAY-12

1. Based addressing mode

2. Offset addressing mode

3. Indexed addressing mode

4. Auto increment indexed

50. Which processor can act as coprocessor for 8086?

8087 numeric data processor is the only processor designed to coprocessor for 8086.

PART B

1. Explain Minimum mode and maximum mode of operation in 8086 in detail. NOV/DEC-2015,

APR/MAY-2015

2. Explain in detail about the system bus timing of 8086/8088. MAY/JUNE-2016

3. Write notes on the following

(i) Programmed I/O

(ii) Interrupt I/O

4. Explain in detail about block transfers and DMA. APR/MAY-14

5. Explain in detail about closely coupled configurations. APR/MAY-14 6. Explain loosely coupled configurations in detail. NOV/DEC-2015

7. Explain the following in detail MAY/JUNE-15 (i) Process Management &iRMX86

(ii) Memory Management

(iii) Virtual Memory

8. Explain Numeric data Processor in detail.

9. Explain in detail about I/O Processor. MAY/JUNE-15 10. Explain the following MAY/JUNE-2016

(i) Multiprocessor system(4)

(ii) Coprocessor(4)

(iii) Multiprogramming(4)

(iv) Semaphore(4)

Page 10: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

UNIT 3

I/O INTERFACING

PART A

1. What is Key debouncing? MAY/JUNE-15

When a key press is found, the microprocessor waits for at least 10 ms before it accepts

the key as input. It is called key debouncing.

2. Explain the operation of a sample hole circuit briefly. MAY/JUNE-15

The sample and hold circuit samples the instantaneous value of A.C signal at the desired

moment and holds it constant during the period of conversion. LF 398 is an IC package

for sample and hold circuit. The hold capacitor is selected by the user.

3. Define PPI. APR/MAY-14

8255 is a widely used, programmable, parallel I/O device. It can be programmed to transfer

data under various conditions from simple I/O to interrupt I/O.

4. Explain the working of receiver part of USART. APR/MAY-14

R D (Receiver Data): This Output signal outputs a composite serial stream of data on

the rising edge of R C.

R RDY (Receiver Ready): This Output signal indicates that the 8251 contains a

character that is ready to be input to the CPU.

R C (Receiver Clock): This clock input controls the rate at which the character is to be

received.

5. Define the following terms for D/A converters. MAY/JUNE-15

(i) Resolution:

It is the ratio of a change in output voltage resulting from a change of 1 LSB at the

digital input. For an N-bit DAC it can be given as

Resolution = VOFS

2n–1

(ii) Accuracy:

It is a comparison of actual output voltage with expected output.

Accuracy = VOFS

(2n–1)2

6. What is the function of gate signal in 8254 timer?

Gate-N counter Gate Inputs are used to activate the counter or timer.

7. What is the necessity of the programmable interval timer?

It is necessary to generate accurate time delays in a microcomputer system. Counters can

be programmed in six different modes for various applications.

Page 11: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

8. Compare parallel and serial type of data transfer. MAY/JUNE-2016

S.No Parallel Data-Transfer Serial Data-Transfer

1. Data is transferred as byte. Data is transferred as bit.

2. More number of channels

are required for data transfer. Only one channel is enough.

3.

No need of parallel to serial

data conversion for

transmission and reception.

Needs parallel to serial data

conversion for transmission

and reception.

9. Bring about the features of 8259 or advantages of PIC chips in microprocessor based

systems. APR/MAY-13

8259 can

(a) Manage 8 interrupts according to the instructions written into its control registers.

(b) Vector an interrupt request anywhere in the memory.

(c) Resolve eight levels of interrupt priorities in a variety of modes.

(d) Mask each interrupt request individually.

(e) Read the status of pending interrupt, in service interrupts and masked interrupts.

(f) Be set to accept either the level triggered or the edge triggered interrupt requests.

(g) Be expanded to 64 priority levels by cascading additional 8259s.

10. Write down the function of OBF in 8255.

OBF (Output Buffer Full):

This is an active low output signal for the output device. The 8255 activates this signal to

indicate output device that the data is available on the output port.

11. Name any two types of ADC.

Successive approximation ADC

Dual slope ADC

Flash type ADC

12. What is the count value needed to program the 8254 to generate the delay of

1 ms. APR/MAY-13

Count = 1 10–3

0.5 10–6

= 2000 D = 07DOH

13. Which is the fastest ADC and why?

Flash type ADC is the fastest of all ADCs. ADC has parallel comparator and the

conversion speed is accomplished by providing 2n – 1 comparators and simultaneously

comparing the input signal with unique reference levels spaced 1 LSB apart.

Page 12: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

14. List the features of 8279. NOV/DEC - 13

(i) 8279 provides a scanned interface to a 64-contact key matrix, with two or more keys

CONTROL and SHIFT.

(ii) It provides three input modes for keyboard interface.

1. Scanned Keyboard Mode.

2. Scanned Sensor Matrix Mode.

3. Strobe Input Mode.

(iii) It has built-in hardware to provide key debounce.

(iv) The interrupt output of 8279 can be used to tell CPU that the key press is detected.

This eliminates the need of software polling.

(v) It provides multiplexed display interface with blanking and inhibit options.

15. What are the various display modes of 8279 Keyboard/Display Controller?

(i) Left Entry (Typewriter Type).

(ii) Right Entry (Calculator Type).

16. What is the need for using opto coupler while interface high-power devices with

microprocessor?

It isolates the power and the control circuit since there is no direct contact between the two

devices concerned. (The principle involves emission of light).

17. Name the modes available in 8255 A Control Word format. APR/MAY-14

(a) BSR Mode.

(b) I/O Mode.

(i) Mode 0: Simple I/O Mode.

(ii) Mode 1: I/O with Handshaking Mode.

(iii) Mode 2: Bidirectional data transfer mode.

18. What are the methods used for communication in 8085.

Serial Communication.

(i) Simplex, half duplex and full duplex communication.

(ii) Synchronous and Asynchronous Communication.

Parallel Communication.

Page 13: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

19. What is the need for interfacing?

Data between memory I/O devices and register has to be transferred for the operation of

processor in real-time applications as a microprocessor is not capable of storing the data

in it, i.e., it has no internal memory.

20. What are the functions of DMA Controller? APR/MAY-12

It has four independent channels with each channel capable of transferring

64k bytes. The controller manages the data transfer between memory and a peripheral

under its control, thus bypassing the MPU. It also resolves the priority among requesting

devices.

21. Write the features of mode 0 in 8255?

1. Two 8-bit ports (port A and port B) and two 4-bit ports (port C upper and lower) are

available. The two 4-bit ports can be combined used as a third 8-bit port. 2. Any port can

be used as an input or output port. 3. Output ports are latched. Input ports are not latched.

4. A maximum of four ports are available so that overall 16 I/O configurations are possible.

22. What are the features used mode 1 in 8255?

Two groups – group A and group B are available for strobed data transfer. 1. Each group

contains one 8-bit data I/O port and one 4-bit control/data port. 2. The 8-bit data port can

be either used as input or output port. The inputs and outputs both are latched. 3. Out of 8-

bit port C, PC0-PC2 is used to generate control signals for port B and PC3=PC5 are used

to generate control signals for port A. The lines PC6, PC7 may be used as independent

data lines.

23. What are the signals used in input control signal & output control signal? APR/MAY-

14

Input control signal STB (Strobe input) IBF (Input buffer full) INTR (Interrupt request)

Output control signal OBF (Output buffer full) ACK (Acknowledge input) INTR

(Interrupt request)

24. What are the features used mode 2 in 8255?

The single 8-bit port in-group A is available.

1. The 8-bit port is bi-directional and additionally a 5-bit control port is available.

2. Three I/O lines are available at port C, viz PC2-PC0.

3. Inputs and outputs are both latched.

4. The 5-bit control port C (PC3=PC7) is used for generating/accepting handshake signals

for the 8-bit data transfer on port A.

25. What are the modes of operations used in 8253? NOV/DEC-13

Each of the three counters of 8253 can be operated in one of the following six modes of

operation. 1. Mode 0 (Interrupt on terminal count) 2. Mode 1 (Programmable monoshot)

Page 14: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

3. Mode 2 (Rate generator) 4. Mode 3 (Square wave generator) 5. Mode 4 (Software

triggered strobe) 6. Mode 5 (Hardware triggered strobe)

26. What are the different types of write operations used in 8253?

There are two types of write operations in 8253 (1) Writing a control word register (2)

Writing a count value into a count register The control word register accepts data from the

data buffer and initializes the counters, as required. The control word register contents are

used for (a) Initializing the operating modes (mode 0-mode4) (b) Selection of counters

(counter 0- counter 2) (c) Choosing binary /BCD counters (d) Loading of the counter

registers. The mode control register is a write only register and the CPU cannot read its

contents.

27. Give the different types of command words used in 8259? APR/MAY-12

The command words of 8259A are classified in two groups 1. Initialization command

words (ICWs) 2. Operation command words (OCWs)

PART B

1. Draw and explain the block diagram of 8254 programmable interval timer. Also explain the

various modes of operation. MAY/JUNE-15

2. Explain 8279 keyboard /display controller with neat block diagram. MAY/JUNE-15 3. (i)Explain how to interface: (i)ADC and (ii) DAC APR/MAY-2015

(ii)Compare serial and parallel interface?

4. With neat block diagram explain the 8251 and its operating modes. NOV/DEC-2015

5. Draw the block diagram of I/O interface &explain in detail. NOV/DEC-14 6. Explain in detail about DMA controller. MAY/JUNE-2016

7. Explain the format of I/O mode set control and BSR control word of programmable peripheral

interface. Explain in detail the operating modes of PPI? APR/MAY-14 8. Draw and explain the block diagram of traffic light control system. APR/MAY-2015

9. Write short notes on LED display, LCD display,Keyboard display interface.

10. Draw and explain the block diagram of alarm controller. MAY/JUNE-2016

11. Draw the block diagram of programmable interrupt controller and explain its operations.

NOV/DEC-2015

Page 15: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

UNIT 4

MICROCONTROLLER

PART A

1. What are the main features of 8051 microcontroller? MAY/JUNE-15

Intel 8051 is an 8-bit CPU.

On-chip oscillator.

4 KB of ROM (Program memory).

128 bytes of RAM (Data Memory).

Bit addressing.

Powerful bit processing capability.

2. What does the mnemonics “LCALL” and “ACALL” stands for?

LCALL stands for Long call is a 3 byte instruction that addresses the full 64K program

space.

ACALL stands for Absolute call is a 2 byte instruction and used when the target address

is in the current 2K page.

3. What is microcontroller?

A microcontroller is a small computer on a single integrated circuit containing a processor

core, memory and programmable input/output peripherals.

Microcontrollers are designed for embedded applications.

4. Name any four additional hardware features available in microcontrollers when

compared to a microprocessors. APR/MAY-14

1. RAM

2. ROM

3. Computers and clock circuit.

4. Parallel and serial I/O.

5. How does 8051 differentiate between the external and internal program memory?

APR/MAY-14

S.No External Program Memory Internal Program Memory

1. EA pin is high. EA pin is grounded.

2. PSEN signal is activated. PSEN signal is grounded.

3. 8051 can address upto 64KB of

external data memory.

4KB of internal memory is

available.

4. Accessible only by direct and

indirect addressing modes.

Accessed by all addressing

modes.

Page 16: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

6. Explain the various flags in PSW register. MAY/JUNE-15

7 What are the differences between a microcontroller and a microprocessor?

S.No Microprocessor Microcontroller

1. It is termed as general purpose

digital computer.

It is termed as special

purpose digital controller.

2. It contains the CPU, memory,

addressing circuits and interrupt

handling circuit.

It possess all features of

microprocessor and

additionally it includes

timers, parallel and serial I/O

and the internal RAM and

ROM.

3. It has one or two types of bit

handling instructions.

It has many bit handling

instructions.

8. What are the differences between internal RAM and ROM?

S.No RAM ROM

1. It is used for data storage. It is used for program

storage.

2. Data of RAM can be changed

during processing.

Data of ROM cannot be

changed during processing.

3. It is non-volatile memory. It is volatile memory.

5. What are Register Banks in 8051 microcontroller? NOV/DEC-14

34 General-Purpose or working registers in which A and B hold results of mathematical

and logical operations.

The other 32 registers are arranged as part of the internal RAM in four banks B0 – B3,

of eight registers.

Page 17: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

6. What is the significance of GATE bit in TMOD control register? NOV/DEC-14

OR Gate enables bit which controls RUN/STOP of timer I/O. Set to 1 by program to

enable timer to run if bit TR1/0 in TCON is set and signal on External Interrupt INT1/0

pin is high. Cleared to 0 by program to enable timer to run if bit TR1/0 in TCON is set.

7. Give the applications of microcontroller.

In real-time systems high-speed/performance control applications such as speed control

of motors, position control, control of physical quantities such as pressure, temperature,

etc.,

8. What are the SFRs associated with the Timer Operations of 8051 microcontroller?

APR/MAY-14

TMOD is dedicated to the two-timers and can be considered to be two duplicate four

bit registers, each of which controls the action of one of the timers.

TCON has control bits and flags for the timers in the copper nibble and control bits and

flags for the external interrupts in the lower nibble.

9. What is the maximum frequency of the clock signal that can be counted by 8051

counter?

The maximum frequency of the clock signal is 1

24 th

of oscillator frequency.

10. What are the addressing modes available in 8051? MAY/JUNE-2016

1. Register Addressing.

2. Direct Addressing.

3. Register-indirect addressing.

4. Immediate addressing.

5. Base register plus Index Register Indirect Addressing.

11. What is the Instruction Format available in 8051? NOV/DEC-13

1. Data Transfer Instructions.

2. Arithmetic Instructions.

3. Logic instructions.

4. Control transfer instructions.

12. What is meant by serial communication?

In serial communication, data is first converted to serial bits by using parallel in-serial

out shift register.

13. How many I/O ports are available in 8051?

There are four I/O ports are available in 8051 such as P0, P1, P2 and P3.

Page 18: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

14. What is meant by Program Counter? APR/MAY-13

Program counter is an important register in the 8051. The program counter points to the

address of the next instruction to be executed. As the CPU fetches the opcode from the

program ROM, the program counter is incremented to point to the next instruction.

15. What is the need for stack in 8051?

8051 has only limited number of registers that is way 8051 use stack variable. Stack is a

section of RAM used by the CPU to store information temporarily.

PART B

1. Explain the architecture of 8051 with its diagram. MAY/JUNE-2016

2. Explain the I/O pins ports and circuit details of 8051 with its diagram. NOV/DEC-14

3. Write an 8051ALP to create a square wave 66%duty cycle on bit3 of port 1. MAY/JUNE-2016,

MAY/JUNE-15 4. With example explain the arithmetic and logic instruction of 8051 microcontroller.

APR/MAY-2015

5. With example explain the different instruction set of 8051 microcontroller. APR/MAY-14 6. Write a program based on 8051 instruction set to pack array of unpacked BCD digits.

7. Explain the different addressing modes of 8051. NOV/DEC-2015

8. Write a program to bring in data in serial form and send it out in parallel form using 8051

9. Explain the data types and assembler directives of 8051. APR/MAY-14 10. Explain about the register banks and special function register of 8051 in detail. NOV/DEC-

2015

Page 19: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

UNIT 5

INTERFACING MICROCONTROLLER

PART A

1. What are the usage of timer and counter? MAY/JUNE-15

Timer is used to give the delay of particular time between some events and also used to

count the machine cycles.

Counter is used to count pulses. External I/P signal must be kept at least for one machine

cycle.

2. When 8051 is reset, all interrupts are disabled. How to enable these interrupts?

Each of the interrupt sources can be individually enabled or disabled by setting or

clearing a bit in the special functions register IE.

IE also has a global disable bit, which disables all interrupts at once.

3. What is nested interrupts? APR/MAY-14

The 8051 is executing an ISR for servicing an interrupt and another interrupt occurs. If

the new coming interrupt is high priority interrupt, then only it can interrupt the

previously occurred low priority interrupt. These are called nested interrupts.

4. Write short notes on interrupt priority. APR/MAY-14

Bits set to 1 are known as interrupt a high priority and 0 assigns low priority.

Interrupts with the highest priority can interrupt another interrupt with a lower priority.

The lower priority interrupt continues after the higher is finished.

If two interrupts with the same priority occur at the same time, then they have the

following ranking.

1. External Interrupt 0 (IE0)

2. Timer 0 Overflow (TF0)

3. External Interrupt 1 (IE1).

4. Timer 1 Overflow (TF1).

5. Serial Port

5. Write the vector address and priority sequence of 8051 interrupts. MAY/JUNE-15

Priority Sequence Interrupt Address (HEX)

1. IE0 0003H

2. TF0 00013H

3. IE1 0013H

4. TF1 001BH

5. Serial 0023H

Page 20: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

6. Give steps to program 8051 for serial data transfer. NOV/DEC-14

The 8051 has a serial data communication circuit that uses register SBUF to hold the

data.

Register SCON controls data communication.

Register PCON controls data rates.

Pins RXD (P3.0) and TXD (P3.1) connect to the serial data network.

7. How does the status of EA pin affect the access to internal and external program

memory? NOV/DEC-14

EA -Enable Interrupt bit, cleared to 0 by program to disable all interrupts; set to 1 to

permit individual interrupts to be enabled by their enabled bits.

It is set to access data from external memory or else it is grounded for internal memory

operation.

8. What are the differences between a microcontroller and a microprocessor?

S.No Microprocessor Microcontroller

1. It is termed as general purpose

digital computer.

It is termed as special

purpose digital controller.

2. It contains the CPU, memory,

addressing circuits and interrupt

handling circuit.

It possess all features of

microprocessor and

additionally it includes

timers, parallel and serial I/O

and the internal RAM and

ROM.

3. It has one or two types of bit

handling instructions.

It has many bit handling

instructions.

9. What are the differences between internal RAM and ROM?

S.No RAM ROM

1. It is used for data storage. It is used for program

storage.

2. Data of RAM can be changed

during processing.

Data of ROM cannot be

changed during processing.

3. It is non-volatile memory. It is volatile memory.

10. What are Register Banks in 8051 microcontroller? APR/MAY-13

34 General-Purpose or working registers in which A and B hold results of mathematical

and logical operations.

The other 32 registers are arranged as part of the internal RAM in four banks B0 – B3,

of eight registers.

Page 21: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

11. What is the significance of GATE bit in TMOD control register? NOV/DEC-13

OR Gate enables bit which controls RUN/STOP of timer I/O. Set to 1 by program to

enable timer to run if bit TR1/0 in TCON is set and signal on External Interrupt INT1/0

pin is high. Cleared to 0 by program to enable timer to run if bit TR1/0 in TCON is set.

12. Give the applications of microcontroller.

In real-time systems high-speed/performance control applications such as speed control

of motors, position control, control of physical quantities such as pressure, temperature,

etc.,

13. What are the SFRs associated with the Timer Operations of 8051 microcontroller?

TMOD is dedicated to the two-timers and can be considered to be two duplicate four

bit registers, each of which controls the action of one of the timers.

TCON has control bits and flags for the timers in the copper nibble and control bits and

flags for the external interrupts in the lower nibble.

14. What are the differences between a Stepper Motor and DC Motor?

S.No Stepper Motor DC Motor

1. It moves in steps of 1 to 15

degrees.

It most continuously.

2. It has many sequences to rotate. It has two directions to

rotate.

3. If we know the starting position,

we can easily count the number

of steps the motor has moved

and calculate the final position

of the motor.

This is not possible in a DC

motor.

15. Define Pulse Width Modulation.

The speed of the motor depends on three factors such as load, voltage and current. For

a given fix to load, we can maintain a steady speed by using a method called pulse width

modulation.

16. Define Stepper Motor. APR/MAY-13

A stepper motor is a widely used to device that translates electrical pulses into

mechanical movement. In applications such as disk drives, dot matrix printers and

robotics, the stepper motor is used for position control.

17. Define Step Angle. APR/MAY-13

The step angle is the minimum degree of rotation associated with a single step. Various

motors have different step angles.

Page 22: BHARATHIDASAN ENGINEERING COLLEGE …library.bec.ac.in/kbc/FAQ BEC/CSE/4 SEM/EC6504-MP… ·  · 2017-01-03The assembler translates the assembly language program text which is given

18. What are the kinds of interface available in stepper motor?

There are three types of stepper motor interfacing such as

1. Universal

2. Unipolar

3. Bipolar

It can be identified by the number of connections to the motor. An universal stepper motor

has eight, unipolar has six and bipolar has four connections.

19. What are the differences between ROM and RAM memory?

S.No ROM RAM

1. It is a nonvolatile memory. It is volatile memory.

2. When power off, it does not

lose its content.

When power off, it will lose its

content

3. It is also called as Primary

Memory

It is also called as Secondary

Memory.

20. What are the types of ADC chips available?

ADC chips can be classified into two types.

1. Parallel ADC Chips

2. Serial ADC Chips

In parallel ADC chips there are 8 or more pins dedicated to bring out the binary data where

in serial ADC chip, only one pin for data out.

PART B

1. Draw the diagram to interface a stepper motor with 8051 microcontroller and explain also

write an 8051 ALP to run the stepper motor in both forward and reverse direction with delay.

MAY/JUNE-2016, NOV/DEC-2015

2. Explain how interrupts are handled in 8051.

3. Write short notes on LCD interface. APR/MAY-2015, MAY/JUNE-15 4. Write notes on 8051 serial port programming. MAY/JUNE-2016

5. Explain about external memory interfacing to 8051. NOV/DEC-13

6. Write notes on 8051 timer and counter programming. APR/MAY-2015

7. Draw and explain the ADC interfacing using 8051. APR/MAY-14

8. Draw and explain the DAC interfacing using 8051.

9. Explain the keyboard interfacing using 8051. NOV/DEC-2015

10. Explain the sensor interfacing using 8051. MAY/JUNE-15