Intelligent terminal self-checking method, device, storage medium and intelligent terminal
By determining the self-test score based on the number of background processes and startup items in the smart terminal, the target program is filtered and optimized, which solves the problem of inaccurate self-testing of smart terminals, realizes dynamic self-testing and memory optimization, and improves detection accuracy and user experience.
Patent Information
- Application Number
- CN202011184613.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-10-29
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2040-10-29
AI Technical Summary
Existing self-testing methods for smart terminals cannot achieve real-time dynamic self-testing, resulting in inaccurate test results.
A reference self-test score is determined based on the number of background processes and startup items currently running in the background of the smart terminal. When the self-test score is lower than a preset threshold, target programs are selected from the background processes for memory optimization to obtain an optimized smart terminal. The target self-test score is then determined based on the optimized state.
It enables dynamic self-testing of smart terminals, improves detection accuracy and memory utilization efficiency, reduces lag, and enhances user experience.
Smart Images

Figure CN112346929B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of smart terminal testing technology, and in particular to a smart terminal self-testing method, device, storage medium, and smart terminal. Background Technology
[0002] Nowadays, more and more smart terminals can be equipped with device self-test applications to ensure the security of smart terminal devices. However, in the traditional case, background running processes and startup items are obtained at once through the system interface. In other words, the number of background running processes and startup items in the current system can be obtained at once, rather than dynamically. Smart terminals cannot perform real-time dynamic self-tests, resulting in delayed and inaccurate test results.
[0003] The above content is only used to help understand the technical solution of the present invention and does not represent an admission that the above content is prior art. Summary of the Invention
[0004] The main objective of this invention is to provide a self-testing method, apparatus, storage medium, and smart terminal for smart terminals, aiming to solve the technical problem that the self-testing of smart terminals in the prior art is not accurate enough.
[0005] To achieve the above objectives, the present invention provides a self-testing method for a smart terminal, the method comprising the following steps:
[0006] The reference self-test score is determined based on the number of background processes currently running in the background of the smart terminal and the number of startup items currently running at boot.
[0007] When the reference self-test score is less than a preset score threshold, a target program is selected from the background running program, and the memory of the smart terminal is optimized according to the target program to obtain an optimized smart terminal.
[0008] The target self-test score is determined based on the target number of background processes running in the background of the optimized smart terminal and the target number of startup items.
[0009] The target self-test score is used as the self-test result of the smart terminal.
[0010] Optionally, before determining the reference self-test score based on the current number of background processes and startup items in the smart terminal, the method further includes:
[0011] Get the number of currently running background processes in the smart terminal;
[0012] When the number of current background processes reaches a preset threshold, the self-test function of the smart terminal is activated.
[0013] When the self-test function of the smart terminal is enabled, the current number of startup items in the smart terminal is obtained.
[0014] Optionally, determining the reference self-test score based on the current number of background processes and startup items in the smart terminal includes:
[0015] The total number of current processes is determined based on the number of background processes running in the background of the smart terminal and the number of startup items.
[0016] The running percentage of the background running program is determined based on the current number of background processes and the total number of current processes.
[0017] The reference self-test score is determined based on the aforementioned operating percentage.
[0018] Optionally, determining the reference self-test score based on the operating percentage includes:
[0019] The running percentage is matched with a preset percentage range to obtain a matching result;
[0020] The self-inspection identifier corresponding to the running percentage is determined based on the matching result;
[0021] Find the reference self-test score corresponding to the self-test identifier from the mapping table.
[0022] Optionally, the step of filtering the target program from the background running programs includes:
[0023] Obtain the runtime package name of the background running program;
[0024] Based on the name of the runtime package, multiple non-system permission programs are selected from the background running programs;
[0025] The target program is selected from the multiple non-system permission programs based on their memory usage and foreground display status.
[0026] Optionally, optimizing the memory of the smart terminal according to the target program to obtain an optimized smart terminal includes:
[0027] Determine the target quantity based on the preset self-inspection indicators;
[0028] Sort the memory usage of the background running programs by size;
[0029] Based on the sorting results and the target program, kill the target number of background running programs from the background running programs to obtain an optimized smart terminal.
[0030] Optionally, after using the target self-test score as the self-test result of the smart terminal, the method further includes:
[0031] Obtain the current memory usage of the target program;
[0032] Obtain the names of the running packages corresponding to the background programs killed during memory optimization, as well as the memory released during the process;
[0033] The currently occupied memory, the released running memory, and the target self-test score are displayed on the screen of the smart terminal.
[0034] Furthermore, to achieve the above objectives, the present invention also proposes a smart terminal self-testing device, the smart terminal self-testing device comprising:
[0035] The calculation module is used to determine the reference self-test score based on the current number of background processes of programs running in the background of the smart terminal and the current number of startup items.
[0036] The optimization module is used to filter out a target program from the background running program when the reference self-test score is less than a preset score threshold, and optimize the memory of the smart terminal according to the target program to obtain an optimized smart terminal.
[0037] The calculation module is also used to determine the target self-test score based on the target number of background processes of the background running program in the optimized smart terminal and the target number of startup items.
[0038] The output module is used to use the target self-test score as the self-test result of the smart terminal.
[0039] Furthermore, to achieve the above objectives, the present invention also proposes a smart terminal, the smart terminal comprising: a memory, a processor, and a smart terminal self-test program stored in the memory and executable on the processor, the smart terminal self-test program being configured to implement the steps of the smart terminal self-test method described above.
[0040] In addition, to achieve the above objectives, the present invention also proposes a storage medium storing a smart terminal self-test program, wherein the smart terminal self-test program, when executed by a processor, implements the steps of the smart terminal self-test method described above.
[0041] This invention determines a reference self-test score based on the current number of background processes and startup items in a smart terminal. When the reference self-test score is less than a preset threshold, a target program is selected from the background processes, and the smart terminal's memory is optimized based on the target program to obtain an optimized smart terminal. A target self-test score is determined based on the target number of background processes and startup items in the optimized smart terminal. The target self-test score is used as the self-test result of the smart terminal. By optimizing the smart terminal's memory and obtaining the optimized self-test result, dynamic self-testing of the smart terminal is achieved, improving the accuracy of the detection. Attached Figure Description
[0042] Figure 1 This is a schematic diagram of the structure of a smart terminal in the hardware operating environment involved in the embodiments of the present invention;
[0043] Figure 2 This is a flowchart illustrating the first embodiment of the smart terminal self-testing method of the present invention;
[0044] Figure 3 This is a flowchart illustrating the second embodiment of the smart terminal self-testing method of the present invention;
[0045] Figure 4 This is a flowchart illustrating the third embodiment of the smart terminal self-testing method of the present invention;
[0046] Figure 5 This is a structural block diagram of the first embodiment of the smart terminal self-testing device of the present invention.
[0047] The realization of the objective, functional features and advantages of the present invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0048] It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the scope of the invention.
[0049] Reference Figure 1 , Figure 1 This is a schematic diagram of the intelligent terminal structure of the hardware operating environment involved in the embodiments of the present invention.
[0050] like Figure 1As shown, the smart terminal may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. The communication bus 1002 is used to enable communication between these components. The user interface 1003 may include a display screen and an input unit such as a keyboard; optionally, the user interface 1003 may also include a standard wired interface or a wireless interface. The network interface 1004 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface). The memory 1005 may be a high-speed random access memory (RAM) or a stable non-volatile memory (NVM), such as a disk drive. The memory 1005 may also optionally be a storage device independent of the aforementioned processor 1001.
[0051] Those skilled in the art will understand that Figure 1 The structure shown does not constitute a limitation on the smart terminal and may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0052] like Figure 1 As shown, the memory 1005, which serves as a storage medium, may include an operating system, a network communication module, a user interface module, and a smart terminal self-test program.
[0053] exist Figure 1 In the smart terminal shown, the network interface 1004 is mainly used for data communication with the network server; the user interface 1003 is mainly used for data interaction with the user; the processor 1001 and the memory 1005 in the smart terminal of the present invention can be set in the smart terminal, and the smart terminal calls the smart terminal self-test program stored in the memory 1005 through the processor 1001 and executes the smart terminal self-test method provided in the embodiment of the present invention.
[0054] This invention provides a self-testing method for smart terminals, referring to... Figure 2 , Figure 2 This is a flowchart illustrating the first embodiment of a self-testing method for a smart terminal according to the present invention.
[0055] In this embodiment, the smart terminal self-test method includes the following steps:
[0056] Step S10: Determine the reference self-test score based on the current number of background processes of programs running in the background of the smart terminal and the current number of startup items.
[0057] It should be noted that the execution entity in this embodiment can be a processor, or other devices with the same or similar functions; this embodiment does not impose any limitations on this. The processor, located within the smart terminal, is the core of computation and control within the smart terminal, used for information processing and program execution, and capable of self-testing the smart terminal based on its internal operating information. This embodiment can also detect the smart terminal through external devices. These external devices obtain the smart terminal's operating information via the internet or other means, and then perform detection based on the obtained operating information. This embodiment uses the processor within the smart terminal as an example for explanation.
[0058] In this embodiment, the smart terminal is a type of embedded computer system device, which can be a smart large-screen device with the same functions as a computer device. Typically, during normal operation, a computer device has two types of running programs: foreground programs and background programs. Foreground programs can be viewed in the taskbar and interacted with, while background programs cannot be viewed in the taskbar but can only be viewed in the resource manager. Background programs receive user messages and notify the user. Although background programs cannot interact with the user, they still consume memory. Too many background programs can affect the normal operation of the computer device. In this embodiment, the self-test of the smart terminal mainly detects the memory usage of the running programs within the smart terminal.
[0059] In specific implementation, the background running programs in the smart terminal are detected to obtain the current number of background processes. Additionally, this embodiment also detects the startup items of the smart terminal to obtain the current number of startup items. This embodiment performs a dynamic self-check on the smart terminal. Dynamic self-check requires the self-check function to be enabled, which can be activated through a health check application installed on the smart terminal. The current number of startup items and the current number of background processes are obtained when the health check application is enabled. Startup items are programs that automatically start and run when the smart terminal boots up.
[0060] It should be noted that in this embodiment, the user can enable the self-test function of the smart terminal by touching the button, or set a preset time. When the preset time is reached, the self-test function of the smart terminal will be automatically enabled. The preset time can be set according to actual needs. The self-test function can also be enabled in other ways, and this embodiment does not limit this.
[0061] In practice, after obtaining the current number of background processes and the current number of startups, a reference self-test score can be determined based on the correspondence between the number of background processes, the number of startups, and the self-test score. For example, if the current number of background processes is X and the number of startups is Y, then the corresponding reference self-test score is A. If the current number of background processes is Z and the number of startups is Y, then the corresponding reference self-test score is B. The correspondence can be changed according to the actual situation, and this embodiment does not impose any restrictions.
[0062] Furthermore, in this embodiment, by detecting background running programs, a self-test function is automatically enabled. Specifically, before step S10, the method further includes: obtaining the current number of background processes of the background running programs in the smart terminal; when the current number of background processes reaches a preset threshold, starting the self-test function of the smart terminal; and when the self-test function of the smart terminal is enabled, obtaining the current number of startup items in the smart terminal.
[0063] It should be noted that the self-check of the smart terminal indicates that there are too many background programs running, which need to be cleaned up to free up running memory. In this embodiment, the number of current background processes is detected to determine whether to enable the self-check function. In this embodiment, the number of current background processes is detected according to a preset number threshold. The preset number threshold represents the maximum number of background programs that will not affect the running performance of the smart terminal. When the number of current background processes reaches the preset number threshold, it indicates that there are too many background programs running. At this time, the self-check function of the smart terminal is activated, and the current number of startup items in the smart terminal is also obtained.
[0064] Step S20: When the reference self-test score is less than a preset score threshold, a target program is selected from the background running program, and the memory of the smart terminal is optimized according to the target program to obtain an optimized smart terminal.
[0065] It's important to note that the reference self-test score represents the running status of various programs on the smart terminal. A lower reference self-test score indicates more background programs running, consuming more memory and potentially causing lag or stuttering on the smart terminal, thus affecting the running status of individual programs. Therefore, the lower the reference self-test score, the worse the running status of each program. The preset score threshold represents the minimum self-test score required for each program to run normally. When the reference self-test score is lower than the preset score threshold, it indicates that the smart terminal's current memory is low, causing various programs on the smart terminal to run abnormally, such as lag or unresponsiveness. In this case, memory optimization of the smart terminal is necessary.
[0066] It is understandable that when optimizing memory for a smart terminal, background programs are killed to free up memory. The target program is the program that the user is currently using. Killing the target program when optimizing memory for a smart terminal will obviously affect the user experience, which is obviously unreasonable in practice. Therefore, it is necessary to keep the target program and kill other background programs that consume a lot of memory.
[0067] Step S30: Determine the target self-test score based on the target number of background processes running in the background of the optimized smart terminal and the target number of startup items.
[0068] Understandably, after optimizing the memory of a smart terminal, in addition to killing some background running programs, the startup items of the smart terminal will also be modified to reduce the startup efficiency and improve the startup speed. After optimization, it is necessary to re-obtain the target number of background processes and the target number of startups, and then determine the target self-test score based on the same method as above.
[0069] Step S40: Use the target self-test score as the self-test result of the smart terminal.
[0070] It is understandable that the self-test of a smart terminal is to monitor the running status and memory usage of the running program. The target self-test score corresponds to the running status and memory usage of the running program, and the target self-test score is the self-test result.
[0071] This embodiment determines a reference self-test score based on the current number of background processes and startup items in the smart terminal. When the reference self-test score is less than a preset score threshold, a target program is selected from the background processes, and the smart terminal's memory is optimized based on the target program to obtain an optimized smart terminal. A target self-test score is determined based on the target number of background processes and startup items in the optimized smart terminal. The target self-test score is used as the self-test result of the smart terminal. By optimizing the smart terminal's memory and obtaining the optimized self-test result, dynamic self-testing of the smart terminal is achieved, improving the accuracy of the detection.
[0072] refer to Figure 3 , Figure 3 This is a flowchart illustrating a second embodiment of a self-testing method for a smart terminal according to the present invention.
[0073] Based on the first embodiment described above, step S10 in the self-test of the smart terminal in this embodiment includes:
[0074] Step S101: Determine the total number of current processes based on the number of background processes of programs running in the background of the smart terminal and the number of startup items.
[0075] It should be noted that the sum of the current number of background processes and the current number of startup items is the total number of current processes. Background processes and startup items have corresponding runtime package names, but one runtime package name corresponds to one or more processes.
[0076] Step S102: Determine the running percentage of the background running program based on the current number of background processes and the total number of current processes.
[0077] In specific implementation, the running percentage of background programs can be obtained based on the current number of background processes and the total number of current processes. In this embodiment, the running percentage is obtained by proportionally calculating the current number of background processes and the total number of current processes. For example, if the current number of background processes is A and the total number of current processes is B, the running percentage of the background programs is A / B.
[0078] Step S103: Determine the reference self-test score based on the running percentage.
[0079] In practice, the smart terminal stores the correspondence between the running percentage and the reference self-test score. The corresponding reference self-test score can be determined according to different running percentages. For example, when the running percentage is 1%, the corresponding reference self-test score is S1, and when the running percentage is 2%, the corresponding reference self-test score is S2.
[0080] Further, step S103 specifically includes: matching the running percentage with a preset percentage range to obtain a matching result; determining the self-test identifier corresponding to the running percentage based on the matching result; and searching for the reference self-test score corresponding to the self-test identifier from the mapping relationship table.
[0081] It should be noted that after obtaining the operating percentage, it is matched with a preset percentage range. The preset percentage range can be set according to the actual situation. For example, the preset percentage range can be set to 1%~3%, 3%~5%, 5%~8%, 8%~12%, 12%~15%, and greater than 15%. The health check mark corresponding to 1%~3% is 1, 3%~5% is 2, 5%~8% is 4, 8%~12% is 6, 12%~15% is 8, and greater than 15% is 8. The identifier is 10. The mapping table shows that the physical examination score corresponding to physical examination identifier 1 is 99, the physical examination score corresponding to physical examination identifier 2 is 98, the physical examination score corresponding to physical examination identifier 4 is 96, the physical examination score corresponding to physical examination identifier 6 is 94, the physical examination score corresponding to physical examination identifier 8 is 92, and the physical examination score corresponding to physical examination identifier 10 is 90. Assuming that the operating percentage is 2%, according to the physical examination identifier 1 corresponding to the operating percentage of 2%, the reference physical examination score can be obtained as 99. Assuming that the operating percentage is 8%, according to the physical examination identifier 6 corresponding to the operating percentage of 8%, the reference physical examination score can be obtained as 94.
[0082] This embodiment determines the total number of current processes based on the number of current background processes of the running programs in the smart terminal and the number of current startup items; it determines the running percentage of each background process based on the number of current background processes and the total number of current processes; it matches the running percentage with a preset ratio range to obtain a matching result; it determines the self-test identifier corresponding to the running percentage based on the matching result; it searches for the reference self-test score corresponding to the self-test identifier in the mapping table; it determines the total number of current processes based on the number of current background processes and the number of current startup items, obtains the running percentage based on the number of current background processes and the total number of current processes, and determines the reference self-test score based on the running percentage, which can more accurately obtain the reference self-test score when the self-test function is enabled, thus improving the accuracy of detection.
[0083] refer to Figure 4 , Figure 4 This is a flowchart illustrating a third embodiment of a self-testing method for a smart terminal according to the present invention.
[0084] Based on the first embodiment described above, step S20 in this embodiment includes:
[0085] Step S2010: Obtain the runtime package name of the background running program.
[0086] It should be noted that background programs all have corresponding runtime package names, which are used to distinguish whether a background program belongs to a system permission program or a non-system permission program.
[0087] Step S2011: Select multiple non-system permission programs from the background running programs according to the name of the running package.
[0088] Understandably, when a computer device is powered on, many background programs are system applications, i.e., system-permission programs. These system-permission programs usually play an auxiliary role and consume very little memory, such as sound card programs, Bluetooth programs, and network card programs. In contrast to system-permission programs are non-system-permission programs. These background programs are usually started by the user. Some background programs are minimized to run in the background while the foreground program is running, while others run in the background simultaneously with the foreground program. Non-system-permission programs do not play an auxiliary role and do not affect the normal operation of the smart device. Furthermore, non-system-permission programs typically consume more memory, and memory optimization targets these non-system-permission programs.
[0089] Step S2012: Select the target program from the multiple non-system permission programs based on the memory usage and foreground display status of each non-system permission program.
[0090] In practice, the background program with the largest memory usage is selected from the background programs based on the memory usage of non-system privilege programs. At the same time, it is also necessary to determine whether the background program has a corresponding foreground display based on the foreground display status. The background program that meets both the criteria of having the largest memory usage and having a corresponding foreground display is the target program.
[0091] Furthermore, step S20 also includes:
[0092] Step S2020: Determine the target quantity based on the preset self-inspection indicator.
[0093] It should be noted that when the reference self-test score is less than the preset score threshold, it indicates that the background running program is consuming a large amount of memory, requiring optimization. The optimization aims to reduce the running percentage of the background program. There is a correlation between the self-test flag and the running percentage; based on the self-test flag, the required running percentage for the background program can be determined. In this embodiment, the preset self-test flag can be set according to actual needs. For example, if the preset self-test flag is 1, the running percentage range corresponding to self-test flag 1 is 1% to 3%, meaning the running percentage of the background program needs to be optimized to within the range of 1% to 3%. After obtaining the running percentage, the target number can be calculated based on the running percentage. The target number is the number of background running processes that need to be killed during memory optimization.
[0094] Step S2021: Sort the memory usage of the background running programs by size.
[0095] It is understandable that memory optimization needs to follow certain rules. In this embodiment, memory optimization first kills background programs that consume a lot of memory. Therefore, the memory consumption of background programs needs to be sorted in order of size.
[0096] Step S2022: Kill the target number of background running programs from the background running programs according to the sorting result and the target program to obtain the optimized smart terminal.
[0097] In practice, the target program is also the program that the user is currently using. Killing the target program along with other background programs would greatly affect the user's operation and reduce the user experience, which is obviously unreasonable. Therefore, when optimizing memory, the target program should be retained according to the runtime package name corresponding to the target program, and the target number of background programs should be killed in descending order.
[0098] Furthermore, after step 40, the method further includes: obtaining the current memory occupied by the target program; obtaining the name of the runtime package corresponding to the background running program killed during memory optimization, and the released runtime memory; and displaying the current memory occupied, the released runtime memory, and the target self-test score on the display screen of the smart terminal.
[0099] It should be noted that after the smart terminal completes its self-test, the results also need to be displayed to visualize them. In this embodiment, the smart terminal is equipped with a display screen. After optimization, the current memory usage of the target program is detected and obtained. Simultaneously, the names of the running packages of the background programs killed during the optimization process are obtained, as well as the memory released during memory optimization. Finally, the current memory usage, released memory, and target self-test score of the target program are visualized on the smart terminal's display screen. The visualization can use bar charts or pie charts, allowing users to clearly understand the self-test results of the smart terminal and facilitating real-time monitoring of the background programs running on the smart terminal.
[0100] This embodiment obtains the runtime package name of the background running program; filters out multiple non-system permission programs from the background running program based on the runtime package name; filters out target programs from the multiple non-system permission programs based on the memory usage and foreground display status of each non-system permission program. The memory usage and foreground display status accurately filter target programs from the background running program, and the target number is determined based on a preset self-check flag; the memory usage of the background running programs is sorted by size; and the target number of background running programs are killed based on the sorting result and the target programs, resulting in an optimized smart terminal. By retaining target programs, memory optimization becomes more user-friendly, and memory optimization can be effectively performed when the smart terminal's performance is poor.
[0101] Furthermore, this embodiment of the invention also proposes a storage medium storing a smart terminal self-test program, which, when executed by a processor, implements the steps of the smart terminal self-test method described above.
[0102] like Figure 5 As shown, the smart terminal self-testing device proposed in this embodiment of the invention includes:
[0103] The calculation module 10 is used to determine the reference self-test score based on the current number of background processes of the background running programs in the smart terminal and the current number of startup items.
[0104] Optimization module 20 is used to filter out target programs from the background running programs when the reference self-test score is less than a preset score threshold, and optimize the memory of the smart terminal according to the target programs to obtain an optimized smart terminal.
[0105] The calculation module 10 is also used to determine the target self-test score based on the target number of background processes of the background running program in the optimized smart terminal and the target number of startup items.
[0106] The output module 30 is used to use the target self-test score as the self-test result of the smart terminal.
[0107] This embodiment determines a reference self-test score based on the current number of background processes and startup items in the smart terminal. When the reference self-test score is less than a preset score threshold, a target program is selected from the background processes, and the smart terminal's memory is optimized based on the target program to obtain an optimized smart terminal. A target self-test score is determined based on the target number of background processes and startup items in the optimized smart terminal. The target self-test score is used as the self-test result of the smart terminal. By optimizing the smart terminal's memory and obtaining the optimized self-test result, dynamic self-testing of the smart terminal is achieved, improving the accuracy of the detection.
[0108] In one embodiment, the smart terminal self-test device further includes: a startup module;
[0109] The startup module is used to obtain the current number of background processes of the programs running in the background of the smart terminal; when the current number of background processes reaches a preset threshold, the self-test function of the smart terminal is started; when the self-test function of the smart terminal is started, the current number of startup items in the smart terminal is obtained.
[0110] In one implementation, the calculation module 10 is further configured to determine the total number of current processes based on the current number of background processes of the background running program in the smart terminal and the current number of startup items; determine the running percentage of the background running program based on the current number of background processes and the total number of current processes; and determine a reference self-test score based on the running percentage.
[0111] In one implementation, the calculation module 10 is further configured to match the running percentage with a preset percentage range to obtain a matching result; determine the self-test identifier corresponding to the running percentage based on the matching result; and search for the reference self-test score corresponding to the self-test identifier from the mapping relationship table.
[0112] In one embodiment, the optimization module 20 is further configured to obtain the runtime package name of the background running program; filter out multiple non-system permission programs from the background running program according to the runtime package name; and filter out a target program from the multiple non-system permission programs according to the memory occupied and foreground display status of each non-system permission program.
[0113] In one embodiment, the optimization module 20 is further configured to determine a target number based on a preset self-test identifier; sort the memory occupied by the background running programs by size; and kill the target number of background running programs from the background running programs according to the sorting result and the target program, so as to obtain an optimized smart terminal.
[0114] In one embodiment, the smart terminal self-testing device further includes: a display module;
[0115] The display module is used to obtain the current memory occupied by the target program; obtain the name of the runtime package corresponding to the background running program killed during memory optimization, and the released runtime memory; and display the current memory occupied, the released runtime memory, and the target self-test score through the display screen of the smart terminal.
[0116] It should be understood that the above are merely illustrative examples and do not constitute any limitation on the technical solutions of the present invention. In specific applications, those skilled in the art can make settings as needed, and the present invention does not impose any restrictions on this.
[0117] It should be noted that the workflow described above is merely illustrative and does not limit the scope of protection of this invention. In practical applications, those skilled in the art can select some or all of the workflow to achieve the purpose of this embodiment according to actual needs, and no restrictions are imposed here.
[0118] In addition, for technical details not described in detail in this embodiment, please refer to the smart terminal self-test method provided in any embodiment of the present invention, which will not be repeated here.
[0119] Furthermore, it should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or system. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or system that includes that element.
[0120] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0121] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as read-only memory (ROM) / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of the present invention.
[0122] The above are merely preferred embodiments of the present invention and do not limit the scope of the patent. Any equivalent structural or procedural transformations made based on the description and drawings of the present invention, or direct or indirect applications in other related technical fields, are similarly included within the scope of patent protection of the present invention.
Claims
1. A self-testing method for a smart terminal, characterized in that, The smart terminal self-test method includes: The reference self-test score is determined based on the number of background processes currently running in the background of the smart terminal and the number of startup items currently running at boot. When the reference self-test score is less than a preset score threshold, a target program is selected from the background running program, and the memory of the smart terminal is optimized according to the target program to obtain an optimized smart terminal. The target self-test score is determined based on the target number of background processes running in the background of the optimized smart terminal and the target number of startup items. The target self-test score is used as the self-test result of the smart terminal; Before determining the reference self-test score based on the current number of background processes and startup items in the smart terminal, the process also includes: Get the number of currently running background processes in the smart terminal; When the number of current background processes reaches a preset threshold, the self-test function of the smart terminal is activated. When the self-test function of the smart terminal is enabled, the current number of startup items in the smart terminal is obtained.
2. The self-testing method for intelligent terminals as described in claim 1, characterized in that, The determination of the reference self-test score based on the current number of background processes running in the background of the smart terminal and the current number of startup items includes: The total number of current processes is determined based on the number of background processes running in the background of the smart terminal and the number of startup items. The running percentage of the background running program is determined based on the current number of background processes and the total number of current processes. The reference self-test score is determined based on the aforementioned operating percentage.
3. The self-testing method for intelligent terminals as described in claim 2, characterized in that, The determination of the reference self-test score based on the operating percentage includes: The running percentage is matched with a preset percentage range to obtain a matching result; The self-inspection identifier corresponding to the running percentage is determined based on the matching result; Find the reference self-test score corresponding to the self-test identifier from the mapping table.
4. The self-testing method for intelligent terminals as described in claim 1, characterized in that, The step of filtering the target program from the background running program includes: Obtain the runtime package name of the background running program; Based on the name of the runtime package, multiple non-system permission programs are selected from the background running programs; The target program is selected from the multiple non-system permission programs based on their memory usage and foreground display status.
5. The self-testing method for intelligent terminals as described in claim 1, characterized in that, The step of optimizing the memory of the smart terminal according to the target program to obtain an optimized smart terminal includes: Determine the target quantity based on the preset self-inspection indicators; Sort the memory usage of the background running programs by size; Based on the sorting results and the target program, kill the target number of background running programs from the background running programs to obtain an optimized smart terminal.
6. The self-testing method for a smart terminal as described in any one of claims 1 to 5, characterized in that, After using the target self-test score as the self-test result of the smart terminal, the method further includes: Obtain the current memory usage of the target program; Obtain the names of the running packages corresponding to the background programs killed during memory optimization, as well as the memory released during the process; The currently occupied memory, the released running memory, and the target self-test score are displayed on the screen of the smart terminal.
7. A self-testing device for a smart terminal, characterized in that, The intelligent terminal self-testing device includes: The calculation module is used to determine the reference self-test score based on the current number of background processes of programs running in the background of the smart terminal and the current number of startup items. The optimization module is used to filter out a target program from the background running program when the reference self-test score is less than a preset score threshold, and optimize the memory of the smart terminal according to the target program to obtain an optimized smart terminal. The calculation module is also used to determine the target self-test score based on the target number of background processes of the background running program in the optimized smart terminal and the target number of startup items. The output module is used to use the target self-test score as the self-test result of the smart terminal; The intelligent terminal self-test device also includes: a startup module; The startup module is used to obtain the current number of background processes of the programs running in the background of the smart terminal; when the current number of background processes reaches a preset threshold, the self-test function of the smart terminal is started; when the self-test function of the smart terminal is started, the current number of startup items in the smart terminal is obtained.
8. A smart terminal, characterized in that, The smart terminal includes: a memory, a processor, and a smart terminal self-test program stored in the memory and executable on the processor, wherein the smart terminal self-test program is configured to implement the steps of the smart terminal self-test method as described in any one of claims 1 to 6.
9. A storage medium, characterized in that, The storage medium stores a smart terminal self-test program, which, when executed by a processor, implements the steps of the smart terminal self-test method as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Self-service terminal equipment, health condition monitoring method and device, and storage medium
CN107862811A
Method and terminal device for controlling background application
US20160062792A1