1.Android sensor is the standard equipment of android mobile phone.
2.sensor type and function
Acceleration sensor, magnetic induction sensor, direction sensor, gyroscope, light sensor, pressure sensor,
Temperature sensor, distance sensor, gravity sensor, linear acceleration, overturn sensor, sex and humidity sensor, etc.
(1) Acceleration sensor
Function: data of three axes can be obtained
Principle: Deform the inside of the acceleration sensor and output three corresponding voltage signals
Application: Shake, game control, etc.
(2) Magnetic induction sensor
Function: Obtain the change of the magnetic field and output the change data of the three axes
Data: X, Y, Z three directions
Application: compass, orientation of positioning devices, etc.
(3) Gyro sensor
Principle: Conservation of angular momentum, there is a gyroscope in the middle, and the positioning components of the three axes around it give three angular velocities according to the rotation process
Data: Return the angular velocity data of the X, Y, and Z axes
Function: game
The difference between the three main sensors of Android:
(1) Acceleration sensor: test the gravity of the equipment, relative to the external reference object;
(2) Magnetometer sensor: locate the orientation of the device. Can measure the angle between the current device and the four directions of east, west, north, south;
(3) Gyro sensor: Measures the rotational motion of the device itself. It is better at the movement of the device itself, but cannot determine the orientation of the device.
Android other sensors:
(1) Light sensor: automatically adjust the brightness of the mobile phone screen;
(2) Proximity sensor: black screen when calling close to the ear;
(3) Pressure sensor: test the distance between the mobile phone and the ground;
3. The system architecture of sensor
app --> framework --> Hal --> driver --> Hardware