8051 MCQ
8051 MCQ
___________________________________________________________________________________
Subject:-Microcontroller Unit:-1
Answer: d
Explanation: Atmel series AT89C2051 and Philips family P89C51RD2 are the two most common
microcontrollers of 8051 families.
6. How are the status of the carry, auxiliary carry and parity flag affected if the write instruction
MOV A,#9C
ADD A,#64H
a) CY=0,AC=0,P=0
b) CY=1,AC=1,P=0
c) CY=0,AC=1,P=0
d) CY=1,AC=1,P=1
Answer: b
Explanation: On adding 9C and 64, a carry is generated from D3 and from the D7 bit so CY and AC are
set to 1. In the result, the number of 1’s present are even so parity flag is set to zero.
7. How are the bits of the register PSW affected if we select Bank2 of 8051?
a) PSW.5=0 and PSW.4=1
b) PSW.2=0 and PSW.3=1
c) PSW.3=1 and PSW.4=1
d) PSW.3=0 and PSW.4=1
Answer: d
Explanation: Bits of PSW register are CY, AC, F0, RS1, RS0, OV, -, P so for selecting bank2 RS1=1 and
RS0=0 which are fourth and third bit of the register respectively.
9. On power up, the 8051 uses which RAM locations for register R0- R7
a) 00-2F
b) 00-07
c) 00-7F
d) 00-0F
Answer:b
10. How many bytes of bit addressable memory is present in 8051 based microcontrollers?
a) 8 bytes
b) 32 bytes
c) 16 bytes
d) 128 bytes
Answer: c
Explanation: 8051 microcontrollers have 16 bytes of bit addressable memory.
Answer:d
Explanation: The timer is an up-counter and generates an interrupt when the count has reached FFFFH.
Practice Test - Chapter 1Practice Test - Chapter 2Practice Test - Chapter 3Practice Test - Chapter 4Practice Test – C
12)The external interrupt that has the lowest priority among the following is
a) TF0
b) TF1
c) IE1
d) NONEhapter 5Practice Test - Chapter 6Practice Test - Chapter 7Practice Test - Chapter 8Practice Test - Chapter
9Practice Test - Chapter 10Mock Test - Chapter 1Mock Test - Chapter 2Mock Test - Chapter 3Mock Test - Chapter
Answer: c
Explanation: The order of given interrupts from high to low priority is TF0, IE1 and TF1. ock Test - Chapter
13)Among the five interrupts generated by 8051, the lowest priority is given to the interrupt
a) IE0
b) TF1
c) TF0
d) RI
Answer:d
Explanation: The interrupt, RI=TI (serial port) is given the lowest priority among all the interrupts.
14)Among the five interrupts generated by 8051, the highest priority is given to the interrupt
a) IE0
b) TF1
c) TF0
d) IE1
Answer: a
Explanation: The interrupt, IE0(External INT0) is given the highest priority among all the interrupts.
15)All the interrupts are enabled using a special function register called
a) interrupt priority register
b) interrupt register
c) interrupt function register
d) interrupt enable register
Answer: d
16)The number of bytes stored on the stack during one operation of PUSH or POP is
a) 1
b) 2
c) 3
d) 4
Answer: a
Explanation: As 8051 stack operations are 8-bit wide i.e. in an operation using PUSH or POP instruction,
one byte of data is stored on a stack or retrieved from the stack. For implementing 16-bit operations, two
8-bit operations are cascaded.
Answer: c
Explanation: The PUSH instruction follows two steps.
1. Increment stack by 1
2. Store 8-bit content of the 8-bit address specified in the instruction to the address pointed to by SP.
Answer: b
Explanation: The stack pointer(SP) is an 8-bit register and is initialized to internal RAM address 07H after
reset.
19)8051 stack is
a) auto-decrement during PUSH operations
b) auto-increment during POP operations
c) auto-decrement during POP operations
d) auto-increment during PUSH operations
Answer: d
Explanation: The 8051 stack is opposite to that in 8085 or 8086 i.e. in 8085 it is auto-decrement while in
8051 it is auto-increment during PUSH operations.
21)The symbol, ‘addr 16’ represents the 16-bit address which is used by the instructions to specify the
a) destination address of CALL
b) source address of JUMP
c) destination address of call or jump
d) source address of call or jump
Answer: c
Explanation: The symbol, ‘addr 16’ represents the 16-bit destination address which is used by the LCALL
or LJMP instruction to specify the call or jump destination address, within 64 Kbytes program memory.
Answer: c
Explanation: Only internal data RAM and SFRS can be directly addressed in direct addressing mode.
23) The address register for storing the 16-bit addresses can only be
a) stack pointer
b) data pointer
c) instruction register
d) accumulator
Answer: b
Explanation: The address register for storing the 16-bit addresses can only be data pointer
30. The only memory which can be accessed using indexed addressing mode is
a) RAM
b) ROM
c) Main memory
d) Program memory
Answer: d
Explanation: Only program memory can be accessed using the indexed addressing mode
31. The data address of look-up table is found by adding the contents of
a) accumulator with that of program counter
b) accumulator with that of program counter or data pointer
c) data register with that of program counter or accumulator
d) data register with that of program counter or data pointer
Answer: b
Explanation: The look-up table data address is found out by adding the contents of register accumulator
with that of the program counter or data pointer.