I want to get the android's accelerometer (x y z coordinates) like this code:
http://www.techrepublic.com/blog/software-engineer/a-quick-tutorial-on-coding-androids-accelerometer/ (function: onSensorChanged(SensorEvent event))
But I can't to catch events from my code because I'm not in the activity class.
Does anyone have an idea how to access this information without access to events?