CN112492102A - Terminal screen brightness control method and terminal - Google Patents
Terminal screen brightness control method and terminal Download PDFInfo
- Publication number
- CN112492102A CN112492102A CN201910769060.2A CN201910769060A CN112492102A CN 112492102 A CN112492102 A CN 112492102A CN 201910769060 A CN201910769060 A CN 201910769060A CN 112492102 A CN112492102 A CN 112492102A
- Authority
- CN
- China
- Prior art keywords
- brightness
- light
- value
- terminal
- values
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- G—PHYSICS
- G09—EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
- G09G—ARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
- G09G5/00—Control arrangements or circuits for visual indicators common to cathode-ray tube indicators and other visual indicators
- G09G5/10—Intensity circuits
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Computer Hardware Design (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Controls And Circuits For Display Device (AREA)
Abstract
The invention relates to the technical field of wireless communication, in particular to a method for controlling the screen brightness of a terminal and the terminal, which are used for solving the problem that the screen brightness is automatically adjusted by a terminal backlight when the ambient light changes rapidly, so that the screen of the terminal is suddenly bright and suddenly dark. The terminal detects the brightness value of the ambient light; after detecting continuous M light and shade alternating intervals, the terminal determines that the brightness fluctuation occurs in the current environment; and the terminal adjusts the screen brightness and keeps the adjusted brightness. According to the control method for the ambient light sensitivity value of the automatic backlight of the terminal, provided by the embodiment of the invention, when the fluctuation of the ambient light brightness is detected, the screen brightness is in a stable state by adjusting the input light sensitivity value of the automatic backlight, so that the problem that the terminal screen brightness is suddenly changed when the ambient light brightness changes quickly is avoided.
Description
Technical Field
The invention belongs to the technical field of wireless communication, and particularly relates to a method for controlling the screen brightness of a terminal and the terminal.
Background
With the development of the times, various multifunctional intelligent mobile terminals are more and more commonly used in people, and people use the intelligent terminals to work, socialize, entertain and the like at any time and any place.
When the terminal is used, the visual fatigue of human eyes can be generated when the brightness of the terminal screen is not coordinated with the brightness of the ambient light. At present, most intelligent mobile terminals can automatically adjust the screen brightness according to the brightness of the environment. When the ambient light brightness is high, the terminal brightens the screen brightness so as to ensure that a user can clearly see the screen; when the ambient light brightness is small, the terminal dims the screen brightness to prevent the screen from being too bright and stabbing eyes. Thus, the screen brightness of the terminal can change along with the ambient light brightness. However, when the brightness of the ambient light in the environment where the terminal is located changes rapidly, the brightness of the screen of the terminal changes suddenly and dimly with the frequent change of the ambient light brightness, and the user experience is poor.
In summary, the current automatic backlight adjustment of the terminal screen brightness can cause the terminal screen to dim and light when the ambient light brightness changes rapidly.
Disclosure of Invention
The invention provides a terminal screen brightness control method and a terminal, which are used for solving the problem that a terminal screen is suddenly bright and suddenly dark due to the fact that the terminal automatically adjusts the screen brightness in a backlight mode when ambient light changes quickly.
Based on the foregoing problem, in a first aspect, an embodiment of the present invention provides a method for controlling terminal screen brightness, including:
the terminal detects the brightness value of the ambient light;
after M continuous light and shade alternating intervals are detected, the terminal determines that the brightness fluctuation occurs in the current environment; the light and dark alternating interval comprises a light interval and a dark interval, the light interval comprises continuous not less than N light values, the dark interval comprises continuous not less than N dark values, the light values are brightness values larger than a first threshold value, the dark values are brightness values not larger than the first threshold value, and M, N is a positive integer;
and the terminal adjusts the screen brightness and keeps the adjusted brightness.
In a second aspect, an embodiment of the present invention provides a terminal, including at least one processing unit and at least one storage unit;
wherein the storage unit stores program code that, when executed by the processing unit, causes the processing unit to perform the following:
detecting a brightness value of the ambient light;
after M continuous light and shade alternating intervals are detected, determining that the brightness fluctuation occurs in the current environment; the light and dark alternating interval comprises a light interval and a dark interval, the light interval comprises continuous not less than N light values, the dark interval comprises continuous not less than N dark values, the light values are brightness values larger than a first threshold value, the dark values are brightness values not larger than the first threshold value, and M, N is a positive integer;
and adjusting the screen brightness and keeping the adjusted brightness.
In a third aspect, an embodiment of the present invention provides a device for controlling terminal screen brightness, including:
the detection module is used for detecting the brightness value of the ambient light;
the determining module is used for determining that the brightness fluctuation occurs in the current environment after M continuous light and shade alternating intervals are detected; the light and dark alternating interval comprises a light interval and a dark interval, the light interval comprises continuous not less than N light values, the dark interval comprises continuous not less than N dark values, the light values are brightness values larger than a first threshold value, the dark values are brightness values not larger than the first threshold value, and M, N is a positive integer;
and the control module is used for adjusting the screen brightness and keeping the adjusted brightness.
In a fourth aspect, embodiments of the present invention provide a computer-readable medium on which a computer program is stored, which when executed by a processor, performs the steps of the method according to the first aspect.
Because the terminal detects the brightness value of the ambient light, when the brightness fluctuation of the current environment is determined after the continuous M light and shade alternating intervals are detected, the terminal adjusts the screen brightness and keeps the adjusted screen brightness. When the terminal detects the fluctuation of the ambient light brightness, the terminal enables the screen to be in stable brightness by adjusting the screen brightness, and the problem that the terminal screen is suddenly bright and suddenly dark when the ambient light brightness changes quickly is avoided.
Drawings
Fig. 1 is a schematic view of a scene in which brightness fluctuation occurs in an environment where a terminal is located according to an embodiment of the present invention;
FIG. 2 is a flowchart of a method for controlling the brightness of a terminal screen according to an embodiment of the present invention;
FIG. 3 is a schematic diagram illustrating an ambient light brightness value detected by a terminal according to an embodiment of the present invention;
FIG. 4 is a diagram illustrating a mathematical model of an aperiodic sawtooth waveform according to an embodiment of the present invention;
FIG. 5a is a diagram illustrating a ring buffer storing data according to an embodiment of the present invention;
FIG. 5b is a diagram illustrating overflow data of a ring buffer according to an embodiment of the present invention;
FIG. 6 is a diagram illustrating the conversion between the wave light mode and the non-wave light mode of the terminal according to the embodiment of the invention;
FIG. 7 is a flowchart illustrating an overall method for controlling the brightness of the terminal screen according to an embodiment of the present invention;
fig. 8 is a schematic structural diagram of a first terminal according to an embodiment of the present invention;
fig. 9 is a schematic structural diagram of a second terminal according to an embodiment of the present invention;
fig. 10 is a schematic structural diagram of a device for controlling the brightness of a terminal screen according to an embodiment of the present invention.
Detailed Description
The terminal of the embodiment of the present invention may be a cellular phone, a cordless phone, a Session Initiation Protocol (SIP) phone, a Wireless Local Loop (WLL) station, a Personal Digital Assistant (PDA), or the like.
Most of existing intelligent mobile terminal devices, such as mobile phones, tablet computers and the like, automatically adjust brightness according to the principle that a terminal screen is provided with an optical sensor, and the terminal adjusts the screen brightness according to the brightness value of ambient light detected by the optical sensor. However, in some scenarios, the luminance value of the ambient light detected by the terminal light sensor changes more frequently, and when the terminal adjusts the screen luminance, the terminal adjusts according to the luminance value of the ambient light detected by the light sensor, so that the terminal screen luminance also changes more frequently. Such as the following common scenarios:
when a user sits at a window, the phenomenon that bright light and dark light appear alternately can be caused when the user drives the street lamp (or the user walks through the street lamp) if the user sits at the window, as shown in fig. 1, the terminal moves along with the driving vehicle, a bright light area is formed in the area where the street lamp is located, and a dark light area is formed between two street lamps which are far away from each other. When a user uses the terminal under the light scene, because the optical sensor of the terminal screen is sensitive to the change of the ambient light brightness, when the detected ambient light brightness value is alternate, the terminal screen brightness can be changed along with the detected ambient light brightness value.
Based on the above problems, embodiments of the present invention provide a method for controlling screen brightness of a terminal, where a terminal detects a brightness value of ambient light through an optical sensor, and determines that brightness fluctuation occurs when it is detected that a change in brightness of the ambient light is frequent, and the terminal adjusts the screen brightness and maintains the adjusted screen brightness, so as to solve a problem that a screen of the terminal is suddenly bright and suddenly dark due to automatic backlight adjustment of the screen brightness by the terminal when the change in the ambient light is frequent.
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The embodiment of the invention provides a method for controlling the brightness of a terminal screen, which comprises the following steps of:
and 203, the terminal adjusts the screen brightness and keeps the adjusted brightness.
Through the scheme, the terminal detects the brightness value of the ambient light, and determines that the brightness fluctuation occurs in the current environment after detecting continuous M light and shade alternating intervals, and at the moment, the terminal adjusts the screen brightness and keeps the adjusted screen brightness. When the terminal detects the fluctuation of the ambient light brightness, the terminal enables the screen to be in stable brightness by adjusting the screen brightness, and the problem that the terminal screen is suddenly bright and suddenly dark when the ambient light brightness changes quickly is avoided.
In the implementation process, in step 203, the terminal controls the automatic backlight input light sensitivity value to keep the screen brightness unchanged.
In the using process of the terminal, the terminal continuously detects the brightness value of the ambient light; for example, the terminal shown in fig. 3 detects the ambient light brightness value within 70 s.
After detecting the brightness value of each ambient light, the terminal compares the detected brightness value of each ambient light with a preset first threshold value, and judges that the detected brightness value of each ambient light is a bright light value or a dark light value; the bright light value is a brightness value larger than a first threshold value, and the dark light value is a brightness value not larger than the first threshold value.
After detecting the brightness values of a plurality of ambient lights, taking continuous bright values not less than N as a bright interval and taking continuous dark values not less than N as a dark interval; the adjacent bright light interval and the dark light interval form a light and shade alternating interval.
In implementation, when detecting a light and dark alternating interval, the embodiment of the invention establishes an aperiodic irregular sawtooth wave mathematical model for the brightness value of the detected environment light, and determines the detected light and dark alternating interval through the mathematical model;
specifically, the ambient light brightness value shown in fig. 3 is modeled as a non-periodic irregular sawtooth wave mathematical model shown in fig. 4; wherein, in the time period from t1 to t2, the brightness value of the environment light is greater than the first threshold value, and in the time period from t2 to t3, the brightness value of the environment light is not greater than the first threshold value. the continuous bright values not less than N in the range from t1 to t2 form a bright range which can also be called a peak; the continuous dark light values not less than N from t2 to t3 form a dark light interval which can also be called a trough; t1 to t3 are adjacent bright light intervals and dark light intervals, which form a bright and dark alternating interval, and can also be called a sawtooth wave. When detecting that the brightness is not less than M light and shade alternation intervals in a certain time, the terminal determines that the brightness fluctuation occurs in the current environment.
The terminal stores the detected brightness value of the ambient light in the buffer, compares the brightness value of the ambient light with a first threshold value by scanning the brightness value of the ambient light stored in the buffer, and judges whether the detected brightness value of the ambient light is a bright light value or a dark light value; the embodiment of the present invention is described by taking a ring buffer as an example.
A circular buffer, also called a circular queue, is a data structure for representing a fixed-size, head-to-tail buffer area, suitable for buffering a data stream, and is a first-in-first-out circular buffer, such as the circular buffer shown in fig. 5a, which sequentially stores data from the beginning of the buffer, sequentially stores natural numbers 1, 2, 3, … … into the circular buffer, and stores first data 1 into the circular buffer, and when storing second data 2, first data 1 is shifted by one bit to the tail end of the circular buffer, and when storing third data 3, data 1 and 2 stored in front of the circular buffer are shifted by one bit to the tail end of the circular buffer.
Assuming that the total capacity size of the ring buffer is n, as shown in fig. 5b, when the amount of data stored in the ring buffer is n-1, if the nth data is stored again, the amount of data in the ring buffer reaches the total capacity size n of the ring buffer. At this time, when the (n + 1) th data is stored into the ring buffer, the stored first data 1 will overflow the ring buffer. In the embodiment of the present invention, the detected brightness value of the ambient light is stored in the ring buffer, and if the environment buffer can store the brightness value of the ambient light detected within 70 seconds, when the ring buffer is full of the brightness value of the ambient light, if the brightness value of the ambient light is stored again, the brightness value before 70 seconds of the current time will overflow, that is, the brightness value of the ambient light stored in the ring buffer is the brightness value of the ambient light within 70 seconds before the current time.
In one embodiment, the brightness value of the ambient light stored in the ring buffer is scanned and compared with the brightness value of the first threshold. If the brightness value of the environment light is larger than the first threshold value, the brightness value of the environment light is considered as a bright light value; if the brightness value of the environment light is not larger than the first threshold value, the brightness value of the environment light is considered as a dark light value. Assume that the first threshold is 30lux (lux). Wherein lux is the unit of illumination. When the brightness value of the ambient light is greater than 30lux, for example, the brightness value of the ambient light is 35lux, the brightness value of the ambient light is considered as a bright value; when the luminance value of the ambient light is not more than 30lux, for example, the luminance value of the ambient light is 24lux, the luminance value of the ambient light is considered to be a dark light value.
Setting a first numerical value for counting the number of continuous bright values, a second numerical value for counting the number of continuous dark values and a third numerical value for counting the number of continuous bright and dark alternating intervals. Before detecting whether the brightness value of the ambient light is a bright light value or a dark light value, the initial values of the first numerical value, the second numerical value and the third numerical value are all 0.
The following describes the statistical manner of the first, second and third values:
the terminal starts to scan the brightness value of the stored environment light in the annular buffer and compares the brightness value with a first threshold value to judge whether the detected brightness value of the environment light is a bright light value or a dark light value; after a bright light value is detected, adding 1 to the first value, continuously detecting the brightness value of the next environment light, and adding 1 to the first value when the detected brightness value of the next environment light is the bright light value; when the detected brightness value of the next environment light is a dim light value, since the first numerical value is used for counting the number of continuous bright light values and the detected dim light value represents continuous interruption of the bright light values, the first numerical value is recorded as 0, and the second numerical value is added with 1;
after detecting a plurality of continuous bright light values, judging whether the first value is smaller than N. If the first value is smaller than N, adding 1 to the first value when detecting that the brightness value of the next ambient light is a bright light value; when the brightness value of the next ambient light is detected to be a dark light value, the first value is recorded as 0, and the second value is added by 1. If the first value is not less than N, determining a bright light interval, and continuously detecting the brightness value of the next ambient light; when the brightness value of the next environment light which is continuously detected is a bright light value, adding 1 to the first numerical value; when the detected brightness value of the next ambient light is a dark light value, recording the first numerical value as 0, and adding 1 to the second numerical value; if a plurality of continuous dark light values are detected after a bright light interval is determined, judging whether the second value is smaller than N; if the second value is smaller than N, when the brightness value of the next environment light which is continuously detected is a bright light value, recording the second value as 0, neglecting the determined bright light interval, and recording the first value as 1; and if the second value is not less than N, determining a dark light interval, forming a light and dark alternating interval by the determined light and dark intervals, adding 1 to the third value, continuously detecting the brightness value of the next environment light, and adding 1 to the third value when detecting the second light and dark alternating interval.
And when the third value is not less than M, the terminal determines that the brightness fluctuation occurs in the current environment.
N and M of the embodiment of the present invention are both values preset according to the vehicle running speed or empirical values preset by those skilled in the art.
For example, assuming that the first threshold is 30lux and N is 5, the brightness value of the scanned ambient light in the ring buffer is shown in table 1:
TABLE 1
The initial values of the first numerical value, the second numerical value and the third numerical value are all 0, the brightness value of the 1 st ambient light is detected to be 28lux, the brightness value is compared with the first threshold value to be 30lux, and as the 1 st brightness value is not larger than the first threshold value, namely a dark light value is detected, the second numerical value for counting the number of continuous dark light values is added with 1; continuously detecting the brightness value of the 2 nd ambient light and comparing the brightness value with the first threshold value, detecting that the 2 nd brightness value is a dark light value, and adding 1 to the second numerical value, wherein the second numerical value is 2; if successive dark light values are detected and the second value is 2 and less than 5, the next brightness value is detected. Detecting that the brightness value of the 3 rd ambient light is 31lux, comparing the brightness value with the first threshold value of 30lux to obtain that the 3 rd brightness value is a bright light value, continuously interrupting a dark light value, recording the second value as 0, and adding 1 to the first value;
and continuously detecting the brightness value of the environment light in the annular buffer, detecting that the 4 th brightness value, the 5 th brightness value, the 6 th brightness value, the 7 th brightness value and the 8 th brightness value are all brightness values, sequentially adding 1 to the first numerical value to obtain a first numerical value of 6, detecting 6 continuous brightness values, and determining a brightness interval.
Detecting that the 9 th brightness value is 30lux and not more than a first threshold value, if the 9 th brightness value is a dark light value, recording the first numerical value as 0, and adding 1 to the second numerical value; and detecting that the 10 th, 11 th, 12 th, 13 th, 14 th and 15 th brightness values are all dark light values, sequentially adding 1 to the second numerical value to obtain a second numerical value of 7, detecting 7 continuous dark light values, and determining a dark light interval. Forming a light and shade alternating interval by the determined adjacent bright light interval and the dark light interval, and adding 1 to a third numerical value; when the second light and shade alternation interval is detected, the third value is added with 1.
And when the third value is not less than M, the terminal determines that the brightness fluctuation occurs in the current environment. Assuming that M is 10, when detecting the brightness value stored in the ring buffer, and when detecting 10 consecutive light and dark alternating intervals, the terminal determines that the environment has brightness fluctuation, and then the terminal enters a fluctuation light mode. And the terminal adjusts the screen brightness in the fluctuation light mode and keeps the adjusted brightness.
In implementation, if the environment where the user is located is the light scene shown in fig. 1, after the terminal determines that the current environment has brightness fluctuation according to the detected brightness value of the ambient light, the terminal enters a fluctuation light mode, and the terminal adjusts the screen brightness and maintains the adjusted brightness, so that the phenomenon that the terminal screen is dim and bright is avoided.
The embodiment of the invention adjusts the screen brightness according to the following modes:
and the terminal determines an automatic backlight input light sensation value according to the detected dark light value and adjusts the screen brightness according to the automatic backlight input light sensation value.
In implementation, the terminal may determine the automatic backlight input light sensitivity value according to the following manner:
the first method is as follows: and taking the dark light value detected last time as the automatic backlight input light sensitivity value.
In implementation, after detecting M consecutive light and dark alternating intervals, the terminal determines that the brightness fluctuation occurs in the current environment, and then uses the last dark light value of the dark light interval in the mth light and dark alternating interval as the automatic backlight input light sensitivity value.
Assuming that after detecting M consecutive alternating bright and dark intervals, the brightness value stored in the buffer is shown in Table 2:
TABLE 2
The last dark light value stored in the buffer is the 15 th luminance value, and the 15 th luminance value of 27lux is used as the automatic backlight input light sensitivity value.
Assuming that after detecting M consecutive alternating bright and dark intervals, the brightness value stored in the buffer is shown in Table 3:
TABLE 3
The last dark light value stored in the buffer is set as the 9 th luminance value, and the 9 th luminance value 26lux is set as the automatic backlight input light sensitivity value.
The second method comprises the following steps: and taking the average value of the dark light values detected in the first preset time period as the automatic backlight input light sensitivity value.
For example, assuming that the first preset time duration is 3 seconds, after detecting M light and dark alternating regions, the terminal determines that the brightness fluctuation occurs in the current environment, and then the terminal takes the average value of the dark light values detected within the first 3 seconds of the current time as the automatic backlight input light sensation value.
In implementation, assuming that the terminal stores the detected brightness value of the ambient light in the ring buffer, the dark light value stored in the ring buffer for a first preset time before the brightness fluctuation of the current environment is determined, and an average value thereof is calculated, the calculated average value is used as an automatic backlight input light sensitivity value, and assuming that the brightness value of the ambient light stored in the ring buffer in the previous 3 seconds of the current time is as shown in table 4:
TABLE 4
Wherein the dark light value is: 28lux, 27lux, 30lux, 26lux, 25lux, 22lux, 20lux, 22lux, 25lux, and the average value thereof was calculated: (28+27+30+26+25+22+20+22+25) ÷ 9 ═ 25lux, then the automatic backlight input light sensitivity value is 25 lux.
After the terminal determines the input light sensitivity value of the automatic backlight through any one of the two modes provided by the embodiment of the invention, the screen brightness of the terminal is adjusted according to the backlight adjusting curve, and the input light sensitivity value of the automatic backlight is converted into the screen backlight through the backlight adjusting curve, so that the screen brightness is adjusted.
In addition, along with the movement of the terminal, the terminal can enter other light scenes; for example, when the vehicle arrives at a destination, the user enters the room with the vehicle and is in a bright environment, or when the vehicle stops running, the terminal is in a scene with stable brightness for a long time. Therefore, after the terminal determines that the brightness fluctuation occurs and enters the fluctuation light mode, the terminal needs to continuously detect the brightness value of the ambient light so as to determine whether the terminal is in the environment with the brightness fluctuation, and when the terminal is determined not to be in the environment with the brightness fluctuation, the terminal exits the fluctuation light mode and enters the non-fluctuation light mode.
When the following conditions are met, the terminal determines that the brightness fluctuation does not occur in the current environment:
and when the terminal determines that the ratio of the number of the detected bright light values in the second preset time length to the total number of the detected brightness values is greater than a second threshold value, determining that the brightness fluctuation does not occur in the current environment.
For example, the second preset time period is 10 seconds, and the second threshold value is 0.8. Assuming that the total number of brightness values stored in the ring buffer within 10 seconds is 50, if the number of brightness values is 45, the terminal determines that no brightness fluctuation occurs in the current environment because the ratio 0.9 of 45 to 50 is greater than the second threshold value 0.8.
And after the terminal determines that the environment is not subjected to brightness fluctuation, the terminal exits the fluctuation light mode and enters a non-fluctuation light mode.
In the embodiment of the invention, the terminal takes the detected brightness value of the ambient light as the input light sensitivity value of the automatic backlight to adjust the screen brightness in the non-fluctuating light mode.
An optional implementation manner is that after determining that the environment where the terminal is located does not have brightness fluctuation, the terminal uses the detected brightness value of the ambient light as an automatic backlight input light sensitivity value, and may convert the automatic backlight input light sensitivity value into screen backlight according to a backlight adjustment curve, so as to adjust the screen brightness.
As shown in fig. 6, a schematic diagram of the conversion between the wave light mode and the non-wave light mode of the terminal according to the embodiment of the present invention.
When the terminal enters a use state, the terminal enters a non-fluctuating light mode by default, the terminal continuously detects the brightness value of the ambient light, and the screen brightness is adjusted through the detected ambient light. When M continuous light and shade alternating intervals are detected, the terminal determines that the environment where the terminal is located generates brightness fluctuation, and the terminal enters a fluctuation light mode. In the fluctuating light mode, the automatic backlight input light sensitivity value is determined by the detected dark light value, and the detection of the brightness value of the ambient light is continued. And when the ratio of the number of the detected brightness values to the total number of the detected brightness values is greater than a second threshold value within a second preset time period, the terminal determines that the environment where the terminal is located does not generate brightness fluctuation, and the terminal enters a non-fluctuation light mode.
As shown in fig. 7, a complete flow chart of the method for controlling the screen brightness of the terminal according to the embodiment of the present invention.
701, detecting the brightness value of the ambient light by the terminal;
703, the terminal determines that the brightness fluctuation occurs in the current environment;
Based on the same inventive concept, the embodiment of the present invention further provides a terminal, and as the principle of solving the problem of the terminal is similar to the method for controlling the brightness of the screen of the terminal in the embodiment of the present invention, the implementation of the terminal may refer to the implementation of the method, and repeated details are not repeated.
As shown in fig. 8, a terminal according to an embodiment of the present invention includes at least one processing unit 800 and at least one storage unit 801;
wherein the memory unit 801 stores program code which, when executed by the processing unit 500, causes the processing unit 800 to perform the following procedure:
detecting a brightness value of the ambient light;
after M continuous light and shade alternating intervals are detected, determining that the brightness fluctuation occurs in the current environment; the light and dark alternating interval comprises a light interval and a dark interval, the light interval comprises continuous not less than N light values, the dark interval comprises continuous not less than N dark values, the light values are brightness values larger than a first threshold value, the dark values are brightness values not larger than the first threshold value, and M, N is a positive integer;
and adjusting the screen brightness and keeping the adjusted brightness.
Optionally, the processing unit 800 is specifically configured to:
and determining an automatic backlight input light sensation value according to the detected dark light value, and adjusting the screen brightness according to the automatic backlight input light sensation value.
Optionally, the processing unit 800 is specifically configured to:
taking the last detected dim light value as the automatic backlight input light sensitivity value; or
And taking the average value of the detected dim light values in the first preset time as the input light sensitivity value of the automatic backlight.
Optionally, the processing unit 800 is further configured to:
detecting the brightness value of the ambient light after adjusting the screen brightness and keeping the adjusted brightness; when the ratio of the number of the detected brightness values in the second preset time length to the total number of the detected brightness values is larger than a second threshold value, determining that the brightness fluctuation does not occur in the current environment; and adjusting the screen brightness by taking the detected brightness value of the ambient light as an automatic backlight input light sensitivity value.
As shown in fig. 9, another terminal 900 for controlling the brightness of a terminal screen according to an embodiment of the present invention includes: light sensor 910, power supply 920, processor 930, memory 940, input unit 950, display unit 960, camera 970, etc. Those skilled in the art will appreciate that the configuration of the terminal shown in fig. 9 is not intended to be limiting, and that the terminal provided by the embodiments of the present application may include more or less components than those shown, or some components may be combined, or a different arrangement of components may be provided.
The following describes the various components of the terminal 900 in detail with reference to fig. 9:
the light sensor 910 may be used to detect a brightness value of ambient light.
The memory 940 may be used to store software programs and modules. The processor 930 executes various functional applications and data processing of the terminal 900 by executing the software programs and modules stored in the memory 940, and after the processor 930 executes the program codes in the memory 940, part or all of the processes in fig. 2 and 7 according to the embodiments of the present invention can be implemented.
Alternatively, the memory 940 may mainly include a program storage area and a data storage area. Wherein, the storage program area can store an operating system, various application programs (such as communication application), various modules for WLAN connection, and the like; the storage data area may store data created according to the use of the terminal, and the like.
Further, the memory 940 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
The input unit 950 may be used to receive numeric or character information input by a user and generate key signal inputs related to user settings and function control of the terminal 900.
Alternatively, the input unit 950 may include a touch panel 951 and other input terminals 952.
The touch panel 951, also referred to as a touch screen, can collect touch operations of a user (for example, operations of a user on or near the touch panel 951 using any suitable object or accessory such as a finger or a stylus pen) and drive a corresponding connection device according to a preset program. Alternatively, the touch panel 951 may include two parts, i.e., a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts it into touch point coordinates, and sends the touch point coordinates to the processor 930, and can receive and execute commands sent from the processor 930. In addition, the touch panel 951 may be implemented in various types, such as resistive, capacitive, infrared, and surface acoustic wave.
Optionally, the other input terminals 952 may include, but are not limited to, one or more of a physical keyboard, function keys (e.g., volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.
The display unit 960 may be used to display information input by a user or information provided to a user and various menus of the terminal 900. The display unit 960 is a display system of the terminal 900, and is configured to present an interface and implement human-computer interaction.
The display unit 960 may include a display panel 961. Alternatively, the Display panel 961 may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like.
Further, the touch panel 951 may cover the display panel 961, and when the touch panel 951 detects a touch operation on or near the touch panel 951, the touch panel 951 transmits the touch operation to the processor 930 to determine the type of the touch event, and then the processor 930 provides a corresponding visual output on the display panel 961 according to the type of the touch event.
Although in fig. 9, the touch panel 951 and the display panel 961 are two independent components to implement the input and output functions of the terminal 900, in some embodiments, the touch panel 951 and the display panel 961 may be integrated to implement the input and output functions of the terminal 900.
The processor 930 is a control center of the terminal 900, connects various components using various interfaces and lines, performs various functions of the terminal 600 and processes data by operating or executing software programs and/or modules stored in the memory 940 and calling data stored in the memory 940, thereby implementing various services based on the terminal.
Optionally, the processor 930 may include one or more processing units. Optionally, the processor 930 may integrate an application processor and a modem processor, wherein the application processor mainly handles operating systems, user interfaces, application programs, and the like, and the modem processor mainly handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 930.
The camera 970 is configured to implement a shooting function of the terminal 900 and shoot pictures or videos. The camera 970 can also be used for realizing the scanning function of the terminal 900 and scanning a scanning object (two-dimensional code/bar code).
The terminal 900 also includes a power supply 920 (e.g., a battery) for powering the various components. Optionally, the power supply 920 may be logically connected to the processor 930 through a power management system, so as to implement functions of managing charging, discharging, power consumption, and the like through the power management system.
Although not shown, the terminal 900 may further include an audio circuit and the like, which are not described in detail herein.
As shown in fig. 10, an apparatus for controlling the brightness of a terminal screen according to an embodiment of the present invention includes:
a detection module 1001 configured to detect a brightness value of ambient light;
the determining module 1002 is configured to determine that brightness fluctuation occurs in the current environment after detecting M consecutive light and dark alternating intervals; the light and dark alternating interval comprises a light interval and a dark interval, the light interval comprises continuous not less than N light values, the dark interval comprises continuous not less than N dark values, the light values are brightness values larger than a first threshold value, the dark values are brightness values not larger than the first threshold value, and M, N is a positive integer;
and the control module 1003 is used for adjusting the screen brightness and maintaining the adjusted brightness.
Optionally, the control module 1003 is specifically configured to:
and determining an automatic backlight input light sensation value according to the detected dark light value, and adjusting the screen brightness according to the automatic backlight input light sensation value.
Optionally, the control module 1003 is specifically configured to:
taking the last detected dim light value as the automatic backlight input light sensitivity value; or
And the terminal takes the average value of the dim light values detected in the first preset time as the input light sensitivity value of the automatic backlight.
Optionally, after the control module 1003 adjusts the screen brightness and maintains the adjusted brightness, the detecting module 1001 is further configured to: detecting a brightness value of the ambient light;
the determining module 1002 is further configured to: when the ratio of the number of the detected brightness values in the second preset time length to the total number of the detected brightness values is larger than a second threshold value, determining that the brightness fluctuation does not occur in the current environment;
the control module 1003 is further configured to: and adjusting the screen brightness by taking the detected brightness value of the ambient light as an automatic backlight input light sensitivity value.
An embodiment of the present invention further provides a computer-readable medium, on which a computer program is stored, where the computer program is executed by a processor to implement the steps of any one of the methods described above.
The present application is described above with reference to block diagrams and/or flowchart illustrations of methods, apparatus (systems) and/or computer program products according to embodiments of the invention. It will be understood that one block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, and/or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer and/or other programmable data processing apparatus, create means for implementing the functions/acts specified in the block diagrams and/or flowchart block or blocks.
Accordingly, the subject application may also be embodied in hardware and/or in software (including firmware, resident software, micro-code, etc.). Furthermore, the invention can take the form of a computer program product on a computer-usable or computer-readable storage medium having computer-usable or computer-readable program code embodied in the medium for use by or in connection with an instruction execution system. In the context of this document, a computer-usable or computer-readable medium may be any medium that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.
Claims (10)
1. A method for controlling the brightness of a terminal screen is characterized by comprising the following steps:
the terminal detects the brightness value of the ambient light;
after M continuous light and shade alternating intervals are detected, the terminal determines that the brightness fluctuation occurs in the current environment; the light and dark alternating interval comprises a light interval and a dark interval, the light interval comprises continuous not less than N light values, the dark interval comprises continuous not less than N dark values, the light values are brightness values larger than a first threshold value, the dark values are brightness values not larger than the first threshold value, and M, N is a positive integer;
and the terminal adjusts the screen brightness and keeps the adjusted brightness.
2. The method of claim 1, wherein the terminal adjusting screen brightness comprises:
and the terminal determines an automatic backlight input light sensation value according to the detected dark light value and adjusts the screen brightness according to the automatic backlight input light sensation value.
3. The method of claim 2, wherein the terminal determines an automatic backlight input light sensation value based on the detected dim light value, comprising:
and the terminal takes the dark light value detected last time as the automatic backlight input light sensitivity value.
4. The method of claim 2, wherein the terminal determines an automatic backlight input light sensation value based on the detected dim light value, comprising:
and the terminal takes the average value of the dim light values detected in the first preset time as the input light sensitivity value of the automatic backlight.
5. The method of claim 1, wherein after the terminal adjusts the screen brightness and maintains the adjusted brightness, further comprising:
the terminal detects the brightness value of the ambient light;
when the terminal determines that the ratio of the number of the detected bright light values in the second preset time period to the total number of the detected brightness values is greater than a second threshold value, determining that the brightness fluctuation does not occur in the current environment;
and the terminal takes the detected brightness value of the ambient light as an automatic backlight input light sensitivity value to adjust the screen brightness.
6. A terminal, comprising at least one processing unit and at least one memory unit;
wherein the storage unit stores program code that, when executed by the processing unit, causes the processing unit to perform the following:
detecting a brightness value of the ambient light;
after M continuous light and shade alternating intervals are detected, determining that the brightness fluctuation occurs in the current environment; the light and dark alternating interval comprises a light interval and a dark interval, the light interval comprises continuous not less than N light values, the dark interval comprises continuous not less than N dark values, the light values are brightness values larger than a first threshold value, the dark values are brightness values not larger than the first threshold value, and M, N is a positive integer;
and adjusting the screen brightness and keeping the adjusted brightness.
7. The terminal of claim 6, wherein the processing unit is further to:
and determining an automatic backlight input light sensation value according to the detected dark light value, and adjusting the screen brightness according to the automatic backlight input light sensation value.
8. The terminal of claim 7, wherein the processing unit is further to:
taking the last detected dim light value as the automatic backlight input light sensitivity value; or
And taking the average value of the detected dim light values in the first preset time as the input light sensitivity value of the automatic backlight.
9. The terminal of claim 6, wherein the processing unit is further to:
detecting a brightness value of the ambient light;
when the ratio of the number of the detected brightness values in the second preset time length to the total number of the detected brightness values is larger than a second threshold value, determining that the brightness fluctuation does not occur in the current environment;
and adjusting the screen brightness by taking the detected brightness value of the ambient light as an automatic backlight input light sensitivity value.
10. A computer-readable storage medium having stored thereon computer instructions which, when executed on a computer, cause the computer to perform the method of any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910769060.2A CN112492102B (en) | 2019-08-20 | 2019-08-20 | Terminal screen brightness control method, terminal and computer readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910769060.2A CN112492102B (en) | 2019-08-20 | 2019-08-20 | Terminal screen brightness control method, terminal and computer readable storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112492102A true CN112492102A (en) | 2021-03-12 |
CN112492102B CN112492102B (en) | 2022-01-25 |
Family
ID=74920077
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910769060.2A Active CN112492102B (en) | 2019-08-20 | 2019-08-20 | Terminal screen brightness control method, terminal and computer readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112492102B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114779914A (en) * | 2021-04-01 | 2022-07-22 | 支付宝(杭州)信息技术有限公司 | Battery electric quantity reminding method and device |
WO2022241631A1 (en) * | 2021-05-18 | 2022-11-24 | 京东方科技集团股份有限公司 | Detection circuit, display panel, and detection method |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102679501A (en) * | 2012-05-28 | 2012-09-19 | 四川长虹电器股份有限公司 | Automatic control method of air conditioner display screen |
CN104394278A (en) * | 2014-11-28 | 2015-03-04 | 广东欧珀移动通信有限公司 | Method, device and mobile terminal for regulating screen brightness |
CN106373531A (en) * | 2016-10-31 | 2017-02-01 | 广东欧珀移动通信有限公司 | Method for adjusting displaying brightness and electronic equipment |
CN106847229A (en) * | 2016-12-29 | 2017-06-13 | 努比亚技术有限公司 | The brightness regulating apparatus and method of a kind of display screen |
US20170171940A1 (en) * | 2015-12-14 | 2017-06-15 | Le Holdings (Beijing) Co., Ltd. | Method and electronic device for adjusting brightness on screen |
CN107665697A (en) * | 2017-10-20 | 2018-02-06 | 维沃移动通信有限公司 | The adjusting method and mobile terminal of a kind of screen intensity |
CN108682400A (en) * | 2018-07-25 | 2018-10-19 | 北京小米移动软件有限公司 | brightness adjusting method and device |
CN109451171A (en) * | 2018-12-12 | 2019-03-08 | 青岛海信移动通信技术股份有限公司 | A kind of method and apparatus of adjusting backlight luminance |
-
2019
- 2019-08-20 CN CN201910769060.2A patent/CN112492102B/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102679501A (en) * | 2012-05-28 | 2012-09-19 | 四川长虹电器股份有限公司 | Automatic control method of air conditioner display screen |
CN104394278A (en) * | 2014-11-28 | 2015-03-04 | 广东欧珀移动通信有限公司 | Method, device and mobile terminal for regulating screen brightness |
US20170171940A1 (en) * | 2015-12-14 | 2017-06-15 | Le Holdings (Beijing) Co., Ltd. | Method and electronic device for adjusting brightness on screen |
CN106373531A (en) * | 2016-10-31 | 2017-02-01 | 广东欧珀移动通信有限公司 | Method for adjusting displaying brightness and electronic equipment |
CN106847229A (en) * | 2016-12-29 | 2017-06-13 | 努比亚技术有限公司 | The brightness regulating apparatus and method of a kind of display screen |
CN107665697A (en) * | 2017-10-20 | 2018-02-06 | 维沃移动通信有限公司 | The adjusting method and mobile terminal of a kind of screen intensity |
CN108682400A (en) * | 2018-07-25 | 2018-10-19 | 北京小米移动软件有限公司 | brightness adjusting method and device |
CN109451171A (en) * | 2018-12-12 | 2019-03-08 | 青岛海信移动通信技术股份有限公司 | A kind of method and apparatus of adjusting backlight luminance |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114779914A (en) * | 2021-04-01 | 2022-07-22 | 支付宝(杭州)信息技术有限公司 | Battery electric quantity reminding method and device |
CN114779914B (en) * | 2021-04-01 | 2024-01-30 | 支付宝(杭州)信息技术有限公司 | Battery electric quantity reminding method and device |
WO2022241631A1 (en) * | 2021-05-18 | 2022-11-24 | 京东方科技集团股份有限公司 | Detection circuit, display panel, and detection method |
Also Published As
Publication number | Publication date |
---|---|
CN112492102B (en) | 2022-01-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP6970265B2 (en) | Devices, methods, and graphical user interfaces for displaying affordances in the background | |
CN108958633B (en) | Split screen display method and device, storage medium and electronic equipment | |
KR102681594B1 (en) | Apparatus and method for driving display based on frequency operaion cycle set differntly according to frequency | |
KR101794000B1 (en) | Apparatus and method for scrolling in portable terminal | |
JP5225576B2 (en) | Mobile terminal and operation method thereof | |
US8117471B2 (en) | Power management method for handheld electronic device using G-sensor | |
EP2733693B1 (en) | Electronic device for adjusting brightness of screen and method thereof | |
CN106055097B (en) | Bright screen control method and device and electronic equipment | |
KR20190035800A (en) | Watch Theater mode | |
CN106020670B (en) | Screen lighting control method and device and electronic equipment | |
US20080266083A1 (en) | Method and algorithm for detecting movement of an object | |
WO2019183811A1 (en) | Screen brightness adjustment method and terminal | |
CN112492102B (en) | Terminal screen brightness control method, terminal and computer readable storage medium | |
WO2014048180A1 (en) | Method and apparatus for controlling terminal device by using non-contact gesture | |
JP6828150B2 (en) | Screen display method and terminal | |
KR20140125243A (en) | Portable device and controlling method thereof | |
US9696895B2 (en) | Portable terminal device, luminance control method, and luminance control program | |
EP3293622B1 (en) | Portable electronic device, operating method for the same, and non-transitory computer readable recording medium | |
CN112214112A (en) | Parameter adjusting method and device | |
TW201510772A (en) | Gesture determination method and electronic device | |
CN109451171A (en) | A kind of method and apparatus of adjusting backlight luminance | |
CN107277903A (en) | Brightness adjusting method and mobile terminal | |
CN105430729A (en) | Power saving method and power saving device | |
CN108682400A (en) | brightness adjusting method and device | |
CN112416172A (en) | Electronic equipment control method and device and electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CP01 | Change in the name or title of a patent holder | ||
CP01 | Change in the name or title of a patent holder |
Address after: 266071 Shandong city of Qingdao province Jiangxi City Road No. 11 Patentee after: Qingdao Hisense Mobile Communication Technology Co.,Ltd. Address before: 266071 Shandong city of Qingdao province Jiangxi City Road No. 11 Patentee before: HISENSE MOBILE COMMUNICATIONS TECHNOLOGY Co.,Ltd. |