The invention discloses a control method for the Dose mode of mobile terminal, which includes: judging whether the mobile terminal satisfies the mode switching condition; detecting whether the mobile terminal has a virtual motion sensor if the mobile terminal satisfies the mode switching condition; and judging the duration when the mobile terminal satisfies the mode switching condition if the mobile terminal has a virtual motion sensor. If the duration of the mobile terminal satisfying the mode switching condition exceeds the preset time threshold, it will enter Doze mode. The control method of the Doze mode of the mobile terminal provided by the invention can make the mobile terminal enter the Doze mode as long as it satisfies the condition of entering the Doze mode without the motion sensor, and can normally restrict the background operation of the mobile terminal and its application software, so as to reduce the standby power consumption of the mobile terminal and optimize the endurance ability of the mobile terminal.
【技术实现步骤摘要】
移动终端的Doze模式的控制方法
本专利技术涉及移动终端
,尤其涉及一种移动终端的Doze模式的控制方法。
技术介绍
Google从android6.0起就开始支持doze模式。doze原理是当手机灭屏静置一段时间,且这段时间内没有充电器插入,则进入doze模式。doze模式通过限制各种应用的alarm、wakelock、网络连接等来降低待机功耗。但google代码逻辑要求手机必须有运动传感器,如果检测到没有运动传感器,就会直接退出doze模式,这样就无法降低待机功耗。google加入此设计可能是为了有好的用户体验,即假设用户移动手机,就立即退出doze模式,解除对各种应用的限制。目前对于中高端产品,加一个运动传感器不是大问题,但对于低端成本手机,加入额外的硬件无疑削弱产品在市场上的竞争力。因此有必要研发一种无运动传感器的移动终端支持doze模式的方法,来优化待机功耗。
技术实现思路
为了达到上述的目的,本专利技术采用了如下的技术方案:一种移动终端的Doze模式的控制方法,所述控制方法包括:判断所述移动终端是否满足模式切换条件;若所述移动终端满足模式切换条件,则检测所述移动终端是否设置有虚拟运动传感器;若所述移动终端设置有虚拟运动传感器,则判断所述移动终端满足模式切换条件的持续时间是否超过预设的时间阈值;若所述移动终端满足模式切换条件的持续时间超过预设的时间阈值,则进入Doze模式。优选地,所述检测所述移动终端是否设置有虚拟运动传感器的步骤具体包括:判断所述移动终端的应用框架层是否包含运动传感器对象。优选地,所述运动传感器对象的参数至少包括名称、版本、型 ...
【技术保护点】
1.一种移动终端的Doze模式的控制方法,其特征在于,所述控制方法包括:判断所述移动终端是否满足模式切换条件;若所述移动终端满足模式切换条件,则检测所述移动终端是否设置有虚拟运动传感器;若所述移动终端设置有虚拟运动传感器,则判断所述移动终端满足模式切换条件的持续时间是否超过预设的时间阈值;若所述移动终端满足模式切换条件的持续时间超过预设的时间阈值,则进入Doze模式。
【技术特征摘要】
1.一种移动终端的Doze模式的控制方法,其特征在于,所述控制方法包括:判断所述移动终端是否满足模式切换条件;若所述移动终端满足模式切换条件,则检测所述移动终端是否设置有虚拟运动传感器;若所述移动终端设置有虚拟运动传感器,则判断所述移动终端满足模式切换条件的持续时间是否超过预设的时间阈值;若所述移动终端满足模式切换条件的持续时间超过预设的时间阈值,则进入Doze模式。2.根据权利要求1所述的控制方法,其特征在于,所述检测所述移动终端是否设置有虚拟运动传感器的步骤具体包括:判断所述移动终端的应用框架层是否包含运动传感器对象。3.根据权利要求2所述的控制方法,其特征在于,所述运动传感器对象的参数至少包括名称、版本、型号和厂商参数。4.根据权利要求1所述的控制方法,其特征在于,所述模式切换...
【专利技术属性】
技术研发人员:郑金国,张燕香,
申请(专利权)人:惠州TCL移动通信有限公司,
类型:发明
国别省市:广东,44
还没有人留言评论。发表了对其他浏览者有用的留言会获得科技券。