I\'m making an application that works as a compass, though I want to calibrate the accelerometer and the magneticfield sensors to make it more efficient.
The OnAccuracyChanged method of your listener is invoked by system, when a sensor begins to report with different accuracy - this is something you receive from the sensor, so you can not set it. SensorManager API has got some enumerations to let you check what accuracy is a sensor reporting at.