[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: EDD Plus Card



glen herrmannsfeldt wrote:
Michael J. Mahon wrote:

(snip)

The formatting routines of the Apple II are software-adaptive to the
speed of rotation of the particular drive, and manage to use the whole
track quite nicely at the cost of just a few bytes of code.


They adapt to the speed?

I believe you always need a gap, at least for write splice.
(The time it takes to turn on the write signal after you detect
the appropriate place.   You also need a gap after for enough
time to turn off the write signal.  That gap also gives you
tolerance for speed variations between formatting and writing.

The Apple II 5.25" formatting routines start by assuming a slow
speed, and write a long track image beginning with a lot of sync
nibbles (to guarantee that the last sector written overlaps the
first sync nibbles written), and with a larger than usual number
of sync nibbles between the sectors.  The routine then reads back
the track, verifying that there are enough sync nibbles left after
the last sector written and before the first sector written.

If there are not enough, the routine progressively reduces the
number of sync nibbles between sectors until there are.  (If the
drive is so fast that this process would lead to too few sync
nibbles between sectors, a formatting error is reported.)

In this way, it adapts to the actual speed of the drive to create
16 approximately equally spaced sectors on the track 0.  It then
assumes that the drive speed is relatively constant and uses the
same timing to format all the other tracks.

This is why the format routine dwells longer on track 0, then
quickly steps through the other tracks when formatting.

(I hope I didn't get the details wrong--this is from memory.  ;-)

Some disks use a servo track so it can follow speed variations
while writing. There are hard disks with a whole surface and head dedicated to the servo.

A servo track requires at least two read channels: one for data and
one for servo.  That level of complication has never been used for
ordinary floppies.

The Disk ][ Controller dynamically adapts to the timing errors
resulting from small rotational speed variations while reading.
It does this using a very clever 2MHz state machine that locks
to the stream of read pulses, effectively recovering the data
clock from them.

I consider Woz's Disk ][ Controller design to be one of the finest
examples of digital engineering--maximum function with minimal
component count--resulting from a virtuoso balancing of hardware
and software functionality.

-michael

NadaPong: Network game demo for Apple II computers!
Home page:  http://members.aol.com/MJMahon/

"The wastebasket is our most important design
tool--and it's seriously underused."