Method and system for dual calibration of proximity sensor
暂无分享,去创建一个
The invention discloses a method and system for dual calibration of a proximity sensor. The method for dual calibration of the proximity sensor comprises the steps that data in a data register of the proximity sensor are read multiple times during starting of a mobile terminal, and the proximity sensor is calibrated according to the data read during starting of the mobile terminal to obtain a first calibration result; the data in the data register of the proximity sensor are read multiple times before communication of the mobile terminal, and the proximity sensor is calibrated according to the data read before communication of the mobile terminal to obtain a second calibration result; when calibration succeeds according to the second calibration result, a threshold value of the proximity sensor is obtained according to the data read before communication of the mobile terminal, and when the calibration fails according to the second calibration result and succeeds according to the first calibration result, the threshold value of the proximity sensor is obtained according to the data read during starting of the mobile terminal.