Commodore 128 Programmer's Reference Manual page 706

Hide thumbs Also See for 128:
Table of Contents

Advertisement

u
696
COMMODORE 128
c3) Sets up PAL and NTSC variables (SYSFREQ)
c4) Closes all open channels
d) This subfunction intializes 8502 system variables, interrupt processing
J j
and system frequencies so that the Z80 and 8502 may communicate
J
back and forth. Processor control is given to either the Z80 or the 8502
at one particular time. The processors cannot run simultaneously.
j j
IV. l.a) Subfunction 1: 1541 Read (GCR format only)
^
b) A = 4
L=l
|i
VICTRACK = (1-35)—Variable for track number on disk
VICSECTOR = (0-21)—Variable for sector number on disk
VICDRV = —Variable for disk drive device number where:
LOWER NYBBLE
OF VICTORY
BIT VALUE
0001
0010
0100
1000
DEVICE NUMBER
8
9
10
11
DRIVE
0
0
0
0
EQUIVALENT OPEN
STATEMENT IN BASIC
OPEN 8,11,15
OPEN 9,12,16
OPEN 10,13,17
OPEN 11,14,18
Values of the Lower Nybble of VICDRV
c) VICDATA = 11 ($0B) if disk in drive has been changed
U
VICDATA = 13 ($0D) if read/write or channel error occurs
VICDATA = 0 if read is successful
i
VICDATA = 15 ($0F) if device is not present
J
d) This function reads a particular track and sector on the disk in the drive
as specified by VICTRACK and VICSECTOR and VICDRV respec
tively. Data is read into the buffer at $FE00H. The value returned in the
variable VICDATA depends on the conditions described in c.
e) Additional Information: This subfunction assumes that both the data and
command channels have been opened previously. An error will occur if
) f
this routine is called to read from a 1571.
M
IV. 2.a) Subfunction 2: 1541 Write (GCR format only)
b) A = 4
L = 2
VICTRACK = Same as for 1541 Read
VICSECTOR = Same as 1541 Read
VICDRV = Same as 1541 Read
c) VICDATA = Same as 1541 Read
d) This subfunction writes data to the specified track and sector on the disk
in the drive as specified by VICTRACK, VICSECTOR and VICDRV
respectively. The value returned in VICDATA depends on the condi
tions described for the outputs in c. See subfunction 1 for details.
LJ

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents