Library to get Magic Mouse’s data from Ruby.
Download the library and require the magicmouse.rb file in your code header.
The library needs to be initialized:
>> mouse = MagicMouse.new
Then, if you want to get the X axis position, do:
>> mouse.x_position => 0.842728
If you want to refresh the values, do:
>> mouse.refresh
For more informations, take a look at the sample-codes folder.
-
Mac OS X with Bluetooth
-
Magic Mouse installed and working.
-
Implement multitouch.
2009 © Developed by pH (Pedro Henrique Cavallieri Franceschi) You can find me at [email protected]. www.iBlogeek.com - 2006-2009 ©