0% found this document useful (0 votes)
7 views

Week5 Tutorial Chapter2

Uploaded by

zhiluke02
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views

Week5 Tutorial Chapter2

Uploaded by

zhiluke02
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 32

PRINCIPLES OF COMPUTER AND

COMPOSITION

Course Information

Dr. Yiju Wang


School of Aerospace and Engineering, Xiamen University
[email protected]
Office: A1-425
Tutorial/Lab
2

 1. Install Dosbox
Tutorial/Lab
3

 1. Install Dosbox
Tutorial/Lab
4

 2. Mount Masm
 Mount c directory of masm
 C:
 Debug
 R
 R ax
 R bx
A
T
5
6
Tutorial/Lab
7

 3. Read and try some DEBUG Commands


Tutorial/Lab
8

 3. Read and try some DEBUG Commands


Tutorial/Lab
9

 4. Try following Debug commands


 R
 R AX
 R BX
 A
 T=0100
 T=0100 3
Tutorial/Lab
10

 5. Understand the Codes for the Flag Register


Commands
Tutorial/Lab
11

 5. Understand the Codes for the Flag Register


Commands
12
13
14
15
16
Tutorial/Lab
17

 6. Fill the table manually, then check your result


with computer.

ADD AL,BL CF OF SF AF PF ZF
12H+34H
56H+78H
9AH+12H
BCH+DEH
F0H+12H
9AH+BCH
Tutorial/Lab
18

 6. Fill the table manually, then check your result


with computer.

ADD AL,BL CF OF SF AF PF ZF
12H+34H
56H+78H
9AH+12H
BCH+DEH
F0H+12H
9AH+BCH
Tutorial/Lab
19

 6. Solution
Tutorial/Lab
20

 7. Fill the table manually, then check your result


with computer.

ADD AX,BX CF OF SF AF PF ZF
12H+34H
56H+78H
9AH+12H
BCH+DEH
F0H+12H
9AH+BCH
Tutorial/Lab
21

 7. Fill the table manually, then check your result


with computer.

ADD AX,BX CF OF SF AF PF ZF
12H+34H
56H+78H
9AH+12H
BCH+DEH
F0H+12H
9AH+BCH
22
Tutorial/Lab
23

 7. Solution
Tutorial/Lab
24

 8. If we are dealing with the packed BCD code


Addition, what shall we do? Fill the table manually,
then check your result with computer, assuming the
DAA function and the reason to use DAA are as
follow.
Tutorial/Lab
25

 8. If we are dealing with the packed BCD code


Addition, what shall we do? Fill the table manually,
then check your result with computer, assuming the
DAA function and the reason to use DAA are as
follow.
Tutorial/Lab
26

 8. If we are dealing with the packed BCD code


Addition, what shall we do? Fill the table manually,
then check your result with computer, assuming the
DAA function and the reason to use DAA are as
follow.
Tutorial/Lab
27

 8. If we are dealing with the packed BCD code


Addition, what shall we do? Fill the table manually,
then check your result with computer, assuming the
DAA function and the reason to use DAA are as
follow.
Tutorial/Lab
28

 8. If we are dealing with the packed BCD code


Addition, what shall we do? Fill the table manually,
then check your result with computer, assuming the
DAA function and the reason to use DAA are as
follow.
Tutorial/Lab
29

 8. If we are dealing with the packed BCD code


Addition, what shall we do? Fill the table manually,
then check your result with computer, assuming the
DAA function and the reason to use DAA are as
follow.
Tutorial/Lab
30

AL CF AF
AL=12H, BL=34H ADD AL,BL
DAA
AL=34H, BL=56H ADD AL,BL
DAA
AL=56H,BL=63H ADD AL,BL
DAA
AL=56H,BL=65H ADD AL,BL
DAA
AL=38H,BL=49H ADD AL,BL
DAA
AL=83H,BL=94H ADD AL,BL
DAA
AL=99H,BL=99H ADD AL,BL
Tutorial/Lab
31

 8. Solution
Tutorial/Lab
32

 9. Tell the meaning of the following Debug


commands

You might also like