accelerometer based mouse, what happens when tilted Answered
I got a free dual axis low g accelerometer from freescale, the output voltage is proportional to the g forces, I also have a ton of free PICmicro chips with I2C and A/D converters. I want to make a mouse just basically for proof of concept. I was thinking about how to program it, since I want to tell the computer the "movement since last request", I would need to calculate the speed using the g force reading (9.8m/s2 = 1g)
if the mouse is moving at a constant speed, the g force would be 0, and the speed would be the same as the last reading, also, gravity affects the reading if the mouse is tilted slightly, increasing the speed even if it is not moving at all, so I was thinking, if the mouse was tilted, and then balanced again, the speed would remain the same, causing annoyance to the user. this is the problem i would like to solve.
Is there a space efficient way to make a accelerometer not affected by tilt? if not, is there any tricks I can use (such as detecting unusually uniform g force and automatically go into "joystick mode")? I have been thinking about using a thumb button to zero the speed (while held down, the mouse can also do "super precise mode" which means one pixel per half second no mater how fast), is the thumb button the way to go? how about sensor to see if there is contact with a surface? or four IR rangers to detect tilt while above a surface?
side note: does anybody have a datasheet for ata1060xa? its a optical mouse sensor with built in 27mhz RF transmitter made by @lab, and they don't share datasheets.
oh and head on over to cypress for free wireless usb modules (2.4ghz i think, multiple channels) if you are interested in cheap RF, i have two with 50 meter range
info on mouses and keyboard serial interface found here