ios sensors
AVAILABLE sensors
- Camera
- Bluetooth
- Audio
- Accelerometer
- Magnetometer
- Gyroscope
- GPS
- Speaker
- Microphone
- Proximity
Accelerometer
- Measures acceleration about all three axis.
- Current position of device relative to ground.
- Measurement is with respect to gravity.
Accelerometer
- When the phone sets on your desk with the screen pointed upward, The accelerometer would give you a value of -1g in the Z Direction. If you were to put the phone face down it would give a 1g value.
- Holding the phone straight up and down would have a value of -1g in the Y direction, Assuming you can stay 100% still. Again, you can probably guess what happens when you hold the phone with the screen facing you and the home button on upward.
Accelerometer
- If you hold the phone with the screen facing you and then rotate it 90 degrees left, you’ll get a -1g value in the X direction. Rotate it right, And you’ll see a 1g value.
- The g here stands for gravity or 9.8m/s^2, at any given time when the phone is at a stand still, the earth is pulling down with the force of gravity. In free fall, the accelerometors read 0.
gyroscope
- Senses rotation around any XYZ axis.
- Output data in terms of units rotations per second.
- If you were to rotate the iPhone 5 times around the Z axis in one second, The output would be eitehr -5 or 5 depending on wether or not you rotated it in the clockwise or counterclockwise direction.
magnetometer
- Report to a direction in which device is pointing.
- Magnetometer data can be obtained in two ways:
- using core Location
- using core motion
GPS:
- can be used to report to a direction in which device is moving.
Frameworks
- http://www.politepix.com/openears/
- https://github.com/KingOfBrian/VocalKit
References:
- http://dl.e-book-free.com/2013/07/basic_sensors_in_ios.pdf
ios sensors
By Torry Harris Business Solutions
ios sensors
- 899