Nothing Special   »   [go: up one dir, main page]

CN109995930A - Process processing method and device, electronic equipment and computer readable storage medium - Google Patents

Process processing method and device, electronic equipment and computer readable storage medium Download PDF

Info

Publication number
CN109995930A
CN109995930A CN201711484459.3A CN201711484459A CN109995930A CN 109995930 A CN109995930 A CN 109995930A CN 201711484459 A CN201711484459 A CN 201711484459A CN 109995930 A CN109995930 A CN 109995930A
Authority
CN
China
Prior art keywords
sim card
sim
electric quantity
electronic device
card
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
CN201711484459.3A
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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201711484459.3A priority Critical patent/CN109995930A/en
Publication of CN109995930A publication Critical patent/CN109995930A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3206Monitoring of events, devices or parameters that trigger a change in power modality
    • G06F1/3212Monitoring battery levels, e.g. power saving mode being initiated when battery voltage goes below a certain level
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3234Power saving characterised by the action undertaken
    • G06F1/3287Power saving characterised by the action undertaken by switching off individual functional units in the computer system
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72454User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to context-related or environment-related conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. Transmission Power Control [TPC] or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0261Power saving arrangements in terminal devices managing power supply demand, e.g. depending on battery level
    • H04W52/0274Power saving arrangements in terminal devices managing power supply demand, e.g. depending on battery level by switching on or off the equipment or parts thereof
    • H04W52/0277Power saving arrangements in terminal devices managing power supply demand, e.g. depending on battery level by switching on or off the equipment or parts thereof according to available power supply, e.g. switching off when a low battery condition is detected
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W52/00Power management, e.g. Transmission Power Control [TPC] or power classes
    • H04W52/02Power saving arrangements
    • H04W52/0209Power saving arrangements in terminal devices
    • H04W52/0261Power saving arrangements in terminal devices managing power supply demand, e.g. depending on battery level
    • H04W52/0274Power saving arrangements in terminal devices managing power supply demand, e.g. depending on battery level by switching on or off the equipment or parts thereof
    • H04W52/028Power saving arrangements in terminal devices managing power supply demand, e.g. depending on battery level by switching on or off the equipment or parts thereof switching on or off only a part of the equipment circuit blocks
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • Environmental & Geological Engineering (AREA)
  • Human Computer Interaction (AREA)
  • Telephone Function (AREA)

Abstract

本申请涉及一种进程处理方法和装置、电子设备、计算机可读存储介质,检测电子设备的剩余电量,将电子设备中预先安装了至少两张用户身份识别SIM卡。当电子设备的剩余电量小于第一设定电量阈值时,则从至少两张用户身份识别SIM卡中选出第一SIM卡,将第一SIM卡作为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。从至少两张用户身份识别SIM卡中获取除去第一SIM卡之外的第二SIM卡,对第二SIM卡的部分进程进行冻结。因为对第二SIM卡的部分进程进行了冻结,从而在一定程度上降低耗电量,延长电子设备的续航时长。

The present application relates to a process processing method and device, an electronic device, and a computer-readable storage medium, which detects the remaining power of an electronic device and pre-installs at least two user identity identification SIM cards in the electronic device. When the remaining power of the electronic device is less than a first set power threshold, a first SIM card is selected from at least two user identity identification SIM cards, and the first SIM card is used as a SIM card for the electronic device during a time period when the remaining power of the electronic device is less than the first set power threshold. A second SIM card other than the first SIM card is obtained from at least two user identity identification SIM cards, and some processes of the second SIM card are frozen. Because some processes of the second SIM card are frozen, power consumption is reduced to a certain extent, and the battery life of the electronic device is extended.

Description

进程处理方法和装置、电子设备、计算机可读存储介质Process processing method and apparatus, electronic device, and computer-readable storage medium

技术领域technical field

本申请涉及计算机技术领域,特别是涉及一种进程处理方法和装置、电子设备、计算机可读存储介质。The present application relates to the field of computer technology, and in particular, to a process processing method and apparatus, an electronic device, and a computer-readable storage medium.

背景技术Background technique

随着电子技术的发展,电子设备中安装的系统应用和第三方应用越来越多。越来越多的应用在后台中运行,使得电子设备的耗电量显著增大。随着耗电量的显著增大,使得电子设备的续航时长越来越短。双卡双待电子设备,因为其可以安装两张用户身份识别SIM卡,方便有多张卡的用户同时进行使用。但是因为在一个电子设备中同时支持两张用户身份识别SIM卡的网络通信,所以双卡双待手机的耗电量就会更大,使得双卡双待手机的续航时长变得更短。With the development of electronic technology, more and more system applications and third-party applications are installed in electronic devices. More and more applications are running in the background, causing the power consumption of electronic devices to increase significantly. With the significant increase in power consumption, the battery life of electronic devices is getting shorter and shorter. The dual-card dual-standby electronic device, because it can install two user identification SIM cards, is convenient for users with multiple cards to use at the same time. However, because the network communication of two user identification SIM cards is supported in one electronic device at the same time, the power consumption of the dual-card dual-standby mobile phone will be greater, and the battery life of the dual-card dual-standby mobile phone will become shorter.

发明内容SUMMARY OF THE INVENTION

本申请实施例提供一种进程处理方法和装置、电子设备、计算机可读存储介质,可以延长续航时长。Embodiments of the present application provide a process processing method and apparatus, an electronic device, and a computer-readable storage medium, which can prolong the battery life.

一种进程处理方法,包括:A process processing method, including:

检测电子设备的剩余电量,所述电子设备中预先安装了至少两张用户身份识别SIM卡;Detecting the remaining power of the electronic device, where at least two user identification SIM cards are pre-installed in the electronic device;

当所述电子设备的剩余电量小于第一设定电量阈值时,则根据SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡,将所述第一SIM卡设置为所述电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡;When the remaining power of the electronic device is less than the first set power threshold, a first SIM card is selected from at least two user identification SIM cards according to the SIM card usage habits, and the first SIM card is set to The SIM card used by the electronic device in the time period when the remaining power of the electronic device is less than the first set power threshold;

从所述至少两张用户身份识别SIM卡中获取除所述第一SIM卡之外的第二SIM卡,对所述第二SIM卡的部分进程进行冻结。A second SIM card other than the first SIM card is obtained from the at least two user identification SIM cards, and a part of the process of the second SIM card is frozen.

一种进程处理装置,所述装置包括:A process processing device, the device includes:

剩余电量检测模块,用于检测电子设备的剩余电量,所述电子设备中预先安装了至少两张用户身份识别SIM卡;a remaining power detection module for detecting the remaining power of an electronic device, wherein at least two user identification SIM cards are pre-installed in the electronic device;

第一SIM卡选择模块,用于当所述电子设备的剩余电量小于第一设定电量阈值时,则根据SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡,将所述第一SIM卡设置为所述电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡;The first SIM card selection module is used to select the first SIM card from at least two user identification SIM cards according to the usage habits of the SIM card when the remaining power of the electronic device is less than the first set power threshold, and select the first SIM card. The first SIM card is set as the SIM card used by the electronic device in the time period when the remaining power of the electronic device is less than the first set power threshold;

进程冻结模块,用于从所述至少两张用户身份识别SIM卡中获取除所述第一SIM卡之外的第二SIM卡,对所述第二SIM卡的部分进程进行冻结。A process freezing module, configured to obtain a second SIM card other than the first SIM card from the at least two user identity identification SIM cards, and freeze part of the processes of the second SIM card.

一种电子设备,包括存储器及处理器,所述存储器中储存有计算机程序,所述指令被所述处理器执行时,使得所述处理器执行如上所述的进程处理方法的步骤。An electronic device includes a memory and a processor, wherein a computer program is stored in the memory, and when the instructions are executed by the processor, the processor executes the steps of the above-mentioned process processing method.

一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现如上所述的进程处理方法的步骤。A computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, implements the steps of the above-mentioned process processing method.

上述进程处理方法和装置、电子设备、计算机可读存储介质,检测电子设备的剩余电量,将电子设备中预先安装了至少两张用户身份识别SIM卡。当电子设备的剩余电量小于第一设定电量阈值时,则根据SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡,将第一SIM卡作为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。从至少两张用户身份识别SIM卡中获取除去第一SIM卡之外的第二SIM卡,对第二SIM卡的部分进程进行冻结。当电子设备的剩余电量小于第一设定电量阈值时,选择出第一SIM卡作为电子设备的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡,而将除去第一SIM卡之外其他的SIM卡的部分进程进行冻结。因为对除去第一SIM卡之外其他的SIM卡的部分进程进行了冻结,从而在一定程度上降低了耗电量,延长了电子设备的续航时长。由于对第二SIM卡只是部分冻结所以也不会影响用户对于同时使用多张SIM卡的需求。The above-mentioned process processing method and device, electronic device, and computer-readable storage medium detect the remaining power of the electronic device, and pre-install at least two user identification SIM cards in the electronic device. When the remaining power of the electronic device is less than the first set power threshold, the first SIM card is selected from at least two user identification SIM cards according to the usage habits of the SIM card, and the first SIM card is used as the remaining power of the electronic device. The SIM card used in the time period when the power is less than the first set power threshold. A second SIM card other than the first SIM card is obtained from at least two user identification SIM cards, and part of the process of the second SIM card is frozen. When the remaining power of the electronic device is less than the first set power threshold, the first SIM card is selected as the SIM card used in the time period when the remaining power of the electronic device is less than the first set power threshold, and the first SIM card will be removed. Part of the process of other SIM cards is frozen. Because some processes of other SIM cards except the first SIM card are frozen, power consumption is reduced to a certain extent, and the battery life of the electronic device is prolonged. Since the second SIM card is only partially frozen, the user's demand for using multiple SIM cards at the same time will not be affected.

附图说明Description of drawings

为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the accompanying drawings required for the description of the embodiments or the prior art. Obviously, the drawings in the following description are only These are some embodiments of the present application. For those of ordinary skill in the art, other drawings can also be obtained based on these drawings without any creative effort.

图1为一个实施例中电子设备的内部结构图;1 is an internal structure diagram of an electronic device in one embodiment;

图2为一个实施例中电子设备中的系统的部分框架示意图;FIG. 2 is a partial frame schematic diagram of a system in an electronic device in one embodiment;

图3为一个实施例中进程处理方法的流程图;3 is a flowchart of a process processing method in one embodiment;

图4为在电子设备上显示SIM卡冻结提示信息的界面示意图;Fig. 4 is the interface schematic diagram that displays SIM card freezing prompt information on electronic equipment;

图5为图3中对第二SIM卡的部分进程进行冻结方法的流程图;5 is a flowchart of a method for freezing part of the process of the second SIM card in FIG. 3;

图6为图3中选出第一SIM卡方法的流程图;Fig. 6 is the flow chart of selecting the first SIM card method in Fig. 3;

图7为又一个实施例中进程处理方法的流程图;7 is a flowchart of a process processing method in yet another embodiment;

图8为一个实施例中进程处理方法的一个具体实施例的流程图;8 is a flowchart of a specific embodiment of a process processing method in an embodiment;

图9为一个实施例中进程处理装置的结构示意图;9 is a schematic structural diagram of a process processing apparatus in an embodiment;

图10为图9中进程冻结模块的结构示意图;Fig. 10 is the structural representation of the process freezing module in Fig. 9;

图11为又一个实施例中进程处理装置的结构示意图;11 is a schematic structural diagram of a process processing apparatus in another embodiment;

图12为一个实施例中提供的电子设备相关的手机的部分结构的框图。FIG. 12 is a block diagram of a partial structure of a mobile phone related to an electronic device provided in an embodiment.

具体实施方式Detailed ways

为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solutions and advantages of the present application more clearly understood, the present application will be described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application.

图1为一个实施例中电子设备的内部结构示意图。如图1所示,该电子设备包括通过系统总线连接的处理器、存储器和网络接口。其中,该处理器用于提供计算和控制能力,支撑整个电子设备的运行。存储器用于存储数据、程序等,存储器上存储至少一个计算机程序,该计算机程序可被处理器执行,以实现本申请实施例中提供的适用于电子设备的进程处理方法。存储器可包括磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等非易失性存储介质,或随机存储记忆体(Random-Access-Memory,RAM)等。例如,在一个实施例中,存储器包括非易失性存储介质及内存储器。非易失性存储介质存储有操作系统和计算机程序。该计算机程序可被处理器所执行,以用于实现以下各个实施例所提供的一种进程处理方法。内存储器为非易失性存储介质中的操作系统计算机程序提供高速缓存的运行环境。网络接口可以是以太网卡或无线网卡等,用于与外部的电子设备进行通信。该电子设备可以是手机、平板电脑或者个人数字助理或穿戴式设备等。FIG. 1 is a schematic diagram of the internal structure of an electronic device in one embodiment. As shown in FIG. 1, the electronic device includes a processor, a memory and a network interface connected through a system bus. Among them, the processor is used to provide computing and control capabilities to support the operation of the entire electronic device. The memory is used for storing data, programs, etc., and at least one computer program is stored in the memory, and the computer program can be executed by the processor to implement the process processing method applicable to the electronic device provided in the embodiments of the present application. The memory may include a non-volatile storage medium such as a magnetic disk, an optical disk, and a read-only memory (Read-Only Memory, ROM), or a random-access-memory (Random-Access-Memory, RAM) and the like. For example, in one embodiment, the memory includes a non-volatile storage medium and internal memory. The nonvolatile storage medium stores an operating system and a computer program. The computer program can be executed by the processor to implement a process processing method provided by the following embodiments. Internal memory provides a cached execution environment for operating system computer programs in non-volatile storage media. The network interface can be an Ethernet card or a wireless network card, etc., and is used to communicate with external electronic devices. The electronic device may be a mobile phone, a tablet computer, a personal digital assistant or a wearable device, and the like.

在一个实施例中,如图2所示,提供了一种电子设备的部分架构图。其中,该电子设备的架构系统中包括JAVA空间层210、本地框架层220以及内核(Kernel)空间层230。JAVA空间层上可包含冻结管理应用212,电子设备可通过该冻结管理应用212来实现对各个应用的冻结策略,对后台耗电的相关应用做冻结操作。本地框架层220中包含资源优先级和限制管理模块222和平台冻结管理模块224。电子设备可通过资源优先级和限制管理模块222实时维护不同的应用处于不同优先级和不同资源的组织中,并根据上层的需求来调整应用程序的资源组别从而达到优化性能,节省功耗的作用。电子设备可通过平台冻结管理模块224将后台可以冻结的任务按照进入冻结时间的长短,分配到对应预设的不同层次的冻结层,可选地,该冻结层可包括三个,分别是:CPU限制睡眠模式、CPU冻结睡眠模式、进程深度冻结模式。In one embodiment, as shown in FIG. 2 , a partial architecture diagram of an electronic device is provided. The architecture system of the electronic device includes a JAVA space layer 210 , a local framework layer 220 and a kernel space layer 230 . A freezing management application 212 may be included on the JAVA space layer, and the electronic device may implement a freezing strategy for each application through the freezing management application 212, and perform a freezing operation on related applications that consume power in the background. The native framework layer 220 includes a resource priority and restriction management module 222 and a platform freeze management module 224. The electronic device can maintain the organization of different applications in different priorities and different resources in real time through the resource priority and limit management module 222, and adjust the resource groups of the application programs according to the needs of the upper layer to optimize performance and save power consumption. effect. The electronic device can allocate the tasks that can be frozen in the background to the corresponding preset freezing layers of different levels according to the length of the entry freezing time through the platform freezing management module 224. Optionally, the freezing layers can include three, respectively: CPU Limit sleep mode, CPU freeze sleep mode, process deep freeze mode.

其中,CPU限制睡眠模式是指对相关进程所占用的CPU资源进行限制,使相关进程占用较少的CPU资源,将空余的CPU资源向其它未被冻结的进程倾斜,限制了对CPU资源的占用,也相应限制了进程对网络资源以及I/O接口资源的占用;CPU冻结睡眠模式是指禁止相关进程使用CPU,而保留对内存的占用,当禁止使用CPU资源时,相应的网络资源以及I/O接口资源也被禁止使用;进程深度冻结模式是指除禁止使用CPU资源之外,进一步对相关进程所占用的内存资源进行回收,回收的内存可供其它进程使用。Among them, the CPU-limited sleep mode refers to restricting the CPU resources occupied by related processes, so that the related processes occupy less CPU resources, and the spare CPU resources are tilted to other processes that are not frozen, so as to limit the occupation of CPU resources. , which also limits the occupation of network resources and I/O interface resources by the process; the CPU freeze sleep mode refers to prohibiting related processes from using the CPU, while retaining the occupation of memory. When the use of CPU resources is prohibited, the corresponding network resources and I/O interface resources The use of /O interface resources is also prohibited; the process deep freeze mode means that in addition to prohibiting the use of CPU resources, the memory resources occupied by related processes are further recovered, and the recovered memory can be used by other processes.

内核空间层230中包括UID管理模块231、Cgroup模块232、Binder管控模块233、进程内存回收模块234以及冻结超时退出模块235。其中,UID管理模块231用于实现基于应用的用户身份标识(User Identifier,UID)来管理第三方应用的资源或进行冻结。相比较于基于进程身份标识(Process Identifier,PID)来进行进程管控,通过UID更便于统一管理一个用户的应用的资源。Cgroup模块232用于提供一套完善的中央处理器(CentralProcessing Unit,CPU)、CPUSET、内存(memory)、输入/输出(input/output,I/O)和Net相关的资源限制机制。Binder管控模块233用于实现后台binder通信的优先级的控制。其中,本地框架层220的接口模块包含开发给上层的binder接口,上层的框架或者应用通过提供的binder接口来发送资源限制或者冻结的指令给资源优先级和限制管理模块222和平台冻结管理模块224。进程内存回收模块234用于实现进程深度冻结模式,这样能当某个第三方应用长期处于冻结状态的时候,会主要释放掉进程的文件区,从而达到节省内存的模块,也加快该应用在下次启动时的速度。冻结超时退出模块235用于解决出现冻结超时场景产生的异常。通过上述的架构,可实现本申请各个实施例中的进程处理方法。The kernel space layer 230 includes a UID management module 231 , a Cgroup module 232 , a Binder management and control module 233 , a process memory recovery module 234 and a freeze timeout exit module 235 . The UID management module 231 is configured to manage or freeze resources of third-party applications based on an application's user identifier (User Identifier, UID). Compared with process management and control based on a process identifier (Process Identifier, PID), it is more convenient to uniformly manage the resources of a user's application through the UID. The Cgroup module 232 is used to provide a complete set of central processing unit (Central Processing Unit, CPU), CPUSET, memory (memory), input/output (I/O) and Net-related resource limitation mechanisms. The binder management and control module 233 is used to implement the priority control of the background binder communication. Wherein, the interface module of the local framework layer 220 includes the binder interface developed to the upper layer, and the upper layer framework or application sends the resource restriction or freezing instruction to the resource priority and restriction management module 222 and the platform freezing management module 224 through the provided binder interface . The process memory recovery module 234 is used to realize the deep freeze mode of the process, so that when a third-party application is in a frozen state for a long time, it will mainly release the file area of the process, so as to achieve a module that saves memory, and also speeds up the application in the next time. speed at startup. The freeze timeout exit module 235 is used to resolve an exception caused by a freeze timeout scenario. Through the above architecture, the process processing methods in the various embodiments of the present application can be implemented.

在一个实施例中,如图3所示,提供了一种进程处理方法,以该方法应用于图1中的电子设备为例进行说明,包括:In one embodiment, as shown in FIG. 3, a process processing method is provided, and the method is applied to the electronic device in FIG. 1 as an example for description, including:

步骤302,检测电子设备的剩余电量,电子设备中预先安装了至少两张用户身份识别SIM卡。In step 302, the remaining power of the electronic device is detected, and at least two user identification SIM cards are pre-installed in the electronic device.

SIM(Subscriber Identity Module客户识别模块)卡,也称为智能卡、用户身份识别卡,移动终端必须装上此卡方能使用通信功能。本申请中的电子设备一般为可以预先安装至少两张用户身份识别SIM卡的电子设备,例如可以是预先安装了两张SIM卡的双卡双待手机,当然,也可以是预先安装了三张SIM卡的三卡三待手机,或者是预先安装了多张SIM卡的多卡多待手机。每张SIM卡都有一个唯一的第一集成电路卡识别码(ICCID,Integratecircuit card identity),一般固化在SIM卡中。ICCID其实就是手机SIM卡的一个编号,不同运营商的SIM卡的ICCID编码规则是不一样。电子设备就是根据SIM卡的ICCID号码来区分不同运营商、不同号码的SIM卡。本来正常情况下,手机中的每张卡都处于开启状态,都可以进行接打电话收发短信以及打开数据流量进行上网等操作。在本申请中实时对电子设备的剩余电量进行检测。SIM (Subscriber Identity Module) card, also known as smart card, user identity card, must be installed on the mobile terminal to use the communication function. The electronic device in this application is generally an electronic device that can be pre-installed with at least two user identification SIM cards, for example, a dual-card dual-standby mobile phone with two SIM cards pre-installed, of course, it can also be pre-installed with three SIM cards. A three-card, three-standby mobile phone with a SIM card, or a multi-card multi-standby mobile phone with multiple SIM cards pre-installed. Each SIM card has a unique first integrated circuit card identification code (ICCID, Integratecircuit card identity), which is generally solidified in the SIM card. ICCID is actually a number of a mobile phone SIM card. The ICCID coding rules of SIM cards of different operators are different. Electronic equipment is to distinguish SIM cards of different operators and numbers according to the ICCID number of the SIM card. Originally, under normal circumstances, each card in the mobile phone is in an open state, and can perform operations such as making and receiving calls, sending and receiving text messages, and opening data traffic for Internet access. In this application, the remaining power of the electronic device is detected in real time.

步骤304,当电子设备的剩余电量小于第一设定电量阈值时,则从至少两张用户身份识别SIM卡中选出第一SIM卡,将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。Step 304, when the remaining power of the electronic device is less than the first set power threshold, then select the first SIM card from at least two user identification SIM cards, and set the first SIM card as the remaining power of the electronic device in itself. SIM cards used within a time period less than the first set power threshold.

第一设定电量阈值为预先设置的,可以根据电子设备电池的总容量进行设置。当检测到电子设备的剩余电量小于第一设定电量阈值时,则根据SIM卡使用习惯自动从该电子设备预先安装的至少两张SIM卡中选出第一SIM卡,一般情况下第一SIM卡为一张SIM卡,当然第一SIM卡也可以为多张SIM卡。第一SIM卡可以为电子设备根据电子设备自身中存储的用户的SIM卡使用习惯,来进行筛选出的SIM卡。此时,电子设备的显示屏上弹出提示信息,提示信息中包含电池电量低于第一设定电量阈值的电量,系统将会自动对您使用较少的第二SIM卡(卡号为159XXXX0000)进行部分冻结,保留您使用较多的第一SIM卡(卡号为185XXXXXXXX)的功能。如图4所示,为电子设备上显示SIM卡冻结提示信息的界面示意图。并提示用户从两个选项“允许”或“禁止”对话框中进行选择。若用户选择了“允许”,则电子设备中的资源优先级和限制管理模块将获取该第一SIM卡的ICCID,根据ICCID将该第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的专用SIM卡。The first set power threshold is preset and can be set according to the total capacity of the battery of the electronic device. When it is detected that the remaining power of the electronic device is less than the first set power threshold, the first SIM card is automatically selected from at least two SIM cards pre-installed in the electronic device according to the usage habits of the SIM card. The card is one SIM card, of course, the first SIM card can also be multiple SIM cards. The first SIM card may be a SIM card selected by the electronic device according to the user's SIM card usage habits stored in the electronic device itself. At this time, a prompt message will pop up on the display screen of the electronic device, and the prompt message includes the battery power below the first set power threshold. Partial freeze, keep the function of the first SIM card (card number 185XXXXXXXX) that you use more. As shown in FIG. 4 , it is a schematic diagram of an interface for displaying SIM card freezing prompt information on an electronic device. And prompt the user to choose from two options "Allow" or "Prohibit" dialog. If the user selects "Allow", the resource priority and restriction management module in the electronic device will obtain the ICCID of the first SIM card, and according to the ICCID, the first SIM card is set as the electronic device's own remaining power is less than the first SIM card. Dedicated SIM card used during the time period for which the battery threshold is set.

步骤306,从至少两张用户身份识别SIM卡中获取除第一SIM卡之外的第二SIM卡,对与第二SIM的部分进程进行冻结。Step 306: Obtain a second SIM card other than the first SIM card from the at least two user identity identification SIM cards, and freeze part of the process with the second SIM.

若用户选择了“允许”,则从至少两张用户身份识别SIM卡中获取除第一SIM卡之外的第二SIM卡,电子设备中的平台冻结管理模块对与第二SIM卡相关的进程进行冻结。具体地,,电子设备中的平台冻结管理模块根据第二SIM卡的ICCID将与第二SIM卡的部分进程进行冻结,当然也可以包括对与第二SIM卡相关的全部进程进行冻结这种冻结方式。If the user selects "Allow", a second SIM card other than the first SIM card is obtained from at least two user identification SIM cards, and the platform freeze management module in the electronic device controls the process related to the second SIM card. Freeze. Specifically, the platform freezing management module in the electronic device freezes part of the processes related to the second SIM card according to the ICCID of the second SIM card, and of course, it may also include freezing all processes related to the second SIM card. Way.

本申请实施例中,当电子设备的剩余电量小于第一设定电量阈值时,选择出第一SIM卡作为电子设备的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡,而将除去第一SIM卡之外的第二SIM卡的部分进程进行冻结。因为保留了第一SIM卡的相关进程,对第二SIM卡的部分进程进行了冻结之后,系统将禁止其在后台运行,并释放其占用的内存,减少其对系统资源的浪费,也减少了电量和消耗以及流量的消耗等。从而在一定程度上降低耗电量,延长电子设备的续航时长。In the embodiment of the present application, when the remaining power of the electronic device is less than the first set power threshold, the first SIM card is selected as the SIM card used in the time period when the remaining power of the electronic device is less than the first set power threshold, and Freeze some processes of the second SIM card except the first SIM card. Because the related processes of the first SIM card are retained, after freezing some processes of the second SIM card, the system will prohibit it from running in the background and release the memory occupied by it, reducing the waste of system resources and reducing the waste of system resources. Power and consumption, and traffic consumption, etc. This reduces power consumption to a certain extent and prolongs the battery life of electronic devices.

在一个实施例中,如图5所示,对第二SIM卡的部分进程进行冻结,包括:In one embodiment, as shown in FIG. 5 , freezing part of the process of the second SIM card includes:

步骤306a,从处于开启状态的进程中获取与第二SIM卡相关的进程。Step 306a, acquiring the process related to the second SIM card from the processes in the open state.

步骤306b,获取与第二SIM卡相关的进程的耗电速度。Step 306b, obtaining the power consumption speed of the process related to the second SIM card.

步骤306c,根据与第二SIM卡相关的进程的耗电速度,从与第二SIM卡相关的进程中筛选出耗电速度高于设定耗电速度阈值的进程作为目标进程。Step 306c, according to the power consumption speed of the process related to the second SIM card, select a process whose power consumption speed is higher than the set power consumption speed threshold from the processes related to the second SIM card as the target process.

步骤306d,对目标进程进行冻结。Step 306d, freeze the target process.

具体地,对于双卡双待的电子设备,当双卡都处于正常使用的状态下时,电子设备中处于开启状态的进程可能同时包括第一SIM卡的进程和第二SIM卡的进程。当电子设备的剩余电量小于第一设定电量阈值时,从电子设备上的双卡中选出了第一SIM卡,作为用户在电子设备自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。对另一张卡即第二SIM卡的部分进程进行冻结。Specifically, for a dual-card dual-standby electronic device, when both cards are in normal use, the process in the open state in the electronic device may include both the process of the first SIM card and the process of the second SIM card. When the remaining power of the electronic device is less than the first set power threshold, the first SIM card is selected from the dual cards on the electronic device as the time period when the user's remaining power in the electronic device is less than the first set power threshold SIM card used inside. Freeze part of the process of another card, that is, the second SIM card.

首先,从电子设备上所有处于开启状态的进程中获取所有与第二SIM卡相关的进程。与第二SIM卡相关的进程包括使用第二SIM卡的数据流量的进程,也包括使用第二SIM卡的基本通信功能的进程。例如,电子设备上开启了视频软件这种非常耗电的进程,且该视频软件是采用第二SIM卡的流量数据。那么获取到的所有与第二SIM卡相关的进程中,就会包括该视频软件的相关进程。First, obtain all the processes related to the second SIM card from all the processes in the open state on the electronic device. The process related to the second SIM card includes the process of using the data traffic of the second SIM card, and also includes the process of using the basic communication function of the second SIM card. For example, a very power-consuming process such as video software is started on the electronic device, and the video software uses the traffic data of the second SIM card. Then, all the acquired processes related to the second SIM card will include related processes of the video software.

其次,在获取到了所有与第二SIM卡相关的进程之后,对这类进程获取每一个进程的耗电速度。将所有与第二SIM卡相关的进程按照耗电速度从大到小进行排序,从所有与第二SIM卡相关的进程中筛选出耗电速度高于设定耗电速度阈值的进程作为目标进程。设定耗电速度阈值为根据电子设备的第一设定电量阈值相应设置的,例如,第一设定电量阈值若是电子设备充满电时候电量的20%,则若为了让电子设备还可以坚持使用2小时以上,则可以相应设置设定耗电速度阈值为每小时耗电高于电子设备充满电时候电量的5%。从按照耗电速度排序后第二SIM卡相关的进程中从获取耗电速度高于设定耗电速度阈值的进程。Secondly, after acquiring all the processes related to the second SIM card, acquire the power consumption speed of each process for such processes. Sort all the processes related to the second SIM card in descending order of power consumption speed, and filter out the processes whose power consumption speed is higher than the set power consumption speed threshold from all the processes related to the second SIM card as the target process . The set power consumption speed threshold is set according to the first set power threshold of the electronic device. For example, if the first set power threshold is 20% of the power when the electronic device is fully charged, if the electronic device can still be used persistently For more than 2 hours, the power consumption speed threshold can be set accordingly to set the power consumption per hour higher than 5% of the power when the electronic device is fully charged. A process whose power consumption speed is higher than the set power consumption speed threshold is obtained from the processes related to the second SIM card after the power consumption speed is sorted.

最后,将耗电速度高于设定耗电速度阈值的进程标记为高耗电进程,将这些高耗电进程作为目标进程进行冻结。Finally, the processes whose power consumption speed is higher than the set power consumption speed threshold are marked as high power consumption processes, and these high power consumption processes are frozen as target processes.

在本实施例中,首先,从电子设备上所有处于开启状态的进程中获取所有与第二SIM卡相关的进程。其次,在获取到了所有与第二SIM卡相关的进程之后,对这类进程获取每一个进程的耗电速度。最后,将耗电速度高于设定耗电速度阈值的进程标记为高耗电进程,将这些高耗电进程作为目标进程进行冻结。从耗电速度角度进行冻结,能够将突然之间开启的那种耗电量很高的进程进行及时冻结,从而及时地减少了电量的消耗,延长电子设备的续航时长。In this embodiment, firstly, all processes related to the second SIM card are acquired from all processes in an open state on the electronic device. Secondly, after acquiring all the processes related to the second SIM card, acquire the power consumption speed of each process for such processes. Finally, the processes whose power consumption speed is higher than the set power consumption speed threshold are marked as high power consumption processes, and these high power consumption processes are frozen as target processes. Freezing from the perspective of power consumption speed can freeze the process with high power consumption that is suddenly turned on in time, thereby reducing power consumption in time and extending the battery life of electronic devices.

在一个实施例中,对与第二SIM卡的部分进程进行冻结,还包括:In one embodiment, freezing part of the process with the second SIM card, further comprising:

从处于开启状态的进程中获取与第二SIM卡相关的进程;Obtain the process related to the second SIM card from the process in the open state;

获取与第二SIM卡相关的进程的CPU资源占用大小;Obtain the CPU resource occupancy size of the process related to the second SIM card;

根据与第二SIM卡相关的进程的CPU资源占用大小,从与第二SIM卡相关的进程中筛选出CPU资源占用大小高于设定CPU资源占用阈值的进程作为目标进程;According to the CPU resource occupancy size of the process related to the second SIM card, the process with the CPU resource occupancy size higher than the set CPU resource occupancy threshold is selected from the processes related to the second SIM card as the target process;

对目标进程进行冻结。Freeze the target process.

具体地,对于双卡双待的电子设备,当双卡都处于正常使用的状态下时,电子设备中处于开启状态的进程可能同时包括第一SIM卡的进程和第二SIM卡的进程。当电子设备的剩余电量小于第一设定电量阈值时,从电子设备上的双卡中选出了第一SIM卡,作为用户在电子设备自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。对另一张卡即第二SIM卡的部分进程进行冻结。Specifically, for a dual-card dual-standby electronic device, when both cards are in normal use, the process in the open state in the electronic device may include both the process of the first SIM card and the process of the second SIM card. When the remaining power of the electronic device is less than the first set power threshold, the first SIM card is selected from the dual cards on the electronic device as the time period when the user's remaining power in the electronic device is less than the first set power threshold SIM card used inside. Freeze part of the process of another card, that is, the second SIM card.

首先,从电子设备上所有处于开启状态的进程中获取所有与第二SIM卡相关的进程。例如,电子设备上开启了视频软件这种非常占用CPU资源的进程,且该视频软件是采用第二SIM卡的流量数据。那么获取到的所有与第二SIM卡相关的进程中,就会包括该视频软件的相关进程,当然还会包括所有使用第二SIM卡的流量数据的相关应用,以及使用第二SIM卡的通信服务的相关进程。First, obtain all the processes related to the second SIM card from all the processes in the open state on the electronic device. For example, video software, a process that consumes CPU resources very much, is started on the electronic device, and the video software uses the traffic data of the second SIM card. Then all the acquired processes related to the second SIM card will include the related processes of the video software, of course, all related applications using the traffic data of the second SIM card, and the communication using the second SIM card. Service-related processes.

其次,在获取到了所有与第二SIM卡相关的进程之后,对这类进程获取每一个进程当前占用CPU资源的大小。将所有与第二SIM卡相关的进程按照占用CPU资源的大小从大到小进行排序,从所有与第二SIM卡相关的进程中筛选出占用CPU资源的大小高于设定CPU资源占用阈值的进程作为目标进程。设定CPU资源占用阈值为根据电子设备的第一设定电量阈值相应设置的,因为进程占用CPU资源越多,可能需要多个CPU同时运转才可以支持,相应地耗电就越多。例如,对于配置了八个处理器的电子设备,只开启两个处理器的耗电量肯定比同时开启八个处理器的耗电量相比要小得多。例如,可以相应设置设定CPU资源占用阈值为10%(电子设备整个CPU资源的10%)。从按照占用CPU资源大小排序后的第二SIM卡相关的进程中,获取CPU资源占用高于设定CPU资源占用阈值的进程。Secondly, after acquiring all the processes related to the second SIM card, acquire the size of the CPU resources currently occupied by each process for such processes. Sort all the processes related to the second SIM card according to the size of CPU resources occupied from large to small, and filter out the processes related to the second SIM card that occupy more CPU resources than the set CPU resource occupation threshold. process as the target process. The setting of the CPU resource occupancy threshold is set according to the first set power threshold of the electronic device, because the more CPU resources a process occupies, the more CPUs may be required to run at the same time, and the more power is consumed accordingly. For example, for an electronic device configured with eight processors, the power consumption of only turning on two processors must be much less than the power consumption of turning on all eight processors at the same time. For example, the CPU resource occupancy threshold may be set to 10% (10% of the entire CPU resource of the electronic device) correspondingly. From the processes related to the second SIM card sorted according to the size of the occupied CPU resources, acquire the processes whose CPU resource occupancy is higher than the set CPU resource occupancy threshold.

最后,将CPU资源占用高于设定CPU资源占用阈值的进程作为目标进程进行冻结。Finally, freeze the process whose CPU resource usage is higher than the set CPU resource usage threshold as the target process.

在本实施例中,首先,从电子设备上所有处于开启状态的进程中获取所有与第二SIM卡相关的进程。其次,在获取到了所有与第二SIM卡相关的进程之后,对这类进程获取每一个进程当前占用CPU资源的大小。最后,将CPU资源占用高于设定CPU资源占用阈值的进程作为目标进程进行冻结。从CPU资源占用大小的角度进行冻结,能够将占用CPU资源较大的进程进行及时冻结,从而减少同时运行的CPU的个数,进而及时地减少了电量的消耗,延长电子设备的续航时长。In this embodiment, firstly, all processes related to the second SIM card are acquired from all processes in an open state on the electronic device. Secondly, after acquiring all the processes related to the second SIM card, acquire the size of the CPU resources currently occupied by each process for such processes. Finally, freeze the process whose CPU resource usage is higher than the set CPU resource usage threshold as the target process. Freezing from the perspective of CPU resource occupancy can freeze processes that occupy a large CPU resource in time, thereby reducing the number of CPUs running at the same time, thereby reducing power consumption in a timely manner and extending the battery life of electronic devices.

在一个实施例中,如图6所示,当电子设备的剩余电量小于第一设定电量阈值时,则根据SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡,将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡,包括:In one embodiment, as shown in FIG. 6 , when the remaining power of the electronic device is less than the first set power threshold, the first SIM card is selected from at least two user identification SIM cards according to the usage habits of the SIM card, The first SIM card is set as the SIM card used by the electronic device in the time period when the remaining power of the electronic device is less than the first set power threshold, including:

步骤304a,获取预设周期内的SIM卡历史使用数据。Step 304a, acquiring historical SIM card usage data within a preset period.

预设周期可以是指电子设备的电量从满电使用到剩余电量至第一设定电量阈值之间这个周期,当然预设周期也可以是以一天为单位,统计用户在一个预设周期内的SIM卡历史使用数据。可以统计至少3个预设周期内用户的SIM卡历史使用数据。例如,在本实施例中统计前3天用户的SIM卡历史使用数据。假设,今天是2017年12月10号,则统计2017年12月9号、2017年12月8号及2017年12月7号这3天用户的SIM卡历史使用数据。SIM卡历史使用数据可以包括用户在预设周期内对不同SIM卡的使用时长,也可以包括用户在预设周期内的SIM卡使用时间段和在SIM卡使用时间段内所使用的SIM卡。The preset period may refer to the period between the full power usage of the electronic device and the remaining power to the first set power threshold. Of course, the preset period can also be a day as a unit, and the user's power consumption in a preset period can be counted. SIM card history usage data. The historical usage data of the user's SIM card in at least 3 preset periods can be counted. For example, in this embodiment, the historical SIM card usage data of the user in the previous three days is counted. Assuming that today is December 10, 2017, the historical SIM card usage data of users for the three days of December 9, 2017, December 8, 2017, and December 7, 2017 are counted. The historical SIM card usage data may include the duration of use of different SIM cards by the user within a preset period, and may also include the user's SIM card usage period within the preset period and the SIM cards used within the SIM card usage period.

步骤304b,根据SIM卡历史使用数据分析得出预设周期内的SIM卡使用习惯,当电子设备的剩余电量小于第一设定电量阈值时,则根据预设周期内的SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡。Step 304b, according to the historical usage data of the SIM card, obtain the usage habit of the SIM card in the preset period, when the remaining power of the electronic device is less than the first set power threshold, then according to the usage habit of the SIM card in the preset period from at least The first SIM card is selected from the two user identification SIM cards.

对统计出的SIM卡历史使用数据进行分析,分析出预设周期内的SIM卡使用习惯。具体地,统计用户在2017年12月9号、2017年12月8号及2017年12月7号这3天每天用户对不同SIM卡的使用时长。假设电子设备中安装了卡一和卡二两张SIM卡,统计出用户对不同SIM卡的使用时长如下表所示:The statistics of the historical usage data of the SIM card are analyzed, and the usage habits of the SIM card in the preset period are analyzed. Specifically, the user's usage time of different SIM cards on a daily basis during the three days of December 9, 2017, December 8, 2017, and December 7, 2017 is counted. Assuming that two SIM cards, Card 1 and Card 2, are installed in the electronic device, the usage time of different SIM cards by users is calculated as shown in the following table:

日期date 卡一使用时长Card usage time 卡二使用时长Card 2 usage time 2017年12月7号December 7, 2017 8h(小时)8h (hours) 4h(小时)4h (hours) 2017年12月8号December 8, 2017 9.5h(小时)9.5h (hour) 5h(小时)5h (hours) 2017年12月9号December 9, 2017 7.5h(小时)7.5h (hour) 4.5h(小时)4.5h (hour) 平均average 8.34h(小时)/天8.34h(hour)/day 4.5h(小时)/天4.5h(hour)/day

根据上表就可以分析出用户在一天中的SIM卡使用习惯为:每天对卡一的使用时长比卡二的使用时长较长。因此,当电子设备的剩余电量小于第一设定电量阈值时,根据用户在一天中的SIM卡使用习惯从卡一和卡二中选出卡一作为第一SIM卡。因为卡一为用户在一天中使用最频繁的、使用时间最长的SIM卡,所以在电子设备的剩余电量小于第一设定电量阈值时,将卡一作为该段时间内用户专用的卡,这样能够最大限度地满足用户的使用需求。其中,第一设定电量阈值可以是电子设备充满电时候电量的20%,也可以是电子设备充满电时候电量的10%,当然也可以是其他数值。According to the above table, it can be analyzed that the user's SIM card usage habits in a day are: the usage time of SIM card 1 is longer than that of SIM card 2 every day. Therefore, when the remaining power of the electronic device is less than the first set power threshold, card one is selected from cards one and two as the first SIM card according to the user's usage habits of the SIM card in one day. Because Card 1 is the SIM card most frequently used by the user in a day and has been in use for the longest time, when the remaining power of the electronic device is less than the first set power threshold, Card 1 is used as a special card for the user during this period of time. This can meet the needs of users to the greatest extent. The first set power threshold may be 20% of the power when the electronic device is fully charged, or 10% of the power when the electronic device is fully charged, and of course other values.

步骤304c,将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。Step 304c, setting the first SIM card as a SIM card used by the electronic device within a time period when the remaining power of the electronic device is less than the first set power threshold.

在系统分析出用户的SIM卡使用习惯,并根据用户的SIM卡使用习惯筛选出了电子设备在自身的剩余电量小于第一设定电量阈值时专用的第一SIM卡之后,弹出提示信息提示用户是否允许系统将第一SIM卡作为专用的SIM卡,而将除了第一SIM卡之外的SIM卡进行冻结。若用户允许了系统进行上述操作,则电子设备中的资源优先级和限制管理模块获取该第一SIM卡的ICCID,根据ICCID将该第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的专用SIM卡。平台冻结管理模块根据第二SIM卡的ICCID将与第二SIM卡相关的进程进行冻结。After the system analyzes the user's SIM card usage habits, and filters out the first SIM card dedicated to the electronic device when its remaining power is less than the first set power threshold according to the user's SIM card usage habits, a prompt message pops up to remind the user Whether to allow the system to use the first SIM card as a dedicated SIM card and freeze the SIM cards other than the first SIM card. If the user allows the system to perform the above operations, the resource priority and restriction management module in the electronic device acquires the ICCID of the first SIM card, and according to the ICCID sets the first SIM card as the electronic device's own remaining power is less than the first SIM card. Dedicated SIM card used during the time period for which the battery threshold is set. The platform freezing management module freezes the process related to the second SIM card according to the ICCID of the second SIM card.

本申请实施例中,通过统计预设周期内的SIM卡历史使用数据,对多个预设周期内的SIM卡历史使用数据进行统计学分析,得出用户在预设周期内的SIM卡使用习惯。当电子设备的剩余电量小于第一设定电量阈值时,再根据预设周期内的SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡作为该低电量时间段内的专用卡,而将其他SIM卡的功能进行冻结以达到降低耗电量且能最大限度满足用户使用需求的效果。通过机器学习的方法帮助用户做出筛选,这样选择出的结果的准确性较高,从而使得电子设备的省电方式更加智能化。In the embodiment of the present application, by counting the historical SIM card usage data in a preset period, statistical analysis is performed on the historical SIM card usage data in multiple preset periods, so as to obtain the user's SIM card usage habits in the preset period . When the remaining power of the electronic device is less than the first set power threshold, the first SIM card is selected from the at least two user identification SIM cards according to the SIM card usage habits in the preset period as the low power time period. A dedicated card is used, and the functions of other SIM cards are frozen to reduce power consumption and meet the needs of users to the greatest extent. The machine learning method is used to help users make screenings, so that the selected results are more accurate, thereby making the power saving method of electronic devices more intelligent.

在一个实施例中,SIM卡历史使用数据包括预设周期内不同SIM卡的使用时长;In one embodiment, the historical SIM card usage data includes the usage duration of different SIM cards in a preset period;

根据SIM卡历史使用数据分析得出预设周期内的SIM卡使用习惯,当电子设备的剩余电量小于第一设定电量阈值时,则根据预设周期内的SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡,包括:According to the historical usage data of the SIM card, the usage habits of the SIM card in the preset period are obtained. When the remaining power of the electronic device is less than the first set power threshold, the usage habits of the SIM card in the preset period are obtained from at least two users. The first SIM card is selected from the identification SIM cards, including:

对预设周期内不同SIM卡的使用时长进行比较,得到最大的使用时长,获取最大的使用时长所对应的SIM卡;Compare the usage durations of different SIM cards in the preset period to obtain the maximum usage duration, and obtain the SIM card corresponding to the maximum usage duration;

当电子设备的剩余电量小于第一设定电量阈值时,则将SIM卡作为第一SIM卡。When the remaining power of the electronic device is less than the first set power threshold, the SIM card is used as the first SIM card.

具体地,SIM卡历史使用数据包括预设周期内不同SIM卡的使用时长。对预设周期内不同SIM卡的使用时长进行比较,得到最大的使用时长,获取最大的使用时长所对应的SIM卡。当电子设备的剩余电量小于第一设定电量阈值时,则将SIM卡作为第一SIM卡。Specifically, the historical SIM card usage data includes usage durations of different SIM cards within a preset period. The usage durations of different SIM cards in the preset period are compared to obtain the maximum usage duration, and the SIM card corresponding to the maximum usage duration is obtained. When the remaining power of the electronic device is less than the first set power threshold, the SIM card is used as the first SIM card.

例如,预设周期若以天为单位,当然预设周期也可以以周为单位。若以天为单位,则统计用户在2017年12月9号、2017年12月8号及2017年12月7号这3天每天用户对不同SIM卡的使用时长。假设电子设备中安装了卡一和卡二两张SIM卡,统计出用户对不同SIM卡的使用时长如下表所示:For example, if the preset period is in days, of course, the preset period may also be in weeks. If the unit is days, the user's usage time of different SIM cards is counted on December 9, 2017, December 8, 2017, and December 7, 2017. Assuming that two SIM cards, Card 1 and Card 2, are installed in the electronic device, the usage time of different SIM cards by users is calculated as shown in the following table:

根据上表就可以分析出用户在一天中的SIM卡使用习惯为:每天对卡一的使用时长比卡二的使用时长较长。因此,当电子设备的剩余电量小于第一设定电量阈值时,根据用户在一天中的SIM卡使用习惯从卡一和卡二中选出卡一作为第一SIM卡。因为卡一为用户在一天中使用最频繁的、使用时间最长的SIM卡,所以在电子设备的剩余电量小于第一设定电量阈值时,将卡一作为该段时间内用户专用的卡,这样能够最大限度地满足用户的使用需求。其中,第一设定电量阈值可以是电子设备充满电时候电量的20%,也可以是电子设备充满电时候电量的10%,当然也可以是其他数值。According to the above table, it can be analyzed that the user's SIM card usage habits in a day are: the usage time of SIM card 1 is longer than that of SIM card 2 every day. Therefore, when the remaining power of the electronic device is less than the first set power threshold, card one is selected from cards one and two as the first SIM card according to the user's usage habits of the SIM card in one day. Because Card 1 is the SIM card most frequently used by the user in a day and has been in use for the longest time, when the remaining power of the electronic device is less than the first set power threshold, Card 1 is used as a special card for the user during this period of time. This can meet the needs of users to the greatest extent. The first set power threshold may be 20% of the power when the electronic device is fully charged, or 10% of the power when the electronic device is fully charged, and of course other values.

本申请实施例中,通过统计预设周期内不同SIM卡的使用时长,对多个预设周期内的不同SIM卡的使用时长进行统计学分析,得出用户在预设周期内平均使用时长最长的SIM卡。当电子设备的剩余电量小于第一设定电量阈值时,再根据预设周期内的SIM卡使用习惯,将该平均使用时长最长的SIM卡作为第一SIM卡。因为用户平时对第一SIM卡的使用时长较长,因此在电量低于第一设定电量阈值的时候,则系统自动将第一SIM卡作为该低电量时间段内的专用卡,而将其他SIM卡的功能进行冻结以达到降低耗电量且能最大限度满足用户使用需求的效果。通过机器学习的方法帮助用户做出筛选,这样选择出的结果的准确性较高,从而使得电子设备的省电方式更加智能化。In the embodiment of the present application, by counting the usage time of different SIM cards in a preset period, and performing statistical analysis on the usage time of different SIM cards in multiple preset periods, it is obtained that the average usage time of the user in the preset period is the longest long sim card. When the remaining power of the electronic device is less than the first set power threshold, the SIM card with the longest average usage time is used as the first SIM card according to the usage habits of the SIM card in the preset period. Because the user usually uses the first SIM card for a long time, when the power is lower than the first set power threshold, the system will automatically use the first SIM card as the dedicated card during the low power period, and use other The function of the SIM card is frozen to reduce power consumption and meet the user's needs to the greatest extent. The machine learning method is used to help users make screenings, so that the selected results are more accurate, thereby making the power saving method of electronic devices more intelligent.

在一个实施例中,SIM卡历史使用数据包括预设周期内的SIM卡使用时间段和在SIM卡使用时间段内所使用的SIM卡;In one embodiment, the historical SIM card usage data includes the SIM card usage time period within a preset period and the SIM cards used within the SIM card usage time period;

根据SIM卡历史使用数据分析得出预设周期内的SIM卡使用习惯,当电子设备的剩余电量小于第一设定电量阈值时,则根据预设周期内的SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡,包括:According to the historical usage data of the SIM card, the usage habits of the SIM card in the preset period are obtained. When the remaining power of the electronic device is less than the first set power threshold, the usage habits of the SIM card in the preset period are obtained from at least two users. The first SIM card is selected from the identification SIM cards, including:

根据预设周期内的SIM卡使用时间段和在SIM卡使用时间段内所使用的SIM卡,计算得到预设周期内不同的SIM卡使用时间段内使用频率最高的SIM卡;According to the SIM card usage time period in the preset period and the SIM card used in the SIM card usage time period, the SIM card with the highest frequency of use in different SIM card usage time periods in the preset period is calculated;

当电子设备的剩余电量小于第一设定电量阈值时,获取电子设备的剩余电量小于第一设定电量阈值时的时间信息,将时间信息分入时间信息所属的SIM卡使用时间段;When the remaining power of the electronic device is less than the first set power threshold, obtain time information when the remaining power of the electronic device is less than the first set power threshold, and divide the time information into the SIM card usage time period to which the time information belongs;

获取SIM卡使用时间段内使用频率最高的SIM卡,将SIM卡作为第一SIM卡。Obtain the SIM card with the highest frequency of use within the SIM card usage time period, and use the SIM card as the first SIM card.

具体地,SIM卡历史使用数据包括预设周期内的SIM卡使用时间段和在SIM卡使用时间段内所使用的SIM卡。预设周期可以是以周为单位,例如统计出在周一至周五的上班时间(9:00am-6:00pm),卡一的使用频率最高,因为卡一是工作号码或者卡一的通话套餐较多,用户多使用卡一与客户进行通话联系。统计出在周一至周五的非上班时间内(6:00pm-9:00pm)和周六周日卡二的使用频率最高,因为用户在该周一至周五的非上班时间段内和周六周日多使用数据流量进行上网,而正好卡二的上网流量套餐比较多,可以满足用户的上网需求。因此,分析出了用户的SIM卡使用习惯为在周一至周五的上班时间(9:00am-6:00pm),卡一的使用频率最高。而在周一至周五的非上班时间内(6:00pm-9:00pm)和周六周日,则卡二的使用频率最高。Specifically, the historical SIM card usage data includes the SIM card usage time period within a preset period and the SIM cards used within the SIM card usage time period. The preset period can be in weeks. For example, during the working hours (9:00am-6:00pm) from Monday to Friday, Card 1 is most frequently used because Card 1 is a work number or a calling plan of Card 1. In many cases, users often use card one to communicate with customers. Statistics show that the use frequency of Card II is the highest during non-working hours (6:00pm-9:00pm) from Monday to Friday and Saturday and Sunday, because users are in the non-working hours from Monday to Friday and Saturday. On Sundays, data traffic is often used to surf the Internet, and it happens that the card 2 has more Internet traffic packages, which can meet the needs of users for surfing the Internet. Therefore, it is analyzed that the user's SIM card usage habit is during the working hours (9:00am-6:00pm) from Monday to Friday, and the usage frequency of SIM card 1 is the highest. During non-working hours (6:00pm-9:00pm) from Monday to Friday and Saturday and Sunday, Card 2 is most frequently used.

因此,当电子设备的剩余电量小于第一设定电量阈值时,获取电子设备的剩余电量小于第一设定电量阈值时的时间信息,将时间信息分入时间信息所属的SIM卡使用时间段。例如,电子设备在周二的8:00pm这个时刻,提示用户电子设备的剩余电量小于第一设定电量阈值,则将周二的8:00pm这个时刻划分入周一至周五的非上班时间内,则可以得出一般在这个时间段内用户对卡二的使用频率最高。获取使用频率最高的SIM卡即卡二,将卡二作为电子设备在剩余电量低于第一设定电量阈值的专用卡即第一SIM卡。Therefore, when the remaining power of the electronic device is less than the first set power threshold, the time information when the remaining power of the electronic device is less than the first set power threshold is obtained, and the time information is divided into the SIM card usage time period to which the time information belongs. For example, if the electronic device prompts the user that the remaining power of the electronic device is less than the first set power threshold at the time of 8:00pm on Tuesday, the time of 8:00pm on Tuesday is divided into the non-working hours from Monday to Friday, then It can be concluded that in this time period, the user uses the card 2 the most frequently. Obtain the SIM card with the highest frequency of use, that is, the second SIM card, and use the second SIM card as the dedicated card of the electronic device when the remaining power is lower than the first set power threshold, that is, the first SIM card.

本申请实施例中,对预设周期内的SIM卡使用时间段和在SIM卡使用时间段内所使用的SIM卡进行统计分析,得出用户的SIM卡使用习惯。SIM卡使用习惯一般指用户在哪个SIM卡使用时间段对应使用频率最高的SIM卡是哪张SIM卡。这样就可以根据电子设备的剩余电量小于第一设定电量阈值时的时间信息,有针对性将该时间信息划分入对应的时间段。根据用户在这个时间段内的SIM卡使用习惯,获取到在该时间段内使用频率最高的SIM卡,将该SIM卡作为第一SIM卡进行设置。通过对用户SIM卡使用习惯进行更加精细的分析,细化至每一个SIM卡使用时间段,因此这个系统筛选出的第一SIM卡就会更加贴合用户的使用需求、使用习惯,大大提升用户体验。In the embodiment of the present application, statistical analysis is performed on the SIM card usage time period within a preset period and the SIM card used in the SIM card usage time period, so as to obtain the user's SIM card usage habit. The SIM card usage habit generally refers to which SIM card is the most frequently used SIM card in which SIM card usage time period of the user. In this way, according to the time information when the remaining power of the electronic device is less than the first set power threshold, the time information can be divided into corresponding time periods in a targeted manner. According to the user's usage habits of the SIM card in this time period, the SIM card with the highest frequency of use in the time period is obtained, and the SIM card is set as the first SIM card. Through a more detailed analysis of the user's SIM card usage habits, it is refined to each SIM card usage time period, so the first SIM card screened out by this system will be more suitable for the user's usage needs and usage habits, which greatly improves the user experience. experience.

在一个实施例中,如图7所示,在从至少两张用户身份识别SIM卡中获取除第一SIM卡之外的第二SIM卡,对与第二SIM卡的部分进程进行冻结之后,包括:In one embodiment, as shown in FIG. 7 , after obtaining a second SIM card other than the first SIM card from at least two user identification SIM cards, and freezing part of the process with the second SIM card, include:

步骤308,当检测到电子设备的剩余电量超过第二设定电量阈值时,则对第二SIM卡已冻结的进程进行解冻,第二设定电量阈值等于或大于第一设定电量阈值。Step 308 , when it is detected that the remaining power of the electronic device exceeds a second set power threshold, the frozen process of the second SIM card is thawed, and the second set power threshold is equal to or greater than the first set power threshold.

具体地,当电子设备的剩余电量小于第一设定电量阈值时,则从该电子设备预先安装的至少两张SIM卡中选出第一SIM卡,将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。电子设备中除去第一SIM卡之外剩余的SIM卡即为第二SIM卡,平台冻结管理模块对与第二SIM卡的部分进程进行冻结。此时若及时对电子设备进行了充电,则当检测到电子设备的剩余电量超过第二设定电量阈值时,则冻结超时退出模块对已经冻结的那部分第二SIM卡的进程进行解冻。其中,第二设定电量阈值可以与第一设定电量阈值相等,即对电子设备进行充电,充电电量达到第一设定电量阈值(例如,20%)则对之前冻结的与第二SIM卡的那部分进程进行解冻,这样电子设备中与第一SIM卡及第二SIM卡相关进程都恢复了正常使用。因为将与第一SIM卡及第二SIM卡相关进程都恢复了正常使用时候的耗电量相对较大,所以也可以将第二设定电量阈值的数值设置为比第一设定电量阈值稍微大些,避免电量很快又下降至第一设定电量阈值。例如,将第二设定电量阈值设置为电子设备充满电时候电量的30%。当然,也可以设置在充电电量达到第一设定电量阈值(例如,20%)时,在设置一个预设时间段(例如10分钟),假如在该预设时间段内剩余电量一直都是达到第一设定电量阈值的,则此时再将第二SIM卡相关进程都进行解冻。通过延时解冻,可以避免电量很快又下降至第一设定电量阈值。Specifically, when the remaining power of the electronic device is less than the first set power threshold, a first SIM card is selected from at least two SIM cards pre-installed in the electronic device, and the first SIM card is set as the electronic device itself. The remaining power of the SIM card used within the time period when the remaining power is less than the first set power threshold. The remaining SIM card in the electronic device except the first SIM card is the second SIM card, and the platform freezing management module freezes part of the process with the second SIM card. At this time, if the electronic device is charged in time, when it is detected that the remaining power of the electronic device exceeds the second set power threshold, the freeze timeout exit module unfreezes the process of the frozen part of the second SIM card. The second set power threshold may be equal to the first set power threshold, that is, the electronic device is charged, and when the charging power reaches the first set power threshold (for example, 20%), the previously frozen and second SIM card will be charged. The part of the process in the electronic device is thawed, so that the processes related to the first SIM card and the second SIM card in the electronic device are restored to normal use. Because the power consumption when the processes related to the first SIM card and the second SIM card are restored to normal use is relatively large, the value of the second set power threshold can also be set to be slightly higher than the first set power threshold. larger, to prevent the battery from rapidly dropping to the first set battery threshold. For example, the second set power threshold is set to 30% of the power when the electronic device is fully charged. Of course, it can also be set that when the charging power reaches the first set power threshold (for example, 20%), and a preset time period (for example, 10 minutes) is set, if the remaining power has always reached the If the power threshold is first set, then all processes related to the second SIM card are thawed at this time. By delaying the defrosting, it can be avoided that the battery power quickly drops to the first set battery power threshold.

本申请实施例中,当电子设备的剩余电量小于第一设定电量阈值时,平台冻结管理模块对与第二SIM卡的部分进程进行了冻结。此时若及时对电子设备进行了充电,则当检测到电子设备的剩余电量超过第二设定电量阈值时,则冻结超时退出模块对第二SIM卡已冻结的进程进行解冻。这样可以及时对进行冻结了的第二SIM卡的进程进行及时解冻,恢复用户对第一SIM卡及第二SIM卡的同时使用。避免了用户在很长时间内都不能使用第二SIM卡。In the embodiment of the present application, when the remaining power of the electronic device is less than the first set power threshold, the platform freezing management module freezes part of the process with the second SIM card. At this time, if the electronic device is charged in time, when it is detected that the remaining power of the electronic device exceeds the second set power threshold, the freeze timeout exit module unfreezes the frozen process of the second SIM card. In this way, the process of the frozen second SIM card can be thawed in time, and the simultaneous use of the first SIM card and the second SIM card by the user can be resumed. It is avoided that the user cannot use the second SIM card for a long time.

在一个实施例中,对与第二SIM卡相关的进程进行冻结,包括:In one embodiment, the process related to the second SIM card is frozen, including:

对与第二SIM卡相关的网络服务进程进行冻结,网络服务包括应用程序服务。Freeze the network service process related to the second SIM card, where the network service includes application program service.

具体地,随着通信技术的发展,可能会出现一种双卡双待手机,安装在其上的多张SIM卡都可以同时进行上网,那么当电子设备的剩余电量小于第一设定电量阈值时,则从该电子设备预先安装的至少两张SIM卡中选出第一SIM卡,将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。此时可以优先对除去第一SIM卡之外的SIM卡即第二SIM卡的网络服务进程都进行冻结。其中,网络服务包括应用程序服务。Specifically, with the development of communication technology, a dual-card dual-standby mobile phone may appear, and multiple SIM cards installed on it can access the Internet at the same time, then when the remaining power of the electronic device is less than the first set power threshold , select the first SIM card from the at least two SIM cards pre-installed in the electronic device, and set the first SIM card as the one used by the electronic device within the time period when the remaining power of the electronic device is less than the first set power threshold. SIM card. At this time, the network service process of the SIM cards other than the first SIM card, that is, the second SIM card, may be frozen preferentially. Among them, the network service includes the application program service.

本申请实施例中,对安装在其上的多张SIM卡都可以同时进行上网的电子设备,则当电子设备的剩余电量小于第一设定电量阈值时,就优先对除去第一SIM卡之外的SIM卡即第二SIM卡的网络服务进程进行冻结。因为网络服务进程的耗电量远远大于基础通信服务,所以将第二SIM卡相关的网络服务进程进行冻结,可以在一定程度上减少耗电量,延长待机时长。In the embodiment of the present application, for an electronic device that can simultaneously access the Internet with multiple SIM cards installed on it, when the remaining power of the electronic device is less than the first set power threshold, priority is given to removing the first SIM card. The network service process of the external SIM card, that is, the second SIM card, is frozen. Because the power consumption of the network service process is much greater than that of the basic communication service, freezing the network service process related to the second SIM card can reduce power consumption to a certain extent and prolong the standby time.

在一个实施例中,对与第二SIM卡相关的进程进行冻结,还包括:In one embodiment, freezing a process related to the second SIM card, further comprising:

对与第二SIM卡相关的基础通信服务进程及网络服务进程进行冻结,基础通信服务包括接打电话服务和收发短信服务,网络服务包括应用程序服务。Freeze the basic communication service process and the network service process related to the second SIM card, the basic communication service includes the service of making and receiving calls and the service of sending and receiving short messages, and the network service includes the application program service.

具体地,随着通信技术的发展,可能会出现一种双卡双待手机,安装在其上的多张SIM卡都可以同时进行上网,那么当电子设备的剩余电量小于第一设定电量阈值时,则从该电子设备预先安装的至少两张SIM卡中选出第一SIM卡,将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。此时就需要对除去第一SIM卡之外的SIM卡,即第二SIM卡的基础通信服务进程及网络服务进程都进行冻结。基础通信服务包括接打电话服务和收发短信服务,网络服务包括应用程序服务。Specifically, with the development of communication technology, a dual-card dual-standby mobile phone may appear, and multiple SIM cards installed on it can access the Internet at the same time, then when the remaining power of the electronic device is less than the first set power threshold , select the first SIM card from the at least two SIM cards pre-installed in the electronic device, and set the first SIM card as the one used by the electronic device within the time period when the remaining power of the electronic device is less than the first set power threshold. SIM card. In this case, it is necessary to freeze the basic communication service process and the network service process of the SIM cards except the first SIM card, that is, the second SIM card. Basic communication services include making and receiving calls and sending and receiving text messages, and network services include application services.

本申请实施例中,对安装在其上的多张SIM卡都可以同时进行上网的电子设备,则当电子设备的剩余电量小于第一设定电量阈值时,就需要对除去第一SIM卡之外的SIM卡的基础通信服务进程及网络服务进程都进行冻结才可以实现彻底对除去第一SIM卡之外的SIM卡相关的进程都进行冻结。以达到最大限度的减少耗电量,延长待机时长。In the embodiment of the present application, for an electronic device that can simultaneously access the Internet with multiple SIM cards installed on it, when the remaining power of the electronic device is less than the first set power threshold, it is necessary to remove the first SIM card. Only by freezing the basic communication service process and the network service process of the external SIM card, it is possible to completely freeze all SIM card related processes except the first SIM card. In order to minimize power consumption and prolong standby time.

请参阅图8,图8为本申请进程处理方法一个具体实施例的流程图,包括:Please refer to FIG. 8. FIG. 8 is a flowchart of a specific embodiment of a process processing method of the application, including:

步骤801,对预先安装了两张用户身份识别SIM卡的双卡双待手机,实时监测该手机的剩余电量;Step 801, for a dual-card dual-standby mobile phone pre-installed with two user identification SIM cards, monitor the remaining power of the mobile phone in real time;

步骤802,判断手机的剩余电量是否低于阈值30%,即剩余电量为电池充满电量的30%,若是则进入步骤803;Step 802, determine whether the remaining power of the mobile phone is lower than the threshold 30%, that is, the remaining power is 30% of the full power of the battery, if so, go to step 803;

步骤803,根据SIM卡使用习惯从预先安装的两张SIM卡中选出第一SIM卡,将第一SIM卡(卡一)设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内专用的SIM卡,因为卡一为用户在预设周期内平均使用时长最长的SIM卡,而将对另一张卡(卡二)进行冻结。进入步骤804;Step 803, select the first SIM card from the two pre-installed SIM cards according to the usage habits of the SIM card, and set the first SIM card (card one) as the electronic device whose remaining power is less than the first set power threshold. The dedicated SIM card within the time period, because the first card is the SIM card that the user has used the longest on average in the preset period, and the other card (card two) will be frozen. Enter step 804;

步骤804,在电子设备上显示SIM卡冻结提示信息。如图4所示,在电子设备上显示的SIM卡冻结提示信息可以是“电量低于30%,系统将会自动对您使用较少的卡二进行部分冻结,并提示用户从两个选项“允许”或“禁止”对话框中进行选择。用户根据显示屏上的SIM卡冻结提示信息,点击屏幕选择了“允许”。则进入步骤805;若用户点击屏幕选择了“禁止”,则进入步骤812不做任何冻结操作。Step 804, displaying SIM card freezing prompt information on the electronic device. As shown in Figure 4, the SIM card freezing prompt information displayed on the electronic device can be "The battery is lower than 30%, the system will automatically partially freeze the SIM card that you use less, and prompt the user to choose from two options" "Allow" or "Forbidden" dialog box to select. The user clicks the screen to select "Allow" according to the SIM card freezing prompt information on the display screen. Then enter step 805; if the user clicks the screen and selects "Forbidden", then enter the step 812 does not do any freezing operation.

步骤805,对卡二的部分功能进行冻结,例如,从处于开启状态的进程中获取与卡二相关的进程;获取与卡二相关的进程的耗电速度;根据与卡二相关的进程的耗电速度,从与卡二相关的进程中筛选出耗电速度高于设定耗电速度阈值的进程作为目标进程;对目标进程进行冻结。进入步骤806;Step 805: Freeze some functions of the card 2, for example, obtain the process related to the card 2 from the processes in the open state; obtain the power consumption speed of the process related to the card 2; Electricity speed, from the processes related to card 2, select the process whose power consumption speed is higher than the set power consumption speed threshold as the target process; freeze the target process. Enter step 806;

步骤806,判断手机的剩余电量低于阈值20%,即剩余电量为电池充满电量的20%,若是则进入步骤807;Step 806, it is judged that the remaining power of the mobile phone is lower than the threshold 20%, that is, the remaining power is 20% of the full power of the battery, if so, go to step 807;

步骤807,对卡二的所有进程(包括耗电速度不高于设定耗电速度阈值的进程)也进行冻结,进入步骤808;Step 807: Freeze all processes of the card 2 (including the processes whose power consumption speed is not higher than the set power consumption speed threshold), and go to step 808;

步骤808,当对手机进行了充电之后,判断手机的剩余电量等于或高于阈值20%,若是则进入步骤809;Step 808, after charging the mobile phone, determine that the remaining power of the mobile phone is equal to or higher than the threshold 20%, and if so, go to step 809;

步骤809,对卡二的耗电速度不高于设定耗电速度阈值的进程进行解冻,对卡二的耗电速度高于设定耗电速度阈值的进程暂时不进行解冻。进入步骤810;Step 809: Unfreeze processes whose power consumption speed of card 2 is not higher than the set power consumption speed threshold, and temporarily do not unfreeze processes whose power consumption speed of card 2 is higher than the set power consumption speed threshold. Enter step 810;

步骤810,当对手机进行了充电时,判断手机的剩余电量是否达到或超过阈值30%,若是则进入步骤811;Step 810, when the mobile phone is charged, determine whether the remaining power of the mobile phone reaches or exceeds the threshold of 30%, and if so, go to step 811;

步骤811,对卡二的耗电速度高于设定耗电速度阈值的进程也进行解冻。此时,用户恢复了对手机中安装的卡一和卡二的全部功能的使用。Step 811, also unfreeze the process whose power consumption speed of the card 2 is higher than the set power consumption speed threshold. At this time, the user resumes the use of all functions of the card 1 and the card 2 installed in the mobile phone.

对安装在其上的两张SIM卡都可以同时进行上网的电子设备,则当电子设备的剩余电量小于第一设定电量阈值30%时,根据SIM卡使用习惯从预先安装的两张SIM卡中选出第一SIM卡,将第一SIM卡(卡一)设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内专用的SIM卡,因为卡一为用户在预设周期内平均使用时长最长的SIM卡。就需要对除去第一SIM卡之外的SIM卡的部分进程,例如对耗电速度高于设定耗电速度阈值的进程进行冻结,这样可以在一定程度上降低耗电量,延长待机时长。当不能及时给电子设备充电时,电子设备的剩余电量低于第二设定电量阈值20%,此时就需要进一步对除去第一SIM卡之外的SIM卡进行深度冻结,将除去第一SIM卡之外的SIM卡的耗电速度不高于设定耗电速度阈值的进程也进行解冻。这样就可以实现彻底对除去第一SIM卡之外的SIM卡相关的进程都进行冻结,以达到最大限度的减少耗电量,延长待机时长。For an electronic device with two SIM cards installed on it that can access the Internet at the same time, when the remaining power of the electronic device is less than 30% of the first set power threshold, the two pre-installed SIM cards will be used according to the SIM card usage habits. Select the first SIM card, and set the first SIM card (card one) as the dedicated SIM card of the electronic device in the time period when the remaining power of the electronic device is less than the first set power threshold value, because the card one is a preset SIM card for the user. The SIM card with the longest average usage time in the cycle. It is necessary to freeze some processes of the SIM card except the first SIM card, for example, to freeze the processes whose power consumption speed is higher than the set power consumption speed threshold, which can reduce power consumption to a certain extent and prolong the standby time. When the electronic device cannot be charged in time, the remaining power of the electronic device is lower than the second set power threshold by 20%. At this time, it is necessary to further freeze the SIM cards except the first SIM card, and the first SIM card will be removed. Processes other than SIM cards whose power consumption speed is not higher than the set power consumption speed threshold are also unfrozen. In this way, all processes related to the SIM card except the first SIM card can be completely frozen, so as to minimize the power consumption and prolong the standby time.

在一个实施例中,如图9所示,提供了一种进程处理装置900,包括:剩余电量检测模块902、第一SIM卡选择模块904及进程冻结模块906。其中,In one embodiment, as shown in FIG. 9 , a process processing apparatus 900 is provided, including: a remaining power detection module 902 , a first SIM card selection module 904 and a process freezing module 906 . in,

剩余电量检测模块902,用于检测电子设备的剩余电量,电子设备中预先安装了至少两张用户身份识别SIM卡。The remaining power detection module 902 is used to detect the remaining power of the electronic device, and at least two user identification SIM cards are pre-installed in the electronic device.

第一SIM卡选择模块904,用于当电子设备的剩余电量小于第一设定电量阈值时,则从至少两张用户身份识别SIM卡中选出第一SIM卡,将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。The first SIM card selection module 904 is used to select the first SIM card from at least two user identification SIM cards when the remaining power of the electronic device is less than the first set power threshold, and set the first SIM card as The SIM card used by the electronic device within the time period when the remaining power of the electronic device is less than the first set power threshold.

进程冻结模块906,用于从至少两张用户身份识别SIM卡中获取除第一SIM卡之外的第二SIM卡,对第二SIM卡的部分进程进行冻结。The process freezing module 906 is configured to obtain a second SIM card other than the first SIM card from the at least two user identification SIM cards, and freeze part of the process of the second SIM card.

在一个实施例中,如图10所示,进程冻结模块906,包括:第二SIM卡相关的进程获取模块906a、耗电速度获取模块906b、目标进程筛选模块906c及目标进程冻结模块906d。In one embodiment, as shown in FIG. 10 , the process freezing module 906 includes: a process acquisition module 906a related to the second SIM card, a power consumption speed acquisition module 906b, a target process screening module 906c and a target process freezing module 906d.

第二SIM卡相关的进程获取模块906a,用于从处于开启状态的进程中获取与第二SIM卡相关的进程;The process acquisition module 906a related to the second SIM card is used to acquire the process related to the second SIM card from the process in the open state;

耗电速度获取模块906b,用于获取与第二SIM卡相关的进程的耗电速度;a power consumption speed obtaining module 906b, used for obtaining the power consumption speed of the process related to the second SIM card;

目标进程筛选模块906c,用于根据与第二SIM卡相关的进程的耗电速度,从与第二SIM卡相关的进程中筛选出耗电速度高于设定耗电速度阈值的进程作为目标进程;The target process screening module 906c is configured to screen out a process whose power consumption speed is higher than the set power consumption speed threshold from the processes related to the second SIM card as the target process according to the power consumption speed of the process related to the second SIM card ;

目标进程冻结模块906d,用于对目标进程进行冻结。The target process freezing module 906d is used to freeze the target process.

在一个实施例中,进程冻结模块906还用于从处于开启状态的进程中获取与第二SIM卡相关的进程;获取与第二SIM卡相关的进程的CPU资源占用大小;根据与第二SIM卡相关的进程的CPU资源占用大小,从与第二SIM卡相关的进程中筛选出CPU资源占用大小高于设定CPU资源占用阈值的进程作为目标进程;对目标进程进行冻结。In one embodiment, the process freezing module 906 is further configured to acquire the process related to the second SIM card from the processes in the open state; acquire the CPU resource occupancy size of the process related to the second SIM card; The CPU resource occupancy size of the process related to the card is selected from the processes related to the second SIM card, and the process whose CPU resource occupancy size is higher than the set CPU resource occupancy threshold is selected as the target process; the target process is frozen.

在一个实施例中,剩余电量检测模块902还用于获取预设周期内的SIM卡历史使用数据;根据SIM卡历史使用数据分析得出预设周期内的SIM卡使用习惯,当电子设备的剩余电量小于第一设定电量阈值时,则根据预设周期内的SIM卡使用习惯从至少两张用户身份识别SIM卡中选出第一SIM卡;将第一SIM卡设置为电子设备在自身的剩余电量小于第一设定电量阈值的时间段内使用的SIM卡。In one embodiment, the remaining power detection module 902 is further configured to obtain historical SIM card usage data within a preset period; and obtain the SIM card usage habit within the preset period by analyzing the historical SIM card usage data. When the power is less than the first set power threshold, the first SIM card is selected from the at least two user identification SIM cards according to the SIM card usage habits in the preset period; the first SIM card is set as the electronic device in its own SIM card. The SIM card used within the time period when the remaining power is less than the first set power threshold.

在一个实施例中,剩余电量检测模块902还用于对预设周期内不同SIM卡的使用时长进行比较,得到最大的使用时长,获取最大的使用时长所对应的SIM卡;当电子设备的剩余电量小于第一设定电量阈值时,则将SIM卡作为第一SIM卡。In one embodiment, the remaining power detection module 902 is further configured to compare the usage durations of different SIM cards in a preset period, obtain the maximum usage duration, and obtain the SIM card corresponding to the maximum usage duration; When the power is less than the first set power threshold, the SIM card is used as the first SIM card.

在一个实施例中,剩余电量检测模块902还用于根据预设周期内的SIM卡使用时间段和在SIM卡使用时间段内所使用的SIM卡,计算得到预设周期内不同的SIM卡使用时间段内使用频率最高的SIM卡;当电子设备的剩余电量小于第一设定电量阈值时,获取电子设备的剩余电量小于第一设定电量阈值时的时间信息,将时间信息分入时间信息所属的SIM卡使用时间段;获取SIM卡使用时间段内使用频率最高的SIM卡,将SIM卡作为第一SIM卡。In one embodiment, the remaining power detection module 902 is further configured to calculate the usage of different SIM cards in the preset period according to the SIM card usage period in the preset period and the SIM cards used in the SIM card usage period The SIM card with the highest frequency in the time period; when the remaining power of the electronic device is less than the first set power threshold, obtain the time information when the remaining power of the electronic device is less than the first set power threshold, and divide the time information into the time information The SIM card usage time period to which it belongs; the SIM card with the highest frequency of use within the SIM card usage time period is obtained, and the SIM card is used as the first SIM card.

在一个实施例中,如图11所示,提供了一种进程处理装置900,还包括:In one embodiment, as shown in FIG. 11 , a process processing apparatus 900 is provided, further comprising:

进程解冻模块908,用于当检测到电子设备的剩余电量超过第二设定电量阈值时,则对第二SIM卡已冻结的进程进行解冻,第二设定电量阈值等于或大于第一设定电量阈值。The process unfreezing module 908 is used for unfreezing the process that has been frozen by the second SIM card when it is detected that the remaining power of the electronic device exceeds the second set power threshold, and the second set power threshold is equal to or greater than the first set Battery threshold.

上述进程处理装置中各个模块的划分仅用于举例说明,在其他实施例中,可将进程处理装置按照需要划分为不同的模块,以完成上述进程处理装置的全部或部分功能。The division of each module in the above-mentioned process processing apparatus is only used for illustration. In other embodiments, the process processing apparatus may be divided into different modules as required to complete all or part of the functions of the above-mentioned process processing apparatus.

一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行上述进程处理方法。A computer program product containing instructions, when executed on a computer, causes the computer to execute the above-described process processing method.

本申请实施例还提供了一种电子设备,包括存储器,处理器及存储在存储器上并可在处理器上运行的计算机程序,处理器执行计算机程序时实现上述各实施例所提供的进程处理方法的步骤。Embodiments of the present application further provide an electronic device, including a memory, a processor, and a computer program stored in the memory and running on the processor. When the processor executes the computer program, the process processing methods provided by the foregoing embodiments are implemented. A step of.

本申请实施例还提供了还提供了一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现上述各实施例所提供的进程处理方法的步骤。Embodiments of the present application also provide a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, implements the steps of the process processing methods provided by the above-mentioned embodiments.

本申请实施例还提供了一种电子设备。如图12所示,为了便于说明,仅示出了与本申请实施例相关的部分,具体技术细节未揭示的,请参照本申请实施例方法部分。该电子设备可以为包括手机、平板电脑、PDA(Personal Digital Assistant,个人数字助理)、POS(Point of Sales,销售终端)、车载电脑、穿戴式设备等任意终端设备,以电子设备为手机为例:The embodiments of the present application also provide an electronic device. As shown in FIG. 12 , for the convenience of description, only the parts related to the embodiments of the present application are shown, and the specific technical details are not disclosed, please refer to the method part of the embodiments of the present application. The electronic device may be any terminal device including a mobile phone, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales, a sales terminal), a vehicle-mounted computer, a wearable device, etc. The electronic device is a mobile phone as an example :

图12为与本申请实施例提供的电子设备相关的手机的部分结构的框图。参考图12,手机1200包括:射频(Radio Frequency,RF)电路1210、存储器1220、输入单元1230、显示单元1240、传感器1250、音频电路1260、无线保真(wireless fidelity,WiFi)模块1270、处理器1280、以及电源1290等部件。本领域技术人员可以理解,图12所示的手机结构并不构成对手机的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。FIG. 12 is a block diagram of a partial structure of a mobile phone related to an electronic device provided by an embodiment of the present application. Referring to FIG. 12 , the mobile phone 1200 includes: a radio frequency (RF) circuit 1210, a memory 1220, an input unit 1230, a display unit 1240, a sensor 1250, an audio circuit 1260, a wireless fidelity (WiFi) module 1270, and a processor 1280, and power supply 1290 and other components. Those skilled in the art can understand that the structure of the mobile phone shown in FIG. 12 does not constitute a limitation on the mobile phone, and may include more or less components than shown, or combine some components, or arrange different components.

其中,RF电路1210可用于收发信息或通话过程中,信号的接收和发送,可将基站的下行信息接收后,给处理器1280处理;也可以将上行的数据发送给基站。通常,RF电路包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器(Low Noise Amplifier,LNA)、双工器等。此外,RF电路1210还可以通过无线通信与网络和其他设备通信。上述无线通信可以使用任一通信标准或协议,包括但不限于全球移动通讯系统(Global System ofMobile communication,GSM)、通用分组无线服务(General Packet Radio Service,GPRS)、码分多址(Code Division Multiple Access,CDMA)、宽带码分多址(Wideband CodeDivision Multiple Access,WCDMA)、长期演进(Long Term Evolution,LTE))、电子邮件、短消息服务(Short Messaging Service,SMS)等。The RF circuit 1210 can be used for receiving and sending signals during sending and receiving of information or during a call. After receiving the downlink information of the base station, it can be processed by the processor 1280; it can also send the uplink data to the base station. Typically, the RF circuit includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, RF circuitry 1210 may also communicate with networks and other devices via wireless communications. The above-mentioned wireless communication can use any communication standard or protocol, including but not limited to Global System of Mobile communication (GSM), General Packet Radio Service (General Packet Radio Service, GPRS), Code Division Multiple Access (Code Division Multiple Access) Access, CDMA), Wideband Code Division Multiple Access (Wideband Code Division Multiple Access, WCDMA), Long Term Evolution (Long Term Evolution, LTE)), email, Short Messaging Service (Short Messaging Service, SMS) and the like.

存储器1220可用于存储软件程序以及模块,处理器1280通过运行存储在存储器1220的软件程序以及模块,从而执行手机的各种功能应用以及数据处理。存储器1220可主要包括程序存储区和数据存储区,其中,程序存储区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能的应用程序、图像播放功能的应用程序等)等;数据存储区可存储根据手机的使用所创建的数据(比如音频数据、通讯录等)等。此外,存储器1220可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 1220 can be used to store software programs and modules, and the processor 1280 executes various functional applications and data processing of the mobile phone by running the software programs and modules stored in the memory 1220 . The memory 1220 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function (such as an application program for a sound playback function, an application program for an image playback function, etc.), etc.; The data storage area may store data (such as audio data, address book, etc.) created according to the usage of the mobile phone, and the like. Additionally, memory 1220 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.

输入单元1230可用于接收输入的数字或字符信息,以及产生与手机1200的用户设置以及功能控制有关的键信号输入。具体地,输入单元1230可包括触控面板1231以及其他输入设备1232。触控面板1231,也可称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板1231上或在触控面板1231附近的操作),并根据预先设定的程式驱动相应的连接装置。在一个实施例中,触控面板1231可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器1280,并能接收处理器1280发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板1231。除了触控面板1231,输入单元1230还可以包括其他输入设备1232。具体地,其他输入设备1232可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)等中的一种或多种。The input unit 1230 may be used to receive input numerical or character information, and generate key signal input related to user settings and function control of the mobile phone 1200 . Specifically, the input unit 1230 may include a touch panel 1231 and other input devices 1232 . The touch panel 1231, also referred to as a touch screen, can collect the user's touch operations on or near it (such as the user using a finger, a stylus, etc., any suitable object or accessory on or near the touch panel 1231) operation), and drive the corresponding connection device according to the preset program. In one embodiment, the touch panel 1231 may include two parts, a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the touch controller. To the processor 1280, and can receive the command sent by the processor 1280 and execute it. In addition, the touch panel 1231 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. Besides the touch panel 1231 , the input unit 1230 may also include other input devices 1232 . Specifically, other input devices 1232 may include, but are not limited to, one or more of physical keyboards, function keys (such as volume control keys, switch keys, etc.), and the like.

显示单元1240可用于显示由用户输入的信息或提供给用户的信息以及手机的各种菜单。显示单元1240可包括显示面板1241。在一个实施例中,可以采用液晶显示器(Liquid Crystal Display,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板1241。在一个实施例中,触控面板1231可覆盖显示面板1241,当触控面板1231检测到在其上或附近的触摸操作后,传送给处理器1280以确定触摸事件的类型,随后处理器1280根据触摸事件的类型在显示面板1241上提供相应的视觉输出。虽然在图10中,触控面板1231与显示面板1241是作为两个独立的部件来实现手机的输入和输入功能,但是在某些实施例中,可以将触控面板1231与显示面板1241集成而实现手机的输入和输出功能。The display unit 1240 may be used to display information input by the user or information provided to the user and various menus of the mobile phone. The display unit 1240 may include a display panel 1241 . In one embodiment, the display panel 1241 may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like. In one embodiment, the touch panel 1231 may cover the display panel 1241. When the touch panel 1231 detects a touch operation on or near it, the touch panel 1231 transmits it to the processor 1280 to determine the type of the touch event, and then the processor 1280 determines the type of the touch event according to the The type of touch event provides a corresponding visual output on the display panel 1241 . Although in FIG. 10, the touch panel 1231 and the display panel 1241 are used as two independent components to realize the input and input functions of the mobile phone, in some embodiments, the touch panel 1231 and the display panel 1241 can be integrated to form a Realize the input and output functions of the mobile phone.

手机1200还可包括至少一种传感器1250,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板1241的亮度,接近传感器可在手机移动到耳边时,关闭显示面板1241和/或背光。运动传感器可包括加速度传感器,通过加速度传感器可检测各个方向上加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换)、振动识别相关功能(比如计步器、敲击)等;此外,手机还可配置陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器等。Cell phone 1200 may also include at least one sensor 1250, such as light sensors, motion sensors, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 1241 according to the brightness of the ambient light, and the proximity sensor may turn off the display panel 1241 and/or when the mobile phone is moved to the ear. or backlight. Motion sensors can include acceleration sensors, which can detect the magnitude of acceleration in all directions, and can detect the magnitude and direction of gravity when stationary. It can be used for applications that recognize the posture of mobile phones (such as switching between horizontal and vertical screens), and vibration recognition related functions (such as Pedometer, tapping), etc.; in addition, the mobile phone can also be equipped with other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared sensor, etc.

音频电路1260、扬声器1261和传声器1262可提供用户与手机之间的音频接口。音频电路1260可将接收到的音频数据转换后的电信号,传输到扬声器1261,由扬声器1261转换为声音信号输出;另一方面,传声器1262将收集的声音信号转换为电信号,由音频电路1260接收后转换为音频数据,再将音频数据输出处理器1280处理后,经RF电路1210可以发送给另一手机,或者将音频数据输出至存储器1220以便后续处理。Audio circuit 1260, speaker 1261 and microphone 1262 may provide an audio interface between the user and the cell phone. The audio circuit 1260 can transmit the received audio data converted electrical signals to the speaker 1261, and the speaker 1261 converts them into sound signals for output; on the other hand, the microphone 1262 converts the collected sound signals into electrical signals, and the audio circuit 1260 converts the collected sound signals into electrical signals. After receiving, the audio data is converted into audio data, and then the audio data is processed by the output processor 1280, and can be sent to another mobile phone via the RF circuit 1210, or the audio data can be output to the memory 1220 for subsequent processing.

WiFi属于短距离无线传输技术,手机通过WiFi模块1270可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图12示出了WiFi模块1270,但是可以理解的是,其并不属于手机1200的必须构成,可以根据需要而省略。WiFi is a short-distance wireless transmission technology. The mobile phone can help users to send and receive emails, browse web pages, and access streaming media through the WiFi module 1270. It provides users with wireless broadband Internet access. Although FIG. 12 shows the WiFi module 1270, it can be understood that it is not a necessary component of the mobile phone 1200 and can be omitted as required.

处理器1280是手机的控制中心,利用各种接口和线路连接整个手机的各个部分,通过运行或执行存储在存储器1220内的软件程序和/或模块,以及调用存储在存储器1220内的数据,执行手机的各种功能和处理数据,从而对手机进行整体监控。在一个实施例中,处理器1280可包括一个或多个处理单元。在一个实施例中,处理器1280可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等;调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器1280中。The processor 1280 is the control center of the mobile phone, and uses various interfaces and lines to connect various parts of the entire mobile phone, by running or executing the software programs and/or modules stored in the memory 1220, and calling the data stored in the memory 1220. Various functions of the mobile phone and processing data, so as to monitor the mobile phone as a whole. In one embodiment, the processor 1280 may include one or more processing units. In one embodiment, the processor 1280 may integrate an application processor and a modem processor, wherein the application processor mainly handles the operating system, user interface and application programs, etc.; the modem processor mainly handles wireless communication. It can be understood that, the above-mentioned modulation and demodulation processor may not be integrated into the processor 1280.

手机1200还包括给各个部件供电的电源1290(比如电池),优选的,电源可以通过电源管理系统与处理器1280逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The mobile phone 1200 also includes a power supply 1290 (such as a battery) for supplying power to various components. Preferably, the power supply can be logically connected to the processor 1280 through a power management system, so as to manage charging, discharging, and power consumption management functions through the power management system.

在一个实施例中,手机1200还可以包括摄像头、蓝牙模块等。In one embodiment, the mobile phone 1200 may further include a camera, a Bluetooth module, and the like.

本申请所使用的对存储器、存储、数据库或其它介质的任何引用可包括非易失性和/或易失性存储器。合适的非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM),它用作外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDR SDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus)直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)。Any reference to a memory, storage, database, or other medium as used herein may include non-volatile and/or volatile memory. Suitable nonvolatile memory may include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM), which acts as external cache memory. By way of illustration and not limitation, RAM is available in various forms such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous Link (Synchlink) DRAM (SLDRAM), Memory Bus (Rambus) Direct RAM (RDRAM), Direct Memory Bus Dynamic RAM (DRDRAM), and Memory Bus Dynamic RAM (RDRAM).

以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。The above-mentioned embodiments only represent several embodiments of the present application, and the descriptions thereof are relatively specific and detailed, but should not be construed as a limitation on the scope of the patent of the present application. It should be pointed out that for those skilled in the art, without departing from the concept of the present application, several modifications and improvements can be made, which all belong to the protection scope of the present application. Therefore, the scope of protection of the patent of the present application shall be subject to the appended claims.

Claims (10)

1. A process processing method, comprising:
detecting the residual electric quantity of electronic equipment, wherein at least two SIM cards for user identity recognition are pre-installed in the electronic equipment;
when the residual electric quantity of the electronic equipment is smaller than a first set electric quantity threshold value, selecting a first SIM card from at least two SIM cards for user identity recognition, and setting the first SIM card as the SIM card used by the electronic equipment in a time period when the self residual electric quantity of the electronic equipment is smaller than the first set electric quantity threshold value;
and acquiring a second SIM card except the first SIM card from the at least two SIM cards for user identity identification, and freezing partial process of the second SIM card.
2. The method of claim 1, wherein freezing a portion of the process of the second SIM card comprises:
acquiring a process related to a second SIM card from the process in the open state;
acquiring the power consumption speed of the process related to the second SIM card;
screening out a process with the power consumption speed higher than a set power consumption speed threshold from the processes related to the second SIM card as a target process according to the power consumption speed of the process related to the second SIM card;
and freezing the target process.
3. The method of claim 1, wherein freezing a portion of the process with the second SIM card further comprises:
acquiring a process related to a second SIM card from the process in the open state;
acquiring the CPU resource occupation size of the process related to the second SIM card;
according to the CPU resource occupation size of the process related to the second SIM card, screening out a process with the CPU resource occupation size higher than a set CPU resource occupation threshold value from the process related to the second SIM card as a target process;
and freezing the target process.
4. The method according to claim 1, wherein when the remaining power of the electronic device is less than a first set power threshold, selecting a first SIM card from at least two SIM cards for user identification, and setting the first SIM card as the SIM card used by the electronic device in a time period in which the remaining power of the electronic device is less than the first set power threshold, comprises:
acquiring historical use data of the SIM card in a preset period;
analyzing the historical use data of the SIM card to obtain the use habit of the SIM card in the preset period, and selecting a first SIM card from at least two SIM cards for user identity recognition according to the use habit of the SIM card in the preset period when the residual electric quantity of the electronic equipment is smaller than a first set electric quantity threshold value;
and setting the first SIM card as the SIM card used by the electronic equipment within a time period that the self residual electric quantity is less than a first set electric quantity threshold value.
5. The method according to claim 4, wherein the historical usage data of the SIM cards comprises usage time lengths of different SIM cards in a preset period;
analyzing the historical use data of the SIM card to obtain the use habit of the SIM card in the preset period, and selecting a first SIM card from at least two SIM cards for user identity recognition according to the use habit of the SIM card in the preset period when the residual electric quantity of the electronic equipment is smaller than a first set electric quantity threshold value, wherein the method comprises the following steps:
comparing the service durations of different SIM cards in the preset period to obtain the maximum service duration, and obtaining the SIM card corresponding to the maximum service duration;
and when the residual electric quantity of the electronic equipment is smaller than a first set electric quantity threshold value, taking the SIM card as a first SIM card.
6. The method of claim 4, wherein the historical SIM card usage data comprises a period of SIM card usage time in a preset period and a SIM card used in the period of SIM card usage time;
analyzing the historical use data of the SIM card to obtain the use habit of the SIM card in the preset period, and selecting a first SIM card from at least two SIM cards for user identity recognition according to the use habit of the SIM card in the preset period when the residual electric quantity of the electronic equipment is smaller than a first set electric quantity threshold value, wherein the method comprises the following steps:
calculating to obtain the SIM card with the highest use frequency in different SIM card use time periods in a preset period according to the SIM card use time period in the preset period and the SIM card used in the SIM card use time period;
when the residual electric quantity of the electronic equipment is smaller than a first set electric quantity threshold value, acquiring time information when the residual electric quantity of the electronic equipment is smaller than the first set electric quantity threshold value, and dividing the time information into the service time period of an SIM card to which the time information belongs;
and acquiring the SIM card with the highest use frequency in the SIM card use time period, and taking the SIM card as the first SIM card.
7. The method according to claim 1, wherein after the obtaining a second SIM card other than the first SIM card from the at least two SIM cards, and freezing a part of the process of the second SIM card, the method comprises:
and when detecting that the residual electric quantity of the electronic equipment exceeds a second set electric quantity threshold value, unfreezing the frozen process of the second SIM card, wherein the second set electric quantity threshold value is equal to or larger than the first set electric quantity threshold value.
8. A process processing apparatus, the apparatus comprising:
the system comprises a residual electric quantity detection module, a residual electric quantity detection module and a control module, wherein the residual electric quantity detection module is used for detecting the residual electric quantity of electronic equipment, and at least two SIM cards for user identity recognition are pre-installed in the electronic equipment;
the first SIM card selection module is used for selecting a first SIM card from at least two SIM cards identified by user identities according to the use habit of the SIM card when the residual electric quantity of the electronic equipment is smaller than a first set electric quantity threshold value, and setting the first SIM card as the SIM card used by the electronic equipment in a time period when the self residual electric quantity is smaller than the first set electric quantity threshold value;
and the process freezing module is used for acquiring a second SIM card except the first SIM card from the at least two SIM cards and freezing partial processes of the second SIM card.
9. An electronic device comprising a memory and a processor, the memory having stored therein a computer program, wherein the instructions, when executed by the processor, cause the processor to perform the steps of the process handling method according to any one of claims 1 to 7.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the process-handling method of any one of claims 1 to 7.
CN201711484459.3A 2017-12-29 2017-12-29 Process processing method and device, electronic equipment and computer readable storage medium Pending CN109995930A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711484459.3A CN109995930A (en) 2017-12-29 2017-12-29 Process processing method and device, electronic equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711484459.3A CN109995930A (en) 2017-12-29 2017-12-29 Process processing method and device, electronic equipment and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN109995930A true CN109995930A (en) 2019-07-09

Family

ID=67110319

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711484459.3A Pending CN109995930A (en) 2017-12-29 2017-12-29 Process processing method and device, electronic equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN109995930A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021121176A1 (en) * 2019-12-18 2021-06-24 深圳优克云联科技有限公司 Method and device for updating status information of sim card, and server

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102075630A (en) * 2011-01-21 2011-05-25 惠州Tcl移动通信有限公司 Mobile terminal capable of automatically switching standby mode of SIM card and method thereof
CN103455407A (en) * 2013-09-03 2013-12-18 小米科技有限责任公司 Mobile terminal CPU (Central Processing Unit) occupation rate monitoring method and device and mobile terminal
CN104159281A (en) * 2014-08-27 2014-11-19 深圳市中兴移动通信有限公司 A method and a device for saving electricity of a mobile terminal
CN104199696A (en) * 2014-08-28 2014-12-10 刘勇 Electric consumption control method and system and intelligent terminal
CN105446776A (en) * 2015-11-20 2016-03-30 北京金山安全软件有限公司 Application program closing method and device and electronic equipment
CN105468409A (en) * 2015-11-20 2016-04-06 北京金山安全软件有限公司 Application program closing method and device and electronic equipment
CN105955869A (en) * 2016-05-12 2016-09-21 捷开通讯科技(上海)有限公司 Electronic device abnormal application monitoring and processing system and method

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102075630A (en) * 2011-01-21 2011-05-25 惠州Tcl移动通信有限公司 Mobile terminal capable of automatically switching standby mode of SIM card and method thereof
CN103455407A (en) * 2013-09-03 2013-12-18 小米科技有限责任公司 Mobile terminal CPU (Central Processing Unit) occupation rate monitoring method and device and mobile terminal
CN104159281A (en) * 2014-08-27 2014-11-19 深圳市中兴移动通信有限公司 A method and a device for saving electricity of a mobile terminal
CN104199696A (en) * 2014-08-28 2014-12-10 刘勇 Electric consumption control method and system and intelligent terminal
CN105446776A (en) * 2015-11-20 2016-03-30 北京金山安全软件有限公司 Application program closing method and device and electronic equipment
CN105468409A (en) * 2015-11-20 2016-04-06 北京金山安全软件有限公司 Application program closing method and device and electronic equipment
CN105955869A (en) * 2016-05-12 2016-09-21 捷开通讯科技(上海)有限公司 Electronic device abnormal application monitoring and processing system and method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021121176A1 (en) * 2019-12-18 2021-06-24 深圳优克云联科技有限公司 Method and device for updating status information of sim card, and server

Similar Documents

Publication Publication Date Title
EP3514684B1 (en) Memory recovery method and apparatus
CN109144232B (en) Process processing method and device, electronic equipment and computer readable storage medium
CN109992398B (en) Resource management method, resource management device, mobile terminal and computer-readable storage medium
CN109992400A (en) Resource allocation method, device, mobile terminal, and computer-readable storage medium
CN112703714A (en) Application program processing method and device, computer equipment and computer readable storage medium
CN109992378A (en) Application freezing method, device, terminal and computer-readable storage medium
CN110032266B (en) Information processing method, apparatus, computer device, and computer-readable storage medium
CN110032431A (en) Application processing method and device, electronic equipment and computer readable storage medium
CN109992364B (en) Application freezing method, apparatus, computer device, and computer-readable storage medium
CN110032397B (en) Application processing method and device, electronic equipment and computer readable storage medium
CN109992425B (en) Information processing method, information processing device, computer equipment and computer readable storage medium
CN110032439A (en) Resource management method, resource management device, mobile terminal and computer-readable storage medium
CN110018885B (en) Application program freezing method and device, storage medium and terminal
CN110046032A (en) Applied program processing method and device, electronic equipment, computer readable storage medium
CN110008007B (en) Application program freezing method and device, storage medium and terminal
CN109992376B (en) Application freezing method, device, terminal and computer readable storage medium
JP7272694B2 (en) Method and terminal for reducing power consumption of terminal
CN107832131B (en) Application program closing method and device, storage medium and electronic equipment
CN110032430B (en) Application program processing method and device, electronic equipment and computer readable storage medium
CN110018886B (en) Application state switching method and device, electronic equipment and readable storage medium
CN110018888A (en) Method for managing resource, device, mobile terminal and computer readable storage medium
CN109995930A (en) Process processing method and device, electronic equipment and computer readable storage medium
CN110035169A (en) Process processing method and apparatus, electronic device, and computer-readable storage medium
CN109375995B (en) Application freezing method and device, storage medium and electronic equipment
CN109511139B (en) WIFI control method and device, mobile device and computer-readable storage medium

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20190709

RJ01 Rejection of invention patent application after publication