
When you turn an iPhone or an iTouch on it’s side the image changes orientation, switching between portrait and landscape. This occurs because the interface is controlled by a motion sensor called a 3-axis accelerometer. It senses the orientation of the phone and adjusts the display by measuring acceleration relative to freefall along a x, y and z axis. X measures acceleration to the right as positive and to the left as negative. Y measures acceleration to the top as positive and to the bottom as negative. Z measures acceleration to the front as positive and to the back as negative. The measurement of acceleration takes into account inertia and gravity on earth.
