On Fri, 2005-08-19 at 13:21 +0200, Johannes Berg wrote: > Hi, > > I have successfully reverse engineered the AMS using a variety of python > scripts, otool, libiberty (for C++ name demangling) and a bit of time. > Most useful is an old script I have that uses graphviz' dot to make a > flow graph out of asm. > > The OSX driver is remarkably well written. But maybe all OSX drivers > are, I don't know :)
Haha... some are, and some are very bad :) Probably depends who wrote it at Apple... > What I found is documented here: > > http://johannes.sipsolutions.net/PowerBook/Apple_Motion_Sensor_Specification > > Some things like how to set the sensitivity are missing, but in normal > operation the OSX driver do this. > > I have written a proof of concept driver that creates a HID device which > fully works, but I suppose I cannot publish it since I disassembled the > OSX driver. OTOH, it should be trivial to write a driver from this :) Hrm... I'm not sure there is such a problem with disassembling, but then, I'm no lawyer. Cleanroom is surely better. Hopefully, somebody will pick up from your doc soon enough. > Have fun. Maybe I'll see a real driver that can even handle interrupts > (I have no idea how to get the interrupt GPIO stuff from the PROM/OF) > when I get back online after the weekend? ;) You can look at how the sound driver does. Ben. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]