      Installing a high-density replacement drive in an ST/STe
      --------------------------------------------------------

If your internal disk drive has broken down for some reason and you've been
looking for a replacement DD (720Kb) drive you've probably realized that
these are near impossible to get hold of today.
But fear not! By following the steps here you'll be able to use a standard
PC type HD (high density -1.44Mb) disk drive which is widely available and
won't cost you an arm and a leg.

I started working on this project in order to upgrade my STe with a HD drive
so I could read/write HD disks in addition to DD disks as they take up the
same physical disk space in my disk storage-box but store twice the amount
of data and cost about the same as DD disks (which are running scarce these
days).


         The job itself
         --------------
I've chosen to use the Sony MPF 520-1 disk drive since it's physically easier
to adapt for use with the ST than with other drives. Besides, Sony is a
reputable company and it should be widely available.

The physical adaption mentioned regards the "eject button" (the plastic
"button" you press in order to eject the disk). You might have noticed that
the Atari styled button is shaped a bit differently from the usual PC styled
eject buttons. Many people have resorted to cutting the computer's case in
order to use a new drive with the PC styled button and front panel, but
there's absolutely no need for this!
With this drive you simply need to do a little modification to the drive
mechanics, and this won't be visible at all when installed. It'll look a
whole lot better than a "home made" hole in the casing!

You end up using the eject button and front panel from the old Atari drive,
and remove the PC styled eject button/front panel from the new PC styled
drive. The front panels snap easily on/off these drives so you should have
no problem with this.
As the eject button from the old drive doesn't have a "hook" which fits the
new drive you'll have to snap this off and possibly use some glue to fix
it to the eject button metal "lug" 
(see enclosed "sony_144.img file for details).


In addition to this minor modification some electronic modifications have to
be done. The 34 pin "Shugart" connector which connects the drive to the ST 
main circuit board has to be inserted "upside down" into the drive unit.
This is because most HD disk drives (all I've come by so far and heard of
from others) have their connectors "reversed" as opposed to the old Atari
ST drive.
To be able to do this you have to cut away a little plastic notch on the
connector at the end of that 34 way ribbon-cable.


Now comes the part where you need to plug in your soldering iron...
you need to connect a wire between the two connections of the "disk detect"
switch. That is, the switch will always be witched "on" after you've
done this.
The ST detects if a disk-change has been made in another way than the PC,
and if this modification isn't done you can end up messing up your disks
real bad (I know!! ...so don't make the same mistake I did when erasing
some files because the computer didn't "see" me change disks!).

The next thing you need to do is to set the drive select to "drive 0". It's
probably set to "drive 1" when you get the drive- this is because PCs see
"drive 1" as the boot drive, while the ST sees the boot drive as "drive 0".
Normally this is just a jumper on the drive's circuit board, close by the
power-connector. If not, it might be soldered on the circuit board, where
you need to de-solder it and relocate the jumper to "drive 0".


         Summary
         -------
-cut away a small part of metal on the drive's mechanics to accomodate for
 the ST styled eject-button and front-panel.

-locate the 34-pin connector at the end of the flat ribbon-cable. You will
 see a notch in the middle of it on one side. This prevents it from going
 into the drive the wrong way, but since this is exactly what we need to
 do you need to cut away this notch and insert it the "wrong way round".

-connect a wire between the two pins of the disk detect switch (usually
 marked "CTIN". It should be the second micro-switch from the left if you
 turn the drive over and look at the front-end of the drive's circuit board.

-The drive-select jumper should be set for "drive 0".


That's it!! Just plug in your drive as explained earlier (34-pin connector 
upside down, and the power connector which should plug in just as the old 
drive, but beware!!! It's been reported that some older disk drives in the 
ST has it's power connections switched even though the plug looks the same.
If you're not 100% sure the connection is correct check it with a 
volt/multi-meter). You have been warned.
The enclosed "sony_144.img" file shows the power-connection pinouts as 
well.

After these connections have been made your drive should act just like your 
old 720Kb drive.
If you want to be able to use HD (1.44Mb) disks as well you should continue 
reading the next part of this text file.


Hallvard Tangeraas (hall@post1.com) 19-May-1997




      HIGH DENSITY MODE
      -----------------
In order to set the drive to "HD mode" where it will accept HD disks, pin 2
of the drive's connector has to get a "high" logic signal. This is easily
achieved by connecting a wire between this input pin and the HD detect
switch which is located at the front end of the circuit board (it's the
microswitch on the right-hand side if you look at the circuit board from
the top. On my drive it's marked "HDIN" and "S3" -it might be marked
differently on your drive, but in any case it's the switch which is located
to detect the extra hole on HD disks which DD disks don't have).
(see enclosed illustration in the "sony_144.img" file)

Once you've located the HD detect switch you need to find the connection of
it which *doesn't* go to ground. There's one pin of the switch which is
shared with the other 2 micro-switches (disk detect and write-protect) and
goes to ground, the other pin will give a +5V signal if there's no disk
inserted in the drive or a HD disk is inserted. This is the pin we're
looking for.
(use a voltmeter/multimeter to check if you're not sure)

So, connect this pin of the HD detect switch to the above-mentioned pin
number 2 of the "Shugart bus" (the 34 pin connector). This is usually
marked with pin numbers, so find pin number 2 there.
Voila! The drive will now work in both HD and DD mode.

In addition to the drive itself working in both modes we need to let the ST
know when to switch between HD and DD modes.
This is where pin 2 of the 34 pin connector comes into the picture again as
the +5V signal from the HD detect switch is used to tell the ST what is HD
and DD mode, so connect an additional wire from pin 2 of the drive's 34 pin
connector 
-this will be used later for the "HD/DD switching circuitry" 
(often referred to as a "HD module") which we need to automatically switch 
between HD and DD modes.

The "HD/DD switching circuitry" is a project I haven't completed yet, but 
will get back to later.


In the meantime you can *manually* switch between HD and DD modes using a 
simple electrical switch.
(illustrated in "man_mode.img")

Explained roughly, the difference between HD and DD modes is that the disk 
controller chip (WD-1772, or rather an "AJAX" in this case) on the ST gets 
either an 8MHz signal (which sets it to DD mode) or a 16MHz signal (which 
sets it to HD mode). Pin 18 of the 1772/AJAX is a "clock" input where the 
density mode is set.

Now, 8 MHz is fed from the main board of the ST directly to pin 18 
naturally since the ST was built for 720Kb disk drives only, so the first 
thing we need to do is disconnect the 8MHz signal from the main board so we 
can select between 8 and 16MHz as we need to change between DD and HD 
modes.

8MHz can ofcourse be tapped from where it originally was used: the 
connection we just cut off from the disk controller chip on the main board, 
but for the 16MHz signal it's safest to use a separate 16MHz oscillator 
instead of tapping it from the main board (I've heard people having 
problems while tapping the signal from the computer itself, so we don't 
want to take any chances).
The 16MHz oscillator I used is shaped like a small "box" with 4 legs 
(3 of them are used); +5V/Ground/16MHz out.
The electrical connections are well catered for since you can tap this off 
the disk controller (or it's socket rather).

** An "AJAX" disk controller chip is *highly* recommended for HD use as the 
WD-1772 was only constructed for DD drives (8MHz). Some people claim to 
have used a specific version of the WD-1772 with great success; the 
1772-02-02, but this isn't guaranteed. It might work for a while, but 
sooner or later the controller chip will get damaged. You have been warned!
 The so called "AJAX" chip from Atari is a pin-by-pin replacement for the 
1772, but it can handle up to 32MHz. In other words, it can handle DD, HD 
and even ED (extended density 2.88Mb) drives!


Hallvard Tangeraas (hall@post1.com)  18-September-1997