Sunday, May 23, 2010

Mac Mighty Mouse trackball embedded interface hack

Inspired by input nirvana from geekhack I got a free mighty mouse from a generous donor and went about interfacing to it. There's plenty of teardowns already available on the net, so I'll skip opening the mouse and just show this picture with the pinout to the trackball. Note that it's even simpler than most typical trackballs in that it doesn't make use of quadrature encoding for the two axes. The trackball actually has four distinct pulsed outputs corresponding to the four little wheels surrounding the ball. When rolling in any of the four cardinal directions (left,right, up,down) only one of those little wheels is actually spinning. Decoding the output of the overall trackball simply requires detecting pulses on each of the four pins. If the state of any pin changes from what it was during the last polling interval then you've moved in that direction. Instead of polling you could also just set up four pin change interrupts.

To test things out I hooked up the trackball to one of the new SMT connector boards from Schmartboard (seen in the picture) and from there to an atmega32u4.

At the moment I haven't decided whether to make a small wireless mouse out of this or integrate it into my kinesis project. I'm leaning heavily towards the former, since the keyboard already has 4 pointing devices.

Total time taken from disassembly to working USB trackball mouse (including the time for this quick writeup): ~2hours 10 mins.


  1. Shop of Ray Ban sunglasses, UK cheap Ray Ban sunglasses on sale for men and women, Ray Ban outlet on huge discount.

  2. You should take part in a contest for one of the most useful sites on the web. I am going to recommend this blog! Get More Info!

  3. Thank you for your helpful information. I like this blog. Thanks for sharing.
    eCommerce Service Providers