With the development of smart phone and Embedded Devices, many types ofsensors are added into theses terminals in hope of better performance and experience.Many of these sensors can receive and send data by using an I2C bus.The majority ofsystems running on these terminals are Android or system with a kernel of Linux.A driver for a type of angular rate sensor which transmits data through the I2Cbus is developed on a hardware platform called Freescale SABRE Lite Board.Linuxdevice driver model and sysfs file system are detailed discussed as well as thefunctionality mechanism of Android sensor module.In the final chapter, we verify the functionality of sensor and driver.According tothe requirements of Android Runtime Layer, the sensor is registered in Linux inputsubsystem and some attribute files of device are generated to provide control interfacesfor Android sensor module. |