<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Tue, 27 Jul 2010 19:58:06 +0100
From   : afra@... (Phill Harvey-Smith)
Subject: FileStore emulator - FDC

On 27/07/2010 18:34, Rick Murray wrote:
> Hi!
>
> Does anybody have experience with the 2793 FDC chip? The FileStore uses
> it, and the (v1.33) firmware probes thusly:

No but I have used the 2797 on the Dragon disk controler which is almost 
the same chip, infact it's also mostly software compatible with the 177x.

> --8<--------
>       9225093&F9F3 : FDC change: Test=No, MRst=No, DDen=Yes; FDC1=Yes,
> FDC2=No, Side=0
>       9225093&F9F3 : Mode LED off
>       9225093&F9F6 : FDC read :<- 0 [Status/Command]
>       9225109&FA06 : FDC write: 80 ->  1 [Track  %01010000]
>       9225109&FA09 : FDC read :<- 1 [Track]
>       9225174&F87F : FDC write: 0 ->  3 [Data  %00000000]
>       9225203&FEFC : FDC read :<- 0 [Status/Command]
>       9225225&ED17 : Network IRQs disabled [READ]
>       9225247&FF0E : FDC write: 8 ->  0 [Status/Command  %00001000]
> --8<--------
>
> I've set the FDC lamp to come on for FDC1/FDC2 selected (instead of
> waiting for Motor On) so I can 'see' when this happens. I'll fix it later.
>
> It is reading the status. It will read zero (no code!), thus the drive
> is ready and not busy.
>
> It writes 80 to the track register, then... reads this back again?

Checking that the FDC is there and that it's datapath is correct ?

> Next, zero is written to the data register and the status register is
> read again; and after killing the network IRQs, the command register is
> programmed with %00001000 which looks like a Restore command to load the
> head (in other words, spin up the disc [this is when the drive lamp
> should come on]).
>
> Is this correct so far? What's the faffing for? Probing the FDC really
> exists? What am I supposed to do? Time out a short while then IRQ for
> disc spun up or something? I would suspect, here, we seek for track zero
> and then force an IRQ...

That seems valid, though I am supprised that it doesn't issue a reset 
command to the FDC, DragonDos does (as does OS-9).

> The TMS279x datasheet describes lots of things except what I'm looking
> for, it would seem.<sigh!>  Why write 80 to the track register? The
> datasheet says "It is incremented by one every time the head is stepped
> in (towards track 76)",

The track register is changed to reflect any commands which change the 
track e.g. step in/out. The controler is quite capable of 80 or more, 
give it a drive with 255 tracks and it'll cope :)

>                          does this imply only 76 tracks are possible? Is
> 80 some sort of flag? This is 80 decimal (%01010000), not high-bit-set hex.

Nope nothing special about 80.

> Oh... why oh why doesn't this heap use an 8271 or 1770 like everything
> else in the Beeb range?

Well the 279x is pretty software compatible with the 1770, though also 
has the advantage that it will handle a 500kHz data rate as used by both 
8" disks and 3.5" HD disks......

Cheers.

Phill.
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>