845
848
The other alternative is a @dfn{true drive} emulation. The
846
849
Commodore disk drives are provided with their own CPU (a 6502 as the
847
850
VIC20 and the PETs) and their own RAM and ROM. So, in order to more
848
closely emulate its features, a complete emulation of this hardware must
849
be provided and that is what the @dfn{hardware level} emulation does.
850
When the @dfn{hardware level} emulation is used, the kernal routines are
851
remain unpatched and the serial line is fully emulated. The problem
852
with this emulation is that it needs a lot of processing power, mainly
853
because the emulator has to emulate two CPUs instead of one.
855
As of 0.14.0 the @dfn{hardware level} emulation is available on all
856
emulators. It can only be used to emulate drive unit #8 or #9. Other
857
units are disabled if @dfn{hardware level} drive emulation is enabled.
859
The PETs do not use a serial IEC bus to communicate with the
860
floppy drive but instead use the parallel IEEE488 bus. This does
851
closely emulate its features, a complete emulation of this hardware
852
must be provided and that is what the @dfn{hardware level} emulation
853
does. When the @dfn{hardware level} emulation is used, the kernal
854
routines are remain unpatched and the serial line is fully emulated.
855
The problem with this emulation is that it needs a lot of processing
856
power, mainly because the emulator has to emulate two CPUs instead of
859
The PETs do not use a serial IEC bus to communicate with the floppy
860
drive but instead use the parallel IEEE488 bus. This does
861
861
@emph{byte by byte} transfers, as opposed to the @emph{bit by bit}
862
862
transfers of the C64 and VIC20, so making it feasible to emulate the
863
863
parallel line completely while emulating the drive at DOS level only.
864
The IEEE488 line interpreter maps the drives 8-11 (as described above)
865
to the IEEE488 disk units, and no kernal traps are needed. The same
866
emulation of the Commodore IEEE488 bus interface is available for the
867
C64 and the VIC20. With IEEE488 drives you can have true 2031 emulation
868
at unit #8, and still have filesystem access at units #10 or #11, because
869
monitoring the IEEE488 lines does not interfere with the true drive
872
The IEEE488 disk drives 3040, 4040, 8050 and 8250 are Dual Drive Floppy Disks.
873
This means that these drives handle two disks. To Accomplish the
874
emulation, only one disk can be emulated, namely unit #8. The
875
attached image, track display and LED display of unit #9 are used
876
for the second drive of the dual disk drives. On unix the unit number
877
display (8 or 9) in the emulation window changes to the drive number
880
The Commodore 3040, 4040, 1001, 8050 and 8250 disk drives are
881
so-called "old-style"
882
disk drives. Their architecture includes not one, but two processors
883
of the 6502 type, namely a 6502 for the file handling and communication
884
with the PET (IP), and a 6504 (which is a 6502 with reduced address space) for
885
the drive handling (FDC). Both processors communicate over a shared memory
886
area. The IP writes commands to read/write blocks to this area and
887
the FDC executes them. To make the emulation feasible, the FDC processor
888
is not emulated cycle-exactly as a 6504, but simply by checking
889
the commands and executing them on the host. This provides a fast
890
FDC emulation, but disallows the sending the FDC processor commands
891
to execute code. Applications where this is necessary are believed
892
to be rather seldom. Only the format command uses this feature, but
895
The dual disk drive 2040 emulates one of the very first CBM disk drives.
896
This drive has DOS version 1. DOS1 uses an own disk type, that is closely
897
related to the 1541 disk image. Only on tracks 18-24 DOS1 disks have
898
a sector more than 1541 disks. DOS1 disk images have the extension .d67.
900
The dual disk drives 3040 and 4040 use the same logical disk format as
901
the VC1541 and the 2031. In fact, the 4040 was the first disk with
902
DOS version 2. The 3040 emulated here originally was the same as 2040, only
903
for the european 30xx PET series. As many of the original DOS1 disk drives
904
were upgraded (a simple ROM upgrade!) to DOS2, I use the 3040 number for
905
a DOS 2.0 disk drive, and 4040 for a revised DOS 2 disk drive.
906
It is, however, not yet clear whether the disks here
907
are write compatible to the 1541, as rumors exist that the write gap between
908
sectors is different. But read compatible they are. As VICE emulates
909
the FDC processor in C and not as 6504 emulation, this does not matter
912
The drives 1001, 8050 and 8250 do actually have the very same DOS ROM.
913
Only the code in the FDC is different, which is taken care of by VICE.
914
So for all three of those disk drives, only @code{dos1001} is needed.
915
The DOS version used is 2.7.
864
The IEEE488 line interpreter maps the drives 8-11 (as described
865
above) to the IEEE488 disk units, and no kernal traps are needed.
866
The same emulation of the Commodore IEEE488 bus interface is
867
available for the C64 and the VIC20. With IEEE488 drives you can have
868
true 2031 emulation at unit #8, and still have filesystem access at
869
units #10 or #11, because monitoring the IEEE488 lines does not
870
interfere with the true drive emulation.
872
The IEEE488 disk drives 3040, 4040, 8050 and 8250 are Dual Drive
873
Floppy Disks. This means that these drives handle two disks. To
874
Accomplish the emulation, only one disk can be emulated, namely unit
875
#8. The attached image, track display and LED display of unit #9 are
876
used for the second drive of the dual disk drives. On unix the unit
877
number display (8 or 9) in the emulation window changes to the drive
878
number display (0 or 1).
880
The Commodore 3040, 4040, 1001, 8050 and 8250 disk drives are
881
so-called "old-style" disk drives. Their architecture includes not
882
one, but two processors of the 6502 type, namely a 6502 for the file
883
handling and communication with the PET (IP), and a 6504 (which is a
884
6502 with reduced address space) for the drive handling (FDC). Both
885
processors communicate over a shared memory area. The IP writes
886
commands to read/write blocks to this area and the FDC executes them.
887
To make the emulation feasible, the FDC processor is not emulated
888
cycle-exactly as a 6504, but simply by checking the commands and
889
executing them on the host. This provides a fast FDC emulation, but
890
disallows the sending the FDC processor commands to execute code.
891
Applications where this is necessary are believed to be rather
892
seldom. Only the format command uses this feature, but this is
895
The dual disk drive 2040 emulates one of the very first CBM disk
896
drives. This drive has DOS version 1. DOS1 uses an own disk type,
897
that is closely related to the 1541 disk image. Only on tracks 18-24
898
DOS1 disks have a sector more than 1541 disks. DOS1 disk images have
901
The dual disk drives 3040 and 4040 use the same logical disk format
902
as the VC1541 and the 2031. In fact, the 4040 was the first disk with
903
DOS version 2. The 3040 emulated here originally was the same as
904
2040, only for the european 30xx PET series. As many of the original
905
DOS1 disk drives were upgraded (a simple ROM upgrade!) to DOS2, I use
906
the 3040 number for a DOS 2.0 disk drive, and 4040 for a revised DOS
907
2 disk drive. It is, however, not yet clear whether the disks here
908
are write compatible to the 1541, as rumors exist that the write gap
909
between sectors is different. But read compatible they are. As VICE
910
emulates the FDC processor in C and not as 6504 emulation, this does
913
The drives 1001, 8050 and 8250 do actually have the very same DOS
914
ROM. Only the code in the FDC is different, which is taken care of by
915
VICE. So for all three of those disk drives, only @code{dos1001} is
916
needed. The DOS version used is 2.7.
917
918
@node Supported file formats, Common problems, Disk drive emulation, Preface
918
919
@section Supported file formats