EasyManua.ls Logo

Oki 182 - Page 52

Oki 182
175 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
Loading...
-
ML182/183
________________
_
-
-
Computers cannot understand letters. They
use
only
numbers, more
specifically, binary numbers
(1
s and
as).
When carrying
out
an
-
LPRINT command, the computer
s.ends
the printer a code number
for each character (letter, symbol, punctuation mark)
within
the
-
quotation marks.
As
the printer receives each number,
it
prints the
-
dot
pattern associated
with
that number.
The American Standard Code for Information Interchange (before
-
known
as
ASCII)
is
the standard code
used
by
computers. Appendix
D gives the
ASCII
code numbers along
with
their hexadecimal,
-
binary, and decimal equivalents. You
can
enter these
ASCII
numbers
directly in your LPRINT statement by using the CHR$ (Character
-
Stri
ng)
function.
-
The CHR$ command
sends
the
ASCII
command in parentheses to
the printer.
For
example,
we
can
write a program this way:
-
LPRLI;:-lT·
CHR$(79);CH R$(75);CHR$(73);CHR$ (68);CHR$(65);
CHJ!$<84);
OtfR$
(65) .
;,:::",;'..
...
,)h
-
This
is
obviously a tedious way to write, but you need to understand
-
the concept when you
want
to
use
certain commands.
Keep in mind that there
is
a big difference between
ASCII
code
-
numbers and numbers that
are
printable characters.
For
example,
if
you want to print the number 1 using
an
LPRINT statement, you
-
would
type this:
-
LPRJ,,Il>jTCHR$(49)
You can also print numbers and symbols by putting them
within
-
quotes, like this:
-
[PRINT"1
"
So
far,
we have discussed printable characters, ASCII codes located
-
between decimal 32 and decimal 127. Non-printable codes, located
between a and 31,
do
not tell the printer to print something. They
instruct the printer
how
to print something. The ASCII chart in the
back
of
this handbook shows that these codes have abbreviations,
such
as
FF
and
US.
Some
of
these abbreviations make
sense
(FF,
for
instance, stands for form feed) but others
do
not unless you
are
a
telecommunications expert.
-
-
40

Related product manuals