Docsity

Fetch-Execute Cycle - Microprocessor Systems - Exam, Exams of Microprocessors

Toggle sidebar
bg1
CORK INSTITUTE OF TECHNOLOGY
INSTITIÚID TEICNEOLAÍOCHTA CHORCAÍ
Autumn Examinations 2011
Module Title: Microprocessor Systems 1
Module Code: ELTR6016
School: Electrical and Electronic Engineering
Programme Title: Bachelor of Engineering in Electronic Engineering
Programme Code: EELXE_7_Y2 EELES_8_Y2
External Examiner(s): Dr A Donnellan
Mr I Kennedy
Internal Examiner(s): Mr J O’Sullivan
Instructions: Attempt any three questions. All questions carry equal marks.
Ensure you include the Return Sheet with your answer book.
Duration: Two hours
Sitting: Autumn 2011
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.
You are expected to present your material in a neat and tidy fashion.
Start each question on a new page.
Remember that there is plenty of time – two hours for three questions.
pf3
pf4
pf5

Partial preview of the text

Download Fetch-Execute Cycle - Microprocessor Systems - Exam and more Exams Microprocessors in PDF only on Docsity!

CORK INSTITUTE OF TECHNOLOGY

INSTITIÚID TEICNEOLAÍOCHTA CHORCAÍ

Autumn Examinations 2011

Module Title: Microprocessor Systems 1

Module Code: ELTR

School: Electrical and Electronic Engineering

Programme Title: Bachelor of Engineering in Electronic Engineering

Programme Code: EELXE_7_Y2 EELES_8_Y

External Examiner(s): Dr A Donnellan

Mr I Kennedy

Internal Examiner(s): Mr J O’Sullivan

Instructions: Attempt any three questions. All questions carry equal marks. Ensure you include the Return Sheet with your answer book.

Duration: Two hours

Sitting: Autumn 2011

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.

You are expected to present your material in a neat and tidy fashion. Start each question on a new page. Remember that there is plenty of time – two hours for three questions.

Q1 (a) List the main parts of a microcomputer and the function performed by each part. [4 marks]

(b) Table 1 below shows a memory printout as seen on the Flight-68K system. On your answer book write down the following: i) the word at location $ ii) the byte at location $40051C iii) the longword at location $ iv) the byte at location $400509 [4 marks]

(c) What is meant by a machine program? In relation to machine programs briefly explain the terms opcode and operand. [3 marks]

(d) Table 2 below shows a printout of a program segment as seen on the Flight-68K system. There are four separate fields (or columns) of information in this table. Identify and explain the information contained in each of these four fields. [4 marks]

(e) Study each line of data in Table 2 and use it to fill in the memory diagram on the Return Sheet accompanying this paper. When the memory diagram is complete, write down the program instructions on the right hand side of the diagram, using curly brackets to associate one or more memory values with each instruction as appropriate. Mark all opcodes in the memory diagram. [5 marks]

00400500 12AB 47B2 9AD3 00A9 2D5B 1CA3 FE15 3C

00400510 E83C 5201 B8D4 1E5D 3AC0 0000 41CB 9AE

Table 1

00400400 303900400500 MOVE.W $400500,D

00400406 044061A8 SUB.W #25000,D

0040040A 4440 NEG.W D

0040040C 33C000400502 MOVE.W D0,$

00400412 4E4B TRAP

00400414 0000 DC.W 0

Table 2

Q4 (a) Explain how the CMP instruction works and state the advantage of using this instruction in assembly language programs. [2 marks]

(b) Assuming the 8-bit values $7B and $E3 are held in D0 and D1 respectively, what will be the effect on the X, N, Z, V and C flags when the instruction CMP.B D0, D1 is carried out. Show any calculations used and justify your conclusion for each flag. [5 marks]

(c) Rank in ascending order of magnitude the following list of 16-bit numbers assuming they represent two’s complement signed values: 4D3A B79D 6A8E 0000 917C E8FF [2 marks]

(d) Describe briefly the difference between the following pairs of similar looking instructions: i) MOVE.W #400500,D MOVE.W $400500,D ii) MOVE.W A0,D MOVE.W (A0),D0 [4 marks]

(e) The program segment in Table 3 below is designed to fill a block of locations in memory with a given fixed value. Using one sentence for each line in the program explain in the context of the overall task, the purpose of each instruction in the table. [7 marks]

FILBLK MOVEA.L #$400500,A

MOVE.W #500,D

MOVE.W #$AAAA,D

FILNXT MOVE.W D1,(A0)+

SUB.W #1,D

BNE FILNXT

TRAP

Table 3

CORK INSTITUTE OF TECHNOLOGY

INSTITIÚID TEICNEOLAÍOCHTA CHORCAÍ

Autumn Examinations 2011

Module Title: Microprocessor Systems 1

RETURN SHEET

Q.1(e)

Memory Diagram Program Instructions

40040A

40040C

40040E

Name: Return this sheet with your answer book