Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

Basic Microprocessor UCCE2043 Practical Assignment

Practical Assignment
Fun with BGC-8088 and EDS8806
This Practical Assignment will contribute 30% to the coursework.
Submit the report before 5.00pm on 15th Apr 2011. Late submission will be
penalized by deduction of 3 marks for every calendar day’s delay.

Question 1: (Refer to Laboratory Experiment 5)

Program 5.3 does not work as intended. Fix the program accordingly.
[5 marks]

Question 2: (Refer to Laboratory Experiment 5)

Integrate the codes in Figure 2 into Program 5.2 so that the microprocessor reads the
combination of DIP switch from Port B and display the corresponding decimal digit on
EDS8806’s 7-segment LED display.

The DIP Switch Pattern and its corresponding 7-Segment Display should be as follow:

DIP Switch from 7-Segment DIP Switch from 7-Segment


MSB to LSB Display MSB to LSB Display
0000 0 0101 5
0001 1 0110 6
0010 2 0111 7
0011 3 1000 8
0100 4 1001 9

PortA equ FF10H


PortB equ FF11H
CWR equ FF13H
Control_byte equ 82H

Mov DX,CWR ;initialize control register


Mov AL,Control_byte ;control byte = 82
Out DX,AL ;write to 8255
Mov DX,PortB ;get address of port B in DX
In AL,DX ;read portB DIP switches
Mov DX,PortA ;get address of port A in DX
Out DX,AL ;display DIP switches value on portA

Figure 2
[8 marks]
Basic Microprocessor UCCE2043 Practical Assignment

Question 3:

7-Segment Display is commonly used in all sort of electronic devices. “Multiplexing”, a


method based on the idea of Persistence of vision of the human eyes is usually used to drive
multiple 7-Segment Displays.

Carefully study materials presented in Appendix A. Write a program that counts from 00 to
99 and display the values on the 7-Segment Display on EDS8806 Board.
[12 marks]

Question 4:

Modify your program in Question 3 so that the 7-segments will display a continuous count up
when the SW1 is hold and count down when the SW2 is hold.

a) The process of counting up and down should begin from the current value as
displayed on the 7-Segment Display.
b) When either SW1 or SW2 is released, the 7-Segment Display should retain the last
count values.
[5 marks]

Reports

• Form a group that consists of 2 persons and submit a common report. Generally, all
group members in the same group will be awarded the same marks. However, peer
review and/or interview may be conducted at any time. Non-contributors will be
penalized with their marks deducted.
• In your report, answer the questions straight to the point by providing just the
Assemble Language source codes together with remarks.
o Remarks should be provided on every line of codes and every section of
codes.
• Print your report on both side of A4 paper and staple-bind on the top left hand corner.
• A CD/DVD that contain the source codes must be submitted together with the report
o Create a folder for each of the question and named the folders as Q1, Q2, Q3
and Q4
o Save all the .asm files, .exe files, .bin files and .txt files in respective folders
with names Q1.*, Q2.*, Q3.* and Q4.*
 .txt is the exact duplication of respective .asm file with all the remarks
deleted.

[Total: 30 marks]

2
Basic Microprocessor UCCE2043 Practical Assignment
APPENDIX A (extracted from Barry B. Brey)
Basic Microprocessor UCCE2043 Practical Assignment

You might also like