62
<port> is the port number (1 or 2).
Example:
A$ = INPUT$(10,#1)
Remarks:
All characters except CTRL+X can be read, including CR and LF: CR and LF
cannot be read with the LINE INPUT statement.
The BASIC LED indicator on the ASCII Unit will blink indicating that the Unit
is waiting for input. It will continue blinking until the specified number of char-
acters is entered.
Example Program:
10
CLS
20
A$ = INPUT$ (1)
30
A$ = HEX$ (ASC(A$))
40
PRINT A$
50
GOTO 20
Remarks:
Displays key character codes.
LOC Function
Purpose:
To return the number of data items in the specified port buffer.
Format:
x = LOC(<port#>)
Example:
A = LOC(2)
Remarks:
The port specified must already be open and in input mode. The number of
data items in the buffer of the specified port is given in byte units.
PEEK Function
Purpose:
To read the contents of a specified memory address
Format: PEEK(<I>)
<I> is the memory location and must be in the range of 0 to
65535 (&HFFFF).
Example:
A = PEEK(&H3000)
Remarks:
If the specified address is not an integer, it is converted into one.
Do not try to read reserved system addresses &H0000 through &H1FFF and
&H8000 through HFFFF.
Note For details of memory structure, refer to Appendix E ASCII Unit Memory
Map.
TIME$ Function
Purpose:
Sets or gives the time
Format:
TIME$ = <x$>
<y$> = TIME$
<x$> is a string expression indicating the time to be set. The fol-
lowing formats may be used:
hh: sets the hour (minutes and seconds 00)
BASIC Language
Section 4-2
Summary of Contents for SYSMAC C200H-ASC02
Page 1: ...Cat No W165 E1 04 ASCII Unit SYSMAC C200H ASC02 ...
Page 2: ...C200H ASC02 ASCII Unit Operation Manual Revised September 2002 ...
Page 3: ...iv ...
Page 5: ...vi ...
Page 7: ...TABLE OF CONTENTS viii Glossary 159 Index 163 Revision History 165 ...
Page 122: ...Appendix B Specifications 115 130 35 100 5 ...
Page 168: ...Cat No W165 E1 04 C200H ASC02 ASCII Unit OPERATION MANUAL ...