Sei sulla pagina 1di 15

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

CHAPTER 3

DOS stands for Disk Operating Systems. It

could be an acronym for any OS, but it is most


often used as a shorthand for MS-DOS
(Microsoft Disk Operating Systems).

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

DOS

A set of functions for using I/O devices


Can be used for displaying data
Can be used for inputting data from the

keyboard

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

BIOS and DOS function calls

for
MOV AH ,4CH
INT 21H

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

The .EXIT command is a shorthand notation

i) Read the keyboard with echo

MOV AH, 01
INT 21H
This call exits with the ASCII value of the key
pressed, being available in AL .
The key pressed is also echoed on the screen
.

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

DOS Function Call

ii) Read Keyboard without echo

MOV AH, 08
INT 21H
This call exits with the ASCII value of the key
pressed being available in AL .
The key pressed is not echoed on the
screen

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

DOS Function Call Contd.

iii) Write a character to the standard display

unit.
For this ,the ASCII value of the character to be
displayed should be in DL

Copyright Dorling Kindersley India Pvt Ltd

Displaying a character

MOV DL, S

MOV AH, 02
INT 21H

The x86 Microprocessor - Lyla B Das

iv) Display a character string on the standard

display unit
The logical address DS:DX should point to the
beginning of the string .
This is to be followed by the following
instructions
MOV AH, 09
INT 21H

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

STRING DISPLAY

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

Table 3.1 | List of 8086 Data Transfer


Instructions with Format and Function

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

Table 3.1 | List of 8086 Data Transfer


Instructions with Format and Function
contd

10

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

Table 3.3 | List of Conditional Jump


Instructions which Cater to Unsigned
Arithmetic and which
Directly Address Flags or Registers

11

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

List of Conditional Jumps Contd.

12

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

Example 3.10a

13

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

Example 3.10b Using Register


Relative Mode

14

The x86 Microprocessor - Lyla B Das

Copyright Dorling Kindersley India Pvt Ltd

Example 3.4a

15

Potrebbero piacerti anche