I want to create an app that which get close whenever the device shakes. Can anyone explain how to do that?
I have an idea that it requires to create a service that runs in background, but I am struggling with actual coding and don't know how to do it.