I have read through a lot of code but I do not understand how you can make an image move using the accelerometer sensor, I understand how to register it but I do not understand how to actually make an image or a shape draw move in sync with the accelerometer axis, I am using android java to do this. Please can someone help me as I am really struggling. Thank you for your time and help.
Share
So, here’s the code to register a listener (I know you said you’ve done this already, but it can never hurt):
You will need a couple fields just below your class declaration:
Here is the event handler, which gets very close to what you need help with: