Re: 1541C/1571 trk0 detection codey

From: Francesco Messineo <francesco.messineo_at_gmail.com>
Date: Fri, 23 Feb 2024 15:09:38 +0100
Message-ID: <CAESs-_zy_x+rKU-wsSbovearcgqpO5eOZE75mpCP+XAg3cPpSg_at_mail.gmail.com>
On Fri, Feb 23, 2024 at 3:02 PM Spiro Trikaliotis
<ml-cbmhackers_at_trikaliotis.net> wrote:
>
> Hello,
>
> * On Fri, Feb 23, 2024 at 02:30:59PM +0100 Francesco Messineo wrote:
>
> >         FF57 A5 7B      LDA ADRSED   ; drive primary addressed?
> >         FF59 D0 0B      BNE LFF66       ; yes, move head
> [...]
> > Does anyone know why the track0 sensing code needs to check if the
> > drive is "primary addressed"? I suspect this page zero location was
> > used for other purposes on both the 1541C and the 1571 but I can't
> > make sense of the few places where the code writes to it.
>
> I had a quick glance at the code. My first estimation is this:
>
> This address ADRSED ($7B) is written to only in the functions FFA1 and
> FFA6 (1570/1571 ROM).

I see it's written also in the 1541C (01/02)

>
> FFA1 is called from D610. It is the function which tries to set the
> head to the next or previous half-track in order to resolve a read
> problem. This test allows for the positioning on a half-track "-0.5", so
> to speak.

yes indeed, they have just re-used the ADRSED location for this other
purpose, as I thought.

>
> FFA6 is called from D628. It moves the head back to the full-track.
>
> So, this code is making a special case to be able to move the head one
> step beyond track 0.

thanks Spiro, now it makes sense.
Frank
Received on 2024-02-23 16:00:13

Archive generated by hypermail 2.3.0.