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

Re: Daisychaining 5.25 " Drives



mdj <mdj.mdj@gmail.com> wrote:

> Michael J. Mahon wrote:
> 
> > IIRC, the 5.25" drives must be at the end of the daisy-chain, so
> > the last smartport device must synthesize drive 1 and 2 select lines
> > for the downstream devices, and must also pass on (or regenerate)
> > all the standard 5.25" vrive signals.
> 
> That sounds reasonable, yes.
> 
> > I expect that there is an signal line that a drive supplies to the
> > interface that says whether it is a smartport device or not, and
> > the interface responds accordingly, even through intermediate
> > smartport devices.
> 
> Hmm, I'm not sure how, since the //c Smartport, Liron card and 5.25"
> controller card are essentially identical, and contain signalling
> that's only relevant to 5.25" drives.

Technically, yes. The IWM and Disk ][ controller provide the same set of
signals to the drive connectors, which are sufficient to control 5.25"
drives.

Intelligent "SmartPort" devices (e.g. the UniDisk 3.5) use the drive I/O
signals in a completely different way from 5.25" drives.

My manuals are buried deep in the basement so I can't look up the
specifics, but working from memory, the key details are:

1. The "Drive select" lines are only used for 5.25" drives. When
accessing SmartPort drives, neither drive select signal is active, so
5.25" drives don't start spinning and don't react to the use of other
signals.

2. SmartPort uses the four "phase" outputs to send special control
signals from the computer to the drives. Certain combinations of the
phase signals are used to tell the drive that a SmartPort transaction is
taking place. These combinations aren't valid for 5.25" drives (e.g.
opposite phases are active at the same time).

3. SmartPort transactions use a packet-based protocol to send commands
to the drive. The data travels over the usual read/write data pins and
is encoded using a 7-and-1 technique (since the IWM requires bit 7 set
in each byte in order to receive it). In effect, the command issued to
the firmware in the Apple II is transferred verbatim to the drive, along
with any data required to execute it.

4. Smartport supports a theoretical maximum of 127 devices per bus. An
address allocation protocol is used at startup, which consists of a bus
reset then accessing each device in the daisy chain successively to
assign an address to it. The addresses are allocated in ascending order
starting at 1 (the device attached to the computer).

5. When a SmartPort transaction is taking place, the last SmartPort
drive in the chain knows that the next drive is a 5.25" one and cuts off
the signals, so the 5.25" drive doesn't try to do silly things with its
stepper motors.

6. SmartPort drives ignore the bus if the drive select signals are
active, and just pass everything through.

The actual limit on the number of drives is determined by power supply
and signal loading limits. In most cases, there is a limit of four
physical drives per controller, and there may be a maximum number for
the entire computer.

Note that the above does not apply to "dumb" 3.5" drives, i.e. the Apple
3.5 Drive and SuperDrive. These work more like the 5.25" drives, in that
they use the drive select signals. They do have some extra features,
e.g. a "3.5DISK" signal from the host tells the 3.5" drives that they
are being accessed, which causes them to cut off daisy-chaining the
signals to other drives.

The reason you see a brief pulse on the LED of a 5.25" drive daisy
chained to an Apple 3.5 Drive is the drive select signal and 3.5DISK
signal being activated simultaneously, both drives reacting to the
selection, then the 3.5" drive cuts off the daisy chained signal, so the
5.25" drive isn't selected long enough for its motor to start moving.

The Apple 3.5 Drive also has some one-bit registers which are write only
or read only, which are accessed using the phase signals (register
select and write data) and the write protect signal (read data). These
are used for controlling stepping, head select and various other things.
(You can't do "half tracks" on a 3.5" drive because the only stepping
operations available are "next track" and "previous track" - no direct
control of the stepper motor.)

Some of the details of the Apple 3.5 Drive are documented in the early
editions of Inside Macintosh.

There is very little public documentation on the SuperDrive, but it is
probably an extension of the Apple 3.5 Drive with different timing. I
have no idea how it operates with MFM-encoded disks.

All of the above explains why the drives have to be in a certain order:

"Dumb" 3.5" drives need to be first, so they can sense the 3.5DISK
signal (not passed on by other drives).

SmartPort drives need to be next, since 5.25" drives would be confused
by the SmartPort signals.

5.25" drives need to be last, so the other drives can avoid passing
signals through when the other drives are being accessed.

> I seem to recall there was a modification made to analog controller
> board in the Platinum 5.25" drives that allowed them to respond to a ID
> request while still essentially being 'dumb' devices

I recall no such feature, and none is required.

The only modification I remember hearing about was a capacitor change in
a DuoDisk to allow it to work on a IIgs without causing problems with
other drives, or something of that nature.

> Surely the electrical characteristics of SmartPort are documented
> somewhere? Perhaps in one of the IIGS reference manuals I don't have.

The most up to date documentation on SmartPort is in the IIgs hardware
reference and IIgs firmware reference, supplemented by technical notes.
It is also covered (not so well and with some inaccuracies) in the IIc
technical reference.

-- 
David Empson
dempson@actrix.gen.nz