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

Re: Hardware musings



BLuRry wrote:
No matter what you "measure" about the characteristics of the disk, it
will still be mostly human judgement that decides what is "relevant".
(Though I still have some hope for an emulator that "observes" what the
protected program does with the disk, assuming that some human is able
to "drive" the program through all its states--solving the game, looking
in all rooms, picking up game pieces in every possible order....  Hmm,
sounds hard.  ;-)


Maybe not to the fullest extent of what you've described (after all,
you might just discover program bugs doing that), but running the game
a few times in an emulator that supports the full to-the-extreme bit
copy format would be useful.  Just log what areas of the disk were used
by the virtual controller.  Sounds pretty easy to me, since all you
have to do is track what phyical bit was read from disk when the
softswitch value was consulted by the program.  The rest is garbage-in,
garbage-out.  You can cull the unused bits in the image by zero-filling
them so that the image compresses better.

There is a little complication in this process.  Most attempts to read
a track for, say, a magic nibble signature, will actually read many more
bytes, and (if sync is not an issue) even a whole track before finding
whatever it is looking for.  So the emulator that's "watching" has to
watch to see if the data read is simply ignored, or if only it's timing
information is used (a count), or if the program enters new states as a
result of what is being read (either by branching or storing the data).

I don't want to scare anyone, but this contains elements of the
"stopping problem".  ;-)

Doing this properly and "automatically" involves emulator support that
goes beyond simply supporting a new image format.

The reason that it is important is that it is unnecessary to write any
data that is irrelevant, and that may make the difference between being
able to recreate a physical disk or not.

Or you can flog me for over-simplifying things.  I like to avoid
writing lots of code. :-)

That's a virtue.  ;-)

"Everything should be made as simple as possible--but no simpler."
A. Einstein

-michael

NadaNet networking for Apple II computers!
Home page:  http://members.aol.com/MJMahon/

"The wastebasket is our most important design
tool--and it's seriously underused."