How can we launch a application by just shaking the device? I want to do something similar to the app "Appshaker".
Asked
Active
Viewed 6,824 times
1 Answers
12
From an activity, you can use the SensorManager
to detect a shake, then react to that shake. That is what AppShaker does. Here is a sample project demonstrating one way to detect a shake.

CommonsWare
- 986,068
- 189
- 2,389
- 2,491
-
Was looking for that exact thing! Thanks. Cool app btw – Mahadevan Sreenivasan Apr 27 '11 at 11:59
-
@MahadevanSreenivasan please check this issue: http://stackoverflow.com/questions/22319601/shake-phone-to-launch-app – Sun Mar 15 '14 at 08:04