Inp; Out - Sharp MZ-700 Basic Manual

Disk basic interpreter
Hide thumbs Also See for MZ-700:
Table of Contents

Advertisement

63
INP@ (input)
Inputs data at 110 ports to variables.
Format:
INP@ <port number>, <variable>
Abbreviated form:
I.@
Explanation:
• Inputs 8-bit data from <port number> input port and sets to <variable> the value
(0 - 255) converted to a decimal number .
• From 0 to 127 ($00 - $7F in hexadecimal), the <port number> can be determined
freely. From 128 to 255 ($FO - $80 in hexadecimal), the use is exclusively as ports
for external devices.
Example:
1 0
FOR
I =0
TO
20
20
C =1 +32
30
GOSUB
"SUB"
40
NEXT
50
END
60
LABEL
"SUB"
70
I NP@ $FE, A
80
I F
NOT
(A
AND
$OD) =0
THEN
70
90
OUT@ $FF,C
100
OUT@ $FE, $80
1 1 0
I NP@ $FE, A
120
I F
NOT
(A
AND
$ 0 D) =1
THE N
1 1 0
130
OUT@ FE, 0
140
RETURN
Reference:
OUT@ (page 64)

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mz-2z009

Table of Contents