EasyManuals Logo

Tandy 1000 Programmer's Reference Guide

Default Icon
251 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #113 background imageLoading...
Page #113 background image
Chapter
1
I
System
Calls
Read
Read
from
a
File
or
Device Function Call
3FH
Transfers a specified number
of
bytes from
a
file into
a
buffer lo-
cation. It is not guaranteed that all bytes will be read. At most
1
line
of
text will be read from the keyboard. If the returned value
for number
of
bytes read is zero, then the program tried
to
read
from the end of file.
All I/O is done using normalized pointers; no segment wrap-
around will occur. MS-DOS takes the pointer you specify in
DS:DX and modifies it
so
that DX
is
OOOFH
or
smaller.
Entry Conditions:
AH
=
3FH
DS:DX
=
pointer
to
buffer
CX
=
number of bytes to read
BX
=
file handle for
the
file
to read
Exit Conditions:
Carry set:
Carry not set:
Error Returns:
AX
=
6
AX
=
error
code
AX
=
number of bytes read
Invalid handle. The handle passed in BX is not currently
open.
Access denied. The handle passed in BX was opened in
a
mode that did not allow reading.
AX
=
5
Example:
Read
equ
3FH
Ids dx,
buff
er
mov
cx, coun
t
mov
bx,handIe
mov
ah,Read
int
21
H
111

Other manuals for Tandy 1000

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Tandy 1000 and is the answer not in the manual?

Tandy 1000 Specifications

General IconGeneral
ProcessorIntel 8088
Processor Speed4.77 MHz
RAM128 KB (expandable to 640 KB)
Operating SystemMS-DOS 2.11
ManufacturerTandy Corporation
Release Year1984
StorageSingle or double 5.25" floppy disk drive (360 KB), optional hard drive
SoundTandy 3-voice sound
PortsParallel, Serial
GraphicsCGA (Color Graphics Adapter)
Graphics Modes320x200, 640x200

Related product manuals