CN103049069A - Terminal battery temperature display method and device and terminal - Google Patents

Terminal battery temperature display method and device and terminal Download PDF

Info

Publication number
CN103049069A
CN103049069A CN2012104872895A CN201210487289A CN103049069A CN 103049069 A CN103049069 A CN 103049069A CN 2012104872895 A CN2012104872895 A CN 2012104872895A CN 201210487289 A CN201210487289 A CN 201210487289A CN 103049069 A CN103049069 A CN 103049069A
Authority
CN
China
Prior art keywords
file
temperature data
battery temperature
battery
terminal
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
Application number
CN2012104872895A
Other languages
Chinese (zh)
Other versions
CN103049069B (en
Inventor
霍小东
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Qihoo Technology Co Ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Qizhi Software Beijing Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Beijing Qihoo Technology Co Ltd, Qizhi Software Beijing Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201210487289.5A priority Critical patent/CN103049069B/en
Publication of CN103049069A publication Critical patent/CN103049069A/en
Application granted granted Critical
Publication of CN103049069B publication Critical patent/CN103049069B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Abstract

An embodiment of the invention discloses a terminal battery temperature display method and device and a terminal. The terminal battery temperature display device comprises a path analysis module, a temperature reading module, a first extraction module and a display module. The path analysis module is suitable for analyzing a file path of a file where battery temperature data locate, and the battery temperature data are sensed by a temperature sensor arranged in a terminal battery and are written into the file by an operation system noticed by a driving program invoked by a system in advance. The temperature reading module is suitable for reading file contents corresponding to the file path. The first extraction module is suitable for extracting the battery temperature data from the file contents. The display module is suitable for displaying the battery temperature data on a user interface of the terminal. By adopting the terminal battery temperature display method and device and the terminal, the battery temperature data can be timely and accurately read, influence on the terminal performance is reduced, the battery temperature data of the terminal are obtained and then can be displayed on the user interface of the terminal, and therefore the battery temperature data can be visually displayed.

Description

End cell process for temperature indication and device and terminal
Technical field
The embodiment of the invention relates to the terminal technology field, is specifically related to a kind of end cell process for temperature indication and device and terminal.
Background technology
Along with the rise of mobile Internet, increasing user selection intelligent mobile terminal.Present intelligent mobile terminal development is rapid, and performance is more and more stronger, screen size is increasing, equipment size is more and more thinner, in order to support stronger performance and larger screen, generally all can be equipped with more jumbo battery.
Because battery in use can produce heat, but thinner terminal fuselage size is unfavorable for heat radiation, thereby causes battery temperature to rise.Particularly the user is when playing mobile phone games, and this situation is more outstanding, and temperature rises can affect the performance of terminal, even may occur overheated under extreme case and cause exploding.
For above-mentioned situation, a kind of effectively solution to the problems described above is not proposed also at present.
Summary of the invention
In view of the above problems, the present invention has been proposed in order to a kind of a kind of end cell process for temperature indication and device and terminal that overcomes the problems referred to above or address the above problem at least in part is provided.
According to an aspect of the present invention, provide a kind of end cell process for temperature indication, having comprised:
The file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery; Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file;
Read file content corresponding to described file path;
From described file content, extract described battery temperature data;
User interface in terminal shows described battery temperature data.
In the embodiment of the invention, the temperature sensor data sensing to the file path of battery temperature place file comprise a plurality of file paths,
Described file content corresponding to described file path that read comprises:
Read corresponding file content successively under described a plurality of file paths, described being read as successively according to the order traversal that sets in advance read;
When reading successively, when under any one file path, reading file content, stop to read file content corresponding to next file path.
In the embodiment of the invention, when reading successively, when reading file content from any one file path, stop to read file content corresponding to next file path, comprising:
When file content corresponding to described any one file path reads successfully, judge whether file content corresponding to described any one file path is empty content;
When described file content is not empty content, stop to read file content corresponding to next file path.
In the embodiment of the invention, read file content corresponding to described file path, also comprise:
When reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continue to read file content corresponding to next file path.
In the embodiment of the invention, under described a plurality of file paths, read corresponding file content successively, comprising:
Recalls information reads the ReadInfo function, successively described a plurality of file paths is passed to described ReadInfo function as parameter;
Receive the rreturn value of described ReadInfo function, described rreturn value is file content corresponding to described file path.
In the embodiment of the invention, in Android operating system, described a plurality of file paths comprise file path/sys/class/hwmon/hwmon0/device/temp1_input, file path/sys/class/power_supply/battery/temp and file path/sys/class/power_supply/battery/batt_temp.
In the embodiment of the invention, the end cell temperature monitoring method also comprises:
When the state that detects battery changes, the broadcast event that monitor terminal operating system is sent;
Read the additional data of described broadcast event, and from described additional data, extract the battery temperature data.
In the embodiment of the invention, the state of battery changes and comprises:
Charging begins, charging is finished or the electric quantity change amount of battery reaches default threshold value.
In the embodiment of the invention, the end cell temperature monitoring method also comprises:
The battery temperature data of extracting and the temperature range of presetting are compared;
When described battery temperature data are within described temperature range, determine that described battery temperature data within temperature range are the battery temperature data of terminal;
When described battery temperature data exceeded described temperature range, with the temperature data of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing were as the battery temperature data of terminal.
In the embodiment of the invention, user interface be following any one:
The plug-in unit of the plug-in unit of desktop, desktop suspended window and browser.
According to a further aspect in the invention, provide a kind of end cell temperature indicating device, having comprised:
The path analysis module is suitable for the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery; Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file;
The temperature read module is suitable for reading file content corresponding to described file path;
The first extraction module is suitable for extracting described battery temperature data from described file content;
Display module is suitable for showing described battery temperature data in the user interface of terminal.
In the embodiment of the invention, temperature sensor senses to the file path of battery temperature data place file comprise a plurality of file paths,
Described temperature read module reads corresponding file content successively under described a plurality of file paths, when reading successively, when under any one file path, reading file content, stop to read file content corresponding to next file path, wherein, described being read as successively according to the order traversal that sets in advance read.
In the embodiment of the invention, the temperature read module comprises:
Judge submodule, be suitable for when file content corresponding to described any one file path reads successfully, judge whether file content corresponding to described any one file path is empty content;
Stop reading submodule, be suitable for when judgment sub-unit is judged described file content not for empty content, stopping to read file content corresponding to next file path.
In the embodiment of the invention, the temperature read module also comprises:
Continue reading submodule, be suitable for when reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continue to read file content corresponding to next file path.
In the embodiment of the invention, the temperature read module comprises:
Call submodule, be suitable for recalls information and read the ReadInfo function, successively described a plurality of file paths are passed to described ReadInfo function as parameter;
Receive submodule, be suitable for receiving the rreturn value of described ReadInfo function, described rreturn value is file content corresponding to described file path.
In the embodiment of the invention, in Android operating system, described a plurality of file paths comprise file path/sys/class/hwmon/hwmon0/device/temp1_input, file path/sys/class/power_supply/battery/temp and file path/sys/class/power_supply/battery/batt_temp.
In the embodiment of the invention, the end cell device for detecting temperature also comprises:
The second extraction module is suitable for when the state that detects battery changes, and the broadcast event that monitor terminal operating system is sent reads the additional data of described broadcast event, and extracts the battery temperature data from described additional data.
In the embodiment of the invention, the state of battery changes and comprises:
Charging begins, charging is finished or the electric quantity change amount of battery reaches default threshold value.
In the embodiment of the invention, the end cell device for detecting temperature also comprises:
Comparison module is suitable for the battery temperature data that will extract and the temperature range of presetting and compares;
Determination module is suitable for comparative result when comparison module and is described battery temperature data within described temperature range the time, determines that described battery temperature data within temperature range are the battery temperature data of terminal;
Modular converter, when being suitable for comparative result when comparison module and being described battery temperature data and exceeding described temperature range, with the temperature of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing are as the battery temperature data of terminal.
In the embodiment of the invention, user interface be following any one:
The plug-in unit of the plug-in unit of desktop, desktop suspended window and browser.
According to a further aspect in the invention, provide a kind of terminal, having comprised: CPU, battery, temperature sensor, storer, and end cell temperature indicating device as described.
End cell process for temperature indication and device according to the embodiment of the invention, the file path of the battery temperature data place file that temperature sensor senses arrives in can the analysing terminal battery, and read file content corresponding to described file path, therefore these file paths can directly extract the battery temperature data of terminal for by the system bottom source code being analyzed the file path of the corresponding temperature sensing data place file that draws from described file content.Solved thus owing to can't obtain current battery temperature data, caused battery temperature too high and affect the problem of terminal capabilities, obtained and can read timely and accurately the battery temperature data, minimizing is on the beneficial effect of the impact of terminal capabilities.
Secondly, after getting access to the battery temperature data of terminal, these battery temperature data can be presented on the user interface of terminal, thereby can more described battery temperature data be shown to the user.
Above-mentioned explanation only is the general introduction of technical solution of the present invention, for can clearer understanding technological means of the present invention, and can be implemented according to the content of instructions, and for above and other objects of the present invention, feature and advantage can be become apparent, below especially exemplified by the specific embodiment of the present invention.
Description of drawings
By reading hereinafter detailed description of the preferred embodiment, various other advantage and benefits will become cheer and bright for those of ordinary skills.Accompanying drawing only is used for the purpose of preferred implementation is shown, and does not think limitation of the present invention.And in whole accompanying drawing, represent identical parts with identical reference symbol.In the accompanying drawings:
Fig. 1 shows a kind of according to an embodiment of the invention process flow diagram of end cell temperature monitoring method;
Fig. 2 shows the process flow diagram of a kind of end cell temperature monitoring method of a specific embodiment according to the present invention;
Fig. 3 shows a kind of according to an embodiment of the invention structured flowchart of end cell device for detecting temperature;
Fig. 4 shows a kind of according to an embodiment of the invention process flow diagram of end cell process for temperature indication;
Fig. 5 shows the surface chart that the described battery temperature of the embodiment of the invention shows; And
Fig. 6 shows a kind of according to an embodiment of the invention structured flowchart of end cell temperature indicating device.
Embodiment
Exemplary embodiment of the present disclosure is described below with reference to accompanying drawings in more detail.Although shown exemplary embodiment of the present disclosure in the accompanying drawing, yet should be appreciated that and to realize the disclosure and the embodiment that should do not set forth limits here with various forms.On the contrary, it is in order to understand the disclosure more thoroughly that these embodiment are provided, and can with the scope of the present disclosure complete convey to those skilled in the art.
The embodiment of the invention can be applied to computer system/server, and it can be with numerous other universal or special computingasystem environment or configuration operation.The example that is suitable for well-known computing system, environment and/or the configuration used with computer system/server includes but not limited to: personal computer system, server computer system, thin client, thick client computer, hand-held or laptop devices, system, set-top box, programmable consumer electronics, NetPC Network PC, minicomputer system, large computer system based on microprocessor and comprise the distributed cloud computing technology environment of above-mentioned any system, etc.
Computer system/server can be described under the general linguistic context of the computer system executable instruction (such as program module) of being carried out by computer system.Usually, program module can comprise routine, program, target program, assembly, logic, data structure etc., and they are carried out specific task or realize specific abstract data type.Computer system/server can be implemented in distributed cloud computing environment, and in the distributed cloud computing environment, task is by carrying out by the teleprocessing equipment of communication network link.In distributed cloud computing environment, program module can be positioned on the Local or Remote computing system storage medium that comprises memory device.
With reference to figure 1, show the process flow diagram of a kind of end cell temperature monitoring method that proposes in the embodiment of the invention, the method specifically can comprise:
Step 100, the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery.
Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file.
Along with the development of internet, increasing user selection intelligent mobile terminal, present intelligent mobile terminal development in order to support stronger performance and larger screen, generally all can be the more jumbo battery of terminal outfit rapidly.And battery in use can produce heat, if battery temperature is too high, then can affect the performance of terminal.
Therefore, the embodiment of the invention has proposed a kind of end cell temperature monitoring method, and the method can directly obtain the battery temperature data by the data of reading terminals internal temperature sensor.Some temperature sensors can be installed in inside in terminal, these temperature sensors can the real-time monitoring terminal internal unit temperature data, the device drives that realizes by production firm can obtain concrete temperature data from temperature sensor, then system's call driver notice operating system in advance is written to these temperature datas in the corresponding file by operating system again.
In the embodiment of the invention, at first can analyze by the bottom source code to terminal system, which file is the temperature sensor data be stored in in the end cell to find out, what file path is, after finding out file path, follow-up can the processing the file content under these file paths.
Step 102 reads file content corresponding to described file path.
In step 100, analyze the file path of the battery temperature data place file that temperature sensor senses arrives in the end cell, because the file under described file path is the file that stores the battery temperature data by determining after terminal is analyzed, therefore, after getting access to above-mentioned file path, namely can read file content corresponding to described file path.
Wherein, comprise the battery temperature data in the described file content, can also comprise some other information, the embodiment of the invention is not limited this.
Step 104 is extracted described battery temperature data from described file content.
Read file content corresponding to described file path, namely can from described file content, directly extract the battery temperature data.
If current battery temperature is too high, can take some measures to reduce battery temperature (for example, if currently play games, can stop current game).
For the detailed process of above-mentioned each step, will introduce in detail in the following embodiments.
The end cell temperature monitoring method that the embodiment of the invention proposes can the analysing terminal battery in the file path of the battery temperature data place file that arrives of temperature sensor senses, and read file content corresponding to described file path, therefore these file paths can directly extract the battery temperature data of terminal for by the system bottom source code being analyzed the file path of the corresponding temperature sensing data place file that draws from described file content.Solved thus owing to can't obtain current battery temperature data, caused battery temperature too high and affect the problem of terminal capabilities, can read timely and accurately the battery temperature data, minimizing is on the impact of terminal capabilities.
Below, the end cell temperature monitoring method that the embodiment of the invention is proposed describes in detail.
With reference to figure 2, show the process flow diagram of a kind of end cell temperature monitoring method of a specific embodiment according to the present invention, the method can comprise:
Step 200, the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery.
Associated description according to above-described embodiment one, at first can analyze by the bottom source code to terminal system in the embodiment of the invention, determine the path of the file of temperature sensor data in the storage terminal battery, after finding out file path, follow-up can the processing the file content under these file paths.
For concrete analytic process, those skilled in the art carry out respective handling according to actual conditions and get final product, and the embodiment of the invention is discussed no longer in detail at this.
Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file.
The production firm that considers each terminal may be different, and the position of the file that the operating system of the different terminal of production firm writes temperature data is different, therefore the path that is used for the file of storage battery temperature data also might be different, therefore the terminal that can produce different production firms is respectively analyzed, thereby draw for different terminals, which the path that wherein is used for the file of storage battery temperature data has.
Therefore, in embodiments of the present invention, described temperature sensor senses to the file path of battery temperature data place file can comprise a plurality of file paths.
Step 202 reads file content corresponding to described file path.
In determining terminal, be used for owing to storing the battery temperature data of terminal in the file content under these file paths, therefore, can reading file content corresponding to described file path by system after the path of file of storage battery temperature data.
In the embodiment of the invention, a timer can be set, can directly go file reading content under the described file path by the timing reporting system by this timer.For the time interval of reading, the embodiment of the invention is not limited.
Associated description according to above-mentioned steps 200 can learn, the file path of the data of temperature sensor described in embodiment of the invention place file can comprise a plurality of file paths, and therefore, this step 202 specifically can comprise:
Substep 2021 reads corresponding file content successively under described a plurality of file paths.
In the embodiment of the invention, terminal for different production firms, the file that wherein stores the battery temperature data may be different, therefore can obtain by analysis a plurality of different file paths, for certain terminal, its battery temperature data can be stored in file corresponding to a file path in these file paths.Therefore, the embodiment of the invention is when reading corresponding file content under described a plurality of file paths, can travel through successively according to the order that sets in advance and read described a plurality of file path, until read corresponding file content under one of them file path.
For example, at first can dissecting needle concerning current terminal, the possibility that comprises described battery temperature data in the file content under each file path, then the size according to possibility sorts to described a plurality of file paths, reads successively at last the file path after the ordering.
Certainly, can also adopt some other characteristic of file path to sort, the embodiment of the invention is not limited this.
In the embodiment of the invention, can under described a plurality of file paths, read corresponding file content by information function reading (ReadInfo function).
This substep 2021 can comprise:
A1 calls the ReadInfo function, successively described a plurality of file paths is passed to described ReadInfo function as parameter.
A2 receives the rreturn value of described ReadInfo function, and described rreturn value is file content corresponding to described file path.
Wherein, the ReadInfo function is the information function reading of operating system, and for the detailed process by this system function file reading content, those skilled in the art carry out respective handling according to actual conditions and get final product, and the embodiment of the invention is discussed no longer in detail at this.
Substep 2022 when reading successively, when reading file content under any one file path, stops to read file content corresponding to next file path.
For different terminals, the path of the file of its storage battery temperature data may be different, by analysis, and the file path of the battery temperature data place file that the file path that these are possible arrives as temperature sensor senses.When processing for a terminal, if under one of them file path, read file content, illustrate that then the file under this document path is the file that is used for the storage battery temperature data in this terminal, at this moment, can no longer read its file content for other path.
In the embodiment of the invention, this substep 2022 can comprise:
B1 when file content corresponding to described any one file path reads successfully, judges whether file content corresponding to described any one file path is empty content.
B2 when described file content is not empty content, stops to read file content corresponding to next file path.
Substep 2023 when reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continues to read file content corresponding to next file path.
Below, be introduced as an example of Android system example, by analysis, in Android operating system, the path that is used for the file of storage battery temperature data can comprise following several:
(1)/sys/class/hwmon/hwmon0/device/temp1_input
(2)/sys/class/power_supply/battery/temp
(3)/sys/class/power_supply/battery/batt_temp
For different production firms, the operating system of terminal is different with the position of the file that temperature data writes, but the analysis found that, the position of temperature data storage is in file corresponding to a path in above-mentioned three file paths.Therefore, in the embodiment of the invention, can successively above-mentioned three file paths regularly be passed to the ReadInfo function, then (for example receive the rreturn value of ReadInfo function, can pass through the Shandong great master regularly to ReadInfo function passes file path), until under one of them file path, read corresponding file content.Detailed process can comprise:
Step 1, file path/sys/class/hwmon/hwmon0/device/temp1_input is passed to the ReadInfo function as parameter.
If the ReadInfo function successfully gets access to the file content under this document path, then execution in step 2; If file content obtains failure, then execution in step 4.
Step 2 judges whether described file content is empty.
If described file content is not empty, then execution in step 3; If described file content is empty, then execution in step 4.
Step 3, the rreturn value of reception ReadInfo function, described rreturn value is file content corresponding to described file path/sys/class/hwmon/hwmon0/device/temp1_input.
Step 4 passes to the ReadInfo function with file path/sys/class/power_supply/battery/temp as parameter.
If the ReadInfo function successfully gets access to the file content under this document path, if then execution in step 5 file contents obtain failure, then execution in step 7.
Step 5 judges whether described file content is empty.
If described file content is not empty, then execution in step 6; If described file content is empty, then execution in step 7.
Step 6, the rreturn value of reception ReadInfo function, described rreturn value is file content corresponding to described file path/sys/class/power_supply/battery/temp.
Step 7, file path/sys/class/power_supply/battery/batt_temp is passed to the ReadInfo function as parameter.
If the ReadInfo function successfully gets access to the file content under this document path, and described file content is not empty, and then execution in step 8.
Step 8, the rreturn value of reception ReadInfo function, described rreturn value is file content corresponding to described file path/sys/class/power_supply/battery/batt_temp.
Owing to can learn that through foregoing description above-mentioned three kinds of file paths are the path of the file of possible storage battery temperature data, therefore, in the embodiment of the invention, can read corresponding file content under the file path therein at least.Therefore, in said process, if under file path/sys/class/hwmon/hwmon0/device/temp1_input and file path/sys/class/power_supply/battery/temp, all do not read corresponding file content, then under file path/sys/class/power_supply/battery/batt_temp, can read corresponding file path.
Need to prove, the order that reads for above-mentioned three kinds of file paths in the embodiment of the invention is not limited.And, above-mentioned three kinds of file paths are for Android operating system, and still, the embodiment of the invention is not limited to above-mentioned three kinds of file paths, for example may be other file path for some other operating system, the embodiment of the invention is discussed no longer in detail to this.
Step 204 is extracted described battery temperature data from described file content.
In step 202, read after the corresponding file path, owing to storing the battery temperature data in the file content under this document path, therefore, in this step, namely can from the file content that reads, extract the battery temperature data.
In the embodiment of the invention, by above-mentioned steps 200-step 204 can Real-time Obtaining to the battery temperature data of terminal, so that obtaining of battery temperature data is more timely.
On the other hand, the analysis found that, when the battery status of terminal changed, the terminal operating system system can send broadcast event, had comprised the battery temperature data message of terminal in the additional data of this broadcast event.Therefore, the embodiment of the invention has also further proposed to obtain by this broadcast event the method for battery temperature data.
Concrete, the battery temperature monitoring method of the embodiment of the invention can also comprise:
Step 206, when the state that detects battery changes, the broadcast event that monitor terminal operating system is sent.
In the embodiment of the invention, the state of described battery changes and can comprise following several situation:
The electric quantity change amount that (for example detect and extract charger) or battery are finished in charging beginning (for example detect and insert charger), charging reach default threshold value (for example the electric quantity change amount of battery reach 1% or other numerical value).
Certainly, the described battery status of the embodiment of the invention changes and is not limited to above-mentioned several situation, can also comprise other situation, and the embodiment of the invention is not limited this.
Step 208 reads the additional data of described broadcast event, and extracts the battery temperature data from described additional data.
Include additional data in the broadcast event that the aforesaid operations system sends, the battery temperature data that comprised terminal in these additional datas, described battery temperature data also can be the battery temperature data that obtain by the above-mentioned method that reads file content corresponding under the default file path, for concrete process, the embodiment of the invention is discussed no longer in detail at this.
After terminal operating system is sent broadcast event, namely can read the additional data of this broadcast event, and from the additional data that reads, extract battery temperature data wherein.
Need to prove, above-mentioned steps 206-step 208 is that broadcast event by the read operation system is to obtain the process of battery temperature data.But, terminal operating system is only sent this broadcast event at the state that the detects battery Shi Caihui that changes, if namely utilize the above-mentioned method that reads broadcast event, only change at battery status and can get access to corresponding battery temperature data, even and remaining the time battery temperature data to have occured to change also be to get access to corresponding battery temperature data.Therefore, there is the untimely problem of battery temperature Data Update in the mode of obtaining the battery temperature data by reading broadcast event.
Therefore, the embodiment of the invention is in order to address this problem, proposed by in the step 200-step 204 in real time the file content corresponding to file path of the battery temperature data place file that senses of reading temperature sensor obtain the method for battery temperature data.The method is at first determined the path that may store the file of battery temperature data in the terminal, then can read in real time the file content under these file paths, thereby can not be subjected to the restriction of battery status, when even battery status does not change, also be to get access to corresponding battery temperature data.Therefore, with respect to the above-mentioned method of obtaining the battery temperature data by reading broadcast event, this method that reads file content corresponding under the default file path can not be subjected to the restriction of external condition (state variation of battery), makes the renewal of battery temperature data more timely.
Because some terminals have singularity, the unit of the battery temperature data that these terminals get access to may not be ℃, therefore, for the span of the unified temperature that gets access to, the battery temperature data can be set all take ℃ as unit in the embodiment of the invention.
In the embodiment of the invention, can set in advance temperature range, when the battery temperature data that get access to are within this default temperature range, determine that this temperature is the battery temperature data of terminal.
Therefore, the described battery temperature data monitoring method of the embodiment of the invention can also may further comprise the steps:
Step 210 compares the battery temperature data of extracting and the temperature range of presetting.
Step 212 when described battery temperature data are within described temperature range, determines that described battery temperature data within temperature range are the battery temperature data of terminal.
In the embodiment of the invention, it is 15 ℃-60 ℃ that described temperature range can be set, if battery temperature data that extract within this temperature range the time, then could be with the battery temperature data of this temperature as terminal.
Step 214, when described battery temperature data exceeded described temperature range, with the temperature of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing were as the battery temperature data of terminal.
If the battery temperature data that extract have exceeded the said temperature scope, the embodiment of the invention can also further be processed the temperature that extracts, so that it is within the normal temperature range.
For example, if the battery temperature data that extract are 300 (its unit may not be ℃), then the embodiment of the invention can be with this numerical value divided by a fixed value (for example divided by 10).If divided by the numerical value after this fixed value also not within the said temperature scope, the numerical value that then can continue to obtain is divided by above-mentioned fixed value, until the numerical value that draws in described temperature range, is defined as described battery temperature data within temperature range the battery temperature data of terminal at last.
Need to prove, above-mentioned temperature range is for the purpose of illustration only, and the embodiment of the invention is not limited concrete numerical value.
The end cell temperature monitoring method of the embodiment of the invention not only can the analysing terminal battery in the file path of the battery temperature data place file that arrives of temperature sensor senses, and regular file reading content under the described file path, and therefrom extract the battery temperature data, can also obtain the battery temperature data by the broadcast event that system sends, thereby can obtain more timely and accurately the battery temperature data of terminal, solved thus owing to can't obtain current battery temperature data, cause battery temperature too high and affect the problem of terminal capabilities, obtained and to have read timely and accurately the battery temperature data, reduced the beneficial effect on the impact of terminal capabilities.
Need to prove, for aforesaid embodiment of the method, for simple description, therefore it all is expressed as a series of combination of actions, but those skilled in the art should know, the application is not subjected to the restriction of described sequence of movement, because according to the application, some step can adopt other orders or carry out simultaneously.Secondly, those skilled in the art also should know, the embodiment described in the instructions all belongs to preferred embodiment, and related action might not be that the application is necessary.
With reference to Fig. 3, show the structured flowchart of a kind of end cell device for detecting temperature of the embodiment of the invention three, this device can comprise: path analysis module 300, temperature read module 302, the first extraction module 304, the second extraction module 306, comparison module 308, determination module 310, modular converter 312.
Wherein,
Path analysis module 300 is suitable for the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery;
Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file.
Temperature read module 302 is suitable for reading file content corresponding to described file path;
In the embodiment of the invention, described end cell device for detecting temperature can also comprise timer, can directly go file reading content under the described file path by the timing reporting system by this timer.
Because the production firm of each terminal may be different, therefore the path that wherein is used for the file of storage battery temperature data also may be different, therefore, in the embodiment of the invention, in the described end cell temperature sensor senses to the file path of battery temperature data place file can comprise a plurality of file paths.
For example, in Android operating system, described a plurality of file paths can comprise file path/sys/class/hwmon/hwmon0/device/temp1_input, file path/sys/class/power_supply/battery/temp and file path/sys/class/power_supply/battery/batt_temp.
Concrete, described temperature read module 302 reads corresponding file content successively under described a plurality of file paths, when reading successively, when reading file content under any one file path, stop to read file content corresponding to next file path.
Wherein, described being read as successively according to the order traversal that sets in advance read.
Described temperature read module 302 can comprise:
Call submodule, be suitable for calling the ReadInfo function, successively described a plurality of file paths are passed to described ReadInfo function as parameter;
Receive submodule, be suitable for receiving the rreturn value of described ReadInfo function, described rreturn value is file content corresponding to described file path;
Judge submodule, be suitable for when file content corresponding to described any one file path reads successfully, judge whether file content corresponding to described any one file path is empty content;
Stop reading submodule, be suitable for when judgment sub-unit is judged described file content not for empty content, stopping to read file content corresponding to next file path;
Continue reading submodule, be suitable for when reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continue to read file content corresponding to next file path.
The first extraction module 304 is suitable for extracting described battery temperature data from described file content;
The second extraction module 306 is suitable for when the state that detects battery changes, and the broadcast event that monitor terminal operating system is sent reads the additional data of described broadcast event, and extracts the battery temperature data from described additional data;
Wherein, the state of described battery changes and comprises following several situation:
Charging begins, charging is finished or the electric quantity change amount of battery reaches default threshold value.
Certainly, can also comprise other situation, the embodiment of the invention is not limited this.
Because some terminals have singularity, span for the unified temperature that gets access in the embodiment of the invention, can set in advance temperature range, when the battery temperature data that get access to are within this default temperature range, determine that this temperature is the battery temperature data of terminal.
Therefore, the described device of the embodiment of the invention can also comprise:
Comparison module 308 is suitable for the battery temperature data that will extract and the temperature range of presetting and compares;
Determination module 310 is suitable for comparative result when comparison module and is described battery temperature data within described temperature range the time, determines that described battery temperature data within temperature range are the battery temperature data of terminal;
Modular converter 312, when being suitable for comparative result when comparison module and being described battery temperature data and exceeding described temperature range, with the temperature of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing are as the battery temperature data of terminal.
For above-mentioned end cell device for detecting temperature embodiment because itself and embodiment of the method basic simlarity, so describe fairly simple, relevant part gets final product referring to the part explanation of embodiment of the method illustrated in figures 1 and 2.
The end cell device for detecting temperature of the embodiment of the invention can obtain the battery temperature data of terminal more timely and accurately, solved thus owing to can't obtain current battery temperature data, cause battery temperature too high and affect the problem of terminal capabilities, obtained and to have read timely and accurately the battery temperature data, reduced the beneficial effect on the impact of terminal capabilities.
Based on above-mentioned end cell device for detecting temperature embodiment, the embodiment of the invention also provides a kind of CPU of comprising, battery, temperature sensor, storer, and the terminal of this end cell device for detecting temperature.Described terminal can the analysing terminal battery in the file path of the battery temperature data place file that arrives of temperature sensor senses, and read file content corresponding to described file path, therefore these file paths can directly extract the battery temperature data of terminal for by the system bottom source code being analyzed the file path of the corresponding temperature sensing data place file that draws from described file content.Solved thus owing to can't obtain current battery temperature data, caused battery temperature too high and affect the problem of terminal capabilities, obtained and can read timely and accurately the battery temperature data, minimizing is on the beneficial effect of the impact of terminal capabilities.
Battery in use can produce heat, causes battery temperature to rise, and battery temperature rises and can affect the performance of terminal, even may occur overheated under extreme case and cause exploding.Therefore, in the use procedure of terminal, in order not affect the performance of terminal, if battery temperature is too high, can temporarily stop the present program of carrying out, to reduce battery temperature.
Therefore, in the embodiment of the invention, a kind of end cell process for temperature indication has been proposed, after obtaining the battery temperature data of terminal, can also show described battery temperature data in the user interface of terminal, more described battery temperature data are shown to the user.
As shown in Figure 4, be the process flow diagram of the described a kind of end cell process for temperature indication of the embodiment of the invention, described method comprises:
Step 400, the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery.
Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file.
Step 402 reads file content corresponding to described file path.
Step 404 is extracted described battery temperature data from described file content.
For the detailed process of above-mentioned steps 400-step 404, get final product referring to the explanation of the part of embodiment of the method illustrated in figures 1 and 2, the embodiment of the invention is discussed no longer in detail at this.
Step 406 is in the described battery temperature data of user interface demonstration of terminal.
Wherein, described user interface is following any one:
The plug-in unit of desktop, the plug-in unit of desktop suspended window and browser.
For example, the embodiment of the invention can show by the plug-in unit widget of desktop described battery temperature data.
Widget is an inserter tool---the Konfabulator that comes from Apple Computers at first, has been extended to now the windows system, and this software can be put into its functional block on the desktop of terminal, and these functional blocks are exactly widget.Such as: clock widget is exactly to show on the table the current time; Weather widget, the weather forecast in area that can displaying format customization; Cpu widget can show the ratio that takies of cpu; Also have WDS widget, stock widget etc.
Concrete, the embodiment of the invention can show described battery temperature data by widget, wherein can comprise battery temperature data and current state of temperature (for example normally, excessively high).
With reference to figure 5, show the surface chart that the described battery temperature of the embodiment of the invention shows, as can be seen from Figure 5, current battery temperature data are 29 °, state is normal.
Certainly, can also be with some in the embodiment of the invention other the information relevant with the battery temperature data (for example how much higher current battery temperature is than normal temperature) be presented on the user interface (for example desktop) of terminal, the embodiment of the invention is not limited this.
In addition, the embodiment of the invention can also show described battery temperature data by the desktop suspended window.
Software on the terminal can generate corresponding suspended window at the screen of terminal, the effect of these suspended windows is, when the window of master routine when minimizing, running status that can also this program of prompting user, and can by clicking these wickets, open quickly the window of master routine.For example, 360 mobile phone security guards provide a suspended window, may be displayed on the terminal screen, and suspended window has shown the system resource information such as EMS memory occupation amount that terminal has been used.
Can show described battery temperature data by the desktop suspended window in the embodiment of the invention, can comprise a default entrance that is used for showing the battery temperature testing result in this suspended window, the request that can receive in real time user side (for example arranges the button of an operation in suspended window, when clicking button, user side gets final product trigger request), after the request that receives user side, the real-time measurement result of temperature data can be displayed.
Certainly, can also show in other way described temperature data, the embodiment of the invention is not limited this.
Corresponding with the method that the end cell temperature of above-described embodiment description shows, the embodiment of the invention has also proposed a kind of end cell temperature indicating device.
Fig. 6 shows the structured flowchart of the described end cell temperature indicating device of the embodiment of the invention, and described device can comprise:
Path analysis module 600 is suitable for the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery;
Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file.
Temperature read module 602 is suitable for reading file content corresponding to described file path;
The first extraction module 604 is suitable for extracting described battery temperature data from described file content.
Display module 606 is suitable for showing described battery temperature data in the user interface of terminal.
Wherein, described user interface is following any one:
The plug-in unit of desktop, the plug-in unit of desktop suspended window and browser.
Wherein, for the specific descriptions of path analysis module 600, temperature read module 602 and the first extraction module 604, can be with reference to the associated description of above-mentioned end cell temperature data monitoring device embodiment, the embodiment of the invention is discussed no longer in detail at this.
The end cell temperature data display packing that above-described embodiment proposes and device can be after getting access to the battery temperature data of terminal, further described battery temperature data are presented on the user interface of terminal, thereby the user can understand the battery temperature data more intuitively, and according to current battery temperature data cases terminal is carried out corresponding operation, if for example current battery temperature is too high, can be by suspending some application program, so that the battery temperature reduction, thereby minimizing is on the impact of terminal capabilities.
Based on above-mentioned end cell temperature indicating device embodiment, the embodiment of the invention also provides a kind of CPU of comprising, battery, temperature sensor, storer, and the terminal of this end cell temperature indicating device.Described terminal can be presented at described battery temperature data on the user interface of terminal after getting access to the battery temperature data of terminal, thereby the user can understand the battery temperature data more intuitively.
Each embodiment in this instructions all adopts the mode of going forward one by one to describe, and what each embodiment stressed is and the difference of other embodiment that identical similar part is mutually referring to getting final product between each embodiment.
What those skilled in the art were easy to expect is: it all is feasible that the combination in any of above-mentioned each embodiment is used, therefore the combination in any between above-mentioned each embodiment all is the application's embodiment, but this instructions has not just described in detail one by one at this as space is limited.
Intrinsic not relevant with any certain computer, virtual system or miscellaneous equipment with demonstration at this algorithm that provides.Various general-purpose systems also can be with using based on the teaching at this.According to top description, it is apparent constructing the desired structure of this type systematic.In addition, the present invention is not also for any certain programmed language.Should be understood that and to utilize various programming languages to realize content of the present invention described here, and the top description that language-specific is done is in order to disclose preferred forms of the present invention.
In the instructions that provides herein, a large amount of details have been described.Yet, can understand, embodiments of the invention can be in the situation that there be these details to put into practice.In some instances, be not shown specifically known method, structure and technology, so that not fuzzy understanding of this description.
Similarly, be to be understood that, in order to simplify the disclosure and to help to understand one or more in each inventive aspect, in the description to exemplary embodiment of the present invention, each feature of the present invention is grouped together in single embodiment, figure or the description to it sometimes in the above.Yet the method for the disclosure should be construed to the following intention of reflection: namely the present invention for required protection requires the more feature of feature clearly put down in writing than institute in each claim.Or rather, as following claims reflected, inventive aspect was to be less than all features of the disclosed single embodiment in front.Therefore, follow claims of embodiment and incorporate clearly thus this embodiment into, wherein each claim itself is as independent embodiment of the present invention.
Those skilled in the art are appreciated that and can adaptively change and they are arranged in one or more equipment different from this embodiment the module in the equipment among the embodiment.Can be combined into a module or unit or assembly to the module among the embodiment or unit or assembly, and can be divided into a plurality of submodules or subelement or sub-component to them in addition.In such feature and/or process or unit at least some are mutually repelling, and can adopt any combination to disclosed all features in this instructions (comprising claim, summary and the accompanying drawing followed) and so all processes or the unit of disclosed any method or equipment make up.Unless in addition clearly statement, disclosed each feature can be by providing identical, being equal to or the alternative features of similar purpose replaces in this instructions (comprising claim, summary and the accompanying drawing followed).
In addition, those skilled in the art can understand, although embodiment more described herein comprise some feature rather than further feature included among other embodiment, the combination of the feature of different embodiment means and is within the scope of the present invention and forms different embodiment.For example, in the following claims, the one of any of embodiment required for protection can be used with array mode arbitrarily.
All parts embodiment of the present invention can realize with hardware, perhaps realizes with the software module of moving at one or more processor, and perhaps the combination with them realizes.It will be understood by those of skill in the art that and to use in practice microprocessor or digital signal processor (DSP) to realize according to some or all some or repertoire of parts in the battery temperature display device of the embodiment of the invention.The present invention can also be embodied as be used to part or all equipment or the device program (for example, computer program and computer program) of carrying out method as described herein.Such realization program of the present invention can be stored on the computer-readable medium, perhaps can have the form of one or more signal.Such signal can be downloaded from internet website and obtain, and perhaps provides at carrier signal, perhaps provides with any other form.
It should be noted above-described embodiment the present invention will be described rather than limit the invention, and those skilled in the art can design alternative embodiment in the situation of the scope that does not break away from claims.In the claims, any reference symbol between bracket should be configured to limitations on claims.Word " comprises " not to be got rid of existence and is not listed in element or step in the claim.Being positioned at word " " before the element or " one " does not get rid of and has a plurality of such elements.The present invention can realize by means of the hardware that includes some different elements and by means of the computing machine of suitably programming.In having enumerated the unit claim of some devices, several in these devices can be to come imbody by same hardware branch.The use of word first, second and C grade does not represent any order.Can be title with these word explanations.
Herein disclosed is A1, a kind of end cell process for temperature indication, comprising: the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery; Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file; Read file content corresponding to described file path; From described file content, extract described battery temperature data; User interface in terminal shows described battery temperature data.A2, according to the described method of A1, described temperature sensor data sensing to the file path of battery temperature place file comprise a plurality of file paths, described file content corresponding to described file path that read, comprise: read corresponding file content successively under described a plurality of file paths, described being read as successively according to the order traversal that sets in advance read; When reading successively, when under any one file path, reading file content, stop to read file content corresponding to next file path.A3, according to the described method of A2, described when reading successively, when reading file content from any one file path, stop to read file content corresponding to next file path, comprise: when file content corresponding to described any one file path reads successfully, judge whether file content corresponding to described any one file path is empty content; When described file content is not empty content, stop to read file content corresponding to next file path.A4, according to the described method of A3, described file content corresponding to described file path that read, also comprise: when reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continue to read file content corresponding to next file path.A5, according to the described method of A2, describedly read successively corresponding file content under described a plurality of file paths, comprising: recalls information reads the ReadInfo function, successively described a plurality of file paths is passed to described ReadInfo function as parameter; Receive the rreturn value of described ReadInfo function, described rreturn value is file content corresponding to described file path.A6, according to the described method of A2, in Android operating system, described a plurality of file paths comprise file path/sys/class/hwmon/hwmon0/device/temp1_input, file path/sys/class/power_supply/battery/temp and file path/sys/class/power_supply/battery/batt_temp.A7, according to the described method of A1, also comprise: when the state that detects battery changes, the broadcast event that monitor terminal operating system is sent; Read the additional data of described broadcast event, and from described additional data, extract the battery temperature data.A8, according to the described method of A7, the state of described battery changes and comprises: charging beginning, charging is finished or the electric quantity change amount of battery reaches default threshold value.A9, according to A1 or the described method of A7, also comprise: the battery temperature data extracted and default temperature range are compared; When described battery temperature data are within described temperature range, determine that described battery temperature data within temperature range are the battery temperature data of terminal; When described battery temperature data exceeded described temperature range, with the temperature data of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing were as the battery temperature data of terminal.A10, according to each described method among the A1 to A9, described user interface be following any one: the plug-in unit of the plug-in unit of desktop, desktop suspended window and browser.
Herein disclosed is B11, a kind of end cell temperature indicating device, comprising: the path analysis module is suitable for the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery; Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file; The temperature read module is suitable for reading file content corresponding to described file path; The first extraction module is suitable for extracting described battery temperature data from described file content.Display module is suitable for showing described battery temperature data in the user interface of terminal.B12, according to the described device of B11, described temperature sensor senses to the file path of battery temperature data place file comprise a plurality of file paths, described temperature read module reads corresponding file content successively under described a plurality of file paths, when reading successively, when under any one file path, reading file content, stop to read file content corresponding to next file path, wherein, described being read as successively according to the order traversal that sets in advance read.B13, according to the described device of B12, described temperature read module comprises: judge to be suitable for submodule when file content corresponding to described any one file path reads successfully, judge whether file content corresponding to described any one file path is empty content; Stop reading submodule, be suitable for when judgment sub-unit is judged described file content not for empty content, stopping to read file content corresponding to next file path.B14, according to the described device of B13, described temperature read module also comprises: continue reading submodule, be suitable for when reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continue to read file content corresponding to next file path.B15, according to the described device of B12, described temperature read module comprises: call submodule, be suitable for recalls information and read the ReadInfo function, successively described a plurality of file paths are passed to described ReadInfo function as parameter; Receive submodule, be suitable for receiving the rreturn value of described ReadInfo function, described rreturn value is file content corresponding to described file path.B16, according to B 12 described devices, in Android operating system, described a plurality of file paths comprise file path/sys/class/hwmon/hwmon0/device/temp1_input, file path/sys/class/power_supply/battery/temp and file path/sys/class/power_supply/battery/batt_temp.B17, according to the described device of B11, also comprise: the second extraction module is suitable for when the state that detects battery changes the broadcast event that monitor terminal operating system is sent, read the additional data of described broadcast event, and from described additional data, extract the battery temperature data.B18, according to the described device of B17, the state of described battery changes and comprises: charging beginning, charging is finished or the electric quantity change amount of battery reaches default threshold value.B19, according to B11 or the described device of B17, also comprise: comparison module is suitable for the battery temperature data that will extract and compares with default temperature range; Determination module is suitable for comparative result when comparison module and is described battery temperature data within described temperature range the time, determines that described battery temperature data within temperature range are the battery temperature data of terminal; Modular converter, when being suitable for comparative result when comparison module and being described battery temperature data and exceeding described temperature range, with the temperature of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing are as the battery temperature data of terminal.B20, according to each described device among the B11 to B20, described user interface be following any one: the plug-in unit of the plug-in unit of desktop, desktop suspended window and browser.
Herein disclosed is C21, a kind of terminal, comprising: CPU, battery, temperature sensor, storer, and as the arbitrary described end cell temperature indicating device of above-mentioned B11 to B20.

Claims (20)

1. end cell process for temperature indication comprises:
The file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery; Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file;
Read file content corresponding to described file path;
From described file content, extract described battery temperature data;
User interface in terminal shows described battery temperature data.
2. method according to claim 1, described temperature sensor data sensing to the file path of battery temperature place file comprise a plurality of file paths,
Described file content corresponding to described file path that read comprises:
Read corresponding file content successively under described a plurality of file paths, described being read as successively according to the order traversal that sets in advance read;
When reading successively, when under any one file path, reading file content, stop to read file content corresponding to next file path.
3. method according to claim 2, described when reading successively, when reading file content from any one file path, stop to read file content corresponding to next file path, comprising:
When file content corresponding to described any one file path reads successfully, judge whether file content corresponding to described any one file path is empty content;
When described file content is not empty content, stop to read file content corresponding to next file path.
4. method according to claim 3, described file content corresponding to described file path that read also comprises:
When reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continue to read file content corresponding to next file path.
5. method according to claim 2 describedly reads corresponding file content successively under described a plurality of file paths, comprising:
Recalls information reads the ReadInfo function, successively described a plurality of file paths is passed to described ReadInfo function as parameter;
Receive the rreturn value of described ReadInfo function, described rreturn value is file content corresponding to described file path.
6. method according to claim 2, in Android operating system, described a plurality of file paths comprise file path/sys/class/hwmon/hwmon0/device/temp1_input, file path/sys/class/power_supply/battery/temp and file path/sys/class/power_supply/battery/batt_temp.
7. method according to claim 1 also comprises:
When the state that detects battery changes, the broadcast event that monitor terminal operating system is sent;
Read the additional data of described broadcast event, and from described additional data, extract the battery temperature data.
8. method according to claim 7, the state of described battery changes and comprises:
Charging begins, charging is finished or the electric quantity change amount of battery reaches default threshold value.
9. also comprise according to claim 1 or 7 described methods:
The battery temperature data of extracting and the temperature range of presetting are compared;
When described battery temperature data are within described temperature range, determine that described battery temperature data within temperature range are the battery temperature data of terminal;
When described battery temperature data exceeded described temperature range, with the temperature data of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing were as the battery temperature data of terminal.
10. each described method in 9 according to claim 1, described user interface be following any one:
The plug-in unit of the plug-in unit of desktop, desktop suspended window and browser.
11. an end cell temperature indicating device comprises:
The path analysis module is suitable for the file path of the battery temperature data place file that temperature sensor senses arrives in the analysing terminal battery; Wherein, described battery temperature data be system in advance call driver notice operating system be written to data in the file;
The temperature read module is suitable for reading file content corresponding to described file path;
The first extraction module is suitable for extracting described battery temperature data from described file content.
Display module is suitable for showing described battery temperature data in the user interface of terminal.
12. device according to claim 11, described temperature sensor senses to the file path of battery temperature data place file comprise a plurality of file paths,
Described temperature read module reads corresponding file content successively under described a plurality of file paths, when reading successively, when under any one file path, reading file content, stop to read file content corresponding to next file path, wherein, described being read as successively according to the order traversal that sets in advance read.
13. device according to claim 12, described temperature read module comprises:
Judge submodule, be suitable for when file content corresponding to described any one file path reads successfully, judge whether file content corresponding to described any one file path is empty content;
Stop reading submodule, be suitable for when judgment sub-unit is judged described file content not for empty content, stopping to read file content corresponding to next file path.
14. device according to claim 13, described temperature read module also comprises:
Continue reading submodule, be suitable for when reading successively, when file content corresponding to described any one file path reads failure, when the file content that perhaps described any one file path is corresponding is empty content, continue to read file content corresponding to next file path.
15. device according to claim 12, described temperature read module comprises:
Call submodule, be suitable for recalls information and read the ReadInfo function, successively described a plurality of file paths are passed to described ReadInfo function as parameter;
Receive submodule, be suitable for receiving the rreturn value of described ReadInfo function, described rreturn value is file content corresponding to described file path.
16. device according to claim 12, in Android operating system, described a plurality of file paths comprise file path/sys/class/hwmon/hwmon0/device/temp1_input, file path/sys/class/power_supply/battery/temp and file path/sys/class/power_supply/battery/batt_temp.
17. device according to claim 11 also comprises:
The second extraction module is suitable for when the state that detects battery changes, and the broadcast event that monitor terminal operating system is sent reads the additional data of described broadcast event, and extracts the battery temperature data from described additional data.
18. device according to claim 17, the state of described battery changes and comprises:
Charging begins, charging is finished or the electric quantity change amount of battery reaches default threshold value.
19. according to claim 11 or 17 described devices, also comprise:
Comparison module is suitable for the battery temperature data that will extract and the temperature range of presetting and compares;
Determination module is suitable for comparative result when comparison module and is described battery temperature data within described temperature range the time, determines that described battery temperature data within temperature range are the battery temperature data of terminal;
Modular converter, when being suitable for comparative result when comparison module and being described battery temperature data and exceeding described temperature range, with the temperature of described battery temperature data-switching one-tenth within described temperature range, and the battery temperature data after will changing are as the battery temperature data of terminal.
20. a terminal comprises: CPU, battery, temperature sensor, storer, and as the arbitrary described end cell temperature indicating device of above-mentioned claim 11 to 19.
CN201210487289.5A 2012-11-26 2012-11-26 End cell process for temperature indication and device and terminal Active CN103049069B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210487289.5A CN103049069B (en) 2012-11-26 2012-11-26 End cell process for temperature indication and device and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210487289.5A CN103049069B (en) 2012-11-26 2012-11-26 End cell process for temperature indication and device and terminal

Publications (2)

Publication Number Publication Date
CN103049069A true CN103049069A (en) 2013-04-17
CN103049069B CN103049069B (en) 2016-03-30

Family

ID=48061739

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210487289.5A Active CN103049069B (en) 2012-11-26 2012-11-26 End cell process for temperature indication and device and terminal

Country Status (1)

Country Link
CN (1) CN103049069B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103257320A (en) * 2013-05-08 2013-08-21 百度在线网络技术(北京)有限公司 Method and device for electric quantity environment construction of mobile terminal
CN103487138A (en) * 2013-09-29 2014-01-01 上海斐讯数据通信技术有限公司 Mobile terminal having ultraviolet ray real-time detection function based on cloud service and method of mobile terminal
WO2015154432A1 (en) * 2014-08-13 2015-10-15 中兴通讯股份有限公司 Temperature processing method and device
CN110293875A (en) * 2018-03-22 2019-10-01 本田技研工业株式会社 The battery temperature display device of vehicle

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN201403119Y (en) * 2008-12-12 2010-02-10 康佳集团股份有限公司 Cell phone with temperature monitoring function
CN101695084A (en) * 2009-09-29 2010-04-14 深圳华为通信技术有限公司 Method and device for prompting
US20100174833A1 (en) * 2009-01-05 2010-07-08 Roderick David Earle Filer Method and Apparatus for Identifying a Device Handle in a Computer System
US20110046832A1 (en) * 2009-02-17 2011-02-24 Vehicules Nemo Inc. Electronic Assistance System and Method
CN101984644A (en) * 2010-10-28 2011-03-09 浙江大学 Android operating system mobile phone-based temperature alarm method
CN202411012U (en) * 2011-12-05 2012-09-05 哈尔滨智木科技有限公司 Battery separation equipment with temperature monitor
CN102694913A (en) * 2012-05-14 2012-09-26 广东欧珀移动通信有限公司 Implementing method for carrying out alarming on abnormal temperature inside mobile phone

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN201403119Y (en) * 2008-12-12 2010-02-10 康佳集团股份有限公司 Cell phone with temperature monitoring function
US20100174833A1 (en) * 2009-01-05 2010-07-08 Roderick David Earle Filer Method and Apparatus for Identifying a Device Handle in a Computer System
US20110046832A1 (en) * 2009-02-17 2011-02-24 Vehicules Nemo Inc. Electronic Assistance System and Method
CN101695084A (en) * 2009-09-29 2010-04-14 深圳华为通信技术有限公司 Method and device for prompting
CN101984644A (en) * 2010-10-28 2011-03-09 浙江大学 Android operating system mobile phone-based temperature alarm method
CN202411012U (en) * 2011-12-05 2012-09-05 哈尔滨智木科技有限公司 Battery separation equipment with temperature monitor
CN102694913A (en) * 2012-05-14 2012-09-26 广东欧珀移动通信有限公司 Implementing method for carrying out alarming on abnormal temperature inside mobile phone

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103257320A (en) * 2013-05-08 2013-08-21 百度在线网络技术(北京)有限公司 Method and device for electric quantity environment construction of mobile terminal
CN103487138A (en) * 2013-09-29 2014-01-01 上海斐讯数据通信技术有限公司 Mobile terminal having ultraviolet ray real-time detection function based on cloud service and method of mobile terminal
WO2015154432A1 (en) * 2014-08-13 2015-10-15 中兴通讯股份有限公司 Temperature processing method and device
CN105472099A (en) * 2014-08-13 2016-04-06 中兴通讯股份有限公司 Temperature processing method and temperature processing device
CN110293875A (en) * 2018-03-22 2019-10-01 本田技研工业株式会社 The battery temperature display device of vehicle

Also Published As

Publication number Publication date
CN103049069B (en) 2016-03-30

Similar Documents

Publication Publication Date Title
CN110489345B (en) Crash aggregation method, device, medium and equipment
CN109947079A (en) Region method for detecting abnormality and edge calculations equipment based on edge calculations
CN110457211B (en) Script performance test method, device and equipment and computer storage medium
EP2684125A1 (en) Detecting application similarity
Varghese et al. An IoT analytics approach for weather forecasting using raspberry Pi 3 model B+
CN109614608A (en) Electronic device, text information detection method and storage medium
CN103365692A (en) Method and device for pushing prompt messages of software upgrading
CN103049069A (en) Terminal battery temperature display method and device and terminal
RU2606880C2 (en) Method, device and software for activity sensor data processing
CN111753192A (en) Advertisement popup intercepting method and device, electronic equipment and storage medium
CN112149329A (en) State rehearsal method, system, equipment and storage medium of key equipment of nuclear power plant
CN103019907A (en) Method and device for monitoring terminal battery temperature and terminal
CN107908679B (en) Script statement conversion method and device and computer readable storage medium
CN111736951A (en) Simulation method for automatic driving, computer device, and storage medium
CN113127050A (en) Application resource packaging process monitoring method, device, equipment and medium
CN103365778A (en) Control test method and device
CN112506871B (en) Automated task management and log management method, system, electronic device and medium
CN114265777A (en) Application program testing method and device, electronic equipment and storage medium
CN111081365A (en) Information display method, sample analysis assembly line and computer storage medium
CN114367983A (en) Abnormality processing method, robot, conveyance system, program product, and storage medium
WO2017172672A1 (en) System for monitoring and reporting performance and correctness issues across design, compile and runtime
CN103020132A (en) Method and device for displaying detection result of database performance
CN112052368A (en) Method, system, storage medium and electronic device for automatically extracting list data
CN112596814A (en) Method, apparatus, device, medium and program product for integrated packaging of items
CN112763251A (en) Mobile robot testing method and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20220728

Address after: Room 801, 8th floor, No. 104, floors 1-19, building 2, yard 6, Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park)

Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Patentee before: Qizhi software (Beijing) Co.,Ltd.