[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Apple floppy adaptor. I'm stuck!
Michael J. Mahon wrote:
> Tristan Mumford wrote:
>> G'day.
>>
>> As you may or may not know I've been working on a little device to allow
>> PC 3-1/2" floppy drives to be used on a disk ][.
>>
>> It can now do the following:
>>
>> * de/Select and spin up/down the drive.
>> * Detect the write-protect state of an inserted floppy.
>> * Move the head around.
>>
>> What it can't seem to do is read and write. The basic question I want to
>> ask is whether the apple2 has an active high or low for read and write
>> pulses. I believe it's active high, but I'm starting to doubt myself a
>> little.
>
> Actually, it's *neither*! The Disk ][ Controller *toggles* the state
> of the write line each time that it writes a "1". No toggle = "0".
>
>> By the way. The slow stepping gives the PC floppy that satisfying "GRONK"
>> sound of the apple drives.
>
> The Apple stepping algorithm is much more sophisticated than the PC's.
> It accelerates and decelerates the stepping rather than just stepping
> at a constant rate, reducing the total time to seek. (Of course, the
> time constants were chosen for a Shugart Associates SA390, so the
> software seek could be speeded up quite a bit for newer drives.)
When I was looking at the head stepping routines I was quite pleased
noticing the acceleration/deceleration.
Yeah, it could be sped up a lot. But given everything else, why bother? A
speed increase at the cost of compatibility.
Judging by the function of the stepping routines and the breakdown of the
method of stepping in UTA2, I would say I am properly decoding all normal
states of the step phase lines. However if there is other software that
forces it to activate other combinations it will just consider that an
illegal combination, do nothing and happily aid in destroying the contents
of the disk :)
>
>> Another possibility I guess is that I have some kind of weird error in
>> the head movement causing it to move to the wrong tracks.
>>
>> Is there some kind of low level format that I can do on an apple floppy.
>> I tried the ProDOS format, but it looks like it only does track 0,
>> somewhere in the middle, and track35? I just got that from watching the
>> head movements.
>
> Then there is something wrong with the head movements, because both DOS
> and ProDOS format all 35 tracks, starting with track 0.
Hmm... I'll have to give it another good looking over. I'm going to change
the names of a couple of the "#define" directives in my code for
readability as it is. Ie change my "UP" and "DOWN" to "IN" and "OUT" for
head direction reference. I suspect that I have a case of double
backwardsness, causing the head to step in the right direction but the
filtering logic not to work right.
>
>> I'm hoping I can get this issue sorted, because it's nearly done! I hope
>> I can get it working right, because I actually decided to use a
>> calculator to figure out final storage capacity *Gasp!*. A 2HD disk
>> should hold 640kb. In it's current form a normal 2HD disk appears as one
>> big single-sided 160 track disk.
>
> Several places in the Disk ][ driver/RWTS think that a disk has at most
> 40 or so tracks--like recalibration.
D'oh! I wonder what I can do about that. Because I have ultimate control of
the head I guess I could make a single floppy into 4 x semi-virtual 40
track drives. The uC keeps track of the trackcount, direction, and side of
disk so it shouldn't be too hard at all.
Tristan.
--
-----> http://members.dodo.com.au/~izabellion1/tristan/index.html <-----
===== It's not pretty, it's not great, but it is mine. =====