I've had success using a digital band pass filter. Instead of fiddling
with velocities, a band pass filter just looks at the power spectrum
within a limited frequency range. I posted my code in the following
thread:

http://groups.google.com/group/android-developers/browse_thread/thread/d61f7790afb3f8b6/770777368e823548?lnk=raot

One problem with this particular example is that the center band of
3.6 Hz is too high. I think a center band of 1.8 Hz would work better.
If I get some time, I'll try recomputing the cooefficients, but
meanwhile you could also work out the math in the linked reference.
The other improvement to my example code would be to detect shake on
more than one axis.

hth

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to