CN107193707A - Information processing method, device and mobile terminal - Google Patents

Information processing method, device and mobile terminal Download PDF

Info

Publication number
CN107193707A
CN107193707A CN201710318084.7A CN201710318084A CN107193707A CN 107193707 A CN107193707 A CN 107193707A CN 201710318084 A CN201710318084 A CN 201710318084A CN 107193707 A CN107193707 A CN 107193707A
Authority
CN
China
Prior art keywords
mobile terminal
wake
current value
power consumption
application program
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
CN201710318084.7A
Other languages
Chinese (zh)
Other versions
CN107193707B (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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201710318084.7A priority Critical patent/CN107193707B/en
Publication of CN107193707A publication Critical patent/CN107193707A/en
Application granted granted Critical
Publication of CN107193707B publication Critical patent/CN107193707B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3058Monitoring arrangements for monitoring environmental properties or parameters of the computing system or of the computing system component, e.g. monitoring of power, currents, temperature, humidity, position, vibrations
    • G06F11/3062Monitoring arrangements for monitoring environmental properties or parameters of the computing system or of the computing system component, e.g. monitoring of power, currents, temperature, humidity, position, vibrations where the monitored property is the power consumption
    • 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
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Computing Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Telephone Function (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The present invention relates to a kind of information processing method, device and mobile terminal.The above method includes:If the difference for detecting mobile terminal the first current value in the standby state and the second current value is more than first threshold, detect the difference of the 3rd current value of first current value with mobile terminal in the standby state whether more than Second Threshold;Wherein, first current value is the average current value of mobile terminal actual consumption in the standby state, and second current value is the reference current value of mobile terminal in the standby state, and the 3rd current value is the scene current value of mobile terminal in the standby state;If the difference of first current value and the 3rd current value be more than Second Threshold, according to mobile terminal in the standby state the wake-up times of wake source, the length of one's sleep of mobile terminal than judge mobile terminal power consumption type.The above method, can efficiently monitor the power consumption type of mobile terminal.

Description

Information processing method, device and mobile terminal
Technical field
The present invention relates to field of computer technology, more particularly to a kind of information processing method, device and mobile terminal.Tool Body, it is related to a kind of standby power consumption monitoring method, device and mobile terminal.
Background technology
With the development of intelligent mobile terminal, intelligent mobile terminal is gradually popularized in people's daily life.In intelligent sliding During the use of dynamic terminal, the operation of the program module of each in intelligent mobile terminal can expend substantial amounts of electricity so that intelligence The power consumption of mobile terminal is accelerated.The power consumption quickening of intelligent mobile terminal is, it is necessary to user is to intelligent mobile terminal frequent charge, and meeting Reduce the service life of battery in intelligent mobile terminal.
The content of the invention
The embodiment of the present invention provides a kind of information processing method, device and mobile terminal, can efficiently monitor mobile whole The power consumption type at end.
A kind of information processing method, including:
If the difference for detecting mobile terminal the first current value in the standby state and the second current value is more than first threshold, Detect whether the difference of the 3rd current value of first current value and mobile terminal in the standby state is more than Second Threshold;
Wherein, first current value is the average current value of mobile terminal actual consumption in the standby state, described the Two current values are the reference current value of mobile terminal in the standby state, and the 3rd current value is mobile terminal in holding state Under scene current value;
If the difference of first current value and the 3rd current value is more than Second Threshold, according to mobile terminal in standby shape The wake-up times of wake source, the power consumption type of the length of one's sleep judgement mobile terminal of mobile terminal under state.
In one of the embodiments, it is described according to the mobile terminal wake-up times of wake source, movement in the standby state The length of one's sleep of terminal judges that the power consumption type of mobile terminal includes:
Detect whether the wake-up times of the wake source reach designated value;
If so, judging the power consumption type of mobile terminal according to the most wake source of the wake-up times;
If it is not, detecting whether the length of one's sleep ratio of first current value and the mobile terminal meets preset rules;If Meet preset rules, the power consumption type of record mobile terminal is hardware anomalies power consumption.
In one of the embodiments, the wake source most according to the wake-up times judges the power consumption of mobile terminal Type includes:
Obtain the wake-up times of each sub- wake source and each sub- wake source of wake-up in the most wake source of the wake-up times Application program;
Mobile terminal is judged according to the wake-up times of each sub- wake source and the application program for waking up each sub- wake source Power consumption type.
In one of the embodiments, methods described also includes:
If the difference for detecting first current value and the 3rd current value is less than Second Threshold, according to the described 3rd electricity Flow valuve judges the power consumption type of mobile terminal.
In one of the embodiments, methods described also includes:
The standby time for detecting mobile terminal is more than preset duration, obtains first current value and second electric current Value.
A kind of information processor, including:
Detection module, if the difference for detecting mobile terminal the first current value in the standby state and the second current value More than first threshold, detect whether the difference of the 3rd current value of first current value and mobile terminal in the standby state is more than Second Threshold;
Wherein, first current value is the average current value of mobile terminal actual consumption in the standby state, described the Two current values are the reference current value of mobile terminal in the standby state, and the 3rd current value is mobile terminal in holding state Under scene current value;
First determination module, if the difference for first current value and the 3rd current value is more than Second Threshold, root According to mobile terminal in the standby state the wake-up times of wake source, mobile terminal the length of one's sleep judge mobile terminal power consumption class Type.
In one of the embodiments, first determination module be additionally operable to detect the wake source wake-up times whether Reach designated value;
If so, judging the power consumption type of mobile terminal according to the most wake source of the wake-up times;
If it is not, detecting whether the length of one's sleep ratio of first current value and the mobile terminal meets preset rules;If Meet preset rules, the power consumption type of record mobile terminal is hardware anomalies power consumption.
In one of the embodiments, first determination module is additionally operable to obtain the most wake source of the wake-up times In each sub- wake source wake-up times and wake up the application program of each sub- wake source;
Mobile terminal is judged according to the wake-up times of each sub- wake source and the application program for waking up each sub- wake source Power consumption type.
In one of the embodiments, described device also includes:
Second determination module, if being less than the second threshold for the difference for detecting first current value and the 3rd current value Value, the power consumption type of mobile terminal is judged according to the 3rd current value.
In one of the embodiments, described device also includes:
Acquisition module, the standby time for detecting mobile terminal is more than preset duration, obtains first current value With second current value.
A kind of mobile terminal, including memory, processor and storage are on a memory and the meter that can run on a processor Calculation machine program, realizes the method described in any of the above-described during the computing device described program.
Brief description of the drawings
Fig. 1 is the application environment schematic diagram of information processing method in one embodiment;
Fig. 2 is the flow chart of information processing method in one embodiment;
Fig. 3 is the flow chart of mobile terminal upload standby current abnormal information in one embodiment;
Fig. 4 is Wi-Fi wake sources statistics schematic diagram in one embodiment;
Fig. 5 is the flow chart of information processing method in another embodiment;
Fig. 6 is the flow chart of monitoring processing center operation in one embodiment;
Fig. 7 is the flow chart without service scenarios detection in one embodiment;
Fig. 8 is the flow chart of the frequent gravity treatment scene detection of cell in one embodiment;
Fig. 9 frequently activates the flow chart that scene detection is frequently retransmitted with short message for data in one embodiment;
Figure 10 is the schematic diagram of data sharing method in one embodiment;
Figure 11 is the flow chart of information processing method in another embodiment;
Figure 12 is the flow chart of information processing method in another embodiment;
Figure 13 is the flow chart of information processing method in another embodiment;
Figure 14 is the flow chart of information processing method in another embodiment;
Figure 15 is the flow chart of information processing method in another embodiment;
Figure 16 is the flow chart of information processing method in another embodiment;
Figure 17 is the flow chart of information processing method in another embodiment;
Figure 18 is the structured flowchart of information processor in one embodiment;
Figure 19 is the structured flowchart of information processor in another embodiment;
Figure 20 is the structured flowchart of information processor in another embodiment;
Figure 21 is the structured flowchart of information processor in another embodiment;
Figure 22 is the structured flowchart of information processor in another embodiment;
Figure 23 is the structured flowchart of information processor in another embodiment;
Figure 24 is the structured flowchart of information processor in another embodiment;
Figure 25 is the structured flowchart of information processor in another embodiment;
Figure 26 is the structured flowchart of information processor in another embodiment;
Figure 27 is the block diagram of the part-structure of the mobile phone related to mobile terminal provided in an embodiment of the present invention.
Embodiment
In order to make the purpose , technical scheme and advantage of the present invention be clearer, it is right below in conjunction with drawings and Examples The present invention is further elaborated.It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, and It is not used in the restriction present invention.
It is appreciated that term " first " used in the present invention, " second " etc. can be used to describe various elements herein, But these elements should not be limited by these terms.These terms are only used for distinguishing first element and another element.Citing comes Say, without departing from the scope of the invention, the first determination module can be referred to as the second determination module, and similarly, Second determination module can be referred to as the first determination module.First determination module and the second determination module both determination module, But it is not same determination module.
Fig. 1 is the application environment schematic diagram of information processing method in one embodiment.As shown in figure 1, being wrapped in mobile terminal Include monitoring module 102, information storage module 104, branch center anomalous identification module 106 and feedback module 108.Monitoring module 102 For monitoring mobile terminal in standby state, monitoring module 102 includes program function pair under monitoring processing center and holding state The current value inventory answered.The second current value can be obtained according to standby interval sequence function and corresponding current value by monitoring processing center, And contrast the first current value and the second current value, whether detection has high current consumption, and root in mobile terminal in standby state The nodal information and Map information provided according to branch center anomalous identification module 106 is consumed to high current to be qualitatively judged, and will determine that knot Crucial subregion in fruit write-in information storage module 104.Information storage module 104 is supervised in the standby state for memory mobile terminal The information obtained is controlled, including BSP modules (Board Support Package, board suppot package) are with treating that Node forms are stored Under machine state the wake-up times of each wake source, Wi-Fi (Wireless-Fidelity, Wireless Fidelity) modules and Modem module with The corresponding current value of each scene, monitoring processing center are stored in the mobile end of crucial subregion under the holding state of Map forms storage The power consumption type at end and it is stored in the data that Block modules are available for instrument after sale to read.Branch center anomalous identification module 106 is used In data under statistics mobile terminal in standby state, including driving layer recognize and count wake source, each sub- wake-up in Wi-Fi module Wake-up identification and Wi-Fi module in the power consumption statistics of known power consumption type, Modem module each sub- wake source wake-up identification Power consumption statistics with power consumption type known to Modem module etc..Feedback module 108 is used to carry in interface of mobile terminal ejection prompting frame The user that wakes up uploads information to server.
Fig. 2 is the flow chart of information processing method in one embodiment.As shown in Fig. 2 a kind of information processing method, including Step S202 to step S204.Wherein:
S202, if the difference for detecting mobile terminal the first current value in the standby state and the second current value is more than first Whether threshold value, the difference of the 3rd current value of detection the first current value and mobile terminal in the standby state is more than Second Threshold.Its In, the first current value is the average current value of mobile terminal actual consumption in the standby state, and the second current value is mobile terminal Reference current value in the standby state, the 3rd current value is the scene current value of mobile terminal in the standby state.
Mobile terminal in the standby state when, can detect whether mobile terminal current idle state meets preparatory condition;If Meet preparatory condition, then judge whether the difference of the first current value and the second current value under mobile terminal in standby state is more than the first threshold Value.Wherein, preparatory condition may include:Whether the standby time of mobile terminal reaches that preset duration, mobile terminal in standby state are No is default holding state etc..Default holding state may include:Background music is played, backstage is downloaded, mobile terminal is opened Modem Log etc..If mobile terminal in standby state is default holding state, current consumption value is larger in mobile terminal, without Current consumption value in mobile terminal is monitored, then does not obtain the first current value and the second current value of mobile terminal.Judge mobile whole Hold whether holding state is that default holding state may include:If detect has audio output in mobile terminal in standby state, Interval, which specifies to detect again after the time, audio output in mobile terminal, then judges mobile terminal current idle state as backstage Music;If detecting in mobile terminal in standby state Wi-Fi flows more than 30M/h (MByte/hour, million/hour), Or data network flux is more than 20M/h, then judge that mobile terminal current idle state is downloaded as backstage.
The total current value that first current value can be consumed in the stand-by time and stand-by time according to mobile terminal is obtained;Second The corresponding current value of program function and program function that current value can in the standby state be opened according to mobile terminal is obtained.Move The corresponding current value of program function under holding state is prestored in dynamic terminal, according to the application opened under mobile terminal in standby state Program function can the corresponding current value of search program function, can calculate the second electric current further according to the corresponding current value of program function Value.Wherein, the corresponding current value of function of application is the service data of mobile terminal hardware state, can be by application program work( The corresponding current value write-in existing power consumption type file of mobile terminal of energy, such as:Vendor/oppo/overlay/ item designations/ In frameworks/base/core/res/res/xml/power_profile.xml files.As shown in table 1, it is a certain batch The corresponding current range of mobile terminal Program function and current value, second can be calculated according to the corresponding current value In of program function Current value I=∑s (I1+I2+…In).For example, mobile terminal single deck tape-recorder is standby and connection Wi-Fi no datas, then the of mobile terminal Two current value I=4.5+4+2.6=11.1mA (milli-Ampere, milliampere).
The program function of table 1 and corresponding current value inventory
In different mobile terminal hardware, system, version, the difference of voltameter can cause function of application correspondence to electricity Flow valuve difference, therefore, the corresponding current value of different mobile terminal Program function are different.According to the corresponding current value of program function The second current value calculated carries float value.Influenceing the factor of the float value of the second current value includes:Standby time T, the second electricity Flow valuve I, battery capacity C and voltameter error amount n%.The float value Δ T of second current value and the functional relation of the above-mentioned factor For:
For example, battery capacity C is 3000mAh (milli-Ampere-hour, MAH), standby time T is 5 hours, Second current value I is 12mA, and voltameter error amount is 1%, then the float value of the second current value is Δ T=(3000*1%)/5= 6mA.When the difference for detecting the current value of mobile terminal first and the second current value is more than float value, that is, judge the electricity of mobile terminal first Flow valuve and the difference of the second current value are more than first threshold, obtain mobile terminal the 3rd current value in the standby state, detection first Whether the difference of current value and the 3rd current value is more than Second Threshold.For example, the first current value is 20mA during mobile terminal standby, the Two current values are 12mA, and the float value of the second current value is 6mA, then the difference of the first current value and the second current value is 8mA, then the The difference of one current value and the second current value is more than the float value of the second current value, obtains the 3rd current value of mobile terminal.
3rd current value refers to the scene current value of mobile terminal in the standby state, mobile terminal field in the standby state Scape may include:Group key interaction times, Wi-Fi re-rent number of times, short message sending times etc. in Wi-Fi scanning times, Wi-Fi, no It is limited to this.Mobile terminal can obtain corresponding current value according to the scene under holding state, by each scene pair under holding state Cumulative i.e. available 3rd current value of current value answered.For example, Wi-Fi scanning times are 10 to mobile terminal in the standby state Secondary, its corresponding scene current value is 1mA;Wi-Fi re-rents number of times for 5 times to mobile terminal in the standby state, its corresponding field Scape current value is 1mA;Then the 3rd current value is 2mA to mobile terminal in the standby state.
S204, if the difference of the first current value and the 3rd current value is more than Second Threshold, according to mobile terminal in holding state The wake-up times of lower wake source, the length of one's sleep of mobile terminal judge the power consumption type of mobile terminal.
Second Threshold can be set as needed.In one embodiment, Second Threshold can be the second current value, the second electric current Float value and designated value sum.The difference of first current value and the 3rd current value is the first current value and the 3rd more than Second Threshold The difference of current value is more than the second current value, the second current floating value and designated value sum.For example, the first current value is 25mA, the Two current values are 12mA, and the float value of the second current value is 6mA, and the 3rd current value is 3mA, and designated value is 3mA, the first current value And the difference of the 3rd current value is 22mA, the second current value, the float value of the second current value and designated value sum are 21mA, the first electricity Flow valuve and the difference of the 3rd current value are more than Second Threshold, then according to mobile terminal in the standby state the wake-up times of wake source, Power consumption type of the length of one's sleep of mobile terminal than judging mobile terminal.In another embodiment, can also be according to mobile whole The end wake-up times of wake source, sleep duration of mobile terminal under standby shape body judge the power consumption type of mobile terminal.
Wake source includes AP (Wireless Access Point, wireless access points) under mobile terminal in standby state Wake-up, Wi-Fi wake up, Modem wakes up, power key wakes up etc., not limited to this.Mobile terminal can be recorded in real time under holding state The wake-up times of each wake source and the application program for waking up each wake source.As shown in table 2, be in mobile terminal wake source and its Definition.
The wake source of table 2 and definition
Wake source Title
power_key Power button wakes up
wcnss_wlan Wi-Fi wakes up
Modem Modem wakes up
qpnp_rtc_alarm Modem wakes up
The data storage that mobile terminal is recorded in real time is in the memory module of mobile terminal.Above-mentioned memory module includes key Partitioned storage module, interim mutual files node and wake source statistics interface.Crucial partitioned storage module, which is used to store, have been recognized Power consumption type and unidentified power consumption type.Interim mutual files node is used to store calling out for each wake source in the standby state The application program for number of times and each wake source of wake-up of waking up.Interim mutual files node is used for temporary transient memory mobile terminal holding state Lower data, when detecting mobile terminal bright screen, data are emptied in interim mutual files node.Wake source statistics interface is used to unite The wake-up times of each wake source are counted, and are supplied to mobile terminal to read by system interface.When acquisition for mobile terminal refers to screen is put out When making, the wake-up times that wake source is counted to each wake source of interface record are reset;When detecting mobile terminal and being waken up, Corresponding wake source is identified, and the wake-up times for recording wake source are added 1, the most wake source of wake-up times is supplied to shifting Dynamic terminal is read.Wherein, wake source statistics interface node can be .../sys/kernel/wakeup_reasons/ap_ resume_reason_stastics.As shown in table 3, it is the power consumption type of crucial partitioned storage module record.
The mobile terminal power consumption type of table 3 and definition
The length of one's sleep of mobile terminal accounts for the ratio of standby time than the duration that refers to sleep under mobile terminal in standby state.Root According to mobile terminal, the most wake source of wake-up times, the length of one's sleep ratio of mobile terminal and the first current value can in the standby state Judge the power consumption type of mobile terminal.
Information processing method in the embodiment of the present invention, by the current value for detecting actual consumption under mobile terminal in standby state With the difference of reference current value, scene current value, further according to wake-up times of wake source under mobile terminal in standby state, it is mobile eventually Power consumption type of the length of one's sleep at end than judging mobile terminal, can easily monitor the power consumption type of mobile terminal.
In one embodiment, mobile terminal can be by the power consumption type upload server of the mobile terminal of judgement.
Mobile terminal can be uploaded onto the server data by Log uploading tools Stethoscope, and every part of Log is with defect Mode is submitted to database correspondence item area.When mobile terminal is detected, power consumption is abnormal, and mobile terminal can determine that mobile terminal Power consumption type and interface of mobile terminal eject prompting frame, for pointing out SCN subscriber connection network and uploading Log automatically.When automatic When uploading many failures of Log, mobile terminal only uploads key message, the power consumption type of such as mobile terminal and corresponding power consumption automatically Amount, and point out user the power consumption type information for uploading mobile terminal manually in interface of mobile terminal pop-up.Log is in mobile terminal Journal file, can record the operation information of operating system and application program in mobile terminal;In the present embodiment, it can be recorded in Log The power consumption type information of mobile terminal.Mobile terminal uploads the power consumption type of mobile terminal according to default time interval, such as moves Dynamic terminal uploaded the power consumption type for the mobile terminal for once monitoring acquisition every 24 hours.Mobile terminal can also be pointed out by pop-up Remind customer mobile terminal power consumption abnormal.Wherein, it is mobile when crucial partitioned storage module Log switches are closed in mobile terminal Terminal not pop-up is reminded;When mobile terminal system version is Release versions, i.e. Log switches are opened, mobile terminal also not bullet Window is reminded;When mobile terminal system version to send when survey version or special version, mobile terminal not pop-up is reminded.As shown in table 4, Survey version and special version and identification feature are sent for mobile terminal.
The mobile terminal version identification feature of table 4
Fig. 3 is the flow chart of mobile terminal upload standby current abnormal information in one embodiment.As shown in figure 3, including:
S302, detects standby current abnormal.Refer to if detecting the current value consumed under mobile terminal in standby state and being more than Definite value, into step S304.
S304, pop-up window prompting user uploads data.It is abnormal that power consumption is uploaded in interface of mobile terminal pop-up prompting user Data.
S306, closes Log switches and compressed data.Modem Log are switched in turning-off mobile terminal, and it is different to record power consumption The Log compressing files of normal information.
S308, if Wi-Fi connection.Whether detection mobile terminal connects Wi-Fi;If so, into step S310;If it is not, Into step S312.
S310, uploads Log.The Log file upload services devices of power consumption abnormal information will be recorded, upload is successfully entered step S318;Upload and unsuccessfully enter step S314.
S312, points out user's connection Wi-Fi.Detect after mobile terminal connection Wi-Fi, upload Log.
Whether S314, upload fail again.If so, into step S316.If it is not, into step S318.
S316, only uploads key message, points out to upload manually.Key message, such as power consumption in Log are uploaded by data network Exception Type is hardware power consumption, and power consumption is 10mA.
S318, terminates.
Information processing method in the embodiment of the present invention, will judge the consumption of the mobile terminal obtained under mobile terminal in standby state Electric type upload server, is conducive to the convenient stand-by power consumption information that mobile terminal is obtained from server of developer, favorably Statistical analysis is carried out in the stand-by power consumption information to mobile terminal.
In one embodiment, in Fig. 2 step S204 according to mobile terminal in the standby state the wake-up times of wake source, The length of one's sleep of mobile terminal judges that the power consumption type of mobile terminal includes:It is specified whether the wake-up times of detection wake source reach Value;If so, judging the power consumption type of mobile terminal according to the most wake source of wake-up times;If it is not, detection the first current value and Whether the length of one's sleep of mobile terminal than meets preset rules;If meeting preset rules, the power consumption type of record mobile terminal is Hardware anomalies power consumption.
Under the holding state of mobile terminal, if the wake-up times of wake source reach designated value in mobile terminal, according to calling out The most wake source of number of times of waking up judges the power consumption type of mobile terminal.Under such as mobile terminal in standby state, Wi-Fi in mobile terminal Wake-up times are 16 times/hour, Modem wake-up times reach that 15 times/hour, AP wake-up times reach 10 times/hour, Wi-Fi The number of times waken up with Modem is waken up more than 15 times/hour, then is waken up according to the most Wi-Fi of wake-up times and judges mobile terminal Power consumption type for Wi-Fi wake up power consumption.If the wake-up times of wake source are not up to designated value, detection first in mobile terminal Whether the length of one's sleep ratio of current value and mobile terminal meets preset rules, and whether such as the first current value is more than 22mA, during sleep Between than whether more than 99% etc..If the first current value is more than 22mA, and mobile terminal sleeps ratio in holding state more than 99%, Then judge the power consumption type of mobile terminal as hardware anomalies power consumption.If the wake-up times of wake source are not up to specified in mobile terminal Value, and be not hardware anomalies power consumption type, then it is determined as unknown power consumption type.
In one embodiment, the above-mentioned wake source most according to wake-up times judges the power consumption type bag of mobile terminal Include:Obtain the application program of the wake-up times of each sub- wake source and each sub- wake source of wake-up in the most wake source of wake-up times; The power consumption type of mobile terminal is judged according to the wake-up times of each sub- wake source and the application program for waking up each sub- wake source.
Each wake source includes sub- wake source in mobile terminal.Wlan_ is waken up as Wi-Fi wake sources include packet Wakeup_src_count [DATA_TYPE_STASTIC], management bag wake up wlan_wakeup_src_count [MGMT_ TYPE_STASTIC], firmware wake up wlan_wakeup_src_count [EVENT_TYPE_STASTIC] and other types wake-up wlan_wakeup_src_count[UNKNOWN_TYPE_STASTIC].As shown in figure 4, putting out screen when mobile terminal is received and referring to When making, mobile terminal calls wlan interface wlan_clear_wakesrc_count () by each sub- wake source in Wi-Fi wake sources Wake-up times reset.Under the holding state of mobile terminal, when Wi-Fi wake sources wake up mobile terminal, mobile terminal can Corresponding sub- wake source in the Wi-Fi wake sources of detection wake-up mobile terminal, and the wake-up times correspondence of sub- wake source Jia 1. When mobile terminal receives bright screen instruction, the wake-up times of each sub- wake source in wake source are write in memory module and handed over temporarily Mutual file node .../sys/kernel/wakeup_reasons/conn_resume_reason_stastics, and by waking up Source statistics interface is supplied to mobile terminal to read.
After mobile terminal detects the most wake source of wake-up times in the standby state, wake-up times are further obtained The application program of the wake-up times of each sub- wake source and the sub- wake source of wake-up, is called out each sub- wake source in most wake sources Wake up and number of times and wake up the application program of sub- wake source and carry out statistical analysis, and by statistic analysis result upload server.For example, moving Dynamic terminal in the standby state the most wake source of wake-up times be Wi-Fi wake sources, wake-up times be 30 times, further obtain It is 15 times to get packet in Wi-Fi wake sources and wake up, and it is 5 times that management bag, which wakes up, and it is 5 times that firmware, which wakes up, and other types wake up For 5 times.It is QQ, microblogging to obtain the packet under mobile terminal in standby state and wake up corresponding application program.Then judge mobile whole The power consumption type at end is that Wi-Fi wakes up power consumption, specifically application program QQ and microblogging frequently carry out packet in mobile terminal Wake up the power consumption caused.
In one embodiment, above- mentioned information processing method also includes:If detecting the first current value and the 3rd current value Difference be less than Second Threshold, according to the 3rd current value judge mobile terminal power consumption type.
When the difference of the first current value and the 3rd current value is less than the difference of Second Threshold, i.e. the first current value and the 3rd current value Less than the second current value, the float value of the second current value and designated value sum, i.e. the difference of the first current value and the 3rd current value exists In domain of walker, then the power consumption type of mobile terminal is judged according to the 3rd current value.For example, under mobile terminal in standby state One current value is 22mA, and the second current value is 12mA, and the float value of the second current value is 6mA, and the 3rd current value is 3mA, is specified It is worth for 3mA, then the difference of the first current value and the 3rd current value is 19mA, the second current value, the float value of the second current value and finger Definite value sum is 21mA, then the difference of the first current value and the 3rd current value is less than Second Threshold, then obtains right in the 3rd current value The current value for each scene answered, such as the 3rd current value 3mA re-rents number of times 5 times including Wi-Fi scanning times 10 1mA, Wi-Fi 1mA, group key interact 10 1mA, then judges the power consumption type of mobile terminal as Wi-Fi scannings frequently, Wi-Fi re-rent it is frequent and Group key interaction is frequent.Mobile terminal can divide the power consumption type information record of the mobile terminal of judgement in the key of partition holding Area's memory module and upload server.Power consumption type such as mobile terminal is frequent for Wi-Fi scannings, and Wi-Fi scanning times are 10 Secondary, corresponding power consumption is 1mA.
Information processing method in the embodiment of the present invention, the power consumption class of mobile terminal is judged according to known scene power consumption Type, can scene known to statistical analysis mobile terminal power consumption condition, according to statistic analysis result be conducive to mobile terminal carry out Improve.
In one embodiment, above- mentioned information processing method also includes:The standby time for detecting mobile terminal is more than in advance If duration, the first current value and the second current value are obtained.
Screen instruction is put out when mobile terminal is received, mobile terminal starts to monitor the power consumption of mobile terminal under holding state; If mobile terminal receives the instruction of bright screen in default time interval, mobile terminal removes the number recorded in the standby state According to, i.e., when the standby time of mobile terminal is more than preset duration, data under mobile terminal monitoring record holding state, and to obtaining Data analyzed, judge mobile terminal power consumption type.For example, preset duration can be 5 hours, it is standby when mobile terminal When duration is more than 5 hours, the data that mobile terminal is obtained to detection are analyzed, and judge the power consumption type of mobile terminal.
Under mobile terminal in standby state power consumption according to battery drain percentage calculate, and in mobile terminal battery electricity Amount is with time nonlinear attenuation, when not having voltameter in mobile terminal, and mobile terminal is calculated according to the percentage of battery drain Under holding state there is larger error in power consumption, and such as 0.5%~1%.
Information processing method in the embodiment of the present invention, the preset duration reached by setting standby time to need, Ke Yiyou The error of the control electric current value of effect, improves the accuracy calculated.
Fig. 5 is the flow chart of information processing method in another embodiment.As shown in figure 5, a kind of information processing method, bag Step S502 is included to step S510.Wherein:
S502, A are not less than BFirst state and the second state can calculate the first electricity during bright screen when putting out screen according to mobile terminal Flow valuve A;Second current value B can be calculated according to program function and corresponding current value inventory.Judge whether the first current value A is not less than Second current value B;If so, into step S504;If it is not, into step S510.
S504, excludes known scene current value.The scene according to known to being monitored Modem and Wi-Fi monitoring records are in Map Power consumption, can obtain the 3rd current value.Determine whether known scene power consumption in the 3rd current value.Excluding the consumption of known scene After electricity, mobile terminal power consumption exceedes designated value, into step S506.
S506, judges mobile terminal power consumption type.BSP wake sources monitoring data according to described in Node judges mobile whole The power consumption type at end, into step S508.
S508, upload server.The power consumption type of the mobile terminal of judgement is write key Log and uploads clothes by mobile terminal Business device.Instrument also can obtain the power consumption type information of mobile terminal by reading key Log information after sale.
S510, terminates.
Information processing method in the embodiment of the present invention, can efficiently monitor the power consumption type of mobile terminal.
Fig. 6 is the flow chart of monitoring processing center operation in one embodiment.As shown in fig. 6, in monitoring module in Fig. 1 Monitor the flow chart of processing center operation, including step S602 to step S620.Wherein:
S602, puts out screen record first state.Mobile terminal receive put out screen instruction when, record put out screen time, battery electric quantity Deng.
S604, bright screen records the second state.Mobile terminal receives bright screen instruction, records bright screen time, battery electric quantity etc..
Whether S606, mobile terminal in standby state is default holding state.If so, into step S608;If it is not, into Step S610.Whether the standby time of detection mobile terminal reaches preset duration, whether the holding state of mobile terminal is not pre- If holding state, whether the Modem Log of mobile terminal close.
S608, reads wake source wake-up times, each sub- wake source wake-up times, scene power consumption information, first state information With the second status information.The information that mobile terminal is recorded in the standby state is read, into step S612.
S610, terminates.
S612, calculates the first current value A, the second current value B, the 3rd current value C.
S614, A are not less than B.Judge whether the first current value A is not less than the second current value B;If so, into step S610; If it is not, into step S616.
Whether S616, A subtract the 3rd current value C up to standard.If so, into step S610;If it is not, into step S618.
S618, judges mobile terminal power consumption type and writes crucial subregion.Judge the power consumption type of mobile terminal, and will sentence Crucial subregion in the power consumption type information write-in memory module of fixed mobile terminal.
S620, Alarm sequence extremely play frame prompting.Alarm is to be used in android system complete alarm clock type timed task Class, Alarm classes can complete disposable timed task or circulation timing task.When detecting mobile terminal power consumption exception, lead to Cross Alarm sequences extremely and play frame prompting user, and by mobile terminal power consumption type information upload server.
Frequently activated without service time, frequent gravity treatment, data in mobile terminal power consumption type and short message is frequently retransmitted and can led to Cross Modem module monitoring.
As shown in fig. 7, being the flow chart detected in one embodiment without service scenarios.When in mobile terminal being double card, If two card simultaneously without service, individually calculate every card the time without service again add up as mobile terminal without service time, But mobile terminal is not more than the mobile terminal standby time without service time.
S702, start.Start Telephony processes after mobile terminal-opening and monitor service state.Wherein, in mobile terminal In ServiceStateTracker classes GSMServiceStateTracker subclasses can monitor mobile card and UNICOM blocks whether without Service;CDMAServiceStateTracker subclasses can monitor telecommunications card whether without service.
S704, monitors service state.Specifically, service state can be monitored in mobile terminal updateSpnDisplay. Monitor that mobile terminal has service, into step S706;Mobile terminal is monitored without service, into step S720.
S706, many cards judge and are handled differently.Detect with the presence or absence of multiple cards in mobile terminal, if in the presence of, while listening for The service state of every card.
S708, records current time.
S710, no service start time is not 0Whether detection without service start time is 0, if so, into step S712; If it is not, return to step S704.
S712, no service start time, which is more than, puts out the screen timeDetection puts out the screen time without whether service start time is more than, if It is, into step S716;If it is not, into step S714.
S714, no service time=without service time+(current time-put out the screen time).
S716, no service time=without service time+(current time-without service start time).
S718, no service start time is set to 0.Return to step S704.
S720, many cards judge and are handled differently.If mobile terminal blocks in the presence of multiple, when adding up without service of multiple cards is calculated Between as mobile terminal without service time;If mobile terminal only exists a card, calculate the card without service time as shifting Dynamic terminal without service time.
S722, records current time.
S724, no service start time is 0Whether detection without service start time is 0, if so, into step S726;If It is no, return to step S704.
S726, no service start time=current time.Return to step S704.
S728, monitors screen state.Screen state can be monitored in mobile terminal handleMessage, judges mobile whole End, which is presently at, puts out screen state and is in bright screen state.When receive put out screen instruction when, into step S730;When receiving During the instruction of bright screen, into step S734.
S730, record puts out the screen time.
S732, no service time resets.When mobile terminal, which is received, puts out screen instruction, it will be reset without service time.
S734, records the bright screen time.
S736, no service start time is not 0If so, into step S738;If it is not, return to step S728.
S738, no service time=without service time+(m- without service start time during bright screen).Return to step S728.
The method detected in the embodiment of the present invention without service scenarios, can efficiently monitor the service state of mobile terminal, Detect in mobile terminal without service time.
As shown in figure 8, being the flow chart of the frequent gravity treatment scene detection of cell in one embodiment.When mobile terminal is by without clothes During the business state entering signal area of coverage, mobile terminal can search all base station signals that can be connected, and select one of base Stand connection.Wherein, the scope of base station signal covering is cell.When mobile terminal connects a certain base station signal, i.e. mobile terminal Reside in the corresponding cell in the base station.When mobile terminal is in the intersection of multiple base stations, mobile terminal can frequent gravity treatment company The base station connect, causes mobile terminal power consumption abnormal.
S802, start.Start to monitor the cell ID that mobile terminal is connected after mobile terminal-opening.
S804, monitors current persistent district number.The ID of current persistent district is monitored, if changing, into step S806;If It is unchanged, persistently monitor current persistent district number.
Reselection frequency increases 1 certainly during S806, bright screen.The frequent reselection frequency of cell is added 1 and recorded.It is mobile whole when listening to The ID of persistent district is held to change 1 time, the frequent reselection frequency of the corresponding cell by record adds 1.
S808, monitors screen state.If monitoring to put out screen, into step S810;If monitoring bright screen, into step S816。
S810, record puts out the screen time.
Reselection frequency/(putting out m- bright screen time during screen) during S812, reselection frequency=bright screen.According to the gravity treatment of record time Count, put out screen time and bright screen Time Calculation cell reselection frequency.
Reselection frequency is reset during S814, dormancy.Calculate after reselection frequency, reselection frequency is reset, return to step S808 Again screen state is monitored.
S816, records the bright screen time.
Reselection frequency=reselection frequency * (m- during bright screen to put out the screen time) during S818, dormancy.
Reselection frequency is reset during S820, reselection frequency clearing, bright screen.Return to step S808 monitors screen state.
In mobile terminal sleep, Telephony layers can not receive Modem layers of cell reselection event in mobile terminal, That is Telephony layers can not receive the message of current area ID information reportings.The heavy Selected Inspection survey side of intermediate frequency of the embodiment of the present invention Method, by record cell reselection frequency during bright screen be used as put out screen when cell reselection frequency, the power consumption of mobile terminal can be reduced.
As shown in figure 9, frequently activating the flow chart that scene detection is frequently retransmitted with short message for data in one embodiment.Number Refer to that data transfer behavior wakes up mobile terminal under mobile terminal in standby state according to frequent activation, short message, which is retransmitted, refers to movement Terminal retries transmission after short message failure is sent, under the holding state of mobile terminal, frequently data activation in mobile terminal Electricity can be consumed by being retransmitted with short message.
S902, start.Start the activation of monitoring data in mobile terminal and short message sending after mobile terminal-opening.
S904, monitored data activation behavior.Activation behavior is listened to, into step S906.Activation behavior is not heard, Then continue monitored data activation behavior.
S906, data activation number of times increases 1 certainly.Data activation behavior is listened to, the data activation behavior number of times of record is added 1。
S908, monitors screen state.In mobile terminal bright screen, screen state is persistently monitored;When mobile terminal puts out screen, Into step S910.
S910, data activation number of times is reset, short message sending times are reset.When listening to mobile terminal and putting out screen, it will record Zeros data, and continue monitor screen state.
S912, monitors short message sending behavior.Short message sending behavior is listened to, into step S914.Position listens to short message Send information and then persistently monitor short message sending information.
S914, short message sending times increase 1 certainly.Listen to short message and retransmit behavior, the short message sending times of record are added 1, and Persistently monitor short message sending behavior.
Frequently activation and short message frequently retransmit scene detection method to data in the embodiment of the present invention, can easily detect Data in mobile terminal frequently activates behavior and short message frequently retransmits behavior, and record data frequently activates the electricity, short of consumption Letter frequently retransmits the electricity of consumption.
(Android Interface Definition Language, Android interface defines language to AIDL in mobile terminal Speech) mechanism the result detected can be passed to stand-by power consumption identification monitoring service.Such as by the data activation frequency monitored, The frequent reselection frequency of short message recurrence frequency, cell and pass to recognition detection service without service time.As shown in Figure 10, by inciting somebody to action ConnectivityManager stores data in ConnectivityService as interface class, mobile terminal it is standby Consumption detection service can store and read data by calling ConnectivityManager.When power consumption is examined in mobile terminal Survey service read data when, if in mobile terminal Telephony layer have not been written to data, the data read and write number According to asynchronous.Wherein, a tag such as AlreadyUpdate can be set and carrys out record data.Telephony layers can be in mobile terminal Tag resets to 0 when putting out screen, and tag is set into designated value such as true again after mobile terminal bright screen writes data.Consumption detection takes Business can judge whether data write completely by tag value;If data write-in is incomplete, examine again after certain time intervals Survey tag value.
Data sharing method in the embodiment of the present invention, the situation that different inter-process datas can be avoided not share can be with The data monitored under mobile terminal in standby state are obtained in real time, are conducive to the data analysis mobile terminal in standby state according to acquisition Under power consumption type.
Figure 11 is the flow chart of information processing method in one embodiment.As shown in figure 11, a kind of information processing method, bag Step S1102 is included to step S1106.Wherein:
S1102, receive mobile terminal puts out screen instruction, and the state information statistics number of times for connecting Wi-Fi is reset.
S1104, if detection connection Wi-Fi state information change, updates the statistics time of connection Wi-Fi status information Number.
S1106, receives the bright screen instruction of mobile terminal, stops detection connection Wi-Fi status information.
Mobile terminal can pass through Wi-Fi and other mobile terminal connection communications.After mobile terminal connects AP, AP can record SSID (Service Set Identifier, service set).After mobile terminal, which is received, puts out screen instruction, record puts out screen Time mScreenOffTime, the connection Wi-Fi that mobile terminal has been counted state information statistics number of times are reset.Mobile terminal It can detect whether connection Wi-Fi status information changes in real time, if detecting connection Wi-Fi state information change, update Connect the statistics number of Wi-Fi status information.When mobile terminal receives bright screen instruction, the bright screen of mobile terminal can record Time mScreenOnTime, and stop detection connection Wi-Fi status information.Specifically, it can pass through in mobile terminal " public int getWi-FiPowerEventCode () " interface supplies power consumption module in mobile terminal to obtain wlan data, sentences Exist under disconnected mobile terminal in standby state abnormal with the presence or absence of mobile terminal power consumption.If mobile terminal, which is received, puts out screen instruction with connecing Time interval is not up to specified duration between receiving bright screen instruction, does not report and connects Wi-Fi's under holding state in mobile terminal Status information, such as put out the screen time not less than 20 seconds, and the connection Wi-Fi counted status information is not reported.
Information processing method in the embodiment of the present invention, Wi-Fi shape is connected by detecting under mobile terminal in standby state The change of state information, can detect the mobile terminal power consumption caused by AP ends are configured, and be conducive to detecting the stand-by power consumption of mobile terminal.
In one embodiment, Wi-Fi status information is connected in above- mentioned information processing method to be included:Group key, dynamic Host configuration DHCP at least one of is re-rented with Wi-Fi connection status.
Connection Wi-Fi status information may include group key, dynamic host configuration protocol DHCP re-rent, Wi-Fi scanning time At least one of number and Wi-Fi connection status.Wi-Fi network can set the group key management cycle in wireless router, that is, be spaced Regular hour updates a group key.Wherein, group key refers to the algorithm of Wi-Fi passwords.Mobile terminal is in connection Wi-Fi When, it is necessary to DHCP (Dynamic Host Configuration Protocol, DHCP) server obtain The IP address of IP (agreement interconnected between Internet Protocol, network) address, mobile terminal and wireless router is signed There is time restriction, mobile terminal needs to re-rent to wireless router to continue to connect Wi-Fi.Under normal circumstances, wireless router The IP address rental period be 1 hour, when the rental period of acquisition for mobile terminal IP address is more than half, mobile terminal can be continuous to wireless router Rent, i.e., when the rental period of the IP address of acquisition for mobile terminal is half an hour, mobile terminal can be re-rented to wireless router.Wi-Fi Connection status refers to whether mobile terminal connects Wi-Fi, when the Wi-Fi signal of wireless router is unstable, mobile terminal meeting Frequently cut off and reconnect Wi-Fi, cause mobile terminal power consumption.
In one embodiment, if step S1104 detections connect Wi-Fi state information change in Figure 11, connection is updated The statistics number of Wi-Fi status information includes:If detecting group key change, the statistics number that group key changes plus 1;On Stating information processing method also includes:If the statistics number for detecting group key change reaches first threshold, in interface of mobile terminal Display reminding.
Under mobile terminal in standby state, mobile terminal, which detects group key in the Wi-Fi currently connected, to be changed, then by group The statistics number mGroupCount of cipher key change adds 1.When mobile terminal receives bright screen instruction, the bright screen time is recorded MSrceenOnTime, shifting can be calculated according to the statistics number for putting out screen time, bright screen time and group key change of mobile terminal Dynamic terminal standby state the following group cipher key change frequency mGroupFreq.If group key change the frequency reach first threshold such as 20 times/ Point, then point out current Wi-Fi group key management excessively frequent in interface of mobile terminal pop-up, remind user's modification Wi-Fi's The group key management cycle.
In one embodiment, if step S1104 detections connect Wi-Fi state information change in Figure 11, connection is updated The statistics number of Wi-Fi status information includes:If detecting DHCP to re-rent, the statistics number that DHCP is re-rented plus 1;Above-mentioned letter Breath processing method also includes:If detecting the statistics number that DHCP re-rents reaches Second Threshold, show and carry in interface of mobile terminal Show.
Under mobile terminal in standby state, mobile terminal, which detects the Wi-Fi currently connected, often initiates a DHCP and re-rents, Then the statistics number mDhcpCount that DHCP is re-rented plus 1.When mobile terminal receives bright screen instruction, the bright screen time is recorded MSrceenOnTime, according to mobile terminal put out the screen time, the statistics number that bright screen time and DHCP are re-rented can calculate movement DHCP re-rents frequency mDhcpFreq under terminal standby state.If DHCP, which re-rents the frequency, reaches such as 40 beats/min of Second Threshold, Interface of mobile terminal pop-up points out the current Wi-Fi DHCP rental periods to set unreasonable, and mobile terminal is re-rented excessively frequently, is reminded and is used The DHCP rental periods that current Wi-Fi is changed at family are set.
In one embodiment, if step S1104 detections connect Wi-Fi state information change in Figure 11, connection is updated The statistics number of Wi-Fi status information includes:If detecting Wi-Fi to disconnect, by the statistics number of Wi-Fi connection status Plus 1;Above- mentioned information processing method also includes:If the statistics number for detecting Wi-Fi connection status reaches the 3rd threshold value, in movement Terminal interface display the prompt box forbids connecting current Wi-Fi.
Under mobile terminal in standby state, when mobile terminal detects Wi-Fi and disconnected, Wi-Fi will be reconnected, and Add 1 in the statistics number mDisconnCount of Wi-Fi connection status.When mobile terminal receives bright screen instruction, bright screen is recorded Time mSrceenOnTime, can according to the statistics number for putting out screen time, bright screen time and Wi-Fi connection status of mobile terminal Calculate Wi-Fi connection status change frequency mDisconnFreq under mobile terminal in standby state.If Wi-Fi connection status changes The frequency reaches such as 35 beats/min of the 3rd threshold value, then points out current Wi-Fi signal unstable in interface of mobile terminal pop-up, it is proposed that weight Open wireless router or connect other Wi-Fi;It is such as mobile whole or mobile terminal is forbidden connecting current Wi-Fi within a certain period of time Forbid connecting current Wi-Fi within a hour in end.
Figure 12 is the flow chart of information processing method in another embodiment.As shown in figure 12, a kind of information processing method, Including step S1202 to step S1214.Wherein:
S1202, puts out screen.Mobile terminal receives to put out to be started to monitor the state for connecting Wi-Fi in mobile terminal after screen instruction Information.
S1204, puts out screen bright screen interval and reaches specified duration.If mobile terminal put out screen with bright screen time interval reach specified when It is long, such as 20 seconds, calculate the state information change frequency under mobile terminal in standby state.
S1206, connection Wi-Fi state information statistics number of times is reset.When detecting mobile terminal bright screen, Wi- will be connected Fi state information statistics number of times is reset.
S1208, connects Wi-Fi state information change.Connection Wi-Fi state information change is detected, connection is updated Wi-Fi state information statistics number of times.
S1210, updates connection Wi-Fi state information statistics number of times, obtains connection Wi-Fi state information change frequency It is secondary.Become according to the status information that the Wi-Fi counted under holding state state information statistics number of times and standby time obtain Wi-Fi Change the frequency.
S1212, the change frequency is more than predetermined threshold value.If the state information change frequency for connecting Wi-Fi is more than the default frequency, Into step S1214.
S1214, the write-in connection Wi-Fi frequent flag bit of state information change.Connect Wi-Fi state information change frequency Numerous flag bit is for identifying Wi-Fi state information change frequently character string.Specifically, group key is shaken hands frequent flag bit It is that the frequent flag bit of 0x100, Wi-Fi disconnection is 0x1000 to re-rent frequent flag bit for 0x10, Wi-Fi.
Figure 13 is the flow chart of information processing method in one embodiment.As shown in figure 13, a kind of information processing method, bag Step S1302 is included to step S1304.Wherein:
S1302, receives scan request under mobile terminal in standby state, detects in the corresponding time interval of scan request Whether scan request except received scan request in addition to is received.
S1304, if not receiving the scan request in addition to scan request has been received, opens mobile terminal Wi-Fi scanning.
After mobile terminal connects Wi-Fi, mobile terminal can move terminal positioning using Wi-Fi.Mobile terminal Each Wi-Fi that scanning is obtained possesses unique MAC (Media Access Control, media access control) address, root The Wi-Fi obtained according to mobile scanning terminal MAC Address and the power of each Wi-Fi signal, can obtain mobile terminal Positional information.When APP (Application, application program) needs to obtain positional information in mobile terminal, it can be sent out to mobile terminal Play scan request.Under mobile terminal in standby state, the scan request that APP is frequently initiated in mobile terminal can cause mobile terminal Power consumption.
Received under mobile terminal in standby state after the scan request that first application program is initiated, starting timer will The scan request delay very first time interval processing that first application is initiated, i.e. mobile terminal detection in very first time interval whether Receive the scan request of the second application program initiation;If if receiving the initiation of the second application program in very first time interval Scan request, then detect the scan request that the initiation of the 3rd application program whether is received in the second time interval;If first Time interval does not receive the scan request of the second application program, opens mobile terminal Wi-Fi scanning so that initiate scan request APP can obtain the positional information of mobile terminal.
Information processing method in the embodiment of the present invention, under mobile terminal in standby state, APP in mobile terminal is sent out in reception The scan request risen, the scan request delay process that APP is initiated, it is possible to reduce frequent by APP under mobile terminal in standby state The mobile terminal power consumption that scanning is caused is initiated, power consumption under mobile terminal in standby state is saved, extends the standby time of mobile terminal.
In one embodiment, above- mentioned information processing method also includes:If detecting current for having received scan request Number reaches designated value, opens mobile terminal Wi-Fi scanning.
If the number that mobile terminal detects the current scan request received exceedes designated value, mobile terminal is opened Wi-Fi is scanned, and the APP for initiating scan request in mobile terminal is obtained the positional information of mobile terminal.By detection The number of the scan request of reception, the scan request number that mobile terminal can be avoided to have received is more, and scan request is for a long time Do not meet with a response, cause the situation that Consumer's Experience is poor.
In one embodiment, above- mentioned information processing method also includes:Scanning is obtained according at the time of receiving scan request Ask waiting time;If detecting scan request waiting time reaches specified duration, mobile terminal Wi-Fi scanning is opened.
Mobile terminal can be recorded at the time of receive scan request, by current time after APP scan request is received The waiting time that scan request is can obtain at the time of receiving scan request is subtracted, if detecting the waiting time of scan request More than specified duration, then mobile terminal Wi-Fi scanning is opened.For example, mobile terminal has currently received sweeping for two application programs Retouch request, mobile terminal is 16 at the time of receiving the scan request that first application program initiate:50:56;Receive second It is 16 at the time of the scan request that individual application program is initiated:51:01.Current time is 16:51:03.Then the first application program is sent out The waiting time of the scan request risen is 7 seconds;The waiting time for the scan request that second application program is initiated is 2 seconds, default Scan request it is specified when a length of 5 seconds, waiting time of scan request that the first application program is initiated reaches specified duration, then opens Open mobile terminal Wi-Fi scanning so that the first application program and the second application program can obtain the positional information of mobile terminal.It is logical The scan request waiting time that detection has been received is spent, the scan request that mobile terminal can be avoided to have received is not rung for a long time Should, cause the situation that Consumer's Experience is poor.
In one embodiment, above- mentioned information processing method also includes:Different scanning asks corresponding time interval for not With value.
The corresponding time interval of scan request received in mobile terminal is different value.Specifically, different scanning is asked Corresponding time interval be different value, i.e. mobile terminal receive the corresponding time interval of the first scan request, second scanning It is without value to ask the corresponding time interval of corresponding time interval ... N scan requests.Specifically, each scan request is corresponding Time interval can gradually increase according to reception order or the corresponding time interval of each scan request can gradually subtract according to reception order The corresponding time interval of small or each scan request is distributed according to the requirement of real-time of each scan request.For example, mobile terminal is received To after the first scan request, detection the very first time interval whether receive the second scan request in 3 seconds;Swept receiving second Retouch after request, whether detection receives the 3rd scan request in 2 seconds in the second time interval.By asking different scanning to set Different time interval, can be to the scan request sweetly disposition that receives, it is to avoid scan request is not rung for a long time in mobile terminal Should, reduce Consumer's Experience.
In one embodiment, above- mentioned information processing method also includes:Different scanning asks corresponding time interval to be phase With value.
The corresponding time interval of scan request that mobile terminal is received is that identical value, i.e. mobile terminal are receiving scanning After request, start timer and postpone identical time-triggered protocol.For example, mobile terminal is after the first scan request is received, detection The second scan request whether is received in the very first time 5 milliseconds of interval;If receiving the second scan request, detect second The 3rd scan request whether is received in 5 milliseconds of time interval, by that analogy.
Figure 14 is the flow chart of information processing method in another embodiment.As shown in figure 14, a kind of information processing method, Including:
S1402, receives the first scan request.Receive after the first scan request, start timer delay stand-by period T1.
S1404, delay waits T1.
S1406, if receive the second scan request.Whether detection receives the second scanning in T1 time intervals please Ask;If so, into step S1408;If it is not, into step S1410.
S1408, delay waits T2.After the second scan request is received, start timer-delay and wait T2.
S1410, opens scanning.Mobile terminal Wi-Fi scanning is opened, the scan request to reception makes feedback.
S1412, if receive the 3rd scan request.Whether detection receives the 3rd scanning in T2 time intervals please Ask;If so, into step S1414;If it is not, into step S1410.
S1414, delay waits T3.Detection receives the 3rd scan request in T2 time intervals, starts timer delay Stand-by period T3.
By that analogy, whether detection receives N scan requests in TN time intervals.
S1416, if receive N scan requests.If so, into step S1418;If it is not, into step S1410.
S1418, delay waits T (N+1).
Figure 15 is the flow chart of information processing method in one embodiment.As shown in figure 15, a kind of information processing method, bag Step S1502 is included to step S1506, wherein:
The Wi-Fi scan request number of times of application program under screen instruction, statistics mobile terminal in standby state is put out in S1502, reception;
Whether S1504, the Wi-Fi scan requests number of times of detection application program reaches designated value;
S1506, it is corresponding according to designated value if the Wi-Fi scan request number of times for detecting application program reaches designated value Mode of operation performs corresponding operation to application program.
Wireless aps possess unique MAC Address, and after mobile terminal opens Wi-Fi scannings, mobile terminal can scan surrounding Wireless aps signal, obtain the MAC Address that broadcasts out of wireless aps, and by the MAC Address upload server of the wireless aps of acquisition. Server can calculate the geographical location information of mobile terminal according to the MAC Address of wireless aps signal strength and wireless aps, and will The positional information for calculating the mobile terminal obtained returns to mobile terminal.During the use of mobile terminal, APP in mobile terminal The positional information of mobile terminal can be applied for obtaining, that is, initiate Wi-Fi scan requests.Wherein, information processing needs to travel through 2.4G13 Individual channel, each channel is stationed 40ms-60ms, if mobile terminal supports double frequency WI-FI, i.e. 5GWI-FI, then needs to scan 36 channels To 156 channels, mobile terminal power consumption is caused to increase.
When acquisition for mobile terminal is to when putting out screen instruction, the Wi- that application program is initiated under mobile terminal in standby state is recorded Fi scan request number of times, if the Wi-Fi scan request number of times for detecting application program initiation reaches designated value, judges application program The Wi-Fi scan request number of times of initiation is excessively frequent, and behaviour corresponding with designated value is performed to the application program for initiating scan request Make.
Information processing method in the embodiment of the present invention, detects that the Wi-Fi of application program is swept under mobile terminal in standby state When retouching request and reaching that the Wi-Fi scan requests of designated value, i.e. application program are excessively frequent, corresponding behaviour is performed to application program Make, it is to avoid the mobile terminal power consumption increase that the Wi-Fi scan requests of application program are excessively frequently caused.In mobile terminal standby shape Under state, the real-time demand of application program is relatively low.To scan request, more frequently application program performs corresponding operation, that is, reduces Mobile terminal stand-by power consumption, by not influenceing Consumer's Experience.
In one embodiment, if designated value is first threshold, the Wi-Fi scan request number of times for detecting application program reaches To first threshold, in interface of mobile terminal pop-up prompting.If designated value is Second Threshold, the Wi-Fi for detecting application program is swept Retouch request number of times and reach Second Threshold, then stop receiving the scan request of application program.If designated value is the 3rd threshold value, detect The Wi-Fi scan request number of times of application program reaches the 3rd threshold value, and application program is terminated and run.
When the scan request number of times of application program reaches different designated values, the operation that mobile terminal is performed to application program Instruction is different.Wherein, Second Threshold is more than first threshold, the 3rd threshold value and is more than Second Threshold.For example, in mobile terminal standby shape Under state, the scan request number of times for detecting application program is 10 times, reaches first threshold 10, in interface of mobile terminal pop-up prompting User's application program power consumption is larger;The scan request number of times for detecting application program is 15 times, reaches Second Threshold 15, then moves Dynamic terminal no longer receives the scan request of application program initiation within a certain period of time, and no longer being received such as within a hour to answer The scan request initiated with program;The scan request number of times for detecting application program is 20 times, reaches the 3rd threshold value 20, then moves Terminal directly terminates application program operation.
In one embodiment, mobile terminal can also calculate the Wi-Fi scan request frequencys of application program, according to applying journey Whether the Wi-Fi scan requests frequency of sequence, which reaches, is specified to perform application program corresponding operation.Wherein, application program The Wi-Fi scan requests frequency can be obtained according to the Wi-Fi scan requests number of times and current idle duration of application program.
In one embodiment, above- mentioned information processing method also includes:The bright screen instruction of mobile terminal is detected, will be applied The Wi-Fi scan requests number of times of program is reset.
When mobile terminal receives bright screen instruction, by the Wi- of the application program recorded under mobile terminal in standby state Fi scan requests number of times is reset.So that when mobile terminal receives and puts out screen instruction into holding state, record applies journey again The Wi-Fi scan request number of times of sequence.
Figure 16 is the flow chart of information processing method in another embodiment.As shown in figure 16, a kind of information processing method, It is characterised in that it includes step S1602 to step S1604.Wherein:
S1602, the application program under screen instruction, record mobile terminal in standby state of putting out for receiving mobile terminal holds wake-up lock Duration and application triggers wake-up alarm number of times.
S1604, receives the bright screen instruction of mobile terminal, is touched according to the duration and application program that application program holds wake-up lock The number of times for sending out wake-up alarm obtains the stand-by power consumption information of application program.
A kind of mechanism that lock is android system is waken up, when in system using wake-up lock is held, system cannot be introduced into not Dormancy state, after wake-up lock all in system is all released, system could enter resting state.Wake-up alarm is also referred to as RTC (Real Time Clock, real-time alarm clock) alarm clock, wake-up alarm is individually powered on hardware circuit, in mobile terminal standby shape Under state, wake-up alarm can be by system wake-up.It can all increase mobile whole using wake-up lock and wake-up alarm wake-up mobile terminal is held The stand-by power consumption at end.
When receive mobile terminal put out screen instruction when, mobile terminal detects and records whether each application program holds wake-up Lock, at the time of application program wakes up lock, application program release is at the time of wake up lock and application program corresponding triggering The number of times of wake-up alarm.Wherein, in android system, wake up lock and managed by PowerManagerService, At the time of there be at the time of application program wake-up lock record, application program release wakes up lock in PowerManagerService, Waken up according to application program at the time of lock and application program is can obtain at the time of discharging and wake up lock and hold the duration for waking up lock. Wake-up alarm is managed by AlarmManagerService, and record has wake-up alarm in AlarmManagerService Relevant information, at the time of such as wake-up alarm is triggered, triggers application program identification of wake-up alarm etc..It is noisy according to the wake-up of record The relevant information of clock can obtain the number of times of each application triggers wake-up alarm in the standby state.
When the bright screen for receiving mobile terminal is instructed, wake-up lock is held according to application program under mobile terminal in standby state Duration and the number of times of application triggers wake-up alarm can calculate the stand-by power consumption information for obtaining application program, and according to application The stand-by power consumption information of program performs corresponding operation to application program.
In one embodiment, the stand-by power consumption information of application program includes:The duration that application program holds wake-up lock is accounted for Ratio, the number of times of application triggers wake-up alarm that all application programs hold the total duration for waking up lock account for all application programs Trigger the ratio of the total degree of wake-up alarm, hold the duration and application triggers wake-up alarm for waking up lock according to application program Number of times obtain application program power consumption index.
Hold the duration for waking up lock and each application according to each application program under mobile terminal in standby state of record Program triggering wake-up alarm number of times can calculate application program hold wake up lock total duration and application triggers wake up lock Total degree, then calculate to obtain application program and hold and wake up the duration of lock and account for the ratio of total duration, application triggers wake up noisy The number of times of clock accounts for the ratio of total degree.Wherein, the duration and application triggers wake-up alarm for waking up lock are held to application program Number of times can set weight factor, application program is held and wakes up the duration and the number of times of application triggers wake-up alarm of lock and adds Power calculates the power consumption index for obtaining application program.
In one embodiment, above- mentioned information processing method also includes:Should according to the stand-by power consumption information of application program Sorted and shown in interface of mobile terminal with the corresponding application program identification of program.
Application program can be sorted according to the stand-by power consumption information of the application program of acquisition, for example, being held according to application program There are the ratio for waking up the duration locked, the ratio according to the number of times of application triggers wake-up alarm, the power consumption index of application program Application program is ranked up, and ranking results are shown in interface of mobile terminal.Wherein, can be according to single value to application program It is ranked up, can also being ranked up to application program according to multiple values.For example, according to application program hold wake up lock when Long ratio is ranked up to application program;Application program is carried out according to the ratio of the number of times of application triggers wake-up alarm Sequence;The ratio for waking up the duration locked, the ratio of the number of times of application triggers wake-up alarm are held according to application program and answered Application program is ranked up with the weighted average of the power consumption index of program.Under normal circumstances, by stand-by power consumption from high to low Application program is ranked up.
In one embodiment, the duration and application triggers wake-up alarms that wake up lock is being held according to application program Number of times is obtained before the stand-by power consumption information of application program, and above- mentioned information processing method also includes:Detect mobile terminal standby shape Whether the current value consumed under state reaches designated value;If so, then holding the duration and application program for waking up lock according to application program The number of times for triggering wake-up alarm obtains the stand-by power consumption information of application program.
Before the stand-by power consumption information of application program is obtained, the current value consumed under mobile terminal in standby state can determine that Whether designated value is reached;If the current value consumed under mobile terminal in standby state reaches designated value, mobile terminal standby is judged Power consumption is abnormal, obtains the stand-by power consumption information of application program under mobile terminal in standby state.By judging mobile terminal standby shape Current value under state, obtains the stand-by power consumption information of application program again when standby current is abnormal, and the information of acquisition is more accurate.
In one embodiment, the duration and application triggers wake-up alarms that wake up lock is being held according to application program Number of times is obtained before the stand-by power consumption information of application program, and above- mentioned information processing method also includes:Detect the standby of mobile terminal Whether duration reaches preset duration;If so, the duration and application triggers of then holding wake-up lock according to application program wake up noisy The number of times of clock obtains the stand-by power consumption information of application program.
Before the stand-by power consumption of application program is obtained, when can determine that whether the standby time of mobile terminal reaches default It is long, stand-by power consumption information in application program is obtained when the standby time of mobile terminal reaches preset duration, answering for acquisition can be made It is more accurate with the stand-by power consumption information of program.
Figure 17 is the flow chart of information processing method in another embodiment.As shown in figure 17, a kind of information processing method, Including step S1702 to step S1706.Wherein:
S1702, obtains application program and holds the duration and application triggers for waking up lock under mobile terminal in standby state The number of times of wake-up alarm;
S1704, application program is obtained according to the number of times for holding the duration for waking up lock and application triggers wake-up alarm Power consumption index.
S1706, if the power consumption index for detecting application program reaches preset value, according to operational order corresponding with preset value Corresponding operation is performed to application program.
The wake-up lock and the wake-up alarm of application triggers that mobile terminal can be held to application program are monitored.Work as inspection When measuring application program wake-up lock, release wake-up lock, application triggers wake-up alarm, it can be remembered accordingly in real time Record.Wherein, in android system, wake up lock and managed by PowerManagerService, in PowerManagerService At the time of middle record has at the time of application program wake-up lock, application program release wakes up lock, called out according to application program Wake up at the time of lock and discharge and the duration that application program holds wake-up lock is can obtain at the time of waking up lock.Wake-up alarm be all by AlarmManagerService is managed, and record has the relevant information of wake-up alarm in AlarmManagerService, such as calls out At the time of awake alarm clock is triggered, application program identification of wake-up alarm etc. is triggered.According to the relevant information of the wake-up alarm of record The number of times of each application triggers wake-up alarm in the standby state can be obtained.Held in the standby state according to application program The number of times of the duration and application triggers wake-up alarm that wake up lock can calculate the power consumption index of application program.When detecting application The power consumption index of program reaches preset value, then the value for the power consumption index that can be reached according to application program is performed accordingly to application program Operation.
In the wake-up alarm that records application program is triggered, the only wake-up of record and application program strong correlation is locked and wakes up noisy Clock.Specifically, can be judged according to the bag name of application program application triggers wake-up alarm whether strong correlation.For example, wechat The entitled com.tencent.mm of bag, first character section com represent business;Second field represents exabyte, and such as tencent is Tencent;3rd field mm represents this application of wechat, and first three field of the bag name of application program is identical to represent same Using.Application program can all carry the bag name information of application program when application wakes up lock and triggering wake-up alarm, if bag name First three field is identical, then is determined as same application program, is recorded as and the application program strong correlation.
In one embodiment, duration and the application for waking up lock are held under mobile terminal in standby state according to application program The power consumption index that the number of times of program triggering wake-up alarm calculates application program includes:Receive mobile terminal puts out screen instruction, record At the time of application program wakes up lock, release wakes up at the time of lock and application triggers wake up the number of times of lock;Receive and move The bright screen instruction of dynamic terminal, wakes up at the time of lock according to application program, obtains application program at the time of release wakes up lock and hold There is the duration for waking up and locking;The number of times calculating for holding the duration for waking up lock and application triggers wake-up alarm according to application program should With the power consumption index of program, power consumption index holds time of the duration and application triggers wake-up alarm that wake up lock with application program Number positive correlation.
In one embodiment, duration and the application for waking up lock are held under mobile terminal in standby state according to application program The power consumption index that the number of times of program triggering wake-up alarm calculates application program includes:The factor, default is locked according to default wake up The wake-up alarm factor, application program hold the duration for waking up lock and the number of times of application triggers wake-up alarm calculates application program Power consumption index.
The power consumption index w of application program is held with default lock factor-alpha, default wake-up alarm factor-beta, the application program of waking up It is w=α * wl+ β * wa to have the relation between duration wl, the number of times wa of application triggers wake-up alarm for waking up and locking.Wherein, no Lock factor-alpha, default wake-up alarm factor-beta difference are waken up with default in mobile terminal.For example, in the terminal α= 0.3, β=0.7, under mobile terminal in standby state, application program, which is held, wakes up the time of lock for 2345ms, application triggers The number of times of wake-up alarm is 23 times, then the power consumption factor w=0.3*2345+0.7*23=719.6 of application program.
In one embodiment, the default lock factor, the default wake-up alarm factor of waking up is obtained by following steps:According to Mobile terminal is waken up the power consumption that time per electricity and mobile terminal are waken up under state and calculates default wake-up lock The factor, the default wake-up alarm factor.
Being waken up power consumption b that time per electricity a and mobile terminal under state be waken up according to mobile terminal can Calculate default wake up and lock factor-alpha, default wake-up alarm factor-beta.Wherein, α=a/ (a+b), β=b/ (a+b).According to movement The test data of terminal in the standby state can obtain the wake-up lock factor and the wake-up alarm factor.
In one embodiment, wrapped according to operational order corresponding with preset value operation corresponding to application program execution Include:If preset value is first threshold, in interface of mobile terminal pop-up prompting;If preset value is Second Threshold, forbid application program Operation.
If the power consumption index for detecting application program reaches first threshold, in interface of mobile terminal pop-up prompting user's application The power consumption index of program is too high;When the power consumption index of application program reaches Second Threshold, then the application program is forbidden to run.Its In, Second Threshold is more than first threshold.In another embodiment, a designated value is set to the power consumption index of application program, When the power consumption index for detecting application program reaches designated value, then point out in interface of mobile terminal pop-up or forbid application program to transport OK.In other embodiments, multiple threshold values also can be set, when the power consumption index of application program reaches different threshold values, to application Program performs different operational orders.
In one embodiment, white list can be set to application program, mobile terminal will not monitor white name under holding state The power consumption index of application program in single.When application program is carrying out the operations such as backstage download, backstage broadcasting audio, it can avoid Power consumption index is too high under application program holding state is terminated operation.
Figure 18 is the structured flowchart of information processor in one embodiment.As shown in figure 18, a kind of information processor, Including the determination module 1804 of detection module 1802 and first.Wherein:
Detection module 1802, if for detecting the first current value and the second current value of mobile terminal in the standby state Difference be more than first threshold, whether the difference of detection the first current value and mobile terminal the 3rd current value in the standby state is more than Second Threshold;Wherein, the first current value is the average current value of mobile terminal actual consumption in the standby state, the second current value For the reference current value of mobile terminal in the standby state, the 3rd current value is the scene electric current of mobile terminal in the standby state Value.
First determination module 1804, if the difference for the first current value and the 3rd current value is more than Second Threshold, according to shifting Dynamic terminal in the standby state the wake-up times of wake source, mobile terminal the length of one's sleep judge mobile terminal power consumption type.
In one embodiment, the first determination module 1804 be additionally operable to detect wake source wake-up times whether reach it is specified Value;If so, judging the power consumption type of mobile terminal according to the most wake source of wake-up times;If it is not, detection the first current value and Whether the length of one's sleep of mobile terminal meets preset rules;If meeting preset rules, the power consumption type of record mobile terminal is hard Part exception power consumption.
In one embodiment, the first determination module 1804 is additionally operable to obtain each son in the most wake source of wake-up times and called out The wake-up times in source of waking up and the application program of each sub- wake source of wake-up;Called out according to the wake-up times of each sub- wake source and each son of wake-up The application program in awake source judges the power consumption type of mobile terminal.
Figure 19 is the structured flowchart of information processor in another embodiment, as shown in figure 19, a kind of information processing apparatus Put, including detection module 1902, the first determination module 1904, the second determination module 1906 and acquisition module 1908.Wherein detect The determination module 1904 of module 1902 and first functions of modules corresponding with Figure 18 is identical.
Second determination module 1906, if being less than Second Threshold for the difference for detecting the first current value and the 3rd current value, The power consumption type of mobile terminal is judged according to the 3rd current value.
Acquisition module 1908, the standby time for detecting mobile terminal is more than preset duration, obtains the first current value With the second current value.
The division of modules is only used for for example, in other embodiments, will can believe in above- mentioned information processing unit Breath processing unit is divided into different modules as required, to complete all or part of function of above- mentioned information processing unit.
Figure 20 is the structured flowchart of information processor in one embodiment.As shown in figure 20, a kind of information processor, Including receiving module 2002, update module 2004 and stopping detection module 2006.Wherein:
Receiving module 2002, the screen that puts out for receiving mobile terminal is instructed, and will connect Wireless Fidelity Wi-Fi status information Statistics number is reset;
Update module 2004, if the state information change for detecting connection Wi-Fi, updates connection Wi-Fi state letter The statistics number of breath;
Stop detection module 2006, the bright screen for receiving mobile terminal is instructed, stop detection connection Wi-Fi state letter Breath.
In one embodiment, connection Wi-Fi status information includes:Group key, dynamic host configuration protocol DHCP continue At least one of rent and Wi-Fi connection status.
Figure 21 is the structured flowchart of information processor in another embodiment.As shown in figure 21, a kind of information processing apparatus Put, including receiving module 2102, update module 2104, stopping detection module 2106, the first reminding module 2108, second prompting mould The reminding module 2112 of block 2110 and the 3rd.Wherein, receiving module 2102, update module 2104 and stopping detection module 2106 and figure Corresponding functions of modules is identical in 20.
If update module 2104 is additionally operable to detect group key change, the statistics number that group key changes plus 1;First carries Show module 2108, if reaching first threshold for the statistics number for detecting group key change, show and carry in interface of mobile terminal Show.
If update module 2104 is additionally operable to detect DHCP and re-rented, the statistics number that DHCP is re-rented plus 1;Second prompting mould Block 2110, if Second Threshold is reached for detecting the statistics number that DHCP is re-rented, in interface of mobile terminal display reminding.
If update module 2104 is additionally operable to detect Wi-Fi and disconnected, the statistics number of Wi-Fi connection status is added 1; 3rd reminding module 2112, if the 3rd threshold value is reached for detecting the statistics number of Wi-Fi connection status, in mobile terminal circle Face display the prompt box forbids connecting current Wi-Fi.
The division of modules is only used for for example, in other embodiments, will can believe in above- mentioned information processing unit Breath processing unit is divided into different modules as required, to complete all or part of function of above- mentioned information processing unit.
Figure 22 is the structured flowchart of information processor in one embodiment.As shown in figure 22, a kind of information processor, Including detection module 2202, opening module 2204.Wherein:
Detection module 2202, for receiving scan request under mobile terminal in standby state, detection is in scan request correspondence Time interval in whether receive the scan request in addition to scan request has been received.
Opening module 2204, if for not receiving the scan request in addition to scan request has been received, opening mobile terminal Wireless Fidelity Wi-Fi is scanned.
In one embodiment, if opening module 2204 is additionally operable to detect the current number for having received scan request and reached Designated value, opens mobile terminal Wi-Fi scanning.
In one embodiment, opening module 2204 is additionally operable to obtain scan request etc. according at the time of receiving scan request Treat duration;If detecting scan request waiting time reaches specified duration, mobile terminal Wi-Fi scanning is opened.
In one embodiment, different scanning asks corresponding time interval to be different value.
In one embodiment, different scanning asks corresponding time interval to be identical value.
The division of modules is only used for for example, in other embodiments, will can believe in above- mentioned information processing unit Breath processing unit is divided into different modules as required, to complete all or part of function of above- mentioned information processing unit.
Figure 23 is the structured flowchart of information processor in one embodiment.As shown in figure 23, a kind of information processor, Including performing module 2302, detection module 2304, performing module 2306 and dump block 2308.Wherein:
Receiving module 2302, screen instruction is put out for receiving, and the Wi-Fi of application program is swept under statistics mobile terminal in standby state Retouch request number of times;
Detection module 2304, for detecting whether the Wi-Fi scan requests number of times of application program reaches designated value;
Performing module 2306, if designated value is reached for the Wi-Fi scan request number of times for detecting application program, according to finger The corresponding mode of operation of definite value performs corresponding operation to application program.
In one embodiment, if designated value is first threshold, the Wi-Fi scan request number of times for detecting application program reaches To first threshold, in interface of mobile terminal pop-up prompting.
In one embodiment, if designated value is Second Threshold, the Wi-Fi scan request number of times for detecting application program reaches To Second Threshold, then stop receiving the scan request of application program.
In one embodiment, if designated value is the 3rd threshold value, the Wi-Fi scan request number of times for detecting application program reaches To the 3rd threshold value, application program is terminated and run.
Dump block 2308, the bright screen for detecting mobile terminal is instructed, by the Wi-Fi scan requests time of application program Number is reset.
The division of modules is only used for for example, in other embodiments, will can believe in above- mentioned information processing unit Breath processing unit is divided into different modules as required, to complete all or part of function of above- mentioned information processing unit.
Figure 24 is the structured flowchart of information processor in one embodiment.As shown in figure 24, a kind of information processor, Including logging modle 2402 and acquisition module 2404.Wherein:
Logging modle 2402, journey is applied for receiving putting out for mobile terminal under screen instruction, record mobile terminal in standby state Sequence holds the number of times of the duration and application triggers wake-up alarm that wake up lock;
Acquisition module 2404, the bright screen for receiving mobile terminal is instructed, and the duration for waking up lock is held according to application program The stand-by power consumption information of application program is obtained with the number of times of application triggers wake-up alarm.
In one embodiment, the stand-by power consumption information of application program includes:The duration that application program holds wake-up lock is accounted for Ratio, the number of times of application triggers wake-up alarm that all application programs hold the total duration for waking up lock account for all application programs Trigger the ratio of the total degree of wake-up alarm, hold the duration and application triggers wake-up alarm for waking up lock according to application program Number of times obtain application program power consumption index.
Figure 25 is the structured flowchart of information processor in another embodiment.As shown in figure 25, a kind of information processing apparatus Put, including logging modle 2502, acquisition module 2504, display module 2506, the detection module of first detection module 2508 and second 2510.Wherein logging modle 2502 and acquisition module 2504 functions of modules corresponding with Figure 24 is identical.
Display module 2506, for the stand-by power consumption information according to application program by the corresponding application program mark of application program Know to sort in interface of mobile terminal and show.
First detection module 2508, it is specified whether the current value consumed for detecting under mobile terminal in standby state reaches Value;If so, then acquisition module is used for time for holding the duration and application triggers wake-up alarm that wake up lock according to application program Number obtains the stand-by power consumption information of application program.
Second detection module 2510, for detecting whether the standby time of mobile terminal reaches preset duration;If so, then obtaining Modulus block is used to hold the duration for waking up lock according to application program and journey is applied in the number of times acquisition of application triggers wake-up alarm The stand-by power consumption information of sequence.
The division of modules is only used for for example, in other embodiments, will can believe in above- mentioned information processing unit Breath processing unit is divided into different modules as required, to complete all or part of function of above- mentioned information processing unit.
Figure 26 is the structured flowchart of information processor in another embodiment.As shown in figure 26, a kind of information processing apparatus Put, including acquisition module 2602, computing module 2604 and operation module 2606.Wherein:
Acquisition module 2602, holds the duration of wake-up lock and answers under mobile terminal in standby state for obtaining application program The number of times of wake-up alarm is triggered with program;
Computing module 2604, for being obtained according to the number of times for holding the duration for waking up lock and application triggers wake-up alarm The power consumption index of application program;
Operation module 2606, if reaching preset value for the power consumption index for detecting application program, according to preset value pair The operational order answered performs corresponding operation to application program.
In one embodiment, computing module 2604 be additionally operable to receive mobile terminal put out screen instruction, records application program At the time of application wake-up is locked, discharge the number of times that at the time of waking up lock and application triggers wake-up is locked;Receive mobile terminal Bright screen instruct, according to application program wake up lock at the time of, release wake up lock at the time of obtain application program hold wake-up lock Duration;The number of times for holding the duration and application triggers wake-up alarm that wake up lock according to application program calculates application program Power consumption index, power consumption index holds the number of times positive of the duration and application triggers wake-up alarm that wake up lock with application program Close.
In one embodiment, computing module 2604 is additionally operable to:The factor, default wake-up alarm are locked according to default wake up The power consumption that the factor, application program hold the number of times calculating application program of the duration for waking up lock and application triggers wake-up alarm refers to Number.
In one embodiment, the default lock factor, the default wake-up alarm factor of waking up is obtained by following steps:According to Mobile terminal is waken up the power consumption that time per electricity and mobile terminal are waken up under state and calculates default wake-up lock The factor, the default wake-up alarm factor.
In one embodiment, operation module 2606 is additionally operable to:If preset value is first threshold, in interface of mobile terminal bullet Window is pointed out;If preset value is Second Threshold, application program is forbidden to run.
The division of modules is only used for for example, in other embodiments, will can believe in above- mentioned information processing unit Breath processing unit is divided into different modules as required, to complete all or part of function of above- mentioned information processing unit.
Figure 27 is the block diagram of the part-structure of the mobile phone related to mobile terminal provided in an embodiment of the present invention.With reference to figure 27, mobile phone includes:Radio frequency (Radio Frequency, RF) circuit 2710, memory 2720, input block 2730, display unit 2740th, the part such as sensor 2750, voicefrequency circuit 2760, wireless fidelity module 2770, processor 2780 and power supply 2790. It will be understood by those skilled in the art that the handset structure shown in Figure 27 does not constitute the restriction to mobile phone, it can include than diagram More or less parts, either combine some parts or different parts arrangement.
Wherein, RF circuits 2710 can be used for receive and send messages or communication process in, the reception and transmission of signal can be by base stations After downlink information is received, handled to processor 2780;Up data can also be sent to base station.Generally, RF circuits include But be not limited to antenna, at least one amplifier, transceiver, coupler, low-noise amplifier (Low Noise Amplifier, LNA), duplexer etc..In addition, RF circuits 2710 can also be communicated by radio communication with network and other equipment.It is above-mentioned wireless Communication can use any communication standard or agreement, including but not limited to global system for mobile communications (Global System of Mobile Communication, GSM), general packet radio service (General Packet Radio Service, GPRS), CDMA (Code Division Multiple Access, CDMA), WCDMA (Wideband Code Division Multiple Access, WCDMA), it is Long Term Evolution (Long Term Evolution, LTE), Email, short Messenger service (Short Messaging Service, SMS) etc..
Memory 2720 can be used for storage software program and module, and processor 2780 is stored in memory by operation 2720 software program and module, so as to perform various function application and the data processing of mobile phone.Memory 2720 can be led To include program storage area and data storage area, wherein, program storage area can be needed for storage program area, at least one function Application program (application program of such as sound-playing function, application program of image player function etc.) etc.;Data storage area can Storage uses created data (such as voice data, address list etc.) etc. according to mobile phone.In addition, memory 2720 can be wrapped High-speed random access memory is included, nonvolatile memory, for example, at least one disk memory, flash memories can also be included Part or other volatile solid-state parts.
Input block 2730 can be used for the numeral or character information for receiving input, and generation and the user of mobile phone 2700 to set Put and the input of key signals that function control is relevant.Specifically, input block 2730 may include contact panel 2731 and other Input equipment 2732.Contact panel 2731, alternatively referred to as touch-screen, collect touch operation (ratio of the user on or near it Such as user is using finger, any suitable object of stylus or annex on contact panel 2731 or near contact panel 2731 Operation), and corresponding attachment means are driven according to formula set in advance.In one embodiment, contact panel 2731 can Including both touch detecting apparatus and touch controller.Wherein, touch detecting apparatus detects the touch orientation of user, and examines The signal that touch operation is brought is surveyed, touch controller is transmitted a signal to;Touch controller is received from touch detecting apparatus to be touched Touch information, and be converted into contact coordinate, then give processor 2780, and the order sent of reception processing device 2780 and can add To perform.Furthermore, it is possible to realize contact panel using polytypes such as resistance-type, condenser type, infrared ray and surface acoustic waves 2731.Except contact panel 2731, input block 2730 can also include other input equipments 2732.Specifically, other are inputted Equipment 2732 can include but is not limited in physical keyboard, function key (such as volume control button, switch key etc.) etc. one Plant or a variety of.
Display unit 2740 can be used for each of the information that is inputted by user of display or the information for being supplied to user and mobile phone Plant menu.Display unit 2740 may include display panel 2741.In one embodiment, liquid crystal display can be used (Liquid Crystal Display, LCD), Organic Light Emitting Diode (Organic Light-Emitting Diode, ) etc. OLED form configures display panel 2741.In one embodiment, contact panel 2731 can cover display panel 2741, After contact panel 2731 detects the touch operation on or near it, send processor 2780 to determine touch event Type, corresponding visual output is provided with preprocessor 2780 according to the type of touch event on display panel 2741.Although In figure 27, contact panel 2731 and display panel 2741 are the input and input that mobile phone is realized as two independent parts Function, but in some embodiments it is possible to by contact panel 2731 and the input that is integrated and realizing mobile phone of display panel 2741 And output function.
Mobile phone 2700 may also include at least one sensor 2750, such as optical sensor, motion sensor and other biographies Sensor.Specifically, optical sensor may include ambient light sensor and proximity transducer, wherein, ambient light sensor can be according to ring The light and shade of environmental light adjusts the brightness of display panel 2741, and proximity transducer can close display when mobile phone is moved in one's ear Panel 2741 and/or backlight.Motion sensor may include acceleration transducer, and all directions are can detect by acceleration transducer The size of upper acceleration, can detect that size and the direction of gravity when static, the application available for identification mobile phone posture is (such as horizontal Portrait layout switches), Vibration identification correlation function (such as pedometer, tap) etc.;In addition, mobile phone can also configure gyroscope, barometer, Other sensors such as hygrometer, thermometer, infrared ray sensor etc..
Voicefrequency circuit 2760, loudspeaker 2761 and microphone 2762 can provide the COBBAIF between user and mobile phone.Sound Frequency circuit 2760 voice data received can be changed after electric signal, loudspeaker 2761 is transferred to, by 2761 turns of loudspeaker It is changed to voice signal output;On the other hand, the voice signal of collection is converted to electric signal by microphone 2762, by voicefrequency circuit 2760 receive after be converted to voice data, then after voice data output processor 2780 is handled, can be sent out through RF circuits 2710 Another mobile phone is given, or voice data is exported to memory 2720 so as to subsequent treatment.
Wi-Fi belongs to short range wireless transmission technology, and mobile phone can help user's transceiver electronicses by Wi-Fi module 2770 Mail, browse webpage and access streaming video etc., it has provided the user wireless broadband internet and accessed.Although Figure 27 is shown Wi-Fi module 2770, but it is understood that, it is simultaneously not belonging to must be configured into for mobile phone 2700, can as needed and Omit.
Processor 2780 is the control centre of mobile phone, using various interfaces and the various pieces of connection whole mobile phone, By operation or perform and be stored in software program and/or module in memory 2720, and call and be stored in memory 2720 Interior data, perform the various functions and processing data of mobile phone, so as to carry out integral monitoring to mobile phone.In one embodiment, Processor 2780 may include one or more processing units.In one embodiment, processor 2780 can integrated application processor And modem processor, wherein, application processor mainly handles operating system, user interface and application program etc.;Modulatedemodulate Processor is adjusted mainly to handle radio communication.It is understood that above-mentioned modem processor can not also be integrated into processor In 2780.
Mobile phone 2700 also includes the power supply 2790 (such as battery) powered to all parts, it is preferred that power supply can pass through Power-supply management system and processor 2780 are logically contiguous, so as to realize management charging, electric discharge, Yi Jigong by power-supply management system The functions such as consumption management.
In one embodiment, mobile phone 2700 can also include camera, bluetooth module etc..
In one embodiment, it can be realized at a kind of information during 2780 configuration processor of processor included by mobile terminal Reason method, including:
(1) if the difference for detecting mobile terminal the first current value in the standby state and the second current value is more than the first threshold Whether value, the difference of the 3rd current value of detection the first current value and mobile terminal in the standby state is more than Second Threshold.Wherein, First current value is the average current value of mobile terminal actual consumption in the standby state, and the second current value is that mobile terminal is being treated Reference current value under machine state, the 3rd current value is the scene current value of mobile terminal in the standby state.
Mobile terminal in the standby state when, can detect whether mobile terminal current idle state meets preparatory condition;If Meet preparatory condition, then judge whether the difference of the first current value and the second current value under mobile terminal in standby state is more than the first threshold Value.Wherein, preparatory condition may include:Whether the standby time of mobile terminal reaches that preset duration, mobile terminal in standby state are No is default holding state etc..Default holding state may include:Background music is played, backstage is downloaded, mobile terminal is opened Modem Log etc..If mobile terminal in standby state is default holding state, current consumption value is larger in mobile terminal, without Current consumption value in mobile terminal is monitored, then does not obtain the first current value and the second current value of mobile terminal.Judge mobile whole Hold whether holding state is that default holding state may include:If detect has audio output in mobile terminal in standby state, Interval, which specifies to detect again after the time, audio output in mobile terminal, then judges mobile terminal current idle state as backstage Music;If detecting Wi-Fi (Wireless-Fidelity, Wireless Fidelity) flow in mobile terminal in standby state to surpass 30M/h (MByte/hour, million/hour) is crossed, or data network flux then judges mobile terminal current idle shape more than 20M/h State is downloaded for backstage.
The total current value that first current value can be consumed in the stand-by time and stand-by time according to mobile terminal is obtained;Second The corresponding current value of program function and program function that current value can in the standby state be opened according to mobile terminal is obtained.Move The corresponding current value of program function under holding state is prestored in dynamic terminal, according to the application opened under mobile terminal in standby state Program function can the corresponding current value of search program function, can calculate the second electric current further according to the corresponding current value of program function Value.Wherein, the corresponding current value of function of application is the service data of mobile terminal hardware state, can be by application program work( The corresponding current value write-in existing power consumption type file of mobile terminal of energy, such as:Vendor/oppo/overlay/ item designations/ In frameworks/base/core/res/res/xml/power_profile.xml files.
In different mobile terminal hardware, system, version, the difference of voltameter can cause function of application correspondence to electricity Flow valuve difference, therefore, the corresponding current value of different mobile terminal Program function are different.According to the corresponding current value of program function The second current value calculated carries float value.Influenceing the factor of the float value of the second current value includes:Standby time T, the second electricity Flow valuve I, battery capacity C and voltameter error amount n%.The float value Δ T of second current value and the functional relation of the above-mentioned factor For:
For example, battery capacity C is 3000mAh (milli-Ampere-hour, MAH), standby time T is 5 hours, Second current value I is 12mA, and voltameter error amount is 1%, then the float value of the second current value is When the difference for detecting the current value of mobile terminal first and the second current value is more than float value, that is, judge the current value of mobile terminal first And the difference of the second current value is more than first threshold, mobile terminal the 3rd current value in the standby state is obtained, the first electric current is detected Whether value and the difference of the 3rd current value are more than Second Threshold.For example, the first current value is 20mA, the second electricity during mobile terminal standby Flow valuve is 12mA, and the float value of the second current value is 6mA, then the difference of the first current value and the second current value is 8mA, then the first electricity Flow valuve and the difference of the second current value are more than the float value of the second current value, obtain the 3rd current value of mobile terminal.
3rd current value refers to the scene current value of mobile terminal in the standby state, mobile terminal field in the standby state Scape may include:Group key interaction times, Wi-Fi re-rent number of times, short message sending times etc. in Wi-Fi scanning times, Wi-Fi, no It is limited to this.Mobile terminal can obtain corresponding current value according to the scene under holding state, by each scene pair under holding state Cumulative i.e. available 3rd current value of current value answered.For example, Wi-Fi scanning times are 10 to mobile terminal in the standby state Secondary, its corresponding scene current value is 1mA;Wi-Fi re-rents number of times for 5 times to mobile terminal in the standby state, its corresponding field Scape current value is 1mA;Then the 3rd current value is 2mA to mobile terminal in the standby state.
(2) if the difference of the first current value and the 3rd current value is more than Second Threshold, according to mobile terminal in the standby state The wake-up times of wake source, the length of one's sleep of mobile terminal judge the power consumption type of mobile terminal.
Second Threshold can be set as needed.In one embodiment, Second Threshold can be the second current value, the second electric current Float value and designated value sum.The difference of first current value and the 3rd current value is the first current value and the 3rd more than Second Threshold The difference of current value is more than the second current value, the second current floating value and designated value sum..For example, the first current value is 25mA, the Two current values are 12mA, and the float value of the second current value is 6mA, and the 3rd current value is 3mA, and designated value is 3mA, the first current value And the difference of the 3rd current value is 22mA, the second current value, the float value of the second current value and designated value sum are 21mA, the first electricity Flow valuve and the difference of the 3rd current value are more than Second Threshold, then according to mobile terminal in the standby state the wake-up times of wake source, Power consumption type of the length of one's sleep of mobile terminal than judging mobile terminal.
Wake source includes AP (Wireless Access Point, wireless access points) under mobile terminal in standby state Wake-up, Wi-Fi wake up, Modem wakes up, power key wakes up etc., not limited to this.Mobile terminal can be recorded in real time under holding state The wake-up times of each wake source and the application program for waking up each wake source.
The data storage that mobile terminal is recorded in real time is in the memory module of mobile terminal.Above-mentioned memory module includes key Partitioned storage module, interim mutual files node and wake source statistics interface.Crucial partitioned storage module, which is used to store, have been recognized Power consumption type and unidentified power consumption type.Interim mutual files node is used to store calling out for each wake source in the standby state The application program for number of times and each wake source of wake-up of waking up, interim mutual files node is used for temporary transient memory mobile terminal holding state Lower data, when detecting mobile terminal bright screen, data are emptied in interim mutual files node.Wake source statistics interface is used to unite The wake-up times of each wake source are counted, and are supplied to mobile terminal to read by system interface.When acquisition for mobile terminal refers to screen is put out When making, the wake-up times that wake source is counted to each wake source of interface record are reset;When detecting mobile terminal and being waken up, Corresponding wake source is identified, and the wake-up times for recording wake source are added 1, the most wake source of wake-up times is supplied to shifting Dynamic terminal is read.Wherein, wake source statistics interface node can be .../sys/kernel/wakeup_reasons/ap_ resume_reason_stastics。
The length of one's sleep of mobile terminal accounts for the ratio of standby time than the duration that refers to sleep under mobile terminal in standby state.Root According to mobile terminal, the most wake source of wake-up times, the length of one's sleep ratio of mobile terminal and the first current value can in the standby state Judge the power consumption type of mobile terminal.
Mobile terminal in the embodiment of the present invention, by the current value and base that detect actual consumption under mobile terminal in standby state The difference of quasi- current value, scene current value, further according to wake-up times of wake source under mobile terminal in standby state, mobile terminal Power consumption type of the length of one's sleep than judging mobile terminal, can easily monitor the power consumption type of mobile terminal.
In one embodiment, mobile terminal can be by the power consumption type upload server of the mobile terminal of judgement.
Mobile terminal can be uploaded onto the server data by Log uploading tools Stethoscope, and every part of Log is with defect Mode is submitted to database correspondence item area.When mobile terminal is detected, power consumption is abnormal, and mobile terminal can determine that mobile terminal Power consumption type and interface of mobile terminal eject prompting frame, for pointing out SCN subscriber connection network and uploading Log automatically.When automatic When uploading many failures of Log, mobile terminal only uploads key message, the power consumption type of such as mobile terminal and corresponding power consumption automatically Amount, and point out user the power consumption type information for uploading mobile terminal manually in interface of mobile terminal pop-up.Mobile terminal is according to pre- If time interval upload the power consumption type of mobile terminal, such as mobile terminal uploaded every 24 hours and once monitors the movement of acquisition The power consumption type of terminal.Mobile terminal can also remind customer mobile terminal power consumption abnormal by pop-up prompting.Log is mobile terminal Middle journal file, can record the operation information of operating system and application program in mobile terminal;In the present embodiment, it can remember in Log Carry the power consumption type information of mobile terminal.Wherein, it is mobile when crucial partitioned storage module Log switches are closed in mobile terminal Terminal not pop-up is reminded;When mobile terminal system version is Release versions, i.e. Log switches are opened, mobile terminal also not bullet Window is reminded;When mobile terminal system version to send when survey version or special version, mobile terminal not pop-up is reminded.As shown in table 4, Survey version and special version and identification Feature are sent for mobile terminal.
In one embodiment, in Fig. 2 step S204 according to mobile terminal in the standby state the wake-up times of wake source, The length of one's sleep of mobile terminal judges that the power consumption type of mobile terminal includes:It is specified whether the wake-up times of detection wake source reach Value;If so, judging the power consumption type of mobile terminal according to the most wake source of wake-up times;If it is not, detection the first current value and Whether the length of one's sleep of mobile terminal meets preset rules;If meeting preset rules, the power consumption type of record mobile terminal is hard Part exception power consumption.
Under the holding state of mobile terminal, if the wake-up times of wake source reach designated value in mobile terminal, according to calling out The most wake source of number of times of waking up judges the power consumption type of mobile terminal.Under such as mobile terminal in standby state, Wi-Fi in mobile terminal Wake-up times are 16 times/hour, Modem wake-up times reach that 15 times/hour, AP wake-up times reach 10 times/hour, Wi-Fi The number of times waken up with Modem is waken up more than 15 times/hour, then is waken up according to the most Wi-Fi of wake-up times and judges mobile terminal Power consumption type for Wi-Fi wake up power consumption.If the wake-up times of wake source are not up to designated value, detection first in mobile terminal Whether the length of one's sleep ratio of current value and mobile terminal meets preset rules, and whether such as the first current value is more than 22mA, during sleep Between than whether more than 99% etc..If the first current value is more than 22mA, and mobile terminal sleeps ratio in holding state more than 99%, Then judge the power consumption type of mobile terminal as hardware anomalies power consumption.
In one embodiment, the above-mentioned wake source most according to wake-up times judges the power consumption type bag of mobile terminal Include:Obtain the application program of the wake-up times of each sub- wake source and each sub- wake source of wake-up in the most wake source of wake-up times; The power consumption type of mobile terminal is judged according to the wake-up times of each sub- wake source and the application program for waking up each sub- wake source.
Each wake source includes sub- wake source in mobile terminal.Wlan_ is waken up as Wi-Fi wake sources include packet Wakeup_src_count [DATA_TYPE_STASTIC], management bag wake up wlan_wakeup_src_count [MGMT_ TYPE_STASTIC], firmware wake up wlan_wakeup_src_count [EVENT_TYPE_STASTIC] and other types wake-up wlan_wakeup_src_count[UNKNOWN_TYPE_STASTIC].As shown in figure 4, putting out screen when mobile terminal is received and referring to When making, mobile terminal calls wlan interface wlan_clear_wakesrc_count () by each sub- wake source in Wi-Fi wake sources Wake-up times reset.Under the holding state of mobile terminal, when Wi-Fi wake sources wake up mobile terminal, mobile terminal can Corresponding sub- wake source in the Wi-Fi wake sources of detection wake-up mobile terminal, and the wake-up times correspondence of sub- wake source Jia 1. When mobile terminal receives bright screen instruction, the wake-up times of each sub- wake source in wake source are write in memory module and handed over temporarily Mutual file node .../sys/kernel/wakeup_reasons/conn_resume_reason_stastics, and by waking up Source statistics interface is supplied to mobile terminal to read.
After mobile terminal detects the most wake source of wake-up times in the standby state, wake-up times are further obtained The application program of the wake-up times of each sub- wake source and the sub- wake source of wake-up, is called out each sub- wake source in most wake sources Wake up and number of times and wake up the application program of sub- wake source and carry out statistical analysis, and by statistic analysis result upload server.For example, moving Dynamic terminal in the standby state the most wake source of wake-up times be Wi-Fi wake sources, wake-up times be 30 times, further obtain It is 15 times to get packet in Wi-Fi wake sources and wake up, and it is 5 times that management bag, which wakes up, and it is 5 times that firmware, which wakes up, and other types wake up For 5 times.It is QQ, microblogging to obtain the packet under mobile terminal in standby state and wake up corresponding application program.Then judge mobile whole The power consumption type at end is that Wi-Fi wakes up power consumption, specifically application program QQ and microblogging frequently carry out packet in mobile terminal Wake up the power consumption caused.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:If the difference for detecting the first current value and the 3rd current value is less than Second Threshold, judged according to the 3rd current value The power consumption type of mobile terminal.
When the first current value and the 3rd current value difference less than Second Threshold, i.e. the first current value subtract the second current value, The float value of second current value, then after subtracting the 3rd current value, resulting difference is less than designated value.That is the first current value with The difference of 3rd current value then judges the power consumption type of mobile terminal in domain of walker according to the 3rd current value.For example, in movement The first current value is 22mA under terminal standby state, and the second current value is 12mA, and the float value of the second current value is 6mA, the 3rd Current value is 3mA, and designated value is 3mA, then the first current value is subtracted after the second current value, the float value of the second current value, then is subtracted The difference gone obtained by the 3rd current value is 1mA, less than designated value 3mA, the i.e. difference of the first current value and the 3rd current value floating In dynamic scope, then the current value of corresponding each scene in the 3rd current value is obtained, such as the 3rd current value 3mA is scanned including Wi-Fi Number of times 10 1mA, Wi-Fi re-rent 5 1mA of number of times, group key interact 10 1mA, then judge the power consumption type of mobile terminal as Wi-Fi scannings are frequently, Wi-Fi is re-rented frequently and group key interaction is frequent.Mobile terminal can be by the power consumption of the mobile terminal of judgement Type information records the crucial partitioned storage module and upload server in partition holding.As the power consumption type of mobile terminal is Wi-Fi scannings are frequent, and Wi-Fi scanning times are 10 times, and corresponding power consumption is 1mA.
Mobile terminal in the embodiment of the present invention, the power consumption type of mobile terminal is judged according to known scene power consumption, can The power consumption condition of scene known to statistical analysis mobile terminal, is conducive to being improved mobile terminal according to statistic analysis result.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:The standby time for detecting mobile terminal is more than preset duration, obtains the first current value and the second current value.
Screen instruction is put out when mobile terminal is received, mobile terminal starts to monitor the power consumption of mobile terminal under holding state; If mobile terminal receives the instruction of bright screen in default time interval, mobile terminal removes the number recorded in the standby state According to, i.e., when the standby time of mobile terminal is more than preset duration, data under mobile terminal monitoring record holding state, and to obtaining Data analyzed, judge mobile terminal power consumption type.For example, preset duration can be 5 hours, it is standby when mobile terminal When duration is more than 5 hours, the data that mobile terminal is obtained to detection are analyzed, and judge the power consumption type of mobile terminal.
Under mobile terminal in standby state power consumption according to battery drain percentage calculate, and in mobile terminal battery electricity Amount is with time nonlinear attenuation, when not having voltameter in mobile terminal, and mobile terminal is calculated according to the percentage of battery drain Under holding state there is larger error in power consumption, and such as 0.5%~1%.
Mobile terminal in the embodiment of the present invention, the preset duration reached by setting standby time to need, can be effective The error of control electric current value, improves the accuracy calculated.
In one embodiment, it can be realized at a kind of information during 2780 configuration processor of processor included by mobile terminal Reason method, including:
(1) receive mobile terminal puts out screen instruction, and the state information statistics number of times for connecting Wi-Fi is reset.
(2) if detection connection Wi-Fi state information change, updates the statistics number of connection Wi-Fi status information.
(3) the bright screen instruction of mobile terminal is received, stops detection connection Wi-Fi status information.
Mobile terminal can pass through Wi-Fi and other mobile terminal connection communications.After mobile terminal connects AP, AP can record SSID (Service Set Identifier, service set).After mobile terminal, which is received, puts out screen instruction, record puts out screen Time mScreenOffTime, the connection Wi-Fi that mobile terminal has been counted state information statistics number of times are reset.Mobile terminal It can detect whether connection Wi-Fi status information changes in real time, if detecting connection Wi-Fi state information change, update Connect the statistics number of Wi-Fi status information.When mobile terminal receives bright screen instruction, the bright screen of mobile terminal can record Time mScreenOnTime, and stop detection connection Wi-Fi status information.Specifically, it can pass through in mobile terminal " public int getWi-FiPowerEventCode () " interface supplies power consumption module in mobile terminal to obtain wlan data, sentences Exist under disconnected mobile terminal in standby state abnormal with the presence or absence of mobile terminal power consumption.If mobile terminal, which is received, puts out screen instruction with connecing Time interval is not up to specified duration between receiving bright screen instruction, does not report and connects Wi-Fi's under holding state in mobile terminal Status information, such as put out the screen time not less than 20 seconds, and the connection Wi-Fi counted status information is not reported.
Mobile terminal in the embodiment of the present invention, the state for connecting Wi-Fi under mobile terminal in standby state by detecting is believed The change of breath, can detect the mobile terminal power consumption caused by AP ends are configured, and be conducive to detecting the stand-by power consumption of mobile terminal.
In one embodiment, above-mentioned connection Wi-Fi status information includes:Group key, DHCP DHCP at least one of is re-rented with Wi-Fi connection status.
Connection Wi-Fi status information may include group key, dynamic host configuration protocol DHCP re-rent, Wi-Fi scanning time At least one of number and Wi-Fi connection status.Wi-Fi network can set the group key management cycle in wireless router, that is, be spaced Regular hour updates a group key.Wherein, group key refers to the algorithm of Wi-Fi passwords.Mobile terminal is in connection Wi-Fi When, it is necessary to DHCP (Dynamic Host Configuration Protocol, DHCP) server obtain The IP address of IP (agreement interconnected between Internet Protocol, network) address, mobile terminal and wireless router is signed There is time restriction, mobile terminal needs to re-rent to wireless router to continue to connect Wi-Fi.Under normal circumstances, wireless router The IP address rental period be 1 hour, when the rental period of acquisition for mobile terminal IP address is more than half, mobile terminal can be continuous to wireless router Rent, i.e., when the rental period of the IP address of acquisition for mobile terminal is half an hour, mobile terminal can be re-rented to wireless router.Wi-Fi Connection status refers to whether mobile terminal connects Wi-Fi, when the Wi-Fi signal of wireless router is unstable, mobile terminal meeting Frequently cut off and reconnect Wi-Fi, cause mobile terminal power consumption.
In one embodiment, if detection connection Wi-Fi state information change, updates connection Wi-Fi status information Statistics number include:If detecting group key change, the statistics number that group key changes plus 1;Above- mentioned information processing method Also include:If the statistics number for detecting group key change reaches first threshold, in interface of mobile terminal display reminding.
Under mobile terminal in standby state, mobile terminal, which detects group key in the Wi-Fi currently connected, to be changed, then by group The statistics number mGroupCount of cipher key change adds 1.When mobile terminal receives bright screen instruction, the bright screen time is recorded MSrceenOnTime, shifting can be calculated according to the statistics number for putting out screen time, bright screen time and group key change of mobile terminal Dynamic terminal standby state the following group cipher key change frequency mGroupFreq.If group key change the frequency reach first threshold such as 20 times/ Point, then point out current Wi-Fi group key management excessively frequent in interface of mobile terminal pop-up, remind user's modification Wi-Fi's The group key management cycle.
In one embodiment, if detection connection Wi-Fi state information change, updates connection Wi-Fi status information Statistics number include:If detecting DHCP to re-rent, the statistics number that DHCP is re-rented plus 1;Above- mentioned information processing method is also wrapped Include:If detecting the statistics number that DHCP re-rents reaches Second Threshold, in interface of mobile terminal display reminding.
Under mobile terminal in standby state, mobile terminal, which detects the Wi-Fi currently connected, often initiates a DHCP and re-rents, Then the statistics number mDhcpCount that DHCP is re-rented plus 1.When mobile terminal receives bright screen instruction, the bright screen time is recorded MSrceenOnTime, according to mobile terminal put out the screen time, the statistics number that bright screen time and DHCP are re-rented can calculate movement DHCP re-rents frequency mDhcpFreq under terminal standby state.If DHCP, which re-rents the frequency, reaches such as 40 beats/min of Second Threshold, Interface of mobile terminal pop-up points out the current Wi-Fi DHCP rental periods to set unreasonable, and mobile terminal is re-rented excessively frequently, is reminded and is used The DHCP rental periods that current Wi-Fi is changed at family are set.
In one embodiment, if detection connection Wi-Fi state information change, updates connection Wi-Fi status information Statistics number include:If detecting Wi-Fi to disconnect, the statistics number of Wi-Fi connection status is added 1;At above- mentioned information Reason method also includes:If the statistics number for detecting Wi-Fi connection status reaches the 3rd threshold value, show and carry in interface of mobile terminal Show frame or forbid connecting current Wi-Fi.
Under mobile terminal in standby state, when mobile terminal detects Wi-Fi and disconnected, Wi-Fi will be reconnected, and Add 1 in the statistics number mDisconnCount of Wi-Fi connection status.When mobile terminal receives bright screen instruction, bright screen is recorded Time mSrceenOnTime, can according to the statistics number for putting out screen time, bright screen time and Wi-Fi connection status of mobile terminal Calculate Wi-Fi connection status change frequency mDisconnFreq under mobile terminal in standby state.If Wi-Fi connection status changes The frequency reaches such as 35 beats/min of the 3rd threshold value, then points out current Wi-Fi signal unstable in interface of mobile terminal pop-up, it is proposed that weight Open wireless router or connect other Wi-Fi;It is such as mobile whole or mobile terminal is forbidden connecting current Wi-Fi within a certain period of time Forbid connecting current Wi-Fi within a hour in end.
In one embodiment, it can be realized at a kind of information during 2780 configuration processor of processor included by mobile terminal Reason method, including:
(1) scan request is received under mobile terminal in standby state, detection is in the corresponding time interval of scan request The no scan request received in addition to scan request has been received.
(2) if not receiving the scan request in addition to scan request has been received, mobile terminal Wi-Fi scanning is opened.
After mobile terminal connects Wi-Fi, mobile terminal can move terminal positioning using Wi-Fi.Mobile terminal Each Wi-Fi that scanning is obtained possesses unique MAC (Media Access Control, media access control) address, root The Wi-Fi obtained according to mobile scanning terminal MAC Address and the power of each Wi-Fi signal, can obtain mobile terminal Positional information.When APP (Application, application program) needs to obtain positional information in mobile terminal, it can be sent out to mobile terminal Play scan request.Under mobile terminal in standby state, the scan request that APP is frequently initiated in mobile terminal can cause mobile terminal Power consumption.
Received under mobile terminal in standby state after the scan request that first application program is initiated, starting timer will The scan request delay very first time interval processing that first application is initiated, i.e. mobile terminal detection in very first time interval whether Receive the scan request of the second application program initiation;If if receiving the initiation of the second application program in very first time interval Scan request, then detect the scan request that the initiation of the 3rd application program whether is received in the second time interval;If first Time interval does not receive the scan request of the second application program, opens mobile terminal Wi-Fi scanning so that initiate scan request APP can obtain the positional information of mobile terminal.
Mobile terminal in the embodiment of the present invention, under mobile terminal in standby state, receives initiate APP in mobile terminal Scan request, the scan request delay process that APP is initiated, it is possible to reduce frequently initiated by APP under mobile terminal in standby state The mobile terminal power consumption caused is scanned, power consumption under mobile terminal in standby state is saved, extends the standby time of mobile terminal.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:If detecting the current number for having received scan request reaches designated value, mobile terminal Wi-Fi scanning is opened.
If the number that mobile terminal detects the current scan request received exceedes designated value, mobile terminal is opened Wi-Fi is scanned, and the APP for initiating scan request in mobile terminal is obtained the positional information of mobile terminal.By detection The number of the scan request of reception, the scan request number that mobile terminal can be avoided to have received is more, and scan request is for a long time Do not meet with a response, cause the situation that Consumer's Experience is poor.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:Scan request waiting time is obtained according at the time of receiving scan request;If detect scan request wait It is long to reach specified duration, open mobile terminal Wi-Fi scanning.
Mobile terminal can be recorded at the time of receive scan request, by current time after APP scan request is received The waiting time that scan request is can obtain at the time of receiving scan request is subtracted, if detecting the waiting time of scan request More than specified duration, then mobile terminal Wi-Fi scanning is opened.For example, mobile terminal has currently received sweeping for two application programs Retouch request, mobile terminal is 16 at the time of receiving the scan request that first application program initiate:50:56;Receive second It is 16 at the time of the scan request that individual application program is initiated:51:01.Current time is 16:51:03.Then the first application program is sent out The waiting time of the scan request risen is 7 seconds;The waiting time for the scan request that second application program is initiated is 2 seconds, default Scan request it is specified when a length of 5 seconds, waiting time of scan request that the first application program is initiated reaches specified duration, then opens Open mobile terminal Wi-Fi scanning so that the first application program and the second application program can obtain the positional information of mobile terminal.It is logical The scan request waiting time that detection has been received is spent, the scan request that mobile terminal can be avoided to have received is not rung for a long time Should, cause the situation that Consumer's Experience is poor.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:Different scanning asks corresponding time interval to be different value.
The corresponding time interval of scan request received in mobile terminal is different value.Specifically, different scanning is asked Corresponding time interval be different value, i.e. mobile terminal receive the corresponding time interval of the first scan request, second scanning It is without value to ask the corresponding time interval of corresponding time interval ... N scan requests.Specifically, each scan request is corresponding Time interval can gradually increase according to reception order or the corresponding time interval of each scan request can gradually subtract according to reception order The corresponding time interval of small or each scan request is distributed according to the requirement of real-time of each scan request.For example, mobile terminal is received To after the first scan request, detection the very first time interval whether receive the second scan request in 3 seconds;Swept receiving second Retouch after request, whether detection receives the 3rd scan request in 2 seconds in the second time interval.By asking different scanning to set Different time interval, can be to the scan request sweetly disposition that receives, it is to avoid scan request is not rung for a long time in mobile terminal Should, reduce Consumer's Experience.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:Different scanning asks corresponding time interval to be identical value.
The corresponding time interval of scan request that mobile terminal is received is that identical value, i.e. mobile terminal are receiving scanning After request, start timer and postpone identical time-triggered protocol.For example, mobile terminal is after the first scan request is received, detection The second scan request whether is received in the very first time 5 milliseconds of interval;If receiving the second scan request, detect second The 3rd scan request whether is received in 5 milliseconds of time interval, by that analogy.
In one embodiment, it can be realized at a kind of information during 2780 configuration processor of processor included by mobile terminal Reason method, including:
(1) the Wi-Fi scan request number of times that application program is detected under mobile terminal in standby state reaches designated value.
(2) corresponding operation is performed to application program according to the corresponding mode of operation of designated value.
Wireless aps possess unique MAC Address, and after mobile terminal opens Wi-Fi scannings, mobile terminal can scan surrounding Wireless aps signal, obtain the MAC Address that broadcasts out of wireless aps, and by the MAC Address upload server of the wireless aps of acquisition. Server can calculate the geographical location information of mobile terminal according to the MAC Address of wireless aps signal strength and wireless aps, and will The positional information for calculating the mobile terminal obtained returns to mobile terminal.During the use of mobile terminal, APP in mobile terminal The positional information of mobile terminal can be applied for obtaining, that is, initiate Wi-Fi scan requests.Wherein, information processing needs to travel through 2.4G13 Individual channel, each channel is stationed 40ms-60ms, if mobile terminal supports double frequency WI-FI, i.e. 5GWI-FI, then needs to scan 36 channels To 156 channels, mobile terminal power consumption is caused to increase.
When acquisition for mobile terminal is to when putting out screen instruction, the Wi- that application program is initiated under mobile terminal in standby state is recorded Fi scan request number of times, if the Wi-Fi scan request number of times for detecting application program initiation reaches designated value, judges application program The Wi-Fi scan request number of times of initiation is excessively frequent, and behaviour corresponding with designated value is performed to the application program for initiating scan request Make.
Mobile terminal in the embodiment of the present invention, detects that the Wi-Fi scannings of application program please under mobile terminal in standby state Ask and reach designated value, be i.e. when the Wi-Fi scan requests of application program are excessively frequent, corresponding operation performed to application program, is kept away Exempt from the mobile terminal power consumption increase that the Wi-Fi scan requests of application program are excessively frequently caused.Under mobile terminal in standby state, The real-time demand of application program is relatively low.To scan request, more frequently application program performs corresponding operation, that is, the shifting reduced The stand-by power consumption of dynamic terminal, by not influenceing Consumer's Experience.
In one embodiment, if designated value is first threshold, the Wi-Fi scan request number of times for detecting application program reaches To first threshold, in interface of mobile terminal pop-up prompting.If designated value is Second Threshold, the Wi-Fi for detecting application program is swept Retouch request number of times and reach Second Threshold, then stop receiving the scan request of application program.If designated value is the 3rd threshold value, detect The Wi-Fi scan request number of times of application program reaches the 3rd threshold value, and application program is terminated and run.
When the scan request number of times of application program reaches different designated values, the operation that mobile terminal is performed to application program Instruction is different.Wherein, Second Threshold is more than first threshold, the 3rd threshold value and is more than Second Threshold.For example, in mobile terminal standby shape Under state, the scan request number of times for detecting application program is 10 times, reaches first threshold 10, in interface of mobile terminal pop-up prompting User's application program power consumption is larger;The scan request number of times for detecting application program is 15 times, reaches Second Threshold 15, then moves Dynamic terminal no longer receives the scan request of application program initiation within a certain period of time, and no longer being received such as within a hour to answer The scan request initiated with program;The scan request number of times for detecting application program is 20 times, reaches the 3rd threshold value 20, then moves Terminal directly terminates application program operation.
In one embodiment, mobile terminal can also calculate the Wi-Fi scan request frequencys of application program, according to applying journey Whether the Wi-Fi scan requests frequency of sequence, which reaches, is specified to perform application program corresponding operation.Wherein, application program The Wi-Fi scan requests frequency can be obtained according to the Wi-Fi scan requests number of times and current idle duration of application program.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:The bright screen instruction of mobile terminal is detected, the Wi-Fi scan requests number of times of application program is reset.
When mobile terminal receives bright screen instruction, by the Wi- of the application program recorded under mobile terminal in standby state Fi scan requests number of times is reset.So that when mobile terminal receives and puts out screen instruction into holding state, record applies journey again The Wi-Fi scan request number of times of sequence.
In one embodiment, it can be realized at a kind of information during 2780 configuration processor of processor included by mobile terminal Reason method, including:
(1) application program under screen instruction, record mobile terminal in standby state of putting out for receiving mobile terminal holds wake-up lock The number of times of duration and application triggers wake-up alarm.
(2) the bright screen instruction of mobile terminal is received, the duration and application triggers for waking up lock are held according to application program The number of times of wake-up alarm obtains the stand-by power consumption information of application program.
A kind of mechanism that lock is android system is waken up, when in system using wake-up lock is held, system cannot be introduced into not Dormancy state, after wake-up lock all in system is all released, system could enter resting state.Wake-up alarm is also referred to as RTC (Real Time Clock, real-time alarm clock) alarm clock, wake-up alarm is individually powered on hardware circuit, in mobile terminal standby shape Under state, wake-up alarm can be by system wake-up.It can all increase mobile whole using wake-up lock and wake-up alarm wake-up mobile terminal is held The stand-by power consumption at end.
When receive mobile terminal put out screen instruction when, mobile terminal detects and records whether each application program holds wake-up Lock, at the time of application program wakes up lock, application program release is at the time of wake up lock and application program corresponding triggering The number of times of wake-up alarm.Wherein, in android system, wake up lock and managed by PowerManagerService, At the time of there be at the time of application program wake-up lock record, application program release wakes up lock in PowerManagerService, Waken up according to application program at the time of lock and application program is can obtain at the time of discharging and wake up lock and hold the duration for waking up lock. Wake-up alarm is managed by AlarmManagerService, and record has wake-up alarm in AlarmManagerService Relevant information, at the time of such as wake-up alarm is triggered, triggers application program identification of wake-up alarm etc..It is noisy according to the wake-up of record The relevant information of clock can obtain the number of times of each application triggers wake-up alarm in the standby state.
When the bright screen for receiving mobile terminal is instructed, wake-up lock is held according to application program under mobile terminal in standby state Duration and the number of times of application triggers wake-up alarm can calculate the stand-by power consumption information for obtaining application program, and according to application The stand-by power consumption information of program performs corresponding operation to application program.
In one embodiment, the stand-by power consumption information of application program includes:The duration that application program holds wake-up lock is accounted for Ratio, the number of times of application triggers wake-up alarm that all application programs hold the total duration for waking up lock account for all application programs Trigger the ratio of the total degree of wake-up alarm, hold the duration and application triggers wake-up alarm for waking up lock according to application program Number of times obtain application program power consumption index.
Hold the duration for waking up lock and each application according to each application program under mobile terminal in standby state of record Program triggering wake-up alarm number of times can calculate application program hold wake up lock total duration and application triggers wake up lock Total degree, then calculate to obtain application program and hold and wake up the duration of lock and account for the ratio of total duration, application triggers wake up noisy The number of times of clock accounts for the ratio of total degree.Wherein, the duration and application triggers wake-up alarm for waking up lock are held to application program Number of times can set weight factor, application program is held and wakes up the duration and the number of times of application triggers wake-up alarm of lock and adds Power calculates the power consumption index for obtaining application program.
In one embodiment, the processor 2780 included by mobile terminal is also held when realizing a kind of information processing method Row following steps:According to the stand-by power consumption information of application program by the corresponding application program identification of application program in mobile terminal circle Face sequence displaying.
Application program can be sorted according to the stand-by power consumption information of the application program of acquisition, for example, being held according to application program There are the ratio for waking up the duration locked, the ratio according to the number of times of application triggers wake-up alarm, the power consumption index of application program Application program is ranked up, and ranking results are shown in interface of mobile terminal.Wherein, can be according to single value to application program It is ranked up, can also being ranked up to application program according to multiple values.For example, according to application program hold wake up lock when Long ratio is ranked up to application program;Application program is carried out according to the ratio of the number of times of application triggers wake-up alarm Sequence;The ratio for waking up the duration locked, the ratio of the number of times of application triggers wake-up alarm are held according to application program and answered Application program is ranked up with the weighted average of the power consumption index of program.Under normal circumstances, by stand-by power consumption from high to low Application program is ranked up.
In one embodiment, the duration and application triggers wake-up alarms that wake up lock is being held according to application program Number of times is obtained before the stand-by power consumption information of application program, and the processor 2780 included by mobile terminal is being realized at a kind of information Following steps are also performed during reason method:Whether the current value consumed under detection mobile terminal in standby state reaches designated value;If so, The number of times for then holding the duration and application triggers wake-up alarm that wake up lock according to application program obtains the standby of application program Power consumption information.
Before the stand-by power consumption information of application program is obtained, the current value consumed under mobile terminal in standby state can determine that Whether designated value is reached;If the current value consumed under mobile terminal in standby state reaches designated value, mobile terminal standby is judged Power consumption is abnormal, obtains the stand-by power consumption information of application program under mobile terminal in standby state.By judging mobile terminal standby shape Current value under state, obtains the stand-by power consumption information of application program again when standby current is abnormal, and the information of acquisition is more accurate.
In one embodiment, the duration and application triggers wake-up alarms that wake up lock is being held according to application program Number of times is obtained before the stand-by power consumption information of application program, and the processor 2780 included by mobile terminal is being realized at a kind of information Following steps are also performed during reason method:Whether the standby time of detection mobile terminal reaches preset duration;If so, then according to application Program holds the stand-by power consumption information of the number of times acquisition application program of the duration for waking up lock and application triggers wake-up alarm.
Before the stand-by power consumption of application program is obtained, when can determine that whether the standby time of mobile terminal reaches default It is long, stand-by power consumption information in application program is obtained when the standby time of mobile terminal reaches preset duration, answering for acquisition can be made It is more accurate with the stand-by power consumption information of program.
In one embodiment, it can be realized at a kind of information during 2780 configuration processor of processor included by mobile terminal Reason method, including:
(1) duration for waking up lock and application triggers wake-up are held under mobile terminal in standby state according to application program The number of times of alarm clock calculates the power consumption index of application program.
(2) if the power consumption index for detecting application program reaches preset value, according to operational order pair corresponding with preset value Application program performs corresponding operation.
The wake-up lock and the wake-up alarm of application triggers that mobile terminal can be held to application program are monitored.Work as inspection When measuring application program wake-up lock, release wake-up lock, application triggers wake-up alarm, it can be remembered accordingly in real time Record.Wherein, in android system, wake up lock and managed by PowerManagerService, in PowerManagerService At the time of middle record has at the time of application program wake-up lock, application program release wakes up lock, called out according to application program Wake up at the time of lock and discharge and the duration that application program holds wake-up lock is can obtain at the time of waking up lock.Wake-up alarm be all by AlarmManagerService is managed, and record has the relevant information of wake-up alarm in AlarmManagerService, such as calls out At the time of awake alarm clock is triggered, application program identification of wake-up alarm etc. is triggered.According to the relevant information of the wake-up alarm of record The number of times of each application triggers wake-up alarm in the standby state can be obtained.Held in the standby state according to application program The number of times of the duration and application triggers wake-up alarm that wake up lock can calculate the power consumption index of application program.When detecting application The power consumption index of program reaches preset value, then the value for the power consumption index that can be reached according to application program is performed accordingly to application program Operation.
In the wake-up alarm that records application program is triggered, the only wake-up of record and application program strong correlation is locked and wakes up noisy Clock.Specifically, can be judged according to the bag name of application program application triggers wake-up alarm whether strong correlation.For example, wechat The entitled com.tencent.mm of bag, first character section com represent business;Second field represents exabyte, and such as tencent is Tencent;3rd field mm represents this application of wechat, and first three field of the bag name of application program is identical to represent same Using.Application program can all carry the bag name information of application program when application wakes up lock and triggering wake-up alarm, if bag name First three field is identical, then is determined as same application program, is recorded as and the application program strong correlation.
In one embodiment, duration and the application for waking up lock are held under mobile terminal in standby state according to application program The power consumption index that the number of times of program triggering wake-up alarm calculates application program includes:Receive mobile terminal puts out screen instruction, record At the time of application program wakes up lock, release wakes up at the time of lock and application triggers wake up the number of times of lock;Receive and move The bright screen instruction of dynamic terminal, wakes up at the time of lock according to application program, obtains application program at the time of release wakes up lock and hold There is the duration for waking up and locking;The number of times calculating for holding the duration for waking up lock and application triggers wake-up alarm according to application program should With the power consumption index of program, power consumption index holds time of the duration and application triggers wake-up alarm that wake up lock with application program Number positive correlation.
In one embodiment, duration and the application for waking up lock are held under mobile terminal in standby state according to application program The power consumption index that the number of times of program triggering wake-up alarm calculates application program includes:The factor, default is locked according to default wake up The wake-up alarm factor, application program hold the duration for waking up lock and the number of times of application triggers wake-up alarm calculates application program Power consumption index.
The power consumption index w of application program is held with default lock factor-alpha, default wake-up alarm factor-beta, the application program of waking up It is w=α * wl+ β * wa to have the relation between duration wl, the number of times wa of application triggers wake-up alarm for waking up and locking.Wherein, no Lock factor-alpha, default wake-up alarm factor-beta difference are waken up with default in mobile terminal.For example, in the terminal α= 0.3, β=0.7, under mobile terminal in standby state, application program, which is held, wakes up the time of lock for 2345ms, application triggers The number of times of wake-up alarm is 23 times, then the power consumption factor w=0.3*2345+0.7*23=719.6 of application program.
In one embodiment, the default lock factor, the default wake-up alarm factor of waking up is obtained by following steps:According to Mobile terminal is waken up the power consumption that time per electricity and mobile terminal are waken up under state and calculates default wake-up lock The factor, the default wake-up alarm factor.
Being waken up power consumption b that time per electricity a and mobile terminal under state be waken up according to mobile terminal can Calculate default wake up and lock factor-alpha, default wake-up alarm factor-beta.Wherein,Treated according to mobile terminal Test data under machine state can obtain the wake-up lock factor and the wake-up alarm factor.
In one embodiment, wrapped according to operational order corresponding with preset value operation corresponding to application program execution Include:If preset value is first threshold, in interface of mobile terminal pop-up prompting;If preset value is Second Threshold, forbid application program Operation.
If the power consumption index for detecting application program reaches first threshold, in interface of mobile terminal pop-up prompting user's application The power consumption index of program is too high;When the power consumption index of application program reaches Second Threshold, then the application program is forbidden to run.Its In, Second Threshold is more than first threshold.In another embodiment, a designated value is set to the power consumption index of application program, When the power consumption index for detecting application program reaches designated value, then point out in interface of mobile terminal pop-up or forbid application program to transport OK.In other embodiments, multiple threshold values also can be set, when the power consumption index of application program reaches different threshold values, to application Program performs different operational orders.
In one embodiment, white list can be set to application program, mobile terminal will not monitor white name under holding state The power consumption index of application program in single.When application program is carrying out the operations such as backstage download, backstage broadcasting audio, it can avoid Power consumption index is too high under application program holding state is terminated operation.
One of ordinary skill in the art will appreciate that realize all or part of flow in above-described embodiment method, being can be with Instruct the hardware of correlation to complete by computer program, program can be stored in a non-volatile computer storage can be read In medium, the program is upon execution, it may include such as the flow of the embodiment of above-mentioned each method.Wherein, storage medium can be magnetic Dish, CD, read-only memory (Read-Only Memory, ROM) etc..
Above example only expresses the several embodiments of the present invention, and it describes more specific and detailed, but can not Therefore it is interpreted as the limitation to the scope of the claims of the present invention.It should be pointed out that for the person of ordinary skill of the art, Without departing from the inventive concept of the premise, various modifications and improvements can be made, these belong to the protection model of the present invention Enclose.Therefore, the protection domain of patent of the present invention should be determined by the appended claims.

Claims (11)

1. a kind of information processing method, it is characterised in that including:
If the difference for detecting mobile terminal the first current value in the standby state and the second current value is more than first threshold, detection Whether the difference of the 3rd current value of first current value and mobile terminal in the standby state is more than Second Threshold;
Wherein, first current value is the average current value of mobile terminal actual consumption in the standby state, second electricity Flow valuve is the reference current value of mobile terminal in the standby state, the 3rd current value be mobile terminal in the standby state Scene current value;
If the difference of first current value and the 3rd current value is more than Second Threshold, according to mobile terminal in the standby state The wake-up times of wake source, the length of one's sleep of mobile terminal judge the power consumption type of mobile terminal.
2. according to the method described in claim 1, it is characterised in that described according to mobile terminal wake source in the standby state Wake-up times, the length of one's sleep of mobile terminal judge that the power consumption type of mobile terminal includes:
Detect whether the wake-up times of the wake source reach designated value;
If so, judging the power consumption type of mobile terminal according to the most wake source of the wake-up times;
If it is not, detecting whether the length of one's sleep ratio of first current value and the mobile terminal meets preset rules;If meeting Preset rules, the power consumption type of record mobile terminal is hardware anomalies power consumption.
3. method according to claim 2, it is characterised in that the wake source most according to the wake-up times judges The power consumption type of mobile terminal includes:
Obtain the application of the wake-up times of each sub- wake source and each sub- wake source of wake-up in the most wake source of the wake-up times Program;
The power consumption of mobile terminal is judged according to the wake-up times of each sub- wake source and the application program for waking up each sub- wake source Type.
4. according to the method described in claim 1, it is characterised in that methods described also includes:
If the difference for detecting first current value and the 3rd current value is less than Second Threshold, according to the 3rd current value Judge the power consumption type of mobile terminal.
5. according to the method described in claim 1, it is characterised in that methods described also includes:
The standby time for detecting mobile terminal is more than preset duration, obtains first current value and second current value.
6. a kind of information processor, it is characterised in that including:
Detection module, if being more than for the difference for detecting mobile terminal the first current value in the standby state and the second current value First threshold, detects whether the difference of the 3rd current value of first current value and mobile terminal in the standby state is more than second Threshold value;
Wherein, first current value is the average current value of mobile terminal actual consumption in the standby state, second electricity Flow valuve is the reference current value of mobile terminal in the standby state, the 3rd current value be mobile terminal in the standby state Scene current value;
First determination module, if the difference for first current value and the 3rd current value is more than Second Threshold, according to shifting Dynamic terminal in the standby state the wake-up times of wake source, mobile terminal the length of one's sleep judge mobile terminal power consumption type.
7. device according to claim 6, it is characterised in that first determination module is additionally operable to detect the wake source Wake-up times whether reach designated value;
If so, judging the power consumption type of mobile terminal according to the most wake source of the wake-up times;
If it is not, detecting whether the length of one's sleep ratio of first current value and the mobile terminal meets preset rules;If meeting Preset rules, the power consumption type of record mobile terminal is hardware anomalies power consumption.
8. device according to claim 7, it is characterised in that first determination module is additionally operable to obtain the wake-up time The application program of the wake-up times of each sub- wake source and each sub- wake source of wake-up in the most wake source of number;
The power consumption of mobile terminal is judged according to the wake-up times of each sub- wake source and the application program for waking up each sub- wake source Type.
9. device according to claim 6, it is characterised in that described device also includes:
Second determination module, if being less than Second Threshold for the difference for detecting first current value and the 3rd current value, The power consumption type of mobile terminal is judged according to the 3rd current value.
10. device according to claim 6, it is characterised in that described device also includes:
Acquisition module, the standby time for detecting mobile terminal is more than preset duration, obtains first current value and institute State the second current value.
11. a kind of mobile terminal, including memory, processor and storage are on a memory and the calculating that can run on a processor Machine program, it is characterised in that the side as any one of claim 1 to 5 is realized during the computing device described program Method.
CN201710318084.7A 2017-05-08 2017-05-08 Information processing method, device and mobile terminal Active CN107193707B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710318084.7A CN107193707B (en) 2017-05-08 2017-05-08 Information processing method, device and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710318084.7A CN107193707B (en) 2017-05-08 2017-05-08 Information processing method, device and mobile terminal

Publications (2)

Publication Number Publication Date
CN107193707A true CN107193707A (en) 2017-09-22
CN107193707B CN107193707B (en) 2018-09-14

Family

ID=59873778

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710318084.7A Active CN107193707B (en) 2017-05-08 2017-05-08 Information processing method, device and mobile terminal

Country Status (1)

Country Link
CN (1) CN107193707B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108541013A (en) * 2018-03-29 2018-09-14 广东欧珀移动通信有限公司 Information processing method, device, mobile terminal and computer readable storage medium
CN108563319A (en) * 2018-04-02 2018-09-21 Oppo广东移动通信有限公司 Information processing method, device, mobile terminal and computer readable storage medium
CN108566472A (en) * 2018-04-20 2018-09-21 Oppo广东移动通信有限公司 Information processing method, device, mobile terminal and computer readable storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102325219A (en) * 2011-09-05 2012-01-18 北京百纳威尔科技有限公司 Method and device for processing electric quantity of mobile terminal
CN103259924A (en) * 2013-04-15 2013-08-21 广东欧珀移动通信有限公司 Method and system for dynamically regulated electric quantity display under low electric quantity of intelligent terminal
CN104156053A (en) * 2014-07-29 2014-11-19 深圳市中兴移动通信有限公司 Abnormal power consumption control method, abnormal power consumption control device and mobile terminal
WO2014183455A1 (en) * 2013-05-17 2014-11-20 Tencent Technology (Shenzhen) Company Limited Method, device and computer storage medium for detecting power consumption of an application
CN104184907A (en) * 2013-05-27 2014-12-03 腾讯科技(深圳)有限公司 Method for detecting awakening data of terminal application software in standby state and terminal
CN105824392A (en) * 2015-11-26 2016-08-03 维沃移动通信有限公司 Application program management method and terminal
CN106055077A (en) * 2016-05-31 2016-10-26 广东欧珀移动通信有限公司 Wake-up lock-based processing method and device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102325219A (en) * 2011-09-05 2012-01-18 北京百纳威尔科技有限公司 Method and device for processing electric quantity of mobile terminal
CN103259924A (en) * 2013-04-15 2013-08-21 广东欧珀移动通信有限公司 Method and system for dynamically regulated electric quantity display under low electric quantity of intelligent terminal
WO2014183455A1 (en) * 2013-05-17 2014-11-20 Tencent Technology (Shenzhen) Company Limited Method, device and computer storage medium for detecting power consumption of an application
CN104184907A (en) * 2013-05-27 2014-12-03 腾讯科技(深圳)有限公司 Method for detecting awakening data of terminal application software in standby state and terminal
CN104156053A (en) * 2014-07-29 2014-11-19 深圳市中兴移动通信有限公司 Abnormal power consumption control method, abnormal power consumption control device and mobile terminal
CN105824392A (en) * 2015-11-26 2016-08-03 维沃移动通信有限公司 Application program management method and terminal
CN106055077A (en) * 2016-05-31 2016-10-26 广东欧珀移动通信有限公司 Wake-up lock-based processing method and device

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108541013A (en) * 2018-03-29 2018-09-14 广东欧珀移动通信有限公司 Information processing method, device, mobile terminal and computer readable storage medium
CN108541013B (en) * 2018-03-29 2022-06-10 Oppo广东移动通信有限公司 Information processing method, device, mobile terminal and computer readable storage medium
CN108563319A (en) * 2018-04-02 2018-09-21 Oppo广东移动通信有限公司 Information processing method, device, mobile terminal and computer readable storage medium
CN108566472A (en) * 2018-04-20 2018-09-21 Oppo广东移动通信有限公司 Information processing method, device, mobile terminal and computer readable storage medium

Also Published As

Publication number Publication date
CN107193707B (en) 2018-09-14

Similar Documents

Publication Publication Date Title
CN107027141B (en) Information processing method, device and mobile terminal
CN107168851B (en) Information processing method, device and mobile terminal
CN107145425B (en) Information processing method, device and mobile terminal
CN104735671A (en) Malicious call recognition method and device
CN107548142A (en) A kind of electricity-saving control method, terminal and computer-readable recording medium
CN108449491A (en) Information processing method, device, mobile terminal and computer readable storage medium
CN107193707B (en) Information processing method, device and mobile terminal
CN106375774A (en) Live broadcast room display content control method, apparatus and system
CN108334651A (en) Collect method, apparatus and storage medium that user's end data realizes preset need
CN108471632A (en) Information processing method, device, mobile terminal and computer readable storage medium
CN108541013A (en) Information processing method, device, mobile terminal and computer readable storage medium
CN105049591A (en) Method and device for processing incoming call
CN108200632A (en) A kind of method and terminal of terminal access LTE network
CN107027160A (en) Information processing method, device and mobile terminal
CN108197934A (en) A kind of method of payment and terminal device
CN103744574A (en) Method and device for turning off alarm clock of mobile terminal and mobile terminal
CN107786714B (en) Sound control method, apparatus and system based on vehicle-mounted multimedia equipment
CN109542232A (en) Switching method, terminal and the computer readable storage medium of terminal horizontal/vertical screen mode
CN105163189A (en) Method for reserving multimedia programs, server and terminal
CN108282834A (en) A kind of method and terminal of terminal access LTE network
CN106817482A (en) Mobile terminal and its method and apparatus called
CN108551530A (en) Call processing method, device, readable storage medium storing program for executing and mobile terminal
CN108549593A (en) Information processing method, device, mobile terminal and computer readable storage medium
CN107197083A (en) The method and mobile terminal of a kind of continuation of the journey duration for adjusting mobile terminal
CN105808716A (en) Alarm clock reminding method and apparatus as well as terminal

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: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Patentee after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP., Ltd.

Address before: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Patentee before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP., Ltd.