CN115373957A - Application killing method and device - Google Patents

Application killing method and device Download PDF

Info

Publication number
CN115373957A
CN115373957A CN202210854339.2A CN202210854339A CN115373957A CN 115373957 A CN115373957 A CN 115373957A CN 202210854339 A CN202210854339 A CN 202210854339A CN 115373957 A CN115373957 A CN 115373957A
Authority
CN
China
Prior art keywords
application
time
interval
killing
score
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.)
Pending
Application number
CN202210854339.2A
Other languages
Chinese (zh)
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.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202210854339.2A priority Critical patent/CN115373957A/en
Publication of CN115373957A publication Critical patent/CN115373957A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3409Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment for performance assessment
    • G06F11/3419Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment for performance assessment by assessing time
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/302Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a software system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3466Performance evaluation by tracing or monitoring
    • G06F11/3476Data logging

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Telephone Function (AREA)

Abstract

The embodiment of the application provides an application killing method and device, and relates to the technical field of terminals. The application killing method obtains relevant data of the application program from a use log of the application program in a preset time period, wherein the relevant data comprises the killing time of the application program, the background switching time of the application program and the foreground switching time. The application killing method also calculates the time interval and the interval application number corresponding to the application program according to the related data; and determining the evaluation result of the application program based on the corresponding time interval and the application number of the interval of each application program and the base score of the application program. The user keep-alive experience can be effectively improved by utilizing the embodiment.

Description

Application killing method and device
Technical Field
The embodiment of the application relates to the technical field of terminals, in particular to an application killing method and device.
Background
The method is limited by using a virtual machine to control memory at the android bottom layer, and some important processes can be kept alive at the background of the electronic device in order to ensure the actual experience that a user uses an application program (simply referred to as "application") in the electronic device (e.g., a mobile phone). The current scheme is to set the number of applications that keep alive in the background and the accessible memory size of different applications for electronic devices of different grades and different memory sizes. For example, the target set for a high-end mobile phone is to keep 10 applications alive in the background on average, and the accessible memory size of 300M is set for a browser. Then, different business domains of the mobile phone manufacturer perform product planning and development according to the target.
However, the above setting is too rigid and rigid, the requirement on an architect in charge of product planning is extremely high, and it is necessary to ensure that the architect is familiar with both user experience and memory service domain before determining the memory baseline of the product. In addition, the original design scheme and the actual experience of the user are split, the product planning can be dynamically adjusted only by public opinion feedback after marketing, the new scheme can be repaired only on a mobile phone system pushed by the next version, hysteresis feedback exists on the actual experience of the user, and the actual experience of the product is influenced.
Disclosure of Invention
The embodiment of the application discloses an application killing method and device, which can adjust the actual experience of a user using a mobile phone in time and enable the mobile phone to be more understandable to the user.
The application discloses in a first aspect a method of killing an application, comprising: acquiring a use log of an application program in a preset time period; acquiring the searching and killing time of each application program from the use log of the application program, and determining the background switching time and the foreground switching time of each application program according to the searching and killing time of each application program; calculating the time interval corresponding to each application program according to the determined time for switching the background and the time for switching the foreground of each application program; determining a number of applications running in a foreground within the time interval; and determining the evaluation result of each application program based on the time interval corresponding to each application program, the number of the application programs running in the foreground in the time interval and the base score of each application program.
By adopting the technical scheme, the basic score and the interval time of the application programs and the dotting information of three dimensions of the number of the application programs running in the foreground in the time interval are introduced, the mistaken killing condition of each application program is dynamically evaluated, the actual use habits of users are fitted, the keep-alive experience of the users to the application programs is improved, the mistaken killing of the application programs is reduced or avoided as much as possible, and the electronic equipment can be effectively ensured to have enough memory to maintain the stable running of the foreground application programs.
In some optional embodiments, the determining the evaluation result of each application program comprises: a kill score is calculated for each application.
By adopting the technical scheme, the condition that the application program is checked and killed is quantified, and the accuracy of checking and killing processing of the application program can be improved.
In some alternative embodiments, said calculating a killing score for each application comprises: obtaining a first score of each application program based on the time interval corresponding to each application program; obtaining a second score for each application based on a number of applications running in the foreground within the time interval; calculating a killing score for each application according to S = Y1 x Y2 x F, wherein S represents the killing score; y1 represents the first score; y2 represents the second score; f represents the base score.
In some alternative embodiments, Y1= a1+ b1 × X + c1 × X 2 +d1*X 3 (ii) a Wherein, a1=206.841793563214; b1= -9.00021943093018; c1=0.134347573391717; d1= -0.000689371112453592; x equals the time interval; y2= a2+ b 2X + c 2X 2 +d2*X 3 (ii) a Wherein, a2=245.460539460545; b2= -47.6803759965558; c2=3.07527766351345; d2= -0.0655251611134173; x is equal to the number of interval applications.
By adopting the technical scheme, the searching and killing score of the application program can be accurately calculated, so that the accuracy of searching and killing processing of the application program can be improved.
In some optional embodiments, the method further comprises: and sequencing the application programs according to the searching and killing scores of each application program.
In some optional embodiments, the method further comprises: and searching and killing the application programs according to the evaluation result of each application program when the residual memory of the electronic equipment is smaller than the preset value.
By adopting the technical scheme, the application searching and killing strategy can be timely adjusted according to the evaluation result of the application program, the searching and killing priority of the application program can be ensured, and the electronic equipment can be further ensured to have enough memory to maintain the stable operation of the foreground application program.
In some optional embodiments, the method further comprises: setting a first threshold value; and if the residual memory of the electronic equipment is smaller than the preset value, preferentially searching and killing the application programs with the searching and killing values lower than the first threshold value.
By adopting the technical scheme, the keep-alive experience of the user on the application program can be improved.
In some optional embodiments, the method further comprises: setting a second threshold; and optimizing the application of which the killing score exceeds the second threshold value.
By adopting the technical scheme, the application program commonly used by the user can be prevented from being killed by mistake, and the keep-alive experience of the user on the application program is further improved.
In some optional embodiments, the method further comprises: and responding to the input of a user, and setting the preset time period. By adopting the technical scheme, the requirements of different users can be met to improve the keep-alive experience.
In some optional embodiments, the usage log of the application includes: the application program background keep-alive log and the application program searching and killing log; wherein the application background keep-alive log comprises: the application name and the package name of each application program, the time for each application program to switch to the background and the time for each application program to switch to the foreground; the application program searching and killing log comprises the following steps: the application name, package name, searching and killing time and searching and killing reason of each application program.
In some optional embodiments, the time for the application to switch back, which is determined according to the killing time of each application, represents the time for the application to switch back last time before the killing time; and the time for switching the application program from the foreground to the background determined according to the searching and killing time of each application program represents the time for switching the application program from the foreground to the background last time after the searching and killing time. By adopting the technical scheme, the time interval can be calculated according to the latest background switching time before the application is checked and killed and the latest foreground switching time after the application is checked and killed, the latest use habits of users are fitted, and the keep-alive experience of the users to the application program is improved.
A second aspect of the application discloses an electronic device comprising a processor and a memory; a memory to store instructions; and the processor is used for calling the instructions in the memory so as to enable the electronic equipment to execute the application killing method.
A third aspect of the present application discloses a computer-readable storage medium having stored thereon at least one instruction, which when executed by a processor, implements the method of killing an application.
For technical effects brought by the second aspect to the third aspect, reference may be made to the description related to the methods in the above method section, and details are not described herein again.
Drawings
Fig. 1 is a schematic flow chart illustrating an application killing method according to an embodiment of the present disclosure.
Fig. 2 is a detailed flowchart of an application killing method according to an embodiment of the present disclosure.
Fig. 3 illustrates the determination of the background switching time and foreground switching time of an application according to the killing time of the application.
Fig. 4 illustrates the plotting in the XOY coordinate system and the trend fitting by setting a plurality of time intervals respectively corresponding to different scores.
Fig. 5 illustrates a method for plotting points in the XOY coordinate system and performing trend fitting by setting a plurality of interval application numbers respectively corresponding to different scores.
Fig. 6 illustrates different application settings base scores.
FIG. 7 illustrates sorting applications according to kill scores.
Fig. 8 is a schematic structural diagram of an electronic device provided in an embodiment of the present application.
Fig. 9 is a block diagram of a software structure of an electronic device according to an embodiment of the present application.
Detailed Description
In the embodiments of the present application, "at least one" means one or more, "and" a plurality "means two or more. "and/or" describes the association relationship of the associated object, indicating that there may be three relationships, for example, a and/or B may represent: a exists alone, A and B exist simultaneously, and B exists alone, wherein A and B can be singular or plural. The terms "first," "second," "third," "fourth," and the like in the description and in the claims and drawings of the present application, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order.
The searching and killing mechanism of Android (Android) application comprises the following steps: applications are first classified into forego (foreground application), visible (visible application), secondary (secondary service), hidden (background application), and the like. And (4) carrying out searching and killing management and control on the application according to the importance of different levels. The Low Memory Kill program sets a corresponding value for each state level of the application. When the remaining Memory is insufficient, the Low Memory Kill program will Kill the application corresponding to the state level to release the Memory. If the residual memory is still insufficient after the application is killed, the application of the previous state level is continuously killed, and so on. Until the foreground application is killed, the running application or game is flashed off, and the user experience is seriously influenced.
Fig. 1 is a schematic flow chart of a method for applying a false kill assessment (Wrong kill assessment) provided in an embodiment of the present application. Referring to fig. 1, in the process of using a mobile phone by a user, various reasons of the searched and killed application are collected by the application killing method provided by the embodiment of the application, the mistaken killing of the application program is evaluated by the application killing method, and the searching and killing strategy is dynamically modified according to the evaluation result to improve the user keep-alive experience. For details, please refer to the description of fig. 2.
Fig. 2 is a detailed flowchart of an application false kill assessment (Wrong kill assessment) method provided in an embodiment of the present application. The application killing method provided by the embodiment of the application can be applied to electronic equipment. The electronic equipment can be terminal equipment such as a mobile phone and a tablet personal computer. By the application killing method, the priority of daily application use of the user is improved, the application which the user focuses on cannot be killed, and the keep-alive experience of the user is improved.
Specifically, the application killing method comprises the following steps:
step S11, acquiring a use log of the application program in a preset time period.
In one embodiment of the present application, the preset time period may refer to a time period of different durations such as the last 1 day or several days or a week or a month of the user. In one embodiment, the preset time period may be set in response to a user input.
In one embodiment of the application, the usage log of the application includes an application background keep-alive log and an application killing log.
The application background keep-alive log includes, but is not limited to, an application name, a package name (package _ name), a time for each application to switch to the background (i.e., a time for each switch from foreground to background), and a time for each switch to the foreground (i.e., a time for each start of an application) for each of the N applications. N is a positive integer greater than or equal to 1.
The application program searching and killing log comprises, but is not limited to, an application name, a package name, searching and killing time and searching and killing reason of each searched and killed application program.
And S12, acquiring the killing time of each application program from the use log of the application program, and determining the background switching time and foreground switching time of each application program according to the killing time of each application program.
In one embodiment, the time that the application program switches back to the background, as determined from the kill time of each application program, represents the time that the application program last switched back to the background prior to the kill time. In one embodiment, the time of application foreground cut determined from the time of kill of each application represents the time of the most recent application foreground cut after the time of kill.
In one embodiment, the killing time of each application program can be obtained from the application program killing log, and then the background switching time and foreground switching time of each application program are determined from the application program background keep-alive log according to the killing time.
For example, referring to fig. 3, assuming that the killing time obtained from the application killing log to the application a is T2, the application background keep-alive log may determine, according to the killing time T2, that the time of the application a last switching to the background before the killing time T2 is T1, and that the time of the application a last switching to the foreground after the killing time T2 is T3.
S13, calculating a time interval T corresponding to each application program according to the determined time for switching the background and the time for switching the foreground of each application program; and determining the interval application number D corresponding to each application program in the time interval T.
In this embodiment, the time interval T corresponding to each application program is equal to the difference between the determined foreground switching time and the determined background switching time of each application program.
In one embodiment, the interval application number D corresponding to each application program in the time interval T represents the number of application programs that are switched to the foreground in the time interval T (i.e., the number of application programs started by the electronic device in the time interval T). In one embodiment, the interval application number D corresponding to each application program can be obtained from the application program background keep-alive log according to the time interval T.
For example, still referring to fig. 3, assume that the time interval T = T3-T1 corresponding to the a application is calculated; in the time interval T3-T1, two applications, i.e., the B application and the C application, are respectively switched to the foreground, and therefore, the number D of interval applications corresponding to the a application is equal to 2.
And S14, determining the evaluation result of each application program based on the time interval T corresponding to each application program, the interval application number D and the basis score F of each application program.
In this embodiment, the determining the evaluation result of each application includes: and calculating the killing score S of each application program.
In this embodiment, the calculating the killing score S of each application includes: obtaining a first score Y1 of each application program based on the time interval T corresponding to each application program; obtaining a second score Y2 of each application program based on the interval application number D corresponding to each application program; and calculating the killing score S of each application program according to the formula S = Y1Y 2F.
In one embodiment, Y1= a1+ b 1X + c 1X 2 +d1*X 3 (ii) a Wherein, X = T; a1=206.841793563214; b1= -9.00021943093018; c1=0.134347573391717; d1= -0.000689371112453592.
In one embodiment, Y2= a2+ b 2X + c 2X 2 +d2*X 3 (ii) a Wherein X = D; a2=245.460539460545; b2= -47.6803759965558; c2=3.07527766351345; d2= -0.0655251611134173.
In one embodiment, the curve function Y1 may be obtained by setting a plurality of time intervals T respectively corresponding to different scores, plotting points of the plurality of time intervals T as abscissa in the XOY coordinate system and the scores respectively corresponding to the plurality of time intervals T as ordinate in the XOY coordinate system, and connecting the points to a curve for trend fitting.
In this embodiment, when the score corresponding to the time interval T is set, a reference value of the time interval T may be set in advance, and the score corresponding to the reference value may be set to 100 points, so that the user's sensitivity is increased when the score is smaller than the reference value, and the user's sensitivity is decreased when the score is larger than the reference value. In addition, a boundary value of the time interval T may be set, and when the value of the time interval T is greater than the set boundary value, the user does not feel bad, and the corresponding score is set to 0 when the time interval T is greater than the set boundary value. In one embodiment, the reference value for the time interval T is set to 15 minutes and the boundary value for the time interval T is set to 60 minutes.
For example, referring to fig. 4, the reference value of the time interval T is set to 15 minutes, the corresponding score is 100 minutes, and the boundary value of the time interval T is set to 60 minutes; setting a time interval of 5 minutes corresponding to the score 160; setting time intervals of 10 minutes corresponding to scores 130 and the like, drawing points in an XOY coordinate system by taking a plurality of set time intervals T and the corresponding scores as coordinate points, and connecting all the drawn points into a curve to perform trend fitting to obtain a curve function Y1.
In the present embodiment, the obtained curve function Y1= a1+ b1 × X + c1 × X 2 +d1*X 3 Degree of fitting R between curves obtained by actual plotting 2 Reach 0.999111278966183.
Similarly, the curve function Y2 may be obtained by setting a plurality of interval application numbers D corresponding to different scores, respectively, plotting points with the interval application numbers D as abscissa in the XOY coordinate system and the scores corresponding to the interval application numbers D, respectively, as ordinate in the XOY coordinate system, and connecting the points into a curve for trend fitting.
In this embodiment, when the score corresponding to the interval application number D is set, a reference value of the interval application number D may be set in advance, and the score corresponding to the reference value may be set to 100, so that the user's perceptibility is increased when the score is smaller than the reference value, and the user's perceptibility is decreased when the score is larger than the reference value, and the score is decreased. In addition, a boundary value of the interval application number D may be set, and when the value of the interval application number D is greater than the set boundary value, the user does not feel bad, and the score value corresponding to the interval application number D greater than the set boundary value is set to 0. In one embodiment, the reference value of the interval application number D is 4, while the boundary value of the interval application number D is set to 13.
For example, referring to fig. 5, the reference value of the interval application number D is set to 4, the corresponding score is 100, and the boundary value of the interval application number D is set to 13; setting the interval application number D as 2, and corresponding to the score 160; setting interval application number D as 3, corresponding to scores 130 and the like, taking the interval application numbers D and the scores corresponding to the interval application numbers D as coordinate points to trace points in an XOY coordinate system, and connecting all the traced points into a curve to perform trend fitting to obtain a curve function Y2.
In the present embodiment, the obtained curve function Y2= a2+ b 2X + c 2X 2 +d2*X 3 Degree of fit R between curves obtained from actual tracing points 2 Can reach 0.999165439224973.
In the present embodiment, the base score F of each application program may be set in advance. In one embodiment, the base score F for each application may be scored according to user usage habits.
In one embodiment, a table may be created with which the base score, F, for each application is recorded. For example, referring to FIG. 6, the table includes a plurality of fields including, but not limited to, an application name for each application, a base score F, a category (i.e., classification) for each application, a package name, and the like.
For example, referring to fig. 6, the basic score F of the "royal glory" application is set to 100 according to the user's usage habit; the base score F for the "QQ" application was set to 80.
In one embodiment, the applications may also be sorted according to the kill score of each application.
In one embodiment, a ranking table may be created to record the scoring ranking each time an application is killed.
For example, referring to fig. 8, the ranking table includes a plurality of fields, such as Serial Number (SN) of the electronic device, package name of the application, background-cut time of the application, foreground-cut time, reason why the application is killed, time when the application is killed, time interval T (minutes), number of applications interval D (number), application name, base score F, application classification, and killing score (scoring data). According to FIG. 8, with "WeChat TM "application" in the background "at time point" 2021-04-24 "and at time point" 2021-04-24 "the TM The number of application intervals during the "application time points" 2021-04-24 "to" 2021-04-24 "40 is 0, and can be calculated according to the method for calculating the killing score S provided in the present application:WeChat TM "application has a kill score of 506.16 ten thousand.
And S15, when the residual memory of the electronic equipment is smaller than a preset value, searching and killing the application programs according to the evaluation result of each application program so as to improve the keep-alive experience of the user on the application.
In one embodiment, when the application program is killed according to the evaluation result of each application program, the killing may be prioritized for the application program with the lower killing score. I.e., the higher the kill score, the higher the likelihood of a false kill.
In an embodiment, a first threshold (for example, 30 points) may also be set, and if the remaining memory of the electronic device is smaller than the preset value, the application program with the killing score value lower than the first threshold is preferentially killed.
In this embodiment, the searching and killing reasons of the applications searched and killed by the electronic device within the preset time period can be dynamically scheduled and analyzed in the background. Specifically, a second threshold value, for example, 80 points, may be set, the cause of the application to be killed that has the killing score exceeding the second threshold value is concerned (for example, the application to be killed that has the killing score exceeding the second threshold value may be optimized, etc.), and a set of expert systems is executed in the background to limit the way of killing the application exceeding the second threshold value, so as to further improve the actual experience of the user. By the application killing method, the application can be prevented from being mistakenly checked and killed, the application checking and killing accuracy is improved, and sufficient memory is ensured to ensure the stable operation of an operating system or foreground application.
Fig. 8 is a schematic structural diagram of an electronic device 100 according to an embodiment of the present application. The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a Universal Serial Bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a key 190, a motor 191, an indicator 192, a camera 193, a display screen 194, a Subscriber Identity Module (SIM) card interface 195, and the like. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, and the like.
It is to be understood that the illustrated structure of the embodiment of the present application does not specifically limit the electronic device 100. In other embodiments of the present application, electronic device 100 may include more or fewer components than shown, or some components may be combined, some components may be split, or a different arrangement of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
Processor 110 may include one or more processing units, such as: the processor 110 may include an Application Processor (AP), a modem processor, a Graphics Processing Unit (GPU), an Image Signal Processor (ISP), a controller, a memory, a video codec, a Digital Signal Processor (DSP), a baseband processor, and/or a neural-Network Processing Unit (NPU), etc. The different processing units may be separate devices or may be integrated into one or more processors.
The controller may be, among other things, a neural center and a command center of the electronic device 100. The controller can generate an operation control signal according to the instruction operation code and the timing signal to complete the control of instruction fetching and instruction execution.
A memory may also be provided in processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may hold instructions or data that have just been used or recycled by the processor 110. If the processor 110 needs to use the instructions or data again, it can call directly from the memory. Avoiding repeated accesses reduces the latency of the processor 110, thereby increasing the efficiency of the system.
In some embodiments, processor 110 may include one or more interfaces. The interface may include an integrated circuit (I2C) interface, an integrated circuit built-in audio (I2S) interface, a Pulse Code Modulation (PCM) interface, a universal asynchronous receiver/transmitter (UART) interface, a mobile industry processor interface (mobile industry processor interface, MIPI), a general-purpose-input/output (GPIO) interface, a Subscriber Identity Module (SIM) interface, and/or a Universal Serial Bus (USB) interface, etc.
The I2C interface is a bidirectional synchronous serial bus including a serial data line (SDA) and a Serial Clock Line (SCL). In some embodiments, processor 110 may include multiple sets of I2C buses. The processor 110 may be coupled to the touch sensor 180K, the charger, the flash, the camera 193, etc. through different I2C bus interfaces, respectively. For example: the processor 110 may be coupled to the touch sensor 180K through an I2C interface, so that the processor 110 and the touch sensor 180K communicate through an I2C bus interface to implement a touch function of the electronic device 100.
The I2S interface may be used for audio communication. In some embodiments, processor 110 may include multiple sets of I2S buses. The processor 110 may be coupled to the audio module 170 through an I2S bus to enable communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 may transmit the audio signal to the wireless communication module 160 through the I2S interface, so as to implement a function of receiving a call through a bluetooth headset.
The PCM interface may also be used for audio communication, sampling, quantizing and encoding analog signals. In some embodiments, audio module 170 and wireless communication module 160 may be coupled by a PCM bus interface. In some embodiments, the audio module 170 may also transmit the audio signal to the wireless communication module 160 through the PCM interface, so as to implement the function of answering a call through the bluetooth headset. Both the I2S interface and the PCM interface may be used for audio communication.
The UART interface is a universal serial data bus used for asynchronous communications. The bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is generally used to connect the processor 110 with the wireless communication module 160. For example: the processor 110 communicates with a bluetooth module in the wireless communication module 160 through a UART interface to implement a bluetooth function. In some embodiments, the audio module 170 may transmit the audio signal to the wireless communication module 160 through a UART interface, so as to implement the function of playing music through a bluetooth headset.
The MIPI interface may be used to connect the processor 110 with peripheral devices such as the display screen 194, the camera 193, and the like. The MIPI interface includes a Camera Serial Interface (CSI), a Display Serial Interface (DSI), and the like. In some embodiments, processor 110 and camera 193 communicate through a CSI interface to implement the capture functionality of electronic device 100. Processor 110 and display screen 194 communicate via a DSI interface to implement display functions of electronic device 100.
The GPIO interface may be configured by software. The GPIO interface may be configured as a control signal and may also be configured as a data signal. In some embodiments, a GPIO interface may be used to connect the processor 110 with the camera 193, the display 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like. The GPIO interface may also be configured as an I2C interface, I2S interface, UART interface, MIPI interface, and the like.
The USB interface 130 is an interface conforming to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, or the like. The USB interface 130 may be used to connect a charger to charge the electronic device 100, and may also be used to transmit data between the electronic device 100 and a peripheral device. And the earphone can also be used for connecting an earphone and playing audio through the earphone. The interface may also be used to connect other electronic devices, such as AR devices and the like.
It should be understood that the connection relationship between the modules illustrated in the embodiment of the present application is only an exemplary illustration, and does not limit the structure of the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection manners or a combination of multiple interface connection manners in the above embodiments.
The charging management module 140 is configured to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive a wireless charging input through a wireless charging coil of the electronic device 100. The charging management module 140 may also supply power to the electronic device through the power management module 141 while charging the battery 142.
The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and/or the charge management module 140 and provides power to the processor 110, the internal memory 121, the external memory, the display 194, the camera 193, the wireless communication module 160, and the like. The power management module 141 may also be used to monitor parameters such as battery capacity, battery cycle count, battery state of health (leakage, impedance), etc. In some other embodiments, the power management module 141 may also be disposed in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be disposed in the same device.
The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, a modem processor, a baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals. Each antenna in the electronic device 100 may be used to cover a single or multiple communication bands. Different antennas can also be multiplexed to improve the utilization of the antennas. For example: the antenna 1 may be multiplexed as a diversity antenna of a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The mobile communication module 150 may provide a solution including wireless communication of 2G/3G/4G/5G, etc. applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a Low Noise Amplifier (LNA), and the like. The mobile communication module 150 may receive the electromagnetic wave from the antenna 1, filter, amplify, etc. the received electromagnetic wave, and transmit the electromagnetic wave to the modem processor for demodulation. The mobile communication module 150 may also amplify the signal modulated by the modem processor, and convert the signal into electromagnetic wave through the antenna 1 to radiate the electromagnetic wave. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the same device as at least some of the modules of the processor 110.
The modem processor may include a modulator and a demodulator. The modulator is used for modulating a low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used for demodulating the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then passes the demodulated low frequency baseband signal to a baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and then transferred to the application processor. The application processor outputs a sound signal through an audio device (not limited to the speaker 170A, the receiver 170B, etc.) or displays an image or video through the display screen 194. In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be provided in the same device as the mobile communication module 150 or other functional modules, independent of the processor 110.
The wireless communication module 160 may provide solutions for wireless communication applied to the electronic device 100, including Wireless Local Area Networks (WLANs) (e.g., wireless fidelity (Wi-Fi) networks), bluetooth (bluetooth, BT), global Navigation Satellite System (GNSS), frequency Modulation (FM), near Field Communication (NFC), infrared (IR), and the like. The wireless communication module 160 may be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, performs frequency modulation and filtering processing on electromagnetic wave signals, and transmits the processed signals to the processor 110. The wireless communication module 160 may also receive a signal to be transmitted from the processor 110, perform frequency modulation and amplification on the signal, and convert the signal into electromagnetic waves through the antenna 2 to radiate the electromagnetic waves.
In some embodiments, antenna 1 of electronic device 100 is coupled to mobile communication module 150 and antenna 2 is coupled to wireless communication module 160 so that electronic device 100 can communicate with networks and other devices through wireless communication techniques. The wireless communication technology may include global system for mobile communications (GSM), general Packet Radio Service (GPRS), code division multiple access (code division multiple access, CDMA), wideband Code Division Multiple Access (WCDMA), time-division code division multiple access (TD-SCDMA), long Term Evolution (LTE), fifth Generation wireless communication systems (5g, the 5th Generation of wireless communication system), BT, GNSS, WLAN, NFC, FM, and/or IR technology, etc. The GNSS may include a Global Positioning System (GPS), a global navigation satellite system (GLONASS), a beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS), and/or a Satellite Based Augmentation System (SBAS).
The electronic device 100 implements display functions via the GPU, the display screen 194, and the application processor. The GPU is a microprocessor for image processing, and is connected to the display screen 194 and an application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
The display screen 194 is used to display images, video, and the like. The display screen 194 includes a display panel. The display panel may adopt a Liquid Crystal Display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (active-matrix organic light-emitting diode, AMOLED), a flexible light-emitting diode (FLED), a miniature, a Micro-oeld, a quantum dot light-emitting diode (QLED), and the like. In some embodiments, the electronic device 100 may include 1 or N display screens 194, N being a positive integer greater than 1.
The electronic device 100 may implement a shooting function through the ISP, the camera 193, the video codec, the GPU, the display 194, the application processor, and the like.
The ISP is used to process the data fed back by the camera 193. For example, when a photo is taken, the shutter is opened, light is transmitted to the camera photosensitive element through the lens, the optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing and converting into an image visible to naked eyes. The ISP can also carry out algorithm optimization on the noise, brightness and skin color of the image. The ISP can also optimize parameters such as exposure, color temperature and the like of a shooting scene. In some embodiments, the ISP may be provided in camera 193.
The camera 193 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image to the photosensitive element. The photosensitive element may be a Charge Coupled Device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to be converted into a digital image signal. And the ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into image signal in standard RGB, YUV and other formats. In some embodiments, electronic device 100 may include 1 or N cameras 193, N being a positive integer greater than 1.
The digital signal processor is used for processing digital signals, and can process digital image signals and other digital signals. For example, when the electronic device 100 selects a frequency bin, the digital signal processor is used to perform fourier transform or the like on the frequency bin energy.
Video codecs are used to compress or decompress digital video. The electronic device 100 may support one or more video codecs. In this way, the electronic device 100 may play or record video in a variety of encoding formats, such as: moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, and the like.
The NPU is a neural-network (NN) computing processor that processes input information quickly by using a biological neural network structure, for example, by using a transfer mode between neurons of a human brain, and can also learn by itself continuously. Applications such as intelligent recognition of the electronic device 100 can be realized through the NPU, for example: image recognition, face recognition, speech recognition, text understanding, and the like.
The external memory interface 120 may be used to connect an external memory card, such as a Micro SD card, to extend the storage capability of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as music, video, etc. are saved in an external memory card.
The internal memory 121 may be used to store computer-executable program code, which includes instructions. The processor 110 executes various functional applications of the electronic device 100 and data processing by executing instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. The storage program area may store an operating system, an application program (such as a sound playing function, an image playing function, etc.) required by at least one function, and the like. The storage data area may store data (such as audio data, phone book, etc.) created during use of the electronic device 100, and the like. In addition, the internal memory 121 may include a high-speed random access memory, and may further include a nonvolatile memory, such as at least one magnetic disk storage device, a flash memory device, a universal flash memory (UFS), and the like.
The electronic device 100 may implement audio functions via the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone interface 170D, and the application processor. Such as music playing, recording, etc.
The audio module 170 is used to convert digital audio information into an analog audio signal output and also to convert an analog audio input into a digital audio signal. The audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be disposed in the processor 110, or some functional modules of the audio module 170 may be disposed in the processor 110.
The speaker 170A, also called a "horn", is used to convert the audio electrical signal into an acoustic signal. The electronic apparatus 100 can listen to music through the speaker 170A or listen to a handsfree call.
The receiver 170B, also called "earpiece", is used to convert the electrical audio signal into an acoustic signal. When the electronic apparatus 100 receives a call or voice information, it can receive voice by placing the receiver 170B close to the ear of the person.
The microphone 170C, also referred to as a "microphone," is used to convert sound signals into electrical signals. When making a call or sending voice information, the user can input a voice signal to the microphone 170C by uttering a voice signal close to the microphone 170C through the mouth of the user. The electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C to achieve a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further include three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, perform directional recording, and so on.
The earphone interface 170D is used to connect a wired earphone. The headset interface 170D may be the USB interface 130, or may be a 3.5mm open mobile electronic device platform (OMTP) standard interface, a cellular telecommunications industry association (cellular telecommunications industry association of the USA, CTIA) standard interface.
The pressure sensor 180A is used for sensing a pressure signal, and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A may be disposed on the display screen 194. The pressure sensor 180A can be of a wide variety, such as a resistive pressure sensor, an inductive pressure sensor, a capacitive pressure sensor, and the like. The capacitive pressure sensor may be a sensor comprising at least two parallel plates having an electrically conductive material. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the strength of the pressure from the change in capacitance. When a touch operation is applied to the display screen 194, the electronic apparatus 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic apparatus 100 may also calculate the touched position from the detection signal of the pressure sensor 180A. In some embodiments, the touch operations that are applied to the same touch position but different touch operation intensities may correspond to different operation instructions. For example: and when the touch operation with the touch operation intensity smaller than the first pressure threshold value acts on the short message application icon, executing an instruction for viewing the short message. And when the touch operation with the touch operation intensity larger than or equal to the first pressure threshold value acts on the short message application icon, executing an instruction of newly building the short message.
The gyro sensor 180B may be used to determine the motion attitude of the electronic device 100. In some embodiments, the angular velocity of electronic device 100 about three axes (i.e., the x, y, and z axes) may be determined by gyroscope sensor 180B. The gyro sensor 180B may be used for photographing anti-shake. For example, when the shutter is pressed, the gyro sensor 180B detects a shake angle of the electronic device 100, calculates a distance to be compensated for by the lens module according to the shake angle, and allows the lens to counteract the shake of the electronic device 100 through a reverse movement, thereby achieving anti-shake. The gyroscope sensor 180B may also be used for navigation, somatosensory gaming scenes.
The air pressure sensor 180C is used to measure air pressure. In some embodiments, electronic device 100 calculates altitude from barometric pressure values measured by barometric pressure sensor 180C to assist in positioning and navigation.
The magnetic sensor 180D includes a hall sensor. The electronic device 100 may detect the opening and closing of the flip holster using the magnetic sensor 180D. In some embodiments, when the electronic device 100 is a flip phone, the electronic device 100 may detect the opening and closing of the flip according to the magnetic sensor 180D. And then according to the opening and closing state of the leather sheath or the opening and closing state of the flip cover, the automatic unlocking of the flip cover is set.
The acceleration sensor 180E may detect the magnitude of acceleration of the electronic device 100 in various directions (typically three axes). The magnitude and direction of gravity can be detected when the electronic device 100 is stationary. The method can also be used for recognizing the posture of the electronic equipment, and is applied to horizontal and vertical screen switching, pedometers and other applications.
A distance sensor 180F for measuring a distance. The electronic device 100 may measure the distance by infrared or laser. In some embodiments, taking a picture of a scene, electronic device 100 may utilize range sensor 180F to range for fast focus.
The proximity light sensor 180G may include, for example, a Light Emitting Diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic apparatus 100 emits infrared light to the outside through the light emitting diode. The electronic device 100 detects infrared reflected light from nearby objects using a photodiode. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100. When insufficient reflected light is detected, the electronic device 100 may determine that there are no objects near the electronic device 100. The electronic device 100 can utilize the proximity sensor 180G to detect that the user holds the electronic device 100 close to the ear for talking, so as to automatically turn off the screen to save power. The proximity light sensor 180G can also be used in a holster mode, a pocket mode automatically unlocks and locks the screen.
The ambient light sensor 180L is used to sense the ambient light level. Electronic device 100 may adaptively adjust the brightness of display screen 194 based on the perceived ambient light level. The ambient light sensor 180L may also be used to automatically adjust the white balance when taking a picture. The ambient light sensor 180L may also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.
The fingerprint sensor 180H is used to collect a fingerprint. The electronic device 100 can utilize the collected fingerprint characteristics to unlock the fingerprint, access the application lock, photograph the fingerprint, answer an incoming call with the fingerprint, and so on.
The temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 implements a temperature processing strategy using the temperature detected by temperature sensor 180J. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 performs a reduction in performance of a processor located near the temperature sensor 180J, so as to reduce power consumption and implement thermal protection. In other embodiments, the electronic device 100 heats the battery 142 when the temperature is below another threshold to avoid the low temperature causing the electronic device 100 to shut down abnormally. In other embodiments, when the temperature is lower than a further threshold, the electronic device 100 performs boosting on the output voltage of the battery 142 to avoid abnormal shutdown due to low temperature.
The touch sensor 180K is also referred to as a "touch panel". The touch sensor 180K may be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, which is also called a "touch screen". The touch sensor 180K is used to detect a touch operation applied thereto or nearby. The touch sensor can communicate the detected touch operation to the application processor to determine the touch event type. Visual output associated with the touch operation may be provided through the display screen 194. In other embodiments, the touch sensor 180K may be disposed on a surface of the electronic device 100, different from the position of the display screen 194.
The bone conduction sensor 180M can acquire a vibration signal. In some embodiments, the bone conduction sensor 180M may acquire a vibration signal of the human vocal part vibrating the bone mass. The bone conduction sensor 180M may also contact the human pulse to receive the blood pressure pulsation signal. In some embodiments, the bone conduction sensor 180M may also be disposed in a headset, integrated into a bone conduction headset. The audio module 170 may analyze a voice signal based on the vibration signal of the bone mass vibrated by the sound part acquired by the bone conduction sensor 180M, so as to implement a voice function. The application processor can analyze heart rate information based on the blood pressure beating signal acquired by the bone conduction sensor 180M, so as to realize the heart rate detection function.
The keys 190 include a power-on key, a volume key, and the like. The keys 190 may be mechanical keys. Or may be touch keys. The electronic apparatus 100 may receive a key input, and generate a key signal input related to user setting and function control of the electronic apparatus 100.
The motor 191 may generate a vibration cue. The motor 191 may be used for incoming call vibration prompts as well as for touch vibration feedback. For example, touch operations applied to different applications (e.g., photographing, audio playing, etc.) may correspond to different vibration feedback effects. The motor 191 may also respond to different vibration feedback effects for touch operations applied to different areas of the display screen 194. Different application scenes (such as time reminding, receiving information, alarm clock, game and the like) can also correspond to different vibration feedback effects. The touch vibration feedback effect may also support customization.
Indicator 192 may be an indicator light that may be used to indicate a state of charge, a change in charge, or a message, missed call, notification, etc.
The SIM card interface 195 is used to connect a SIM card. The SIM card can be brought into and out of contact with the electronic apparatus 100 by being inserted into the SIM card interface 195 or being pulled out of the SIM card interface 195. The electronic device 100 may support 1 or N SIM card interfaces, N being a positive integer greater than 1. The SIM card interface 195 may support a Nano SIM card, a Micro SIM card, a SIM card, etc. The same SIM card interface 195 can be inserted with multiple cards at the same time. The types of the plurality of cards may be the same or different. The SIM card interface 195 may also be compatible with different types of SIM cards. The SIM card interface 195 may also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as communication and data communication. In some embodiments, the electronic device 100 employs esims, namely: an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.
The software system of the electronic device 100 may employ a layered architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. The embodiment of the present application takes an Android system with a hierarchical architecture as an example, and exemplarily illustrates a software structure of the electronic device 100.
Fig. 9 is a block diagram of a software structure of the electronic device 100 according to an embodiment of the present application. The layered architecture divides the software into several layers, each layer having a clear role and division of labor. The layers communicate with each other through a software interface. In some embodiments, the Android system is divided into four layers, an application layer, an application framework layer, an Android runtime (Android runtime) and system library, and a kernel layer from top to bottom. The application layer may include a series of application packages.
As shown in fig. 9, the application package may include applications such as camera, gallery, calendar, phone call, map, navigation, WLAN, bluetooth, music, video, short message, etc.
The application framework layer provides an Application Programming Interface (API) and a programming framework for the application program of the application layer. The application framework layer includes a number of predefined functions.
As shown in FIG. 9, the application framework layers may include a window manager, content provider, view system, phone manager, resource manager, notification manager, and the like.
The window manager is used for managing window programs. The window manager can obtain the size of the display screen, judge whether a status bar exists, lock the screen, intercept the screen and the like.
Content providers are used to store and retrieve data and make it accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.
The view system includes visual controls such as controls to display text, controls to display pictures, and the like. The view system may be used to build applications. The display interface may be composed of one or more views. For example, the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
The phone manager is used to provide communication functions of the electronic device 100. Such as management of call status (including on, off, etc.).
The resource manager provides various resources for the application, such as localized strings, icons, pictures, layout files, video files, and the like.
The notification manager enables the application to display notification information in the status bar, can be used to convey notification-type messages, can disappear automatically after a short dwell, and does not require user interaction. Such as a notification manager used to inform download completion, message alerts, etc. The notification manager may also be a notification that appears in the form of a chart or scroll bar text at the top status bar of the system, such as a notification of a background running application, or a notification that appears on the screen in the form of a dialog window. For example, prompting text information in the status bar, sounding a prompt tone, vibrating the electronic device, flashing an indicator light, etc.
The Android Runtime comprises a core library and a virtual machine. The Android runtime is responsible for scheduling and managing an Android system.
The core library comprises two parts: one part is a function which needs to be called by java language, and the other part is a core library of android.
The application layer and the application framework layer run in a virtual machine. And executing java files of the application program layer and the application program framework layer into a binary file by the virtual machine. The virtual machine is used for performing the functions of object life cycle management, stack management, thread management, safety and exception management, garbage collection and the like.
The system library may include a plurality of functional modules. For example: surface managers (surface managers), media Libraries (Media Libraries), three-dimensional graphics processing Libraries (e.g., openGL ES), 2D graphics engines (e.g., SGL), wrong Kill, and the like.
The surface manager is used to manage the display subsystem and provide fusion of 2D and 3D layers for multiple applications.
The media library supports a variety of commonly used audio, video format playback and recording, and still image files, among others. The media library may support a variety of audio-video encoding formats, such as MPEG4, h.264, MP3, AAC, AMR, JPG, PNG, and the like.
The three-dimensional graphic processing library is used for realizing three-dimensional graphic drawing, image rendering, synthesis, layer processing and the like.
The 2D graphics engine is a drawing engine for 2D drawing.
The kernel layer is a layer between hardware and software. The inner core layer at least comprises a display driver, a camera driver, an audio driver and a sensor driver.
The modules integrated by the electronic device 100 may be stored in a computer-readable storage medium if they are implemented in the form of software functional modules and sold or used as separate products. Based on such understanding, all or part of the flow in the method of the embodiments described above can be realized by the present application, and can also be realized by hardware related to computer readable instructions, which can be stored in a computer readable storage medium, and when the computer readable instructions are executed by a processor, the steps of the above described method embodiments can be realized. Wherein the computer readable instructions comprise computer readable instruction code which may be in source code form, object code form, an executable file or some intermediate form, and the like. The computer-readable medium may include: any entity or device capable of carrying the computer readable instruction code, recording medium, U disk, removable hard disk, magnetic disk, optical disk, computer memory, read Only Memory (ROM), random Access Memory (RAM), etc.
The present embodiment also provides a computer storage medium, where computer instructions are stored, and when the computer instructions are run on an electronic device, the electronic device is caused to execute the above related method steps to implement the method for killing an application in the above embodiment.
The present embodiment further provides a computer program product, which, when running on an electronic device, causes the electronic device to execute the relevant steps described above, so as to implement the method for killing an application in the foregoing embodiments.
In addition, embodiments of the present application also provide an apparatus, which may be specifically a chip, a component or a module, and the apparatus may include a processor and a memory connected to each other; the memory is used for storing computer execution instructions, and when the device runs, the processor can execute the computer execution instructions stored in the memory, so that the chip can execute the method for killing the application in the above method embodiments.
The electronic device, the computer storage medium, the computer program product, or the chip provided in this embodiment are all configured to execute the corresponding method provided above, so that the beneficial effects achieved by the electronic device, the computer storage medium, the computer program product, or the chip may refer to the beneficial effects in the corresponding method provided above, and are not described herein again.
Through the description of the foregoing embodiments, it will be clear to those skilled in the art that, for convenience and simplicity of description, only the division of the functional modules is illustrated, and in practical applications, the above function distribution may be completed by different functional modules as needed, that is, the internal structure of the apparatus may be divided into different functional modules to complete all or part of the above described functions.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical functional division, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another device, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may be one physical unit or a plurality of physical units, that is, may be located in one place, or may be distributed in a plurality of different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit may be implemented in the form of hardware, or may also be implemented in the form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a readable storage medium. Based on such understanding, the technical solutions of the embodiments of the present application may be essentially or partially contributed to by the prior art, or all or part of the technical solutions may be embodied in the form of a software product, where the software product is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, or the like) or a processor (processor) to execute all or part of the steps of the method described in the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above description is only an embodiment of the present application, but the scope of the present application is not limited thereto, and any changes or substitutions within the technical scope of the present disclosure should be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (12)

1. A method of killing an application, the method comprising:
switching the first application to the background at a first point in time;
successively switching a first number of other applications to the foreground after the first time point; switching the first application to the foreground at a second time point after the first number of other applications are successively switched to the foreground and the first application is killed, wherein a time period between the first time point and the second time point is a first interval time within which the first application is not operated at the foreground;
switching the first application to the background at a third point in time;
switching the first number of other applications to the foreground in sequence within the duration of the first interval time from the third time point;
killing the first application within a duration of the first interval time from the third time point based on the first application being killed within the first interval time;
switching the first application to the background at a fourth point in time;
after the fourth time point, successively switching a second number of other applications to the foreground, wherein the first number is greater than the second number;
switching the first application to the foreground at a fifth time point after the second number of other applications are successively switched to the foreground and the first application is killed, wherein a time period between the fourth time point and the fifth time point is a second interval time within which the first application is not operated in the foreground;
switching the first application to the background at a sixth point in time;
successively switching the second number of other applications to the foreground within the duration of the second interval time from the sixth time point;
based on the first application being killed in the second interval time, killing at least one application running in the background from the second number of other applications within a duration of the second interval time from the sixth time point, without killing the first application.
2. The method of claim 1, wherein the first application is killed within a duration of the first interval time from the third point in time further based on the first number being greater than a preset number.
3. The method of claim 1, wherein at least one application of the second number of applications running in the background is killed, the first application is not killed, and the second number is less than a preset number for a duration of the second interval time from the sixth time point.
4. The method of claim 1, wherein the first interval time is less than a preset time period.
5. The method of claim 1, wherein the killing the first application for a duration of the first interval time from the third point in time based on the first application being killed within the first interval time comprises:
calculating a first kill score for the first application based on the first application being killed within the first interval of time;
killing the first application within a duration of the first interval time from the third time point based on the first kill score being below a first threshold.
6. The method of claim 5, wherein said calculating a first suicide score of the first application comprises:
obtaining a first score for the first application based on a duration of the first interval;
obtaining a second score for the first application based on a number of applications that are cut to foreground in the first interval; and
and calculating a first check and kill score of the first application according to the first score and the second score.
7. The method of claim 6, wherein said calculating a killing score for the first application from the first score and the second score comprises:
calculating a first challenge score for the first application according to S = Y1 x Y2 x F, wherein S represents the first challenge score; y1 represents the first score; y2 represents the second score; f represents a base score.
8. The method of claim 7, wherein Y1= a1+ b1 x T + c1 x T 2 +d1*T 3 (ii) a Wherein, a1=206.841793563214; b1= -9.00021943093018; c1=0.134347573391717; d1= -0.000689371112453592; t is equal to the duration of the first interval time, and the value range of T is (0,60)]In the unit ofThe method comprises the following steps of (1) taking minutes;
Y2=a2+b2*X+c2*X 2 +d2*X 3 (ii) a Wherein, a2=245.460539460545; b2= -47.6803759965558; c2=3.07527766351345; d2= -0.0655251611134173; x is equal to the number of applications to be switched to the foreground in the first interval, and the value range of X is [0,13 ]]。
9. The method of claim 1, wherein killing at least one of the two other applications for a duration of the second interval from the sixth time point based on the first application being killed within the second interval comprises:
calculating a second kill score for the first application based on the first application being killed within the second interval of time;
killing at least one of the two other applications, without killing the first application, for a duration of the second interval time from the sixth time point based on the second kill score exceeding a second threshold.
10. The method of any one of claims 1-9, wherein the killing the first application for a duration of the first interval from the third time point based on the first application being killed within the first interval comprises:
and based on that the first application is killed in the first interval time, determining that the residual memory of the electronic equipment is smaller than a preset value in the duration of the first interval time from the third time point, and killing the first application.
11. An electronic device comprising a processor and a memory; the memory to store instructions; the processor is configured to invoke the instructions in the memory to cause the electronic device to execute the method of killing an application according to any one of claims 1 to 10.
12. A computer-readable storage medium storing at least one instruction which, when executed by a processor, implements a method of killing an application as claimed in any one of claims 1 to 10.
CN202210854339.2A 2021-05-21 2021-05-21 Application killing method and device Pending CN115373957A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210854339.2A CN115373957A (en) 2021-05-21 2021-05-21 Application killing method and device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210854339.2A CN115373957A (en) 2021-05-21 2021-05-21 Application killing method and device
CN202110558868.3A CN113407300B (en) 2021-05-21 2021-05-21 Application false killing evaluation method and related equipment

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
CN202110558868.3A Division CN113407300B (en) 2021-05-21 2021-05-21 Application false killing evaluation method and related equipment

Publications (1)

Publication Number Publication Date
CN115373957A true CN115373957A (en) 2022-11-22

Family

ID=77679259

Family Applications (2)

Application Number Title Priority Date Filing Date
CN202210854339.2A Pending CN115373957A (en) 2021-05-21 2021-05-21 Application killing method and device
CN202110558868.3A Active CN113407300B (en) 2021-05-21 2021-05-21 Application false killing evaluation method and related equipment

Family Applications After (1)

Application Number Title Priority Date Filing Date
CN202110558868.3A Active CN113407300B (en) 2021-05-21 2021-05-21 Application false killing evaluation method and related equipment

Country Status (2)

Country Link
CN (2) CN115373957A (en)
WO (1) WO2022242412A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115373957A (en) * 2021-05-21 2022-11-22 荣耀终端有限公司 Application killing method and device

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2538327A1 (en) * 2011-06-16 2012-12-26 Samsung Electronics Co., Ltd. Adaptive Termination and Pre-Launching Policy for Improving Application Startup Time
CN110022347B (en) * 2014-11-20 2023-07-28 华为终端有限公司 Application management method and mobile terminal
EP3125503A1 (en) * 2015-07-29 2017-02-01 Telefonica Digital España, S.L.U. A method, a system and computer program products for keeping an end-to-end data connection active
CN105653323B (en) * 2015-12-28 2019-07-02 小米科技有限责任公司 Application management method and device
CN107908273B (en) * 2017-11-14 2020-07-07 Oppo广东移动通信有限公司 Application management method and device, storage medium and electronic equipment
CN108363529A (en) * 2018-03-20 2018-08-03 青岛海信移动通信技术股份有限公司 The determination method and device of the front stage operation time of Application Program Interface
CN110597451B (en) * 2018-06-12 2021-02-23 华为技术有限公司 Method for realizing virtualized cache and physical machine
CN109388947B (en) * 2018-10-30 2023-06-20 浙江解纷链数字科技有限公司 Background management method, device and computer readable storage medium
CN110221921A (en) * 2019-06-13 2019-09-10 深圳Tcl新技术有限公司 EMS memory management process, terminal and computer readable storage medium
CN111611020A (en) * 2020-04-14 2020-09-01 上海卓易科技股份有限公司 Application process searching and killing method and device for application program
CN111596971B (en) * 2020-05-14 2023-07-14 Oppo广东移动通信有限公司 Application cleaning method and device, storage medium and electronic equipment
CN112307465A (en) * 2020-10-30 2021-02-02 上海中通吉网络技术有限公司 Keep-alive pull-alive method, storage medium and equipment for coping with application program being checked and killed
CN115373957A (en) * 2021-05-21 2022-11-22 荣耀终端有限公司 Application killing method and device

Also Published As

Publication number Publication date
CN113407300A (en) 2021-09-17
CN113407300B (en) 2022-08-12
WO2022242412A1 (en) 2022-11-24

Similar Documents

Publication Publication Date Title
CN110134316B (en) Model training method, emotion recognition method, and related device and equipment
CN109766036B (en) Message processing method and electronic equipment
CN110058777B (en) Method for starting shortcut function and electronic equipment
CN113645351B (en) Application interface interaction method, electronic device and computer-readable storage medium
CN113704014B (en) Log acquisition system, method, electronic device and storage medium
CN113325941B (en) Method for displaying finger print under screen and electronic equipment
CN116564304A (en) Voice interaction method and device
WO2021218540A1 (en) Antenna power adjustment method, terminal device and storage medium
CN114650363A (en) Image display method and electronic equipment
CN113704205B (en) Log storage method, chip, electronic device and readable storage medium
CN113778641B (en) Method for controlling camera, electronic device and computer readable storage medium
CN114115512B (en) Information display method, terminal device, and computer-readable storage medium
CN113254409A (en) File sharing method, system and related equipment
CN113641271A (en) Application window management method, terminal device and computer readable storage medium
CN114995715B (en) Control method of floating ball and related device
CN111031492B (en) Call demand response method and device and electronic equipment
CN110058729B (en) Method and electronic device for adjusting sensitivity of touch detection
CN113407300B (en) Application false killing evaluation method and related equipment
CN113438366A (en) Information notification interaction method, electronic device and storage medium
CN113380240B (en) Voice interaction method and electronic equipment
CN114489469B (en) Data reading method, electronic equipment and storage medium
CN114003241A (en) Interface adaptation display method and system of application program, electronic device and medium
CN114971107A (en) Privacy risk feedback method and device and first terminal equipment
CN114828098A (en) Data transmission method and electronic equipment
CN113050864A (en) Screen capturing method and related equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination