



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




Semester 1 Examinations 2008/
Module Code: ELTR
School: Electrical and Electronic Engineering
Programme Title: Bachelor of Engineering in Electronic Engineering
Programme Code: EELXE_7_Y
External Examiner(s): Mr D Denieffe Dr P O’Sullivan
Internal Examiner(s): Mr J O’Sullivan
Instructions: Attempt any three questions. All questions carry equal marks.
Duration: Two hours
Sitting: Winter 2008
Requirements for this examination: N/A
Note to Candidates: Please check the Programme Title and the Module Title to ensure that you have received the correct examination paper. If in doubt please contact an Invigilator.
Q1 (a) Draw a simple diagram showing the main parts of a microcomputer. What do you understand by the concept of such a device being used as an embedded controller? [5 marks]
(b) What do you understand by the term two’s complement as applied to numbers in a computer? List in ascending order of magnitude the following two’s complement numbers: F286 5E2B 9D4C 0000 1C3A B24E Express the smallest of these numbers as a 24-bit value. [5 marks]
(c) Using one sentence in each case explain the effect on the X, N, Z, V and C flags of the instruction ADD.W D0,D1 if D0.W = $6A25 and D1.W = $D4E7 [5 marks]
(d) In your own words, explain how the instruction CMP.W D1,D0 works. Assuming D0.W = $8765 and D1.W = $5678, explain if the program will branch to Label after the following program segment is executed. CMP.W D1,D BGE Label [5 marks]
Q2 (a) What is the difference between a resident assembler and a cross-assembler? [3 marks]
(b) Outline any advantages of using a cross-assembler over a resident assembler. [3 marks]
(c) Draw a flowchart to show how you would solve the following programming task: It is required to check the 16-bit two’s complement value stored in location $400500 and if it is negative, replace it with its positive equivalent. [6 marks]
(d) Write a program in assembly language with appropriate comments to carry out this task on a 68000-based computer. [8 marks]
Q3 (a) Draw a detailed block diagram showing the internal structure of the 68000 MPU and outline the function of each block. [10 marks]
(b) Explain what is meant by the term fetch-execute cycle as it applies to the operation of a computer. [4 marks]
(c) The following is a line of code from a 68000 program listing: 00400400 A07B0064 ADD.W #100,D Making reference to the block diagram in (a), briefly describe in your own words, the fetch-execute cycle for this instruction. [6 marks]