Final Exam QP - Microprocessor and Microcontroller - Sep - 2023
Final Exam QP - Microprocessor and Microcontroller - Sep - 2023
September 2023
Instructions to candidates:
1. Please check that this examination paper consists of FIVE (5) pages before you
begin the examination.
3. All necessary working steps must be shown clearly. The omission of essential
working steps will result in a loss of marks.
Question 1
(a) List down FOUR (4) differences between the microprocessor and the
microcontroller.
(CLO1/PLO1/C2– 8 marks)
(c) Describe the benefits of applying an assembler than the binary program.
(CLO1/PLO1/C2– 2 marks)
(d) Pipelining is a technique in which a given task is divided into several subtasks that
must be performed in a sequence. Consider a pipeline having 4 phases with a
duration of 110, 80, 100 and 90 ns. Given latch delay is 4 ns. Evaluate:
(i) The pipeline cycle time.
(CLO1/PLO1/C3 – 2 marks)
(CLO1/PLO1/C3 – 2 marks)
(CLO1/PLO1/C3 – 3 marks)
(CLO1//PLO1/C3 – 2 marks)
(CLO1/PLO1/C3 – 2 marks)
[25 marks]
Page 2 of 5
TEL205/03 Microprocessor and Microcontroller Sep 2023
Question 2
(c) Page size refers to the size of a page, a block of stored memory. Page size affects
the memory needed and space used when running programs. For a programme
memory that has a page size of 1K, determine the start and end addresses.
(CLO2/PLO2/C3 – 9 marks)
(CLO2/PLO2/C3 – 9 marks)
[25 marks]
Question 3
(a) Create a program that does the addition of 15H and 45H, and shifts the summation
value into the 13H register. Write the task descriptions done by the microcontroller
for each of the program code.
(CLO3/PLO3/C3 – 15 marks)
Page 3 of 5
TEL205/03 Microprocessor and Microcontroller Sep 2023
(b) In accordance to the program written for Question 3(a), formulate and state the
final data stored in the 13H register. Suggest the answer in decimal base and prove
the mathematical measure clearly.
(CLO1/PLO1/C4 – 5 marks)
(c) Estimate the data length for the program counter in PIC18.
(CLO1/PLO1/C3 – 1 mark)
(d) Measure and decide the maximum program memory address than can be
accessed by the program counter of PIC18.
(CLO2/PLO2/C4 – 4 marks)
[25 marks]
Question 4
(a) In reference to Figure Q4(a), write an embedded C code which toggles LED1 at
an interval of 1 second. Assume that the operating frequency is 20 MHz.
Figure Q4(a)
(CLO3/PLO3/C4 – 19 marks)
Page 4 of 5
TEL205/03 Microprocessor and Microcontroller Sep 2023
[25 marks]
Page 5 of 5