EasyManuals Logo

Tandy 1000 Basic Reference Manual

Default Icon
411 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 #359 background imageLoading...
Page #359 background image
Chapter
11
I
Technical Information
How
Variables are Stored
BASIC stores variables in its data segment
as
follows:
Byte
Byte
0
Bytes
1
and
2
Byte
3
Byte
4
+
integer stored
in Byte
3
Byte
4
+
length
Contents Description
Type
Identifies the type
of
vari-
able stored
at
this location:
2
integer
3
string
4
single precision
8
double precision
Name The first 2 characters
of
the
variable name.
Integer Integer is the number
of
ad-
3
-
38
ditional characters in the
variable name.
Name The remainder
of
the vari-
able name is stored at bytes
4
+
the integer stored in
Byte
3.
The contents
of
the variable
are stored in the bytes im-
mediately following the vari-
able name. The data can be
2,
3,
4,
or
8
bytes in length,
depending
on
the type
of
data.
Data
At
least
3
bytes are required
to
store any variable name.
A
1-
or
2-character variable name occupies exactly
3
bytes. Bytes
1
and
2
for
the
first
2 characters and Byte
3
to contain a zero to indi-
cate that there are no additional characters in the variable
name. If the variable name only contains
1
or
2 characters, the
data is stored beginning at Byte
4.
As you can see, the location
of
the first actual byte
of
data depends on the length
of
the vari-
able name. VARPTR returns the offset
of
the first actual byte
of
data, not the offset
of
the beginning
of
the storage area.
357

Table of Contents

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