Commodore 128 System Manual page 292

Hide thumbs Also See for 128:
Table of Contents

Advertisement

Following the device number may be a third parameter called the
secondary address, ln the case of the cassette, this can be 0 for
read, 1 for write and 2 for write with END-OF-TAPE marker at the
end. ln the case of the disk, the number refers to the channel
number. See your disk drive manual for more information on
channels and channel numbers. For the printer, the secondary
addresses are used to select certain programming functions.
There may also be a filename specified for disk or tape OR a
string following the secondary address, which could be a
command to the disk/tape drive or the name of the file on tape or
disk. If the filename is specified, the type and mode refer to disk
files only. File types are PROGRAM, SEQUENTIAL, RELATIVE
and USER; modes are READ and WRITE.
EXAMPLES:
10 OPEN 3,3
OPENs the screen as file number 3
20 OPEN 1,0
OPENs the keyboard as file number 1
30 OPEN 1,1,0," DOT"
OPENs the cassette for reading, as file number 1, using " DOT"
as the filename
OPEN 4,4
OPENs the printer as file number 4
OPEN 15,8,15
OPENs the command channel on the disk as file 15, with
secondary address 15. (Secondary address 15 is reserved for the
disk drive error command channel.)
5 OPEN 8,8,12,"TESTFILE.SEQ,WRITE"
OPENs a sequential disk file for writing called TESTFILE as file
number 8, with secondary address 12.
17-50

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

128d

Table of Contents