Atari ST and hard disks

From Atari Wiki
Revision as of 23:28, 26 September 2007 by Admin (talk | contribs) (Fixed formatting, minor edits for better English, slightly wikified)
Jump to navigation Jump to search

Atari ST and hard disks

Here we will focus mostly on ST and STE machines, but much of this remains the same with the Atari Falcon and TT machines too.


A little history for better understanding:

When the Atari ST was launched, in 1985 hard disks were not much used - they were too expensive, exotic pieces of hardware. Standards were not established, and there was no IDE (ATA), later winner in mass storage system for masses :-) Atari added some support for the (future) connection of hard disks in the form of the ACSI port. It was typical for that time: proprietary, and thus not compatible with any other. But it was not so bad a , considering the lack of standards. And ACSI port is actually some kind of simplified SCSI port. After it, some hard disks appeared on market. More success than Atari had independent manufacturers. Typical hard disk kit for Atari ST machines was: ACSI-SCSI adapter and SCSI disk + power supply + driver, partioning software. In the meantime IDE hard disks appeared on the market. They were designed to be cheap, simple interfaceable. Atari made support for IDE disks somewhere in 1991-92. Code for boot from such interface/disk was added to TOS 2.06, and the latest machines such as the ST-Book and Falcon had built-in IDE interface. However, at the time some people did not realise what was really happening: I read in an article in a German Atari magazine that it was not wise to produce an IDE interface, because SCSI was just little more expensive, and IDE has no perspective. Now we know that they were wrong. The biggest problem with an IDE interface is that it can not be simple connected to machine - you need to open the case and solder a lot of lines. In case of Mega STs it was a little simpler, but still some soldering and mounting connector was required. Now we have the absurd situation that some Atari users have a ACSI-SCSI-IDE chain of interfaces. The main problem here is that Atari went bankrupt after 1992, and that there is no expansion port/bus on ST machines.


How it works?

Unlike modern PCs, there is very little support for hard disks in TOS. Actually, in TOS there is only a small amount of code for loading the master boot record from hard disks. The rest is done by the driver and it's loader. TOS has support for FAT16 filesystem - MS DOS compatible. Later TOS versions added some support for bigger FAT16 partitions in the form of 'Big sectors'. This also required compatible hard disk drivers.


Limitations:

TOS 1.0 was limited to partition sizes with a max of 16MB due to a bug (without big sectors). FAT16 partition has a max size of 32MB. FAT16 with big sectors, called BGM may be up to 1GB, depending on TOS version. ACSI in it's initial form has a limit of 1GB for total size of an attached hard disk, because of the addressing system. It was expanded later in XHDI. But we should not blame Atari too much for those limits, in comparison, for the PC the situation was even worse - max half GB total disk size accessible with CHS addressing by IDE/MFM disks. Not to mention mess in partition tables. IDE (ATA) went through numerous expansions. The most important is LBA addressing, whic allows hard disks sizes of up to 128GB capacity. BigDOS partitions on PC have a limit of 2GB in size, and they are readable on an Atari with help of the free program BIGDOS + hard disk driver (at least AHDI 3.0 compat.)


Partitioning of hard disks:

In the very first sector of every hard disk is the partition table. Atari uses the so called GEMDOS partition table. It is defined in AHDI. However, we are not forced to use that system at all - because there is nothing in TOS related to it. All this is done by the hard disk driver. Usage of MS DOS partition system offers another possibility - it uses the same FAT16 partitions as GEMDOS. And we have the added benefit that such a disk will be readable on a PC without any special software.


Speed:

Speed depends on a combination of the attached drive, the interface, the DMA chip in ST (ACSI port), the ST's CPU speed and driver, with the transfer speed constrained by the slowest part of the chain. In the case of ACSI it is not exactly clear: some sources say that DMA chip can reach a max of 1MB/sec, others talk about a max of 1.5MB/sec (these are max. burst speeds, and we may just go close to them). It is even possible that earlier machine versions have a lower max. speed and later higher. In any case we may say for now that ACSI has a 1-1.4MB/sec maximum. In reality this means some 10-20% less when working with large files, and less speed again with short files. IDE speed: it depends not on the interface (which is just a I/O port). In the case of an 8MHz ST it can go up to 1.6MB/sec, and with a blitter chip fitted (STe, Mega ST) up to 1.8MB/sec. For a Falcon it can be aprox. twice as fast. But in the case of MS DOS disks and CD ROM/DVDs IDE will be very slow. The reason is byte order, what is reversed by such disks. Swapping Low/High byte is pretty slow with MC68000, so we can expect speeds in the range of 250-400KB/sec max. Some interfaces perform that byte-swap in hardware, so can work at max. speed as above (IDE speed), but such interfaces are not AHDI compatible.


Where we are today (2007) ?

Still some people use Atari ST machines. Things have changed a lot from the 1980s till now, we now have cheap Flash mass storage media, with low power consumption, and fast speeds. SCSI is developed too, but it is not for the mass-market. Nobody manufactures ACSI-SCSI adapters. The ideal would be an ACSI-IDE or a ACSI-some Flash card interface, but from some reasons they are not available, although there are some projects under development/manufacturing. IDE has advanced so that CD ROM/DVDs can be attached too. The problem is that ACSI and IDE (ATA) are not compatible. For instance IDE has 16-bit data bus, while ACSI has 8. An even bigger problem is control: ACSI first gives command code, then parameters, while IDE does it in the opposite order. So, designing an ACSI-IDE interface is not so simple.

There is still a lot of working, good quality ACSI-SCSI adapters used with Atari machines, and they are the best supported by the available software, where as IDE is not so well supported, and most of the drivers are obsolete. The problem is when someone wants to buy an adapter and mass storage media: What should they buy today? Currently they may have go to E-bay and look for a second-hand combination. Of course, the prices are not too good, considering that a new Flash card of 4GB costs under 50 Euros, and will be become gradually cheaper. Or waiting...

P. Putnik , March 2007.