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

Re: help decoding address fields



On Jan 15, 6:45 pm, jonnosan <jonno...@gmail.com> wrote:
> AF AF   <- sector # in 4-4 encoding=3 3 (51)

One way of 4&4 decoding is ((n1 << 1) | 1) & n2.

AF << 1 => 5E
5E | 1 => 5F
5F & AF => 0F

So it's sector 15.

If in doubt, look at a DOS disassembly:
http://www.textfiles.com/apple/ANATOMY/rwtsdrvr.read.txt
(Search for "B96D" and ignore the flawed comment above it!)

Cheers,
Nick.