Re: [NTLK] ATA Support and PC-based card readers

From: Paul Guyot (pguyot_at_kallisys.net)
Date: Fri Apr 05 2002 - 14:34:17 EST


Date: Thu, 4 Apr 2002 23:12:21 -0500
From: Jim Witte <jswitte_at_bloomington.in.us>

> Paul said a while back that the chance of having a reader for Newt
>formatted ATA cards on a desktop PC was probably rather low, for some
>unspecified technical reasons it sounded like. What are these (short
>version if possible)? Is it that the Newton uses the memory-mode access
>for the ATA interface, while everything else uses the disk-based mode,
>and hence most desktop PC-Card interface stacks don't handle the memory
>mode? Even a way to do a straight binary dump to/from the card would be
>handy for backup - just tell the Newt to back everything up to a card,
>then stick it in your TiBook and do a binary dump to a file. To say
>nothing about the possibilities if soup-writing cards on a Mac/PC were
>possible (thought this would probably be only slightly easier than
>making a Newton emulator..)

First, the difference between memory mode and I/O Modes is just about
how to communicate with the driver. The addresses where the registers
are written and read are different (and not in the same PCMCIA space)
and memory mode doesn't rely on interruptions to know when the
transfer is over.
Accessing the card in this or that mode doesn't change anything about
what is on the card, and ATA Support indeed only uses memory mode but
mostly because it is said to be faster (check the various card specs)
and is simpler to implement (I did not have to work on interrupts
handling which isn't documented of course).

Now, the reason why you can't access the data on a Newton card from a
laptop is that you don't know the format of the data.
There are actually two levels:

- First level is the ATA store format, i.e. how objects are stored on
the card. I documented it at first, there was some changes since, but
I'm ready to document the new format (well, rather, publish the specs
that lies my hard drive) if anyone wants to work on a data reader. I
haven't done so to be free to make changes to the format at will, but
the format seems pretty stable for RC1 unless the last bug I know in
the store engine is rooted in the format.

- Second level is the NewtonOS store format, i.e. how objects are
flattened to the store. Some stuff are known (such as how to find out
the name of the store) and some aren't (such as how the soups are
stored and so on). We can guess that frames are flattened the NSOF
formats, although there is no evidence of that. I don't recall if
Philz found some information about that.
It would be a good idea to reverse engineer this format, but it's
actually of no use for a Newton Emulator.

 From the ATA Support partition map format, however, one can make
Newton Store images to store it on a laptop. Unfortunately, I don't
have any PC card reader, so I can't work on that, but if anyone has
and wants to work on that, I'll be pleased to send the docs of the
partition map format. This shouldn't be too hard, the difficult part
is to find out on your OS how to read & write sectors from an ATA
card.
Additionally, I wrote a software some time ago that lets you make an
image of an ATA card using a Newton connected to a computer running
MacOS. It could be easily adapted to new developer APIs and include
the possibility to restore the image to the card.

Paul

-- 
Home page: http://www.kallisys.com/
Newton-powered WebServer: http://newton.kallisys.net:8080/

-- Read the List FAQ/Etiquette: http://www.newtontalk.net/faq.html Read the Newton FAQ: http://www.guns-media.com/mirrors/newton/faq/ This is the NewtonTalk mailing list - http://www.newtontalk.net



This archive was generated by hypermail 2.1.2 : Sun May 05 2002 - 14:02:50 EDT