Magnetic Compass in Android phones Magnetic compass is used to locate the direction and the position of a particular location, as the position ch…