The latest Slam Stick release has an IMU capable of recording the device's orientation relative to either its initial orientation (relative orientation), or to relative to magnetic north (absolute orientation). As I discuss elsewhere, the sensor uses a magnetometer to measure the Earth's magnetic field for absolute orientation, along with the accelerometer and gyroscope used to track gravity and the device's movement. The algorithms to synthesize these sensors into one set of coordinates are relatively complicated, and they need to go through a calibration procedure to become accurate.
The calibration procedure consists of exposing the device to a variety of data by rotating it slowly through some orthogonal positions, and letting the device sit for a second at each position. The Slam Stick has a blue light that blinks more frequently when it has low accuracy, and stays off when it is highly accurate.
Once the Slam Stick is calibrated, it should stay calibrated as long as it is not exposed to acceleration past 4gs, rotation past 300 revolutions per minute, or external magnetic fields.