Sharp CE-158 Instruction Manual page 30

Interface for pc-1500
Hide thumbs Also See for CE-158:
Table of Contents

Advertisement

All
and
more about
Sharp
PC-1
500 at http:l/www.PC-1500.info
This program example contains two programs
that
are loaded
using
the
MERGE
state·
menL
With
the first program,
input
of
data
through
the
RS-232C port is PIJt on the
displav.
With
the second program. it sends
out
the
r~pective
code on
the
RS-232C
port when ihere
is
a kev
entry.
Kev o
peration
What
is sent on
the RS·232C
port
SETDEV
PO
I
on1•
)
Direct to
execute
the
LUST
statement
to
th•
.................
RS.232C port.
It indicate$
after
turn
ing
the RS.232C
ports OTR
OUTSTAT 0
(
..
n•
..................
and
RTS
signals
active
that
the
RS.232C
interface
is
ready
for
operation.
LUST
l
'"'"'
l
All
programs
lines.
LUST
30
I
CHI
CA
I
30 CLS line
onlv.
fO "'B" SETCOM
300, 7, E, 1
LUST
"'
B'",30
i<
•n~
I
20SETOEV OO:OUTSTAT 0
30 IF IN
KEYS
GOTO
30
LL IST, 20
,
.,., ..
J
10
"'A'"
REM
•••
RS-232C
•••
200UTSTAT0
10"8" SETCOM
300,7,E,
1
.
20SETOEV
OO
:OUTSTAT
0
LUST
"'B"
,
I
DITOI]
30
IF
INKEYSGOTO
30
40 BS=INKEYS
50 IF
8$
PRINT
BS;: GOTO
30
60GOT040
NOTE
: "
r
"
and ..
,, ..
quoted
in
the
program will
be
o
utputted by the
code
s tring
of
square
plus
a
spac,
c
and
pi
plus a
space,
respectively.
The
same
is
applicable
for
the CSAVEo statement
which
will
be
di
scussed
later
.
12.
PRINT
But.
it
will
result
in error if
the
CLOADa
statement
(which
will
be
discussed
later)
is
exeOJtC
d
at the receive side
with
••
r
••
or
••
ll"
..
q uoted
in quotation
marks.
Effective
only when
00
has
been
declared by
the
SETOEV statement.
• Specified
data i.sent out In the
ASCII
code,
What
differs
f
rom
the LPR
INT
statement are as
follows
:
(t
I
Does
not meet
with th
e
USING
format
(format fre<:
of
USING format
desiQnationl. so
it
will
result in
error
if
USING
is
inserted
in
this
statement.
(21
TAB designation
is
not
permitted.
(31 Thou(#'I
either a
semicolon (
;
I
or a comma
(
• I can
be
used
for a data
separator.
the
comma
(.
I
is
handled
the
same as
the
semicolon
(
;
).
It
is
not
possible to
end
with
a
comma
(.I.
(41 Sign
code
(+or spacel will
not
be
af
fixed to the
data of
a posit ive value.
28
Do
not
sell
this PDF !!!

Advertisement

Table of Contents
loading

Table of Contents