CS-401 Computer Architecture & Assembly Language Programming

Slides:



Advertisements
Similar presentations
Register In computer architecture, a processor register is a small amount of storage available on the CPU whose contents can be accessed more quickly than.
Advertisements

DOS and BIOS Interrupts DOS and BIOS interrupts are used to perform some very useful functions, such as displaying data to the monitor, reading data from.
CEN 226: Computer Organization & Assembly Language :CSC 225 (Lec#3) By Dr. Syed Noman.
Flow Diagram: Push flags, CS, IP Pop IP,CS,flags Push AX,BX,CX,DX,ES,DS,SI,DI,BP POP BP,DI,SI,DS,ES,DX,CX,BX,AX.
Azir ALIU 1 What is an assembly language?. Azir ALIU 2 Inside the CPU.
Princess Sumaya University
8.7 Memory management Program E Program D System memory DOS INT 21, function 48H: Allocate Memory Specification: allocates a number of memory paragraphs.
Microprocessor Systems Design I Instructor: Dr. Michael Geiger Spring 2013 Lecture 4: 80386DX memory, addressing.
Microprocessor Systems Design I Instructor: Dr. Michael Geiger Spring 2014 Lecture 4: x86 memory.
Riyadh Philanthropic Society For Science Prince Sultan College For Woman Dept. of Computer & Information Sciences CS 251 Introduction to Computer Organization.
CEN 226: Computer Organization & Assembly Language :CSC 225 (Lec#8) By Dr. Syed Noman.
CE302 Outline Multiplication Division Program Segment Prefix Command Line Parameters.
An Introduction to 8086 Microprocessor.
Introduction to Subroutines. All the combinations in which a subroutine can be written 1. The subroutine may be: a. Internal or b. External 2. The type.
1/2002JNM1 Positional Notation (Hex Digits). 1/2002JNM2 Problem The 8086 has a 20-bit address bus. Therefore, it can access 1,048,576 bytes of memory.
Programming the Microprocessor A Course in Microprocessor Electrical Engineering Dept. University of Indonesia.
1 Screen and Keyboard Operations Suthida Chaichomchuen
Text-Mode Programming Question #1 What are the three levels of access to the video display when writing characters on the screen in text mode?
CET 3510 Microcomputer Systems Tech. Lecture 2 Professor: Dr. José M. Reyes Álamo.
UHD:CS2401: A. Berrached1 The Intel x86 Hardware Organization.
Video systems. Lesson plan Review the code for the previous exercise Video systems Review for midterm exam.
Writing and Reading Files Methods for processing disk files File Control Blocks (FCBs) –Supported by DOS –Can address drives and filenames.
COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE LECTURE # 4 BY MUHAMMAD JAFER 1.
10H Interrupt. Option 0H – Sets video mode. Registers used: – AH = 0H – AL = Video Mode. 3H - CGA Color text of 80X25 7H - Monochrome text of 80X25 Ex:
Assembly Language programming
4. Kernel and VGA ENGI 3655 Lab Sessions. Richard Khoury2 Textbook Readings  None.
Control Structure vs. Assembly Language NASM. If-then-else If conditional then then_actions jump to endif else else_actions endif.
Computer and Information Sciences College / Computer Science Department CS 206 D Computer Organization and Assembly Language.
Riyadh Philanthropic Society For Science Prince Sultan College For Woman Dept. of Computer & Information Sciences CS 251 Introduction to Computer Organization.
1 x86 Programming Model Microprocessor Computer Architectures Lab Components of any Computer System Control – logic that controls fetching/execution of.
File Operations. FILE PROCESSING For the purposes of the following discussion, reading means copying all or part of an existing file into memory Writing.
CS-401 Computer Architecture & Assembly Language Programming Lecture-16 Display Memory.
Computer Architecture and Assembly Language
Instruction set Architecture
Presentation on Real Mode Memory Addressing
Microprocessor Systems Design I
Assembly Language programming
Assembly Language Programming Part 3
8086 Microprocessor.
Computer Organization & Assembly Language Chapter 3
ADDRESSING MODES.
ADDRESSING MODES.
University of Gujrat Department of Computer Science
CS-401 Computer Architecture & Assembly Language Programming
CS-401 Computer Architecture Assembly Language Programming
Symbolic Instruction and Addressing
Introduction to Assembly Language
CS-401 Computer Architecture & Assembly Language Programming
8086 Registers Module M14.2 Sections 9.2, 10.1.
CS-401 Computer Architecture & Assembly Language Programming
Interrupt Mechanism Interrupt Compared With Procedures Call MyProc
Morgan Kaufmann Publishers Computer Organization and Assembly Language
Symbolic Instruction and Addressing
CS-401 Computer Architecture & Assembly Language Programming
Shift & Rotate Instructions)
Symbolic Instruction and Addressing
CNET 315 Microprocessor & Assembly Language
Unit:08 Software Interrupts
Computer Architecture CST 250
CS-401 Assembly Language Programming
Microprocessor and Assembly Language
CS-401 Computer Architecture & Assembly Language Programming
CS-401 Computer Architecture & Assembly Language Programming
UNIT-II Assembly Language Programs Involving Logical
Chapter 6 –Symbolic Instruction and Addressing
CS-401 Computer Architecture & Assembly Language Programming
CS-401 Computer Architecture and Assembly Language Programming
Microprocessor and Assembly Language
CS-401 Computer Architecture & Assembly Language Programming
(The Stack and Procedures)
Presentation transcript:

CS-401 Computer Architecture & Assembly Language Programming Lecture-36 Secondary Storage

Lets revise the last lecture

Logical view of secondary storage

int 0x21 DOS Services Create Truncate File AH = 0x3C CX = file attribute DS:DX = ASCII file name Return On success CF = clear AX = file handle On error CF = set AX = error code

int 0x21 DOS Services Open Existing File AH = 0x3D AL = access and sharing mode DS:DX = ASCII file name CL = attribute mask Return On success CF = clear AX = file handle On error CF = set AX = error code

int 0x21 DOS Services Close File AH = 0x3D BC = file handle Return On success CF = clear AX = undefined On error CF = set AX = error code

int 0x21 DOS Services Read File AH = 0x3F BX = file handle CX = number of bytes to read DS:DX = buffer Return On success CF = clear AX = number of bytes actually read On error CF = set AX = error code

int 0x21 DOS Services Write File AH = 0x40 BX = file handle CX = number of bytes to write DS:DX = buffer Return On success CF = clear AX = number of bytes actually written On error CF = set AX = error code

int 0x21 DOS Services Delete File AH = 0x41 DS:DX = ASCII file name CL = attribute mask Return On success CF = clear AX = undefined On error CF = set AX = error code

Seek –Set Current File Position int 0x21 DOS Services Seek –Set Current File Position AH = 0x42 AL = origin of move (00=start,01=current,02=end) BX = file handle DS:DX = offset from origin Return On success CF = clear DX:AX = new file position On error CF = set AX = error code

int 0x21 DOS Services Get File Attributes AH = 0x43 AL = 0x00 DS:DX = ASCII file name Return On success CF = clear CX = file attributes On error CF = set AX = error code (#01680)

int 0x21 DOS Services Set File Attributes AH = 0x43 AL = 0x01 CX = file attributes DS:DX = ASCII file name Return On success CF = clear AX = undefined On error CF = set AX = error code

PSP

PSP 0x00 – 0x7F 0x80 0x80-(0x80+count) Count DOS Information Chars . . . . .

int 0x21 DOS Services Exec- Load and Execute AH = 0x4B AL = type (0x00 load and exec, 0x01 load) DS:DX = ASCII file name ES:BX = parameter block Return On success CF = clear On error AX = error code

int 0x21 DOS Services 0x01 0x02 0x06 0x0A 0x0E 0x12 0x16 Command Tail First FCB Second FCB SS:SP SS:IP Environment

int 0x21 DOS Services Allocate Memory AH = 0x48 BX = number of paragraphs Return On success CF = clear AX = segment of memory block On error CF = set AX = error code BX = largest available block

int 0x21 DOS Services Free Memory AH = 0x49 ES = segment of block to free Return On success CF = clear On error CF = set AX = error code

int 0x21 DOS Services Resize Memory Block AH = 0x4A BX = number of paragraphs ES = segment of block Return On success CF = clear On error CF = set AX = error code BX = maximum paragraphs available