Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
Summary 209 10.5 Summary In this chapter, we've covered three of the most unique features available to you as an SDK programmer. The accelerometers can give you access to a variety of information about where a device exists in space. By sensing gravity, you can easily discover precise orientation. By measuring movement, you can see how the device is being guided through space. Finally, you can build more complex movements into three-dimensional gestures, such as a shake. We've talked about the touch screen when discussing input, but the accelerome- ters provide another method for allowing users to make simple adjustments to a pro- gram. We can imagine game controls and painting programs built entirely around the accelerometers. The internal GPS can give you information about longitude, latitude, and altitude. The horizontal information is the most reliable, although it's more useful when you connect to the internet. Altitude information isn't available to everyone, and even if it is, it has a higher chance of being incorrect, so use it with caution. The compass gives you complete information about the user's heading. It lets you determine exactly which way the device is facing and allows for a large variety of new application types.