Commodore 2001-8 User Manual page 75

Table of Contents

Advertisement

IEEE-488 OPEN CONSIDERATIONS
If the OPEN command selects a device which has a value of 4 or more, the operating system assumes
that the device is an IEEE·488 device.
If the OPEN does not specify a file name, then nothing is communicated on the IEEE-48B bus. However, if
a file name is specified, the operating system sends a listen attention sequence to the device number
specified in the OPEN along with a secondary address which is the OR of hexadecimal "FO" and the
secondary address specified in the OPEN statement.
Commodore-supplied peripherals, such as the floppy disc storage system, will use this secondary
address and also the file name, which is then transmitted to the listening device in order to transfer data
later to the open file.
TAPE FILE OPERATION MODES
tape files can be opened for two distinct purposes:
a) In order to write from the PET onto tape.
b) In order to read from tape to the PET.
OPEN FOR WRITE ON TAPE FROM PET
The flow diagram of Figure 7.15 outlines the PET-user interaction and PET function when opening a file
for write on tape. The initial block shows that there are two ways of opening the file:
a) OPEN for write-data tape.
b) SAVE-write a program tape.
Note that if the tape file is opened directly from the keyboard, then the message WRITING NAME is
displayed. If the file is opened under program control, and the PLAY and RECORD buttons are depressed
previously, then no message appears on the screen. In this manner, any display material placed there by
the current program is not disturbed.
OPEN FOR READ FROM PET TO TAPE
The flow diagram of Figure 7.16 outlines the PET-user interaction and PET function when opening a file
for reading on tape. The initial block shows that there are two ways of opening the file:
a) OPEN for read data tape.
b) LOAD program into memory.
Note that if the file is opened directly, that is from the keyboard, then the messages PRESS PLAY,
SEARCHING FOR NAME and FOUND NAME are displayed. If LOAD was used, then the BASIC variables
of the loaded program are initialized.
If the file is opened under program control and provided that the PLAY button had been pressed
previously, no messages appear on the video screen in order to disturb material displayed by the current
program. Initialization of the BASIC variables does not occur.
72

Advertisement

Table of Contents
loading

This manual is also suitable for:

Pet 2001-8

Table of Contents