MTL200 Exam Questions and Answers
Graded A+
N/A - Correct answer-
What is the difference between volatile and non volatile memory in
microcontrollers? - Correct answer-Volatile memory (RAM) loses stored data when
power is removed. Non-volatile memory (Flash, EEPROM) retains data even when
power is lost.
How does a microcontroller execute instructions stored in its memory? - Correct
answer-It follows the Fetch-Decode-Execute cycle: Fetch retrieves the instruction,
Decode interprets it, and Execute performs the operation.
Explain the role of the Control Unit (CU) in a microcontroller? - Correct answer-
The CU directs instruction execution, manages communication between ALU,
registers, and memory, and controls data flow.
What is the purpose of the Status Register in a microcontroller? - Correct answer-It
stores flags that indicate operation results, such as carry, zero, and overflow, which
are used for conditional execution.
©COPYRIGHT 2025, ALL RIGHTS RESERVED 1
, How many clock cycles does it take for an instruction to execute on an
ATmega328P? - Correct answer-Most AVR instructions execute in 1 clock cycle,
except for branching/jump instructions, which take 2-3 cycles.
Name and explain three types of memory used in the ATmega328P
microcontroller? - Correct answer-Flash (stores program code), SRAM (stores
variables during execution), and EEPROM (stores data that must be retained after
power loss).
What is the function of the Stack Pointer (SP), and how does it change when
pushing and popping data? - Correct answer-The SP holds the top address of the
stack. Pushing data decrements SP, while popping data increments SP.
What is the difference between general purpose registers and special function
registers? - Correct answer-General purpose registers (R0-R31) store temporary
data and arithmetic results, while special function registers (e.g., SREG, SP)
control system functions.
What is the function of the PINx register in ATmega328P? - Correct answer-It
reads the current logic level of an input pin.
How do you configure Port D, Pin 5 as an output and set it to HIGH in C? -
Correct answer-Use DDRD |= (1 << PD5); to set PD5 as an output and PORTD |=
(1 << PD5); to set it HIGH.
©COPYRIGHT 2025, ALL RIGHTS RESERVED 2
Graded A+
N/A - Correct answer-
What is the difference between volatile and non volatile memory in
microcontrollers? - Correct answer-Volatile memory (RAM) loses stored data when
power is removed. Non-volatile memory (Flash, EEPROM) retains data even when
power is lost.
How does a microcontroller execute instructions stored in its memory? - Correct
answer-It follows the Fetch-Decode-Execute cycle: Fetch retrieves the instruction,
Decode interprets it, and Execute performs the operation.
Explain the role of the Control Unit (CU) in a microcontroller? - Correct answer-
The CU directs instruction execution, manages communication between ALU,
registers, and memory, and controls data flow.
What is the purpose of the Status Register in a microcontroller? - Correct answer-It
stores flags that indicate operation results, such as carry, zero, and overflow, which
are used for conditional execution.
©COPYRIGHT 2025, ALL RIGHTS RESERVED 1
, How many clock cycles does it take for an instruction to execute on an
ATmega328P? - Correct answer-Most AVR instructions execute in 1 clock cycle,
except for branching/jump instructions, which take 2-3 cycles.
Name and explain three types of memory used in the ATmega328P
microcontroller? - Correct answer-Flash (stores program code), SRAM (stores
variables during execution), and EEPROM (stores data that must be retained after
power loss).
What is the function of the Stack Pointer (SP), and how does it change when
pushing and popping data? - Correct answer-The SP holds the top address of the
stack. Pushing data decrements SP, while popping data increments SP.
What is the difference between general purpose registers and special function
registers? - Correct answer-General purpose registers (R0-R31) store temporary
data and arithmetic results, while special function registers (e.g., SREG, SP)
control system functions.
What is the function of the PINx register in ATmega328P? - Correct answer-It
reads the current logic level of an input pin.
How do you configure Port D, Pin 5 as an output and set it to HIGH in C? -
Correct answer-Use DDRD |= (1 << PD5); to set PD5 as an output and PORTD |=
(1 << PD5); to set it HIGH.
©COPYRIGHT 2025, ALL RIGHTS RESERVED 2