With the popularity of the smart phones, a variety of sensors were integrated intothe Personal Digital Assistant for improving user experiences. More of these sensorssupport the I~2C bus transfer protocol. Generally, the mobile processors integrate one ormore I~2C controllers for supporting all kinds of peripherals.This paper taking the development of a mobile processor based on ARMContext-A5as the background. Introducing the design and implementation of the driverabout the I~2C-bus controller integrated in the processor, and the design andimplementation of the driver about the acceleration sensor (G-sensor) connected to thisI~2C controller.In this paper, the working condition of the acceleration sensor is used to verify thereliability of the I~2C controller and its drivers. And improve the performance of the twodevices by optimizing the drive. |