EasyManua.ls Logo

Commodore Plus 4 - Page 385

Commodore Plus 4
464 pages
Print Icon
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...
The
Printer
373
where
filenumber
is
the
logical
file
number
to
which
output
should
be
directed.
Once
this
command
is
executed,
all
output
that
would
normally
go
to
the
screen
goes
to
the
named
file
instead.
So,
to
list
a
program,
type
0PEN4,4:CMD4:LIST
PRINT#4:CL0SE4
The
PRINT#4
is
needed
to
restore
the
default
output
device
to
the
screen
and
to
tell
the
printer
to
stop
listening
on
the
serial
bus.
When
output
to
the
printer
is
finished,
the
file
should
always be
closed
using
CLOSE
filenumber
where
filenumber
is
the
logical
file
number
used
for
the
printer.
To
ensure
that
the
printer's
internal
buffer
has
been
emptied,
and
a
stop
listening
command
sent,
the
last
data
byte
sent
to
the
printer
should
be
a
carriage
return.
Usually,
in
a
program,
this
happens
to
be
the
case.
When
it
is
not,
the
CLOSE
command
should
be
preceded
by
PRINT*filenumber
The
second
method
of
directing
data
to
the
printer
is
with
the
PRINT#
command.
Every
character
sent
to
the
printer
is
interpreted
as
a
command
or
data.
Generally,
CHR$
codes
of
32
through
127,
and
160
through
255
are
printable
characters
whereas
other
values
may
be
control
characters.
The
inter
pretation
of
CHR$
codes
depends
on
the
particular
printer;
check
your
manual.
For
the
MPS-801,
the
following
control
codes
are
available:
8
=
enter
dot
mode
10
=
linefeed
(and
carriage
return)
13
=
carriage
return
(and
linefeed)
14
=
enter
double
width
character
mode
15 =
enter
standard
width
character
mode
16
=
set
the
print
head
position
17
=
switch
to
upper/
lower
case
18
=
turn
on
reverse
field
26
=
repeat
dot
pattern
27
=
specify
dot
address
for
print
head