In some embodiments, the electronic device may control the preset region of the display screen to display the predetermined picture when there is a need to detect the ambient light intensity. That is, the electronic device may control the preset region of the display screen to display the predetermined picture in response to a triggering event, such as a user instruction, a time point and so on. In some embodiments, the electronic device may also control the preset region of the display screen to display the predetermined picture all the time.
At block S120, an ambient light intensity value detected by the ambient light sensor is obtained.
When the preset region of the display screen of the electronic device displays the predetermined picture, the electronic device may control the ambient light sensor to detect a current ambient light intensity value. The electronic device obtains the ambient light intensity value detected by the ambient light sensor.
It should be understood that, when the ambient light sensor detects the ambient light intensity value, external environment light (i.e., visible light) enters the ambient light sensor through the display region of the display screen. When the display region of the display screen displays information, the display screen itself is also illuminated, and light emitted by the display screen is also visible light. The light emitted by the display screen may also enter the ambient light sensor, thus affecting detection result of the ambient light sensor.