CN113015226B - Network connection method and device - Google Patents

Network connection method and device Download PDF

Info

Publication number
CN113015226B
CN113015226B CN202110204759.1A CN202110204759A CN113015226B CN 113015226 B CN113015226 B CN 113015226B CN 202110204759 A CN202110204759 A CN 202110204759A CN 113015226 B CN113015226 B CN 113015226B
Authority
CN
China
Prior art keywords
network
terminal
condition
level
threshold
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.)
Active
Application number
CN202110204759.1A
Other languages
Chinese (zh)
Other versions
CN113015226A (en
Inventor
拓欣依
吴梦想
刘殷卉
罗佳玮
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Vivo Mobile Communication Co Ltd filed Critical Vivo Mobile Communication Co Ltd
Priority to CN202110204759.1A priority Critical patent/CN113015226B/en
Publication of CN113015226A publication Critical patent/CN113015226A/en
Priority to PCT/CN2022/076560 priority patent/WO2022179425A1/en
Application granted granted Critical
Publication of CN113015226B publication Critical patent/CN113015226B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/14Reselecting a network or an air interface
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/24Reselection being triggered by specific parameters
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/24Reselection being triggered by specific parameters
    • H04W36/30Reselection being triggered by specific parameters by measured or perceived connection quality data
    • 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)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The application discloses a network connection method and device, wherein the network connection method comprises the following steps: under the condition that the electronic equipment is connected to a first network, acquiring the temperature grade of the terminal and the first quality grade of the first network; and under the condition that the temperature grade and the first quality grade meet the preset conditions, the control terminal is switched to the second network, and an optimization program corresponding to the preset conditions is executed. According to the embodiment of the application, on one hand, the temperature of the terminal can be reduced, the power consumption abnormality caused by overhigh temperature of the terminal is prevented, the endurance time of the terminal is further ensured, on the other hand, the 5G network can be automatically optimized, the mobile phone is controlled to be connected to the 4G network during the period, the situation that the mobile phone is blocked and cut off for a long time is prevented, and the Internet surfing experience of a user is ensured.

Description

一种网络连接方法及装置A network connection method and device

技术领域technical field

本申请属于通信技术领域,具体涉及一种网络连接方法及装置。The present application belongs to the technical field of communication, and in particular relates to a network connection method and device.

背景技术Background technique

在相关技术中,手机等电子设备已支持5G网络,但由于5G功耗较大,容易造成手机发热,缩短手机续航能力。In related technologies, electronic devices such as mobile phones already support 5G networks, but due to the high power consumption of 5G, it is easy to cause the mobile phone to heat up and shorten the battery life of the mobile phone.

同时,5G网络的组网方式包括独立组网(Standalone,SA)和非独立组网(Non-Standalone,NSA),对于非独立组网的场景,由于其网络构成复杂,容易存在5G断流,用户无法上网的情况。At the same time, the networking methods of 5G networks include standalone networking (Standalone, SA) and non-standalone networking (Non-Standalone, NSA). For the scenario of non-standalone networking, due to the complex network structure, it is easy to have 5G disconnection and users cannot access the Internet.

因此,如何减少5G断流和5G网络带来的发热情况,是目前亟待解决的技术问题。Therefore, how to reduce 5G outages and heat generation caused by 5G networks is a technical problem that needs to be solved urgently.

发明内容Contents of the invention

本申请实施例的目的是提供一种网络连接方法及装置,能够提高5G驻留率,并降低5G网络的功耗。The purpose of the embodiments of the present application is to provide a network connection method and device, which can improve the 5G resident rate and reduce the power consumption of the 5G network.

为了解决上述技术问题,本申请是这样实现的:In order to solve the above-mentioned technical problems, the application is implemented as follows:

第一方面,本申请实施例提供了一种终端网络连接方法,包括:In the first aspect, the embodiment of the present application provides a terminal network connection method, including:

在终端连接至第一网络的情况下,获取终端的温度等级和第一网络的第一质量等级;If the terminal is connected to the first network, acquire the temperature level of the terminal and the first quality level of the first network;

在温度等级和第一质量等级满足预设条件的情况下,控制终端切换至第二网络,并执行预设条件对应的优化程序。When the temperature level and the first quality level meet the preset conditions, the control terminal switches to the second network, and executes an optimization program corresponding to the preset conditions.

第二方面,本申请实施例提供了一种终端网络连接装置,包括:In the second aspect, the embodiment of the present application provides a terminal network connection device, including:

获取模块,用于在终端连接至第一网络的情况下,获取终端的温度等级和第一网络的第一质量等级;An acquisition module, configured to acquire the temperature level of the terminal and the first quality level of the first network when the terminal is connected to the first network;

控制模块,用于在温度等级和第一质量等级满足预设条件的情况下,控制终端切换至第二网络,并执行预设条件对应的优化程序。The control module is configured to switch the control terminal to the second network and execute an optimization program corresponding to the preset conditions when the temperature level and the first quality level meet the preset conditions.

第三方面,本申请实施例提供了一种终端,该终端包括处理器、存储器及存储在提供的存储器上并可在提供的处理器上运行的程序或指令,提供的程序或指令被提供的处理器执行时实现如第一方面提供的终端网络连接方法的步骤。In a third aspect, an embodiment of the present application provides a terminal, the terminal includes a processor, a memory, and a program or instruction stored in the provided memory and operable on the provided processor. When the provided program or instruction is executed by the provided processor, the steps of the terminal network connection method provided in the first aspect are implemented.

第四方面,本申请实施例提供了一种可读存储介质,提供的可读存储介质上存储程序或指令,提供的程序或指令被处理器执行时实现如第一方面提供的终端网络连接方法的步骤。In a fourth aspect, an embodiment of the present application provides a readable storage medium, in which programs or instructions are stored, and when the provided programs or instructions are executed by a processor, the steps of the terminal network connection method provided in the first aspect are implemented.

第五方面,本申请实施例提供了一种芯片,提供的芯片包括处理器和通信接口,提供的通信接口和提供的处理器耦合,提供的处理器用于运行程序或指令,实现如第一方面提供的终端网络连接方法的步骤。In the fifth aspect, the embodiment of the present application provides a chip, the provided chip includes a processor and a communication interface, the provided communication interface is coupled to the provided processor, and the provided processor is used to run programs or instructions to implement the steps of the terminal network connection method provided in the first aspect.

在本申请实施例中,第一网络具体为5G网络,第二网络具体为4G网络,能够理解的是,本申请实施例在于解决“高速”网络下的发热和断流情况,因此,随着网络发展,第一网络还可能是“6G”、“7G”或其他高速网络,本申请实施例对第一网络和第二网络的具体网络类型不做限定。In the embodiment of the present application, the first network is specifically a 5G network, and the second network is specifically a 4G network. It can be understood that the embodiment of the present application aims to solve the problem of heat generation and outages under the "high-speed" network. Therefore, as the network develops, the first network may also be "6G", "7G" or other high-speed networks. The embodiment of the present application does not limit the specific network types of the first network and the second network.

下面以第一网络为5G网络来进行举例说明。具体地,在终端,如手机或平板电脑等设备连接至5G网络时,设备持续获取自身的温度等级,以及5G网络的质量等级。The following uses an example in which the first network is a 5G network for illustration. Specifically, when a terminal, such as a mobile phone or a tablet computer, is connected to a 5G network, the device continuously obtains its own temperature level and the quality level of the 5G network.

其中,温度等级是根据终端的温度值划分的预设等级,每个等级对应一个温度区间,比如,30℃以下为一个温度区间,对应温度等级0,30℃至35℃为一个温度区间,对应温度等级1,35℃至40℃为一个温度区间,对应温度等级3,以此类推,即温度等级越高,说明终端的温度越高。Among them, the temperature level is a preset level divided according to the temperature value of the terminal. Each level corresponds to a temperature range. For example, below 30°C is a temperature range, corresponding to temperature level 0, 30°C to 35°C is a temperature range, corresponding to temperature level 1, 35°C to 40°C is a temperature range, corresponding to temperature level 3, and so on.

同理,第一质量等级是反应第一网络的网络连接质量的预设等级,其中第一质量等级0、第一质量等级1、第一质量等级2中,第一质量等级越高,则说明第一网络的网络质量越差(如出现卡断、延迟、断流等情况)。Similarly, the first quality level is a preset level reflecting the quality of the network connection of the first network. Among the first quality level 0, the first quality level 1, and the first quality level 2, the higher the first quality level, the worse the network quality of the first network (for example, when there is a freeze, delay, or disconnection, etc.).

终端持续判断温度等级和第一质量等级是否满足预设条件,当满足预设条件时,则控制终端暂时断开5G连接,改为连接至4G网络,并执行对应的优化程序。The terminal continues to judge whether the temperature level and the first quality level meet the preset conditions. When the preset conditions are met, the control terminal temporarily disconnects the 5G connection, connects to the 4G network instead, and executes the corresponding optimization program.

本申请实施例通过同时监控终端的温度和5G网络质量,在温度高和/或5G网络质量差(如卡顿或断流等)时,暂时断开5G网络并切换至4G网络,同时根据终端的温度和/或5G网络质量,对应执行优化程序,一方面能够降低终端的温度,防止终端温度过高导致耗电异常,进而保证终端的续航时间,另一方面能够对5G网络进行优化,并在此期间控制手机连接至4G网络,防止手机长时间处于网络卡断、断流的情况,提高用户的上网体验。The embodiment of the present application monitors the temperature of the terminal and the quality of the 5G network at the same time. When the temperature is high and/or the quality of the 5G network is poor (such as freezing or disconnection), the 5G network is temporarily disconnected and switched to the 4G network. At the same time, according to the temperature of the terminal and/or the quality of the 5G network, an optimization program is executed correspondingly. On the one hand, it can reduce the temperature of the terminal to prevent abnormal power consumption caused by excessive terminal temperature, thereby ensuring the battery life of the terminal. On the other hand, it can optimize the 5G network and control the mobile phone to connect to the 4G network during this period. To improve the user's online experience.

附图说明Description of drawings

图1示出了根据本申请实施例的网络连接方法的流程图之一;Fig. 1 shows one of the flowcharts of the network connection method according to the embodiment of the present application;

图2示出了根据本申请实施例的网络连接方法的流程图之二;Fig. 2 shows the second flow chart of the network connection method according to the embodiment of the present application;

图3示出了根据本申请实施例的网络连接方法的流程图之三;Fig. 3 shows the third flowchart of the network connection method according to the embodiment of the present application;

图4示出了根据本申请实施例的网络连接方法的流程图之四;FIG. 4 shows a fourth flowchart of a network connection method according to an embodiment of the present application;

图5示出了根据本申请实施例的网络连接方法的流程图之五;FIG. 5 shows a fifth flowchart of a network connection method according to an embodiment of the present application;

图6示出了根据本申请实施例的网络连接方法的流程图之六;FIG. 6 shows a sixth flowchart of a network connection method according to an embodiment of the present application;

图7示出了根据本申请实施例的网络连接方法的流程图之七;FIG. 7 shows a seventh flowchart of a network connection method according to an embodiment of the present application;

图8示出了根据本申请实施例的网络连接装置的结构框图;FIG. 8 shows a structural block diagram of a network connection device according to an embodiment of the present application;

图9为实现本申请实施例的一种电子设备的硬件结构示意图。FIG. 9 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.

具体实施方式Detailed ways

下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of them. Based on the embodiments in this application, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of this application.

本申请的说明书和权利要求书中的术语“第一”、“第二”等是用于区别类似的对象,而不用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便本申请的实施例能够以除了在这里图示或描述的那些以外的顺序实施。此外,说明书以及权利要求中“和/或”表示所连接对象的至少其中之一,字符“/”,一般表示前后关联对象是一种“或”的关系。The terms "first", "second" and the like in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific sequence or sequence. It is to be understood that the data so used can be interchanged under appropriate circumstances such that the embodiments of the application can be practiced in sequences other than those illustrated or described herein. In addition, "and/or" in the specification and claims means at least one of the connected objects, and the character "/" generally means that the related objects are an "or" relationship.

下面结合附图,通过具体的实施例及其应用场景对本申请实施例提供的网络连接方法及装置、终端和存储介质进行详细地说明。The network connection method and device, terminal, and storage medium provided by the embodiments of the present application are described in detail below through specific embodiments and application scenarios with reference to the accompanying drawings.

在本申请的一些实施例中,图1示出了根据本申请实施例的网络连接方法的流程图之一,如图1所示,该网络连接方法包括:In some embodiments of the present application, FIG. 1 shows one of the flowcharts of the network connection method according to the embodiment of the present application. As shown in FIG. 1, the network connection method includes:

步骤102,在终端连接至第一网络的情况下,获取终端的温度等级和第一网络的第一质量等级;Step 102, when the terminal is connected to the first network, acquire the temperature level of the terminal and the first quality level of the first network;

步骤104,在温度等级和第一质量等级满足预设条件的情况下,控制终端切换至第二网络,并执行预设条件对应的优化程序。Step 104, when the temperature level and the first quality level meet the preset conditions, the control terminal switches to the second network, and executes an optimization program corresponding to the preset conditions.

在本申请实施例中,第一网络具体为5G网络,第二网络具体为4G网络,能够理解的是,本申请实施例在于解决“高速”网络下的发热和断流情况,因此,随着网络发展,第一网络还可能是“6G”、“7G”或其他高速网络,本申请实施例对第一网络和第二网络的具体网络类型不做限定。In the embodiment of the present application, the first network is specifically a 5G network, and the second network is specifically a 4G network. It can be understood that the embodiment of the present application aims to solve the problem of heat generation and outages under the "high-speed" network. Therefore, as the network develops, the first network may also be "6G", "7G" or other high-speed networks. The embodiment of the present application does not limit the specific network types of the first network and the second network.

下面以第一网络为5G网络来进行举例说明。具体地,在终端,如手机或平板电脑等设备连接至5G网络时,设备持续获取自身的温度等级,以及5G网络的质量等级。The following uses an example in which the first network is a 5G network for illustration. Specifically, when a terminal, such as a mobile phone or a tablet computer, is connected to a 5G network, the device continuously obtains its own temperature level and the quality level of the 5G network.

其中,温度等级是根据终端的温度值划分的预设等级,每个等级对应一个温度区间,比如,25℃以下为一个温度区间,对应温度等级0,25℃至30℃为一个温度区间,对应温度等级1,30℃至35℃为一个温度区间,对应温度等级2,以此类推,即温度等级越高,说明终端的温度越高。Among them, the temperature level is a preset level divided according to the temperature value of the terminal. Each level corresponds to a temperature range. For example, below 25°C is a temperature range, which corresponds to a temperature level of 0; from 25°C to 30°C, a temperature range corresponds to a temperature level of 1;

同理,第一质量等级是反应第一网络的网络连接质量的预设等级,其中第一质量等级1、第一质量等级2、第一质量等级3中,第一质量等级越高,则说明第一网络的网络质量越差(如出现卡断、延迟、断流等情况)。Similarly, the first quality level is a preset level that reflects the network connection quality of the first network. Among the first quality level 1, the first quality level 2, and the first quality level 3, the higher the first quality level, the worse the network quality of the first network (such as freezes, delays, disconnections, etc.).

终端持续判断温度等级和第一质量等级是否满足预设条件,当满足预设条件时,则控制Modem向网络发送SCG Failure信令,控制终端暂时断开5G连接,改为连接至4G网络,并执行对应的优化程序。The terminal continues to judge whether the temperature level and the first quality level meet the preset conditions. When the preset conditions are met, the Modem is controlled to send the SCG Failure signaling to the network, and the terminal is controlled to temporarily disconnect the 5G connection, connect to the 4G network instead, and execute the corresponding optimization program.

本申请实施例通过同时监控终端的温度和5G网络质量,在温度高和/或5G网络质量差(如卡顿或断流等)时,暂时断开5G网络并切换至4G网络,同时根据终端的温度和/或5G网络质量,对应执行优化程序,一方面能够降低终端的温度,防止终端温度过高导致耗电异常,进而保证终端的续航时间,另一方面能够自动对5G网络进行优化,并在此期间控制手机连接至4G网络,防止手机长时间处于网络卡断、断流的情况,保证用户的上网体验。The embodiment of this application monitors the temperature of the terminal and the quality of the 5G network at the same time. When the temperature is high and/or the quality of the 5G network is poor (such as freezing or disconnection, etc.), the 5G network is temporarily disconnected and switched to the 4G network. At the same time, according to the temperature of the terminal and/or the quality of the 5G network, an optimization program is executed correspondingly. On the one hand, it can reduce the temperature of the terminal to prevent abnormal power consumption caused by excessive terminal temperature, thereby ensuring the battery life of the terminal. On the other hand, it can automatically optimize the 5G network and control the mobile phone during this period. flow to ensure the user's online experience.

在本申请的一些实施例中,图2示出了根据本申请实施例的网络连接方法的流程图之二,如图2所示,获取终端的温度等级和第一网络的第一质量等级,包括:In some embodiments of the present application, FIG. 2 shows the second flow chart of the network connection method according to the embodiment of the present application. As shown in FIG. 2, obtaining the temperature level of the terminal and the first quality level of the first network includes:

步骤202,获取终端的当前温度值,根据当前温度值确定温度等级;Step 202, obtaining the current temperature value of the terminal, and determining the temperature level according to the current temperature value;

步骤204,获取第一网络的网络连接信息,根据第一网络的网络连接信息确定第一质量等级。Step 204, acquiring network connection information of the first network, and determining a first quality level according to the network connection information of the first network.

在本申请实施例中,终端上设置有用于获取当前温度值的温度传感器,通过传感器获取的数据,来对当前温度等级进行判断。具体地,温度等级是根据终端的温度值划分的预设等级,每个等级对应一个温度区间,比如,30℃以下为一个温度区间,对应温度等级0,30℃至35℃为一个温度区间,对应温度等级1,35℃至40℃为一个温度区间,对应温度等级2,40℃以上为一个温度区间,对应温度等级3,即终端的温度越高,则温度等级也越高。In the embodiment of the present application, the terminal is provided with a temperature sensor for obtaining the current temperature value, and the current temperature level is judged based on the data obtained by the sensor. Specifically, the temperature level is a preset level divided according to the temperature value of the terminal. Each level corresponds to a temperature range. For example, below 30°C is a temperature range, which corresponds to temperature level 0; from 30°C to 35°C, a temperature range corresponds to temperature level 1;

当温度等级为0时,设备温度正常。当温度等级为1时,终端已经开始发热。当温度等级为2时,终端发热情况较为严重。当温度等级为3时,终端已经严重发烫,可能影响用户使用甚至影响电子器件的寿命。When the temperature level is 0, the device temperature is normal. When the temperature level is 1, the terminal has started to heat up. When the temperature level is 2, the terminal heats up more seriously. When the temperature level is 3, the terminal is already seriously hot, which may affect the use of users and even affect the life of electronic devices.

同理,第一质量等级是反应第一网络的网络连接质量的预设等级,第一网络的网络质量越差(卡断更多、延迟更大、出现断流等情况),则第一质量等级越高。如第一质量等级包括:第一质量等级0、第一质量等级1、第一质量等级2和第一质量等级3,其中第一质量等级0代表网络质量最好,第一质量等级1代表网络质量尚可,不会影响用户体验,第一质量等级2则表示出现了卡顿、延迟等影响上网体验的情况,第一质量等级3则代表出现了断流,或网络连接已断开。Similarly, the first quality level is a preset level reflecting the network connection quality of the first network, and the worse the network quality of the first network (more hangups, greater delay, disconnection, etc.), the higher the first quality level. For example, the first quality level includes: the first quality level 0, the first quality level 1, the first quality level 2, and the first quality level 3. The first quality level 0 means that the network quality is the best, the first quality level 1 means that the network quality is not bad, and will not affect the user experience, the first quality level 2 means that there are situations such as freezes and delays that affect the online experience, and the first quality level 3 means that there is a disconnection or the network connection has been disconnected.

在本申请的一些实施例中,网络连接信息包括以下一种或组合:In some embodiments of the present application, the network connection information includes one or a combination of the following:

小区信号强度、小区信号质量、物理层误码率、介质访问控制层缓冲、发射功率、填充比特占比、分组数据汇聚协议丢包率、服务数据适配协议层吞吐量、应用用户身份证明、网络类型,传输控制协议往返时延、传输控制协议握手成功个数、域名系统成功个数、域名系统失败个数、域名系统成功平均时延。Cell signal strength, cell signal quality, physical layer bit error rate, medium access control layer buffering, transmit power, filling bit ratio, packet data convergence protocol packet loss rate, service data adaptation protocol layer throughput, application user identity certificate, network type, transmission control protocol round-trip delay, number of successful transmission control protocol handshakes, number of domain name system successes, number of domain name system failures, and average delay of domain name system successes.

在该实施例中,终端包括AP层(上层)和Modem层(底层),其中,AP层关联AP参数,AP参数包括:In this embodiment, the terminal includes an AP layer (upper layer) and a Modem layer (bottom layer), wherein the AP layer is associated with AP parameters, and the AP parameters include:

应用用户身份证明(uid)、网络类型(network type),传输控制协议往返时延(Transmission Control Protocol Round-Trip Time,TCP RTT)、传输控制协议(Transmission Control Protocol,TCP)握手成功个数、域名系统(Domain Name System,DNS)成功个数、域名系统(DNS)失败个数、域名系统(DNS)成功平均时延等。Application user identification (uid), network type (network type), transmission control protocol round-trip delay (Transmission Control Protocol Round-Trip Time, TCP RTT), transmission control protocol (Transmission Control Protocol, TCP) handshake success number, domain name system (Domain Name System, DNS) success number, domain name system (DNS) failure number, domain name system (DNS) success average delay, etc.

Modem层关联Modem参数,Modem参数包括:The Modem layer is associated with Modem parameters, and the Modem parameters include:

小区信号强度、小区信号质量、物理层误码率、介质访问控制层缓冲(MAC(MediaAccess Control,MAC)buffer)、发射功率(Txpower)、填充比特占比、分组数据汇聚协议(Packet Data Convergence Peotocol,PDCP)丢包率、服务数据适配协议(Service DataAdaptation Protocol,SDAP)层吞吐量等。Cell signal strength, cell signal quality, physical layer bit error rate, media access control layer buffer (MAC (Media Access Control, MAC) buffer), transmit power (Txpower), filling bit ratio, packet data convergence protocol (Packet Data Convergence Peotocol, PDCP) packet loss rate, service data adaptation protocol (Service Data Adaptation Protocol, SDAP) layer throughput, etc.

在本申请的一些实施例中,预设条件包括第一条件,第一条件为:In some embodiments of the present application, the preset conditions include a first condition, and the first condition is:

温度等级与第一质量等级的和大于或等于预设的第一阈值,且温度等级等于第一阈值。The sum of the temperature level and the first quality level is greater than or equal to a preset first threshold, and the temperature level is equal to the first threshold.

在本申请实施例中,预设条件中包括第一条件,当满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足温度等级等于第一阈值时,可以确定温度等级和第一质量等级满足第一条件。In the embodiment of the present application, the preset conditions include the first condition. When the sum of the temperature level and the first quality level is satisfied, which is greater than or equal to the preset first threshold, and the temperature level is equal to the first threshold, it can be determined that the temperature level and the first quality level meet the first condition.

具体举例来说,假设第一阈值为3,终端确定当前温度等级为3,且第一网络的第一质量等级为1,则判断满足第一条件,当前终端出现网络状态差,需要进行优化,且温度过高是网络状态差的主要因素。Specifically, for example, assuming that the first threshold is 3, the terminal determines that the current temperature level is 3, and the first quality level of the first network is 1, then it is determined that the first condition is met, the current terminal has a poor network status and needs to be optimized, and excessive temperature is the main factor for poor network status.

此时,则可以针对温度,对终端进行有针对性的优化,从而降低终端的温度,防止终端温度过高导致耗电异常,进而保证终端的续航时间,提高终端的使用寿命。At this time, the terminal can be optimized according to the temperature, thereby reducing the temperature of the terminal, preventing the abnormal power consumption caused by the excessive temperature of the terminal, thereby ensuring the battery life of the terminal and improving the service life of the terminal.

在本申请的一些实施例中,在温度等级和第一质量等级满足第一条件的情况下,执行预设条件对应的优化程序,包括:In some embodiments of the present application, when the temperature level and the first quality level meet the first condition, the optimization program corresponding to the preset condition is executed, including:

禁止终端连接至第一网络,直至温度等级小于第二阈值。Prohibiting the terminal from connecting to the first network until the temperature level is less than the second threshold.

在本申请实施例中,如果温度等级和第一质量等级满足第一条件,即满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足温度等级等于第一阈值,则禁止终端连接至第一网络,即禁止终端连接至5G网络,具体地,可通过禁止终端上报B1测量结果,避免终端驻上NR,从而防止终端连接到5G网络,以降低终端的网络功耗开销,从而降低终端的温度。In this embodiment of the application, if the temperature level and the first quality level meet the first condition, that is, the sum of the temperature level and the first quality level is greater than or equal to the preset first threshold, and the temperature level is equal to the first threshold, then the terminal is prohibited from connecting to the first network, that is, the terminal is prohibited from connecting to the 5G network. Specifically, the terminal can be prevented from being connected to the NR by prohibiting the terminal from reporting the B1 measurement results, thereby preventing the terminal from connecting to the 5G network, so as to reduce the network power consumption of the terminal, thereby reducing the temperature of the terminal.

在禁止终端连接到5G网络后,持续获取终端的温度,在温度等级小于第二阈值,如温度等级降低至温度等级1后,控制终端退出温度优化程序,此时终端能够正常连接5G网络。After the terminal is prohibited from connecting to the 5G network, the temperature of the terminal is continuously obtained. When the temperature level is lower than the second threshold, such as the temperature level drops to temperature level 1, the terminal is controlled to exit the temperature optimization program. At this time, the terminal can normally connect to the 5G network.

在本申请的一些实施例中,预设条件包括第二条件,第二条件为:In some embodiments of the present application, the preset conditions include a second condition, and the second condition is:

述温度等级与第一质量等级的和大于或等于第一阈值,且第一质量等级等于第一阈值。The sum of the temperature level and the first quality level is greater than or equal to the first threshold, and the first quality level is equal to the first threshold.

在本申请实施例中,预设条件中包括第二条件,当满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足第一质量等级等于第一阈值时,可以确定温度等级和第一质量等级满足第二条件。In the embodiment of the present application, the preset conditions include the second condition. When the sum of the temperature level and the first quality level is satisfied, which is greater than or equal to the preset first threshold, and the first quality level is equal to the first threshold, it can be determined that the temperature level and the first quality level meet the second condition.

具体举例来说,假设第一阈值为3,终端确定当前温度等级为1,且第一网络的第一质量等级为3,则判断满足第二条件,当前终端出现网络状态差,需要进行优化,且5G网络连接质量低是网络状态差的主要因素。For example, assuming that the first threshold is 3, the terminal determines that the current temperature level is 1, and the first quality level of the first network is 3, then it is determined that the second condition is met, the current terminal has a poor network status and needs to be optimized, and the low quality of the 5G network connection is the main factor for the poor network status.

此时,则可以针对5G网络,对终端进行有针对性的优化,从而优化5G网络连接,控制终端暂时通过4G网络访问互联网,防止手机长时间处于网络卡断、断流的情况,保证用户的上网体验。At this time, the terminal can be targeted to optimize the 5G network, thereby optimizing the 5G network connection, controlling the terminal to temporarily access the Internet through the 4G network, preventing the mobile phone from being stuck in the network for a long time, and ensuring the user's online experience.

在本申请的一些实施例中,图3示出了根据本申请实施例的网络连接方法的流程图之三,如图3所示,控制方法还包括:In some embodiments of the present application, FIG. 3 shows the third flowchart of the network connection method according to the embodiment of the present application. As shown in FIG. 3, the control method further includes:

步骤302,将计数器的计数值设置为N;Step 302, the count value of the counter is set to N;

步骤304,禁止终端连接至第一网络,并启动计时器;Step 304, prohibiting the terminal from connecting to the first network, and starting a timer;

步骤306,在计时时长达到时长阈值的情况下,控制终端重新连接至第一网络。Step 306, when the timed duration reaches the duration threshold, the control terminal reconnects to the first network.

其中,N为大于零的自然数,时长阈值等于计数值与预设的单位时长的乘积。Wherein, N is a natural number greater than zero, and the duration threshold is equal to the product of the count value and the preset unit duration.

在本申请实施例中,如果温度等级和第一质量等级满足第二条件,即满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足第一质量等级等于第一阈值,则禁止终端连接至第一网络,并将计数器的计数值设置为N,此处取N=1,即计数值为1。In this embodiment of the present application, if the temperature level and the first quality level meet the second condition, that is, the sum of the temperature level and the first quality level is greater than or equal to the preset first threshold, and the first quality level is equal to the first threshold, the terminal is prohibited from connecting to the first network, and the count value of the counter is set to N, where N=1, that is, the count value is 1.

同时,执行断流优化,禁止终端连接至第一网络,即禁止终端连接至5G网络,具体地,可通过禁止终端上报B1测量结果,避免终端驻上NR,从而防止终端连接到5G网络,并通过4G网络访问互联网,从而防止手机长时间处于网络卡断、断流的情况。At the same time, cut-off optimization is performed to prohibit the terminal from connecting to the first network, that is, prohibiting the terminal from connecting to the 5G network. Specifically, by prohibiting the terminal from reporting B1 measurement results, the terminal can be prevented from being stationed in NR, thereby preventing the terminal from connecting to the 5G network and accessing the Internet through the 4G network, thereby preventing the mobile phone from being stuck in the network for a long time.

在断开5G连接后,终端的惩罚计时器开始计时,当计时时长达到时长阈值的情况下,控制终端重新连接5G网络。具体地,当5G网络差时,一方面可能是因为当前小区连接人数多,造成网络堵塞,另一方面可能是用户所处位置的信号覆盖弱,造成信号强度低。因此,暂时控制终端运行于4G网络,并在一定时长内禁止连接至5G网络,待惩罚计时器达到时长阈值后,则再次尝试连接至5G网络。After the 5G connection is disconnected, the penalty timer of the terminal starts counting, and when the timing reaches the threshold, the terminal is controlled to reconnect to the 5G network. Specifically, when the 5G network is poor, on the one hand, it may be due to the large number of connected people in the current cell, causing network congestion; on the other hand, it may be that the signal coverage of the user's location is weak, resulting in low signal strength. Therefore, temporarily control the terminal to run on the 4G network, and prohibit the connection to the 5G network for a certain period of time, and try to connect to the 5G network again after the penalty timer reaches the duration threshold.

其中,时长阈值与计数器的计数值相关,具体地,可设置一个预设的单位时长,如2分钟,时长阈值为计数值与单位时长的乘积,如上述实施例中,计数值N=1,则时长阈值对应为2分钟。Wherein, the duration threshold is related to the count value of the counter. Specifically, a preset unit duration can be set, such as 2 minutes, and the duration threshold is the product of the count value and the unit duration. As in the above embodiment, the count value N=1, then the duration threshold corresponds to 2 minutes.

在本申请的一些实施例中,图4示出了根据本申请实施例的网络连接方法的流程图之四,如图4所示,在控制终端重新连接至第一网络之后,控制方法还包括:In some embodiments of the present application, FIG. 4 shows the fourth flowchart of the network connection method according to the embodiment of the present application. As shown in FIG. 4, after the control terminal is reconnected to the first network, the control method further includes:

步骤402,在第一预设时长内,第一质量等级小于第三阈值的情况下,将计数器清零;Step 402, if the first quality level is less than the third threshold within the first preset time period, clear the counter;

步骤404,在第一预设时长内,第一质量等级不小于第三阈值的情况下,将计数器的计数值设置为N+1,并再次执行预设条件对应的优化程序。Step 404 , if the first quality level is not less than the third threshold within the first preset time period, set the count value of the counter to N+1, and execute the optimization program corresponding to the preset condition again.

在本申请实施例中,在断开5G连接,并重新连接至5G网络后,持续获取5G网络的网络连接信息,并确定第一质量等级。如果在一段时间内,具体在第一预设时长内,第一质量等级持续小于第三阈值,则说明5G网络回复正常,断流现象消失,此时可能是因为当前小区连接人数减少,网络回复畅通,也可能是用户所处位置改变,信号强度增强,此时用户可通过5G网络顺畅的访问互联网,因此可以将计数器清零,终端退出断流优化程序。In the embodiment of the present application, after disconnecting the 5G connection and reconnecting to the 5G network, the network connection information of the 5G network is continuously obtained, and the first quality level is determined. If within a certain period of time, specifically within the first preset time period, the first quality level continues to be less than the third threshold, it means that the 5G network returns to normal and the outage phenomenon disappears. At this time, it may be because the number of connected people in the current cell has decreased and the network has recovered smoothly.

如果在上述第一预设时长内,第一等级仍大于或等于第三阈值,则说明此时5G网络仍然不畅通,则将计数器的计数值设置为N+1,即增加惩罚计时器的时长阈值,并重新执行断流优化程序。If the first level is still greater than or equal to the third threshold within the above-mentioned first preset duration, it means that the 5G network is still not smooth at this time, then the count value of the counter is set to N+1, that is, the duration threshold of the penalty timer is increased, and the cutoff optimization program is re-executed.

具体地,假设第一次执行断流优化程序时,计数器的计数值N=1,单位时长为2分钟,则时长阈值对应为2分钟。在第二次执行断流优化程序时,计数器的计数值N+1=2,则时长阈值增加到4分钟。即通过更长的时间来让5G网络恢复,避免5G网络恢复畅通前频繁切换网络。Specifically, assuming that when the cutoff optimization program is executed for the first time, the count value of the counter is N=1, and the unit duration is 2 minutes, then the duration threshold corresponds to 2 minutes. When the cutoff optimization program is executed for the second time, the count value of the counter is N+1=2, and the duration threshold is increased to 4 minutes. That is, it takes a longer time to restore the 5G network to avoid frequent network switching before the 5G network is restored.

在本申请的一些实施例中,预设条件包括第三条件,第三条件为:In some embodiments of the present application, the preset conditions include a third condition, and the third condition is:

述温度等级与第一质量等级的和大于或等于第一阈值,且温度等级和第一质量等级均小于第一阈值。The sum of the temperature level and the first quality level is greater than or equal to the first threshold, and both the temperature level and the first quality level are less than the first threshold.

在本申请实施例中,预设条件中包括第三条件,当满足温度等级与第一质量等级的和,大于或等于预设的第三阈值,且满足温度等级和第一质量等级均小于第一阈值时,可以确定温度等级和第一质量等级满足第三条件。In the embodiment of the present application, the preset conditions include the third condition. When the sum of the temperature level and the first quality level is satisfied, which is greater than or equal to the preset third threshold, and both the temperature level and the first quality level are less than the first threshold, it can be determined that the temperature level and the first quality level meet the third condition.

具体举例来说,假设第一阈值为3,终端确定当前温度等级为2,且第一网络的第一质量等级为2,则判断满足第三条件,当前终端出现网络状态差,需要进行优化,且网络状态差的主要因素不是温度或5G网络之一。For example, assuming that the first threshold is 3, the terminal determines that the current temperature level is 2, and the first quality level of the first network is 2, then it is judged that the third condition is met, the current terminal has a poor network status and needs to be optimized, and the main factor of the poor network status is not one of the temperature or the 5G network.

此时,对终端进行综合优化,即同时优化温度和5G网络连接,具体为控制终端暂时通过4G网络访问互联网,一方面能够降低终端的温度,防止终端温度过高导致耗电异常,进而保证终端的续航时间,另一方面能够自动对5G网络进行优化,并在此期间控制手机连接至4G网络,防止手机长时间处于网络卡断、断流的情况,保证用户的上网体验。At this time, the terminal is comprehensively optimized, that is, the temperature and 5G network connection are optimized at the same time. Specifically, the terminal is temporarily controlled to access the Internet through the 4G network. On the one hand, it can reduce the temperature of the terminal to prevent abnormal power consumption caused by excessive terminal temperature, thereby ensuring the battery life of the terminal.

在本申请的一些实施例中,图5示出了根据本申请实施例的网络连接方法的流程图之五,如图5所示,在温度等级和第一质量等级满足第三条件的情况下,执行预设条件对应的优化程序,包括:In some embodiments of the present application, FIG. 5 shows the fifth flowchart of the network connection method according to the embodiment of the present application. As shown in FIG. 5 , when the temperature level and the first quality level meet the third condition, the optimization program corresponding to the preset condition is executed, including:

步骤502,控制终端切换至第一网络;Step 502, the control terminal switches to the first network;

步骤504,在温度等级和第一质量等级仍满足第三条件的情况下,控制终端断开第一网络,并启动计时器;Step 504, when the temperature level and the first quality level still meet the third condition, the control terminal disconnects the first network and starts a timer;

步骤506,在计时时长达到时长阈值的情况下,控制终端重新连接至第一网络。Step 506, when the timed duration reaches the duration threshold, the control terminal reconnects to the first network.

在本申请实施例中,在满足第三条件时,启动综合优化。由于当前终端的温度还未过高,且网络也没有达到断流的情况,因此控制终端切换至第二网络后,即可切换回第一网络,即自动执行“5G-4G-5G”的网络切换,相当于控制终端重新连接至5G网络,并判断是否解决网络卡顿的问题。In the embodiment of the present application, when the third condition is satisfied, comprehensive optimization is started. Since the temperature of the current terminal is not too high, and the network has not reached the situation of cut-off, after the control terminal is switched to the second network, it can switch back to the first network, that is, the network switching of "5G-4G-5G" is automatically performed, which is equivalent to controlling the terminal to reconnect to the 5G network and judging whether the problem of network freeze is solved.

如果此时仍满足第三条件,即网络状态没有改善,则再次断开5G网络,使终端连接至4G网络,同时惩罚计时器启动计时器。此处与断流优化的步骤类似,暂时控制终端运行于4G网络,并在一定时长内禁止连接至5G网络,具体为待惩罚计时器达到时长阈值后,则再次尝试连接至5G网络。If the third condition is still met at this time, that is, the network status has not improved, the 5G network is disconnected again, the terminal is connected to the 4G network, and the penalty timer starts the timer. The steps here are similar to the cut-off optimization steps. Temporarily control the terminal to run on the 4G network, and prohibit the connection to the 5G network for a certain period of time. Specifically, after the penalty timer reaches the duration threshold, try to connect to the 5G network again.

其中,时长阈值同样与计数器的计数值相关,具体地,假设预设的单位时长为2分钟,在计数值N=1的情况下,则时长阈值对应为2分钟。Wherein, the duration threshold is also related to the count value of the counter. Specifically, assuming that the preset unit duration is 2 minutes, in the case of the count value N=1, the duration threshold corresponds to 2 minutes.

在本申请的一些实施例中,图6示出了根据本申请实施例的网络连接方法的流程图之六,如图6所示,在控制终端重新连接至第一网络之后,控制方法还包括:In some embodiments of the present application, FIG. 6 shows the sixth flowchart of the network connection method according to the embodiment of the present application. As shown in FIG. 6, after the control terminal is reconnected to the first network, the control method further includes:

步骤602,在温度等级和第一质量等级不再满足第三条件的情况下,将计数器清零;Step 602, when the temperature level and the first quality level no longer satisfy the third condition, clear the counter;

步骤604,在温度等级和第一质量等级仍满足第三条件的情况下,将计数器的计数设置为N+1,并再次执行预设条件对应的优化程序。Step 604, when the temperature level and the first quality level still meet the third condition, set the count of the counter to N+1, and execute the optimization program corresponding to the preset condition again.

在本申请实施例中,在重新断开5G连接,并重新连接至5G网络后,持续获取5G网络的网络连接信息和终端的温度信息,并确定温度等级和第一质量等级是否满足第三条件。In the embodiment of the present application, after re-disconnecting the 5G connection and reconnecting to the 5G network, continuously obtain the network connection information of the 5G network and the temperature information of the terminal, and determine whether the temperature level and the first quality level meet the third condition.

如果在重新连接至5G网络后,温度等级和第一质量等级不再满足第三条件,则说明终端的联网状态改善,此时用户可通过5G网络顺畅的访问互联网,因此可以将计数器清零,终端退出综合优化程序。If after reconnecting to the 5G network, the temperature level and the first quality level no longer meet the third condition, it means that the terminal's networking status has improved. At this time, the user can smoothly access the Internet through the 5G network, so the counter can be cleared, and the terminal exits the comprehensive optimization program.

而如果在重新连接至5G网络后,温度等级和第一质量等级仍然满足第三条件,则说明此时终端的联网状态没有改善,则将计数器的计数值设置为N+1,即增加惩罚计时器的时长阈值,并重新执行断流优化程序。And if after reconnecting to the 5G network, the temperature level and the first quality level still meet the third condition, it means that the network status of the terminal has not improved at this time, then set the count value of the counter to N+1, that is, increase the duration threshold of the penalty timer, and re-execute the disconnection optimization program.

具体地,假设第二次断开5G网络时,计数器的计数值N=1,单位时长为2分钟,则第二次断开5G网络的时长阈值对应为2分钟。在第三次断开5G网络时,计数器的计数值N+1=2,惩罚计时器的时长阈值增加到4分钟,通过更长的时间来让5G网络恢复,避免5G网络恢复畅通前频繁切换网络。Specifically, assuming that when the 5G network is disconnected for the second time, the count value of the counter is N=1, and the unit duration is 2 minutes, then the duration threshold for disconnecting the 5G network for the second time corresponds to 2 minutes. When the 5G network is disconnected for the third time, the count value of the counter is N+1=2, and the duration threshold of the penalty timer is increased to 4 minutes, allowing the 5G network to recover through a longer period of time to avoid frequent network switching before the 5G network is restored.

在本申请的一些实施例中,图7示出了根据本申请实施例的网络连接方法的流程图之七,如图7所示,在控制终端切换至第二网络之后,控制方法还包括:In some embodiments of the present application, FIG. 7 shows the seventh flowchart of the network connection method according to the embodiment of the present application. As shown in FIG. 7, after the control terminal is switched to the second network, the control method further includes:

步骤702,获取第二网络的网络连接信息,根据第二网络的网络连接信息确定第二质量等级;Step 702, acquiring network connection information of the second network, and determining a second quality level according to the network connection information of the second network;

步骤704,在第二质量等级大于第四阈值的情况下,获取当前小区的小区状态信息;Step 704, when the second quality level is greater than the fourth threshold, obtain cell state information of the current cell;

步骤706,在小区状态信息为异常状态的情况下,控制终端在第二预设时长内停止连接当前小区。Step 706, when the cell status information is abnormal, the control terminal stops connecting to the current cell within a second preset time period.

在本申请实施例中,在终端连接至第二网络连接,即连接至4G网络之后,根据4G网络的网络连接信息,对4G网络的第二质量等级进行评价。如果第二质量等级大于第四阈值,也就说明4G网络也不通畅,此时判断当前小区是否为异常状态,具体地,可通过大数据获取当前小区状态,如果当前连接的基站的驻留用户数量超过5个,且这些用户的握手超时失败率的平均值大于60%,则可以确定当前小区状态为异常状态,此时控制终端在第二预设时长内停止连接当前小区,具体地,可以采取禁小区操作,降低该小区优先级,使终端搜网时尽量不驻留该小区,从而避免异常小区影响用户的上网体验。In the embodiment of the present application, after the terminal is connected to the second network connection, that is, connected to the 4G network, the second quality level of the 4G network is evaluated according to the network connection information of the 4G network. If the second quality level is greater than the fourth threshold, it means that the 4G network is not smooth. At this time, it is judged whether the current cell is in an abnormal state. Specifically, the current cell state can be obtained through big data. If the number of resident users of the currently connected base station exceeds 5, and the average value of the handshake timeout failure rate of these users is greater than 60%, it can be determined that the current cell state is abnormal. At this time, the control terminal stops connecting to the current cell within the second preset time length. Prevent abnormal cells from affecting the user's online experience.

可选地,终端可以搜索当前小区附近是否存在合适的相邻小区,优先连接至合适的相邻小区。其中,当存在信号强度满足预设的强度范围的相邻小区时,可以将该小区认定为合适的相邻小区。Optionally, the terminal may search whether there is a suitable neighboring cell near the current cell, and preferentially connect to a suitable neighboring cell. Wherein, when there is a neighboring cell whose signal strength satisfies a preset strength range, the cell may be identified as a suitable neighboring cell.

预设强度范围可以是rsrp>-110dBm&&rsrq>-12dB。The preset intensity range can be rsrp>-110dBm&&rsrq>-12dB.

在本申请的一些实施例中,网络连接方法还包括:In some embodiments of the present application, the network connection method also includes:

在第二质量等级大于第五阈值的情况下,控制终端在第三预设时长内断开网络连接,其中,第五阈值大于第四阈值。When the second quality level is greater than a fifth threshold, the control terminal disconnects the network connection within a third preset time period, wherein the fifth threshold is greater than the fourth threshold.

在本申请实施例中,如果第二质量等级大于第五阈值,则说明4G网络也出现了断流的情况,此时无论4G网络还是5G网络均无法顺畅连接了,此时控制终端断开网络连接,即彻底的重启网络。期间,可设置惩罚定时器,在第三预设时长内控制终端维持在关闭NR的状态下,在惩罚定时器计时时长达到第三预设时长后,重新开启NR,即控制终端重新常识联网。In this embodiment of the application, if the second quality level is greater than the fifth threshold, it means that the 4G network is also disconnected. At this time, neither the 4G network nor the 5G network can be connected smoothly. At this time, the control terminal disconnects the network connection, that is, completely restarts the network. During this period, a penalty timer can be set, and the control terminal remains in the state of turning off NR within the third preset time period. After the penalty timer reaches the third preset time period, NR is turned on again, that is, the control terminal is connected to the common sense network again.

本申请实施例在终端无法正常连接网络的情况下,通过尝试重启终端的网络连接来使终端的4G和5G网络恢复正常。In the embodiment of the present application, when the terminal cannot connect to the network normally, the 4G and 5G networks of the terminal are restored to normal by trying to restart the network connection of the terminal.

在本申请的一些实施例中,网络连接方法还包括:In some embodiments of the present application, the network connection method also includes:

接收网络重启指令;Receive network restart command;

响应于网络重启指令,控制终端重启网络连接,并将计数器的计数值清零。In response to the network restart instruction, the control terminal restarts the network connection and clears the count value of the counter.

在本申请实施例中,网络重启指令可以是打开/关闭飞行模式的指令,在接收到网络重启指令后,终端重启网络连接,具体为关闭网络连接相关的程序和硬件,并在延时后重新启动,通过尝试重启终端的网络连接来使终端的4G和5G网络恢复正常。In this embodiment of the application, the network restart instruction may be an instruction to turn on/off the flight mode. After receiving the network restart instruction, the terminal restarts the network connection, specifically, shutting down the programs and hardware related to the network connection, and restarting after a delay. By trying to restart the terminal's network connection, the terminal's 4G and 5G networks return to normal.

由于终端的网络连接重新启动,则可以终止当前运行的优化程序,将计数器的计数值清零。终端重新获取温度等级和第一网络的第一质量等级,在温度等级和第一质量等级满足预设条件的情况下,重新执行预设条件对应的优化程序。Since the network connection of the terminal is restarted, the currently running optimization program may be terminated, and the count value of the counter may be cleared. The terminal reacquires the temperature level and the first quality level of the first network, and re-executes the optimization program corresponding to the preset condition when the temperature level and the first quality level meet the preset condition.

在本申请的一些实施例中,图8示出了根据本申请实施例的网络连接装置的结构框图,如图8所示,网络连接装置800包括:In some embodiments of the present application, FIG. 8 shows a structural block diagram of a network connection device according to an embodiment of the present application. As shown in FIG. 8 , the network connection device 800 includes:

获取模块802,用于在终端连接至第一网络的情况下,获取终端的温度等级和第一网络的第一质量等级;An acquiring module 802, configured to acquire the temperature level of the terminal and the first quality level of the first network when the terminal is connected to the first network;

控制模块804,用于在温度等级和第一质量等级满足预设条件的情况下,控制终端切换至第二网络,并执行预设条件对应的优化程序。The control module 804 is configured to switch the control terminal to the second network when the temperature level and the first quality level meet the preset conditions, and execute an optimization program corresponding to the preset conditions.

在本申请实施例中,第一网络具体为5G网络,第二网络具体为4G网络,能够理解的是,本申请实施例在于解决“高速”网络下的发热和断流情况,因此,随着网络发展,第一网络还可能是“6G”、“7G”或其他高速网络,本申请实施例对第一网络和第二网络的具体网络类型不做限定。In the embodiment of the present application, the first network is specifically a 5G network, and the second network is specifically a 4G network. It can be understood that the embodiment of the present application aims to solve the problem of heat generation and outages under the "high-speed" network. Therefore, as the network develops, the first network may also be "6G", "7G" or other high-speed networks. The embodiment of the present application does not limit the specific network types of the first network and the second network.

下面以第一网络为5G网络来进行举例说明。具体地,在终端,如手机或平板电脑等设备连接至5G网络时,设备持续获取自身的温度等级,以及5G网络的质量等级。The following uses an example in which the first network is a 5G network for illustration. Specifically, when a terminal, such as a mobile phone or a tablet computer, is connected to a 5G network, the device continuously obtains its own temperature level and the quality level of the 5G network.

其中,温度等级是根据终端的温度值划分的预设等级,每个等级对应一个温度区间,比如,25℃以下为一个温度区间,对应温度等级0,25℃至30℃为一个温度区间,对应温度等级1,30℃至35℃为一个温度区间,对应温度等级2,以此类推,即温度等级越高,说明终端的温度越高。Among them, the temperature level is a preset level divided according to the temperature value of the terminal. Each level corresponds to a temperature range. For example, below 25°C is a temperature range, which corresponds to a temperature level of 0; from 25°C to 30°C, a temperature range corresponds to a temperature level of 1;

同理,第一质量等级是反应第一网络的网络连接质量的预设等级,其中第一质量等级1、第一质量等级2、第一质量等级3中,第一质量等级越高,则说明第一网络的网络质量越差(如出现卡断、延迟、断流等情况)。Similarly, the first quality level is a preset level that reflects the network connection quality of the first network. Among the first quality level 1, the first quality level 2, and the first quality level 3, the higher the first quality level, the worse the network quality of the first network (such as freezes, delays, disconnections, etc.).

终端持续判断温度等级和第一质量等级是否满足预设条件,当满足预设条件时,则控制Modem向网络发送SCGFailure信令,控制终端暂时断开5G连接,改为连接至4G网络,并执行对应的优化程序。The terminal continues to judge whether the temperature level and the first quality level meet the preset conditions. When the preset conditions are met, the Modem is controlled to send the SCGFailure signaling to the network, and the terminal is controlled to temporarily disconnect the 5G connection, connect to the 4G network instead, and execute the corresponding optimization program.

本申请实施例通过同时监控终端的温度和5G网络质量,在温度高和/或5G网络质量差(如卡顿或断流等)时,暂时断开5G网络并切换至4G网络,同时根据终端的温度和/或5G网络质量,对应执行优化程序,一方面能够降低终端的温度,防止终端温度过高导致耗电异常,进而保证终端的续航时间,另一方面能够自动对5G网络进行优化,并在此期间控制手机连接至4G网络,防止手机长时间处于网络卡断、断流的情况,保证用户的上网体验。The embodiment of this application monitors the temperature of the terminal and the quality of the 5G network at the same time. When the temperature is high and/or the quality of the 5G network is poor (such as freezing or disconnection, etc.), the 5G network is temporarily disconnected and switched to the 4G network. At the same time, according to the temperature of the terminal and/or the quality of the 5G network, an optimization program is executed correspondingly. On the one hand, it can reduce the temperature of the terminal to prevent abnormal power consumption caused by excessive terminal temperature, thereby ensuring the battery life of the terminal. On the other hand, it can automatically optimize the 5G network and control the mobile phone during this period. flow to ensure the user's online experience.

其中,获取模块802具体用于获取终端的当前温度值,根据当前温度值确定温度等级;以及Wherein, the acquiring module 802 is specifically configured to acquire the current temperature value of the terminal, and determine the temperature level according to the current temperature value; and

获取第一网络的网络连接信息,根据第一网络的网络连接信息确定第一质量等级。The network connection information of the first network is acquired, and the first quality level is determined according to the network connection information of the first network.

终端上设置有用于获取当前温度值的温度传感器,通过传感器获取的数据,来对当前温度等级进行判断。具体地,温度等级是根据终端的温度值划分的预设等级,每个等级对应一个温度区间,比如,30℃以下为一个温度区间,对应温度等级0,30℃至35℃为一个温度区间,对应温度等级1,35℃至40℃为一个温度区间,对应温度等级2,40℃以上为一个温度区间,对应温度等级3,即终端的温度越高,则温度等级也越高。The terminal is provided with a temperature sensor for obtaining the current temperature value, and the current temperature level is judged by the data obtained by the sensor. Specifically, the temperature level is a preset level divided according to the temperature value of the terminal. Each level corresponds to a temperature range. For example, below 30°C is a temperature range, which corresponds to temperature level 0; from 30°C to 35°C, a temperature range corresponds to temperature level 1;

当温度等级为0时,设备温度正常。当温度等级为1时,终端已经开始发热。当温度等级为2时,终端发热情况较为严重。当温度等级为3时,终端已经严重发烫,可能影响用户使用甚至影响电子器件的寿命。When the temperature level is 0, the device temperature is normal. When the temperature level is 1, the terminal has started to heat up. When the temperature level is 2, the terminal heats up more seriously. When the temperature level is 3, the terminal is already seriously hot, which may affect the use of users and even affect the life of electronic devices.

同理,第一质量等级是反应第一网络的网络连接质量的预设等级,第一网络的网络质量越差(卡断更多、延迟更大、出现断流等情况),则第一质量等级越高。如第一质量等级包括:第一质量等级0、第一质量等级1、第一质量等级2和第一质量等级3,其中第一质量等级0代表网络质量最好,第一质量等级1代表网络质量尚可,不会影响用户体验,第一质量等级2则表示出现了卡顿、延迟等影响上网体验的情况,第一质量等级3则代表出现了断流,或网络连接已断开。Similarly, the first quality level is a preset level reflecting the network connection quality of the first network, and the worse the network quality of the first network (more hangups, greater delay, disconnection, etc.), the higher the first quality level. For example, the first quality level includes: the first quality level 0, the first quality level 1, the first quality level 2, and the first quality level 3. The first quality level 0 means that the network quality is the best, the first quality level 1 means that the network quality is not bad, and will not affect the user experience, the first quality level 2 means that there are situations such as freezes and delays that affect the online experience, and the first quality level 3 means that there is a disconnection or the network connection has been disconnected.

其中,网络连接信息包括以下一种或组合:Among them, the network connection information includes one or a combination of the following:

小区信号强度、小区信号质量、物理层误码率、介质访问控制层缓冲、发射功率、填充比特占比、分组数据汇聚协议丢包率、服务数据适配协议层吞吐量、应用用户身份证明、网络类型,传输控制协议往返时延、传输控制协议握手成功个数、域名系统成功个数、域名系统失败个数、域名系统成功平均时延。Cell signal strength, cell signal quality, physical layer bit error rate, medium access control layer buffering, transmit power, filling bit ratio, packet data convergence protocol packet loss rate, service data adaptation protocol layer throughput, application user identity certificate, network type, transmission control protocol round-trip delay, number of successful transmission control protocol handshakes, number of domain name system successes, number of domain name system failures, and average delay of domain name system successes.

终端包括AP层(上层)和Modem层(底层),其中,AP层关联AP参数,AP参数包括:The terminal includes an AP layer (upper layer) and a Modem layer (bottom layer), wherein the AP layer is associated with AP parameters, and the AP parameters include:

应用用户身份证明(uid)、网络类型(network type),传输控制协议往返时延(Transmission Control Protocol Round-Trip Time,TCP RTT)、传输控制协议(Transmission Control Protocol,TCP)握手成功个数、域名系统(Domain Name System,DNS)成功个数、域名系统(DNS)失败个数、域名系统(DNS)成功平均时延等。Application user identification (uid), network type (network type), transmission control protocol round-trip delay (Transmission Control Protocol Round-Trip Time, TCP RTT), transmission control protocol (Transmission Control Protocol, TCP) handshake success number, domain name system (Domain Name System, DNS) success number, domain name system (DNS) failure number, domain name system (DNS) success average delay, etc.

Modem层关联Modem参数,Modem参数包括:The Modem layer is associated with Modem parameters, and the Modem parameters include:

小区信号强度、小区信号质量、物理层误码率、介质访问控制层缓冲(MAC(MediaAccess Control,MAC)buffer)、发射功率(Txpower)、填充比特占比、分组数据汇聚协议(Packet Data Convergence Peotocol,PDCP)丢包率、服务数据适配协议(Service DataAdaptation Protocol,SDAP)层吞吐量等。Cell signal strength, cell signal quality, physical layer bit error rate, media access control layer buffer (MAC (Media Access Control, MAC) buffer), transmit power (Txpower), filling bit ratio, packet data convergence protocol (Packet Data Convergence Peotocol, PDCP) packet loss rate, service data adaptation protocol (Service Data Adaptation Protocol, SDAP) layer throughput, etc.

其中,预设条件包括第一条件,第一条件为:温度等级与第一质量等级的和大于或等于预设的第一阈值,且温度等级等于第一阈值。Wherein, the preset condition includes a first condition, and the first condition is: the sum of the temperature level and the first quality level is greater than or equal to a preset first threshold, and the temperature level is equal to the first threshold.

预设条件中包括第一条件,当满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足温度等级等于第一阈值时,可以确定温度等级和第一质量等级满足第一条件。The preset conditions include the first condition. When the sum of the temperature level and the first quality level is satisfied, which is greater than or equal to the preset first threshold, and the temperature level is equal to the first threshold, it can be determined that the temperature level and the first quality level meet the first condition.

具体举例来说,假设第一阈值为3,终端确定当前温度等级为3,且第一网络的第一质量等级为1,则判断满足第一条件,当前终端出现网络状态差,需要进行优化,且温度过高是网络状态差的主要因素。Specifically, for example, assuming that the first threshold is 3, the terminal determines that the current temperature level is 3, and the first quality level of the first network is 1, then it is determined that the first condition is met, the current terminal has a poor network status and needs to be optimized, and excessive temperature is the main factor for poor network status.

此时,则可以针对温度,对终端进行有针对性的优化,从而降低终端的温度,防止终端温度过高导致耗电异常,进而保证终端的续航时间,提高终端的使用寿命。At this time, the terminal can be optimized according to the temperature, thereby reducing the temperature of the terminal, preventing the abnormal power consumption caused by the excessive temperature of the terminal, thereby ensuring the battery life of the terminal and improving the service life of the terminal.

控制模块804在温度等级和第一质量等级满足第一条件的情况下,执行预设条件对应的优化程序,包括:When the temperature level and the first quality level meet the first condition, the control module 804 executes an optimization program corresponding to the preset condition, including:

禁止终端连接至第一网络,直至温度等级小于第二阈值。Prohibiting the terminal from connecting to the first network until the temperature level is less than the second threshold.

如果温度等级和第一质量等级满足第一条件,即满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足温度等级等于第一阈值,则禁止终端连接至第一网络,即禁止终端连接至5G网络,具体地,可通过禁止终端上报B1测量结果,避免终端驻上NR,从而防止终端连接到5G网络,以降低终端的网络功耗开销,从而降低终端的温度。If the temperature level and the first quality level meet the first condition, that is, the sum of the temperature level and the first quality level is greater than or equal to the preset first threshold, and the temperature level is equal to the first threshold, then the terminal is prohibited from connecting to the first network, that is, the terminal is prohibited from connecting to the 5G network. Specifically, the terminal can be prevented from being connected to the NR by prohibiting the terminal from reporting the B1 measurement results, thereby preventing the terminal from connecting to the 5G network, so as to reduce the network power consumption of the terminal, thereby reducing the temperature of the terminal.

在禁止终端连接到5G网络后,持续获取终端的温度,在温度等级小于第二阈值,如温度等级降低至温度等级1后,控制终端退出温度优化程序,此时终端能够正常连接5G网络。After the terminal is prohibited from connecting to the 5G network, the temperature of the terminal is continuously obtained. When the temperature level is lower than the second threshold, such as the temperature level drops to temperature level 1, the terminal is controlled to exit the temperature optimization program. At this time, the terminal can normally connect to the 5G network.

预设条件包括第二条件,第二条件为:The preset conditions include a second condition, and the second condition is:

温度等级与第一质量等级的和大于或等于第一阈值,且第一质量等级等于第一阈值。The sum of the temperature level and the first quality level is greater than or equal to the first threshold, and the first quality level is equal to the first threshold.

预设条件中包括第二条件,当满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足第一质量等级等于第一阈值时,可以确定温度等级和第一质量等级满足第二条件。The preset condition includes a second condition. When the sum of the temperature level and the first quality level is satisfied, which is greater than or equal to the preset first threshold, and the first quality level is equal to the first threshold, it can be determined that the temperature level and the first quality level meet the second condition.

具体举例来说,假设第一阈值为3,终端确定当前温度等级为1,且第一网络的第一质量等级为3,则判断满足第二条件,当前终端出现网络状态差,需要进行优化,且5G网络连接质量低是网络状态差的主要因素。For example, assuming that the first threshold is 3, the terminal determines that the current temperature level is 1, and the first quality level of the first network is 3, then it is determined that the second condition is met, the current terminal has a poor network status and needs to be optimized, and the low quality of the 5G network connection is the main factor for the poor network status.

此时,则可以针对5G网络,对终端进行有针对性的优化,从而优化5G网络连接,控制终端暂时通过4G网络访问互联网,防止手机长时间处于网络卡断、断流的情况,保证用户的上网体验。At this time, the terminal can be targeted to optimize the 5G network, thereby optimizing the 5G network connection, controlling the terminal to temporarily access the Internet through the 4G network, preventing the mobile phone from being stuck in the network for a long time, and ensuring the user's online experience.

控制模块804还用于将计数器的计数值设置为N;禁止终端连接至第一网络,并启动计时器;在计时时长达到时长阈值的情况下,控制终端重新连接至第一网络。The control module 804 is further configured to set the count value of the counter to N; prohibit the terminal from connecting to the first network, and start the timer; and control the terminal to reconnect to the first network when the timed duration reaches the duration threshold.

其中,N为大于零的自然数,时长阈值等于计数值与预设的单位时长的乘积。Wherein, N is a natural number greater than zero, and the duration threshold is equal to the product of the count value and the preset unit duration.

如果温度等级和第一质量等级满足第二条件,即满足温度等级与第一质量等级的和,大于或等于预设的第一阈值,且满足第一质量等级等于第一阈值,则禁止终端连接至第一网络,并将计数器的计数值设置为N,此处取N=1,即计数值为1。If the temperature level and the first quality level meet the second condition, that is, the sum of the temperature level and the first quality level is greater than or equal to the preset first threshold, and the first quality level is equal to the first threshold, the terminal is prohibited from connecting to the first network, and the count value of the counter is set to N, where N=1, that is, the count value is 1.

同时,执行断流优化,禁止终端连接至第一网络,即禁止终端连接至5G网络,具体地,可通过禁止终端上报B1测量结果,避免终端驻上NR,从而防止终端连接到5G网络,并通过4G网络访问互联网,从而防止手机长时间处于网络卡断、断流的情况。At the same time, cut-off optimization is performed to prohibit the terminal from connecting to the first network, that is, prohibiting the terminal from connecting to the 5G network. Specifically, by prohibiting the terminal from reporting B1 measurement results, the terminal can be prevented from being stationed in NR, thereby preventing the terminal from connecting to the 5G network and accessing the Internet through the 4G network, thereby preventing the mobile phone from being stuck in the network for a long time.

在断开5G连接后,终端的惩罚计时器开始计时,当计时时长达到时长阈值的情况下,控制终端重新连接5G网络。具体地,当5G网络差时,一方面可能是因为当前小区连接人数多,造成网络堵塞,另一方面可能是用户所处位置的信号覆盖弱,造成信号强度低。因此,暂时控制终端运行于4G网络,并在一定时长内禁止连接至5G网络,待惩罚计时器达到时长阈值后,则再次尝试连接至5G网络。After the 5G connection is disconnected, the penalty timer of the terminal starts counting, and when the timing reaches the threshold, the terminal is controlled to reconnect to the 5G network. Specifically, when the 5G network is poor, on the one hand, it may be due to the large number of connected people in the current cell, causing network congestion; on the other hand, it may be that the signal coverage of the user's location is weak, resulting in low signal strength. Therefore, temporarily control the terminal to run on the 4G network, and prohibit the connection to the 5G network for a certain period of time, and try to connect to the 5G network again after the penalty timer reaches the duration threshold.

其中,时长阈值与计数器的计数值相关,具体地,可设置一个预设的单位时长,如2分钟,时长阈值为计数值与单位时长的乘积,如上述实施例中,计数值N=1,则时长阈值对应为2分钟。Wherein, the duration threshold is related to the count value of the counter. Specifically, a preset unit duration can be set, such as 2 minutes, and the duration threshold is the product of the count value and the unit duration. As in the above embodiment, the count value N=1, then the duration threshold corresponds to 2 minutes.

控制模块804还用于在第一预设时长内,第一质量等级小于第三阈值的情况下,将计数器清零;在第一预设时长内,第一质量等级不小于第三阈值的情况下,将计数器的计数值设置为N+1,并再次执行预设条件对应的优化程序。The control module 804 is also configured to clear the counter when the first quality level is less than the third threshold within the first preset time period; and set the count value of the counter to N+1 when the first quality level is not less than the third threshold within the first preset time period, and execute the optimization program corresponding to the preset condition again.

在断开5G连接,并重新连接至5G网络后,持续获取5G网络的网络连接信息,并确定第一质量等级。如果在一段时间内,具体在第一预设时长内,第一质量等级持续小于第三阈值,则说明5G网络回复正常,断流现象消失,此时可能是因为当前小区连接人数减少,网络回复畅通,也可能是用户所处位置改变,信号强度增强,此时用户可通过5G网络顺畅的访问互联网,因此可以将计数器清零,终端退出断流优化程序。After disconnecting the 5G connection and reconnecting to the 5G network, continuously obtain the network connection information of the 5G network, and determine the first quality level. If within a certain period of time, specifically within the first preset time period, the first quality level continues to be less than the third threshold, it means that the 5G network returns to normal and the outage phenomenon disappears. At this time, it may be because the number of connected people in the current cell has decreased and the network has recovered smoothly.

如果在上述第一预设时长内,第一等级仍大于或等于第三阈值,则说明此时5G网络仍然不畅通,则将计数器的计数值设置为N+1,即增加惩罚计时器的时长阈值,并重新执行断流优化程序。If the first level is still greater than or equal to the third threshold within the above-mentioned first preset duration, it means that the 5G network is still not smooth at this time, then the count value of the counter is set to N+1, that is, the duration threshold of the penalty timer is increased, and the cutoff optimization program is re-executed.

具体地,假设第一次执行断流优化程序时,计数器的计数值N=1,单位时长为2分钟,则时长阈值对应为2分钟。在第二次执行断流优化程序时,计数器的计数值N+1=2,则时长阈值增加到4分钟。即通过更长的时间来让5G网络恢复,避免5G网络恢复畅通前频繁切换网络。Specifically, assuming that when the cutoff optimization program is executed for the first time, the count value of the counter is N=1, and the unit duration is 2 minutes, then the duration threshold corresponds to 2 minutes. When the cutoff optimization program is executed for the second time, the count value of the counter is N+1=2, and the duration threshold is increased to 4 minutes. That is, it takes a longer time to restore the 5G network to avoid frequent network switching before the 5G network is restored.

预设条件包括第三条件,第三条件为:The preset conditions include a third condition, and the third condition is:

温度等级与第一质量等级的和大于或等于第一阈值,且温度等级和第一质量等级均小于第一阈值。The sum of the temperature level and the first quality level is greater than or equal to the first threshold, and both the temperature level and the first quality level are less than the first threshold.

预设条件中包括第三条件,当满足温度等级与第一质量等级的和,大于或等于预设的第三阈值,且满足温度等级和第一质量等级均小于第一阈值时,可以确定温度等级和第一质量等级满足第三条件。The preset conditions include a third condition. When the sum of the temperature level and the first quality level is satisfied, which is greater than or equal to the preset third threshold, and both the temperature level and the first quality level are less than the first threshold, it can be determined that the temperature level and the first quality level meet the third condition.

具体举例来说,假设第一阈值为3,终端确定当前温度等级为2,且第一网络的第一质量等级为2,则判断满足第三条件,当前终端出现网络状态差,需要进行优化,且网络状态差的主要因素不是温度或5G网络之一。For example, assuming that the first threshold is 3, the terminal determines that the current temperature level is 2, and the first quality level of the first network is 2, then it is judged that the third condition is met, the current terminal has a poor network status and needs to be optimized, and the main factor of the poor network status is not one of the temperature or the 5G network.

此时,对终端进行综合优化,即同时优化温度和5G网络连接,具体为控制终端暂时通过4G网络访问互联网,一方面能够降低终端的温度,防止终端温度过高导致耗电异常,进而保证终端的续航时间,另一方面能够自动对5G网络进行优化,并在此期间控制手机连接至4G网络,防止手机长时间处于网络卡断、断流的情况,保证用户的上网体验。At this time, the terminal is comprehensively optimized, that is, the temperature and 5G network connection are optimized at the same time. Specifically, the terminal is temporarily controlled to access the Internet through the 4G network. On the one hand, it can reduce the temperature of the terminal to prevent abnormal power consumption caused by excessive terminal temperature, thereby ensuring the battery life of the terminal.

控制模块804还用于控制终端切换至第一网络;在温度等级和第一质量等级仍满足第三条件的情况下,控制终端断开第一网络,并启动计时器;在计时时长达到时长阈值的情况下,控制终端重新连接至第一网络。The control module 804 is also used to control the terminal to switch to the first network; when the temperature level and the first quality level still meet the third condition, the control terminal disconnects from the first network and starts a timer; when the timing time reaches a time threshold, the control terminal reconnects to the first network.

在满足第三条件时,启动综合优化。由于当前终端的温度还未过高,且网络也没有达到断流的情况,因此控制终端切换至第二网络后,即可切换回第一网络,即自动执行“5G-4G-5G”的网络切换,相当于控制终端重新连接至5G网络,并判断是否解决网络卡顿的问题。When the third condition is satisfied, comprehensive optimization is started. Since the temperature of the current terminal is not too high, and the network has not yet reached the cut-off situation, after the control terminal is switched to the second network, it can switch back to the first network, that is, the network switching of "5G-4G-5G" is automatically performed, which is equivalent to controlling the terminal to reconnect to the 5G network and judging whether to solve the problem of network freeze.

如果此时仍满足第三条件,即网络状态没有改善,则再次断开5G网络,使终端连接至4G网络,同时惩罚计时器启动计时器。此处与断流优化的步骤类似,暂时控制终端运行于4G网络,并在一定时长内禁止连接至5G网络,具体为待惩罚计时器达到时长阈值后,则再次尝试连接至5G网络。If the third condition is still met at this time, that is, the network status has not improved, the 5G network is disconnected again, the terminal is connected to the 4G network, and the penalty timer starts the timer. The steps here are similar to the cut-off optimization steps. Temporarily control the terminal to run on the 4G network, and prohibit the connection to the 5G network for a certain period of time. Specifically, after the penalty timer reaches the duration threshold, try to connect to the 5G network again.

其中,时长阈值同样与计数器的计数值相关,具体地,假设预设的单位时长为2分钟,在计数值N=1的情况下,则时长阈值对应为2分钟。Wherein, the duration threshold is also related to the count value of the counter. Specifically, assuming that the preset unit duration is 2 minutes, in the case of the count value N=1, the duration threshold corresponds to 2 minutes.

控制模块804还用于在温度等级和第一质量等级不再满足第三条件的情况下,将计数器清零;在温度等级和第一质量等级仍满足第三条件的情况下,将计数器的计数设置为N+1,并再次执行预设条件对应的优化程序。The control module 804 is also used to clear the counter when the temperature level and the first quality level no longer meet the third condition; when the temperature level and the first quality level still meet the third condition, set the count of the counter to N+1, and execute the optimization program corresponding to the preset condition again.

在重新断开5G连接,并重新连接至5G网络后,持续获取5G网络的网络连接信息和终端的温度信息,并确定温度等级和第一质量等级是否满足第三条件。After re-disconnecting the 5G connection and reconnecting to the 5G network, continuously obtain the network connection information of the 5G network and the temperature information of the terminal, and determine whether the temperature level and the first quality level meet the third condition.

如果在重新连接至5G网络后,温度等级和第一质量等级不再满足第三条件,则说明终端的联网状态改善,此时用户可通过5G网络顺畅的访问互联网,因此可以将计数器清零,终端退出综合优化程序。If after reconnecting to the 5G network, the temperature level and the first quality level no longer meet the third condition, it means that the terminal's networking status has improved. At this time, the user can smoothly access the Internet through the 5G network, so the counter can be cleared, and the terminal exits the comprehensive optimization program.

而如果在重新连接至5G网络后,温度等级和第一质量等级仍然满足第三条件,则说明此时终端的联网状态没有改善,则将计数器的计数值设置为N+1,即增加惩罚计时器的时长阈值,并重新执行断流优化程序。And if after reconnecting to the 5G network, the temperature level and the first quality level still meet the third condition, it means that the network status of the terminal has not improved at this time, then set the count value of the counter to N+1, that is, increase the duration threshold of the penalty timer, and re-execute the disconnection optimization program.

具体地,假设第二次断开5G网络时,计数器的计数值N=1,单位时长为2分钟,则第二次断开5G网络的时长阈值对应为2分钟。在第三次断开5G网络时,计数器的计数值N+1=2,惩罚计时器的时长阈值增加到4分钟,通过更长的时间来让5G网络恢复,避免5G网络恢复畅通前频繁切换网络。Specifically, assuming that when the 5G network is disconnected for the second time, the count value of the counter is N=1, and the unit duration is 2 minutes, then the duration threshold for disconnecting the 5G network for the second time corresponds to 2 minutes. When the 5G network is disconnected for the third time, the count value of the counter is N+1=2, and the duration threshold of the penalty timer is increased to 4 minutes, allowing the 5G network to recover through a longer period of time to avoid frequent network switching before the 5G network is restored.

获取模块802还用于获取第二网络的网络连接信息,根据第二网络的网络连接信息确定第二质量等级;在第二质量等级大于第四阈值的情况下,获取当前小区的小区状态信息;The obtaining module 802 is also used to obtain the network connection information of the second network, and determine the second quality level according to the network connection information of the second network; when the second quality level is greater than the fourth threshold, obtain the cell state information of the current cell;

控制模块804用于在小区状态信息为异常状态的情况下,控制终端在第二预设时长内停止连接当前小区。The control module 804 is configured to control the terminal to stop connecting to the current cell within a second preset time period when the cell state information is in an abnormal state.

在终端连接至第二网络连接,即连接至4G网络之后,根据4G网络的网络连接信息,对4G网络的第二质量等级进行评价。如果第二质量等级大于第四阈值,也就说明4G网络也不通畅,此时判断当前小区是否为异常状态,具体地,可通过大数据获取当前小区状态,如果当前连接的基站的驻留用户数量超过5个,且这些用户的握手超时失败率的平均值大于60%,则可以确定当前小区状态为异常状态,此时控制终端在第二预设时长内停止连接当前小区,具体地,可以采取禁小区操作,降低该小区优先级,使终端搜网时尽量不驻留该小区,从而避免异常小区影响用户的上网体验。After the terminal is connected to the second network connection, that is, to the 4G network, the second quality level of the 4G network is evaluated according to the network connection information of the 4G network. If the second quality level is greater than the fourth threshold, it means that the 4G network is not smooth. At this time, it is judged whether the current cell is in an abnormal state. Specifically, the current cell state can be obtained through big data. If the number of resident users of the currently connected base station exceeds 5, and the average value of the handshake timeout failure rate of these users is greater than 60%, it can be determined that the current cell state is abnormal. At this time, the control terminal stops connecting to the current cell within the second preset time length. Prevent abnormal cells from affecting the user's online experience.

可选地,终端可以搜索当前小区附近是否存在合适的相邻小区,优先连接至合适的相邻小区。其中,当存在信号强度满足预设的强度范围的相邻小区时,可以将该小区认定为合适的相邻小区。Optionally, the terminal may search whether there is a suitable neighboring cell near the current cell, and preferentially connect to a suitable neighboring cell. Wherein, when there is a neighboring cell whose signal strength satisfies a preset strength range, the cell may be identified as a suitable neighboring cell.

预设强度范围可以是rsrp>-110dBm&&rsrq>-12dB。The preset intensity range can be rsrp>-110dBm&&rsrq>-12dB.

控制模块804还用于在第二质量等级大于第五阈值的情况下,控制终端在第三预设时长内断开网络连接,其中,第五阈值大于第四阈值。The control module 804 is further configured to control the terminal to disconnect from the network within a third preset time period when the second quality level is greater than a fifth threshold, wherein the fifth threshold is greater than the fourth threshold.

在本申请实施例中,如果第二质量等级大于第五阈值,则说明4G网络也出现了断流的情况,此时无论4G网络还是5G网络均无法顺畅连接了,此时控制终端断开网络连接,即彻底的重启网络。期间,可设置惩罚定时器,在第三预设时长内控制终端维持在关闭NR的状态下,在惩罚定时器计时时长达到第三预设时长后,重新开启NR,即控制终端重新常识联网。In this embodiment of the application, if the second quality level is greater than the fifth threshold, it means that the 4G network is also disconnected. At this time, neither the 4G network nor the 5G network can be connected smoothly. At this time, the control terminal disconnects the network connection, that is, completely restarts the network. During this period, a penalty timer can be set, and the control terminal remains in the state of turning off NR within the third preset time period. After the penalty timer reaches the third preset time period, NR is turned on again, that is, the control terminal is connected to the common sense network again.

本申请实施例在终端无法正常连接网络的情况下,通过尝试重启终端的网络连接来使终端的4G和5G网络恢复正常。In the embodiment of the present application, when the terminal cannot connect to the network normally, the 4G and 5G networks of the terminal are restored to normal by trying to restart the network connection of the terminal.

控制模块804还用于接收网络重启指令;The control module 804 is also configured to receive a network restart instruction;

响应于网络重启指令,控制终端重启网络连接,并将计数器的计数值清零。In response to the network restart instruction, the control terminal restarts the network connection and clears the count value of the counter.

网络重启指令可以是打开/关闭飞行模式的指令,在接收到网络重启指令后,终端重启网络连接,具体为关闭网络连接相关的程序和硬件,并在延时后重新启动,通过尝试重启终端的网络连接来使终端的4G和5G网络恢复正常。The network restart instruction can be an instruction to turn on/off the flight mode. After receiving the network restart instruction, the terminal restarts the network connection, specifically shutting down the programs and hardware related to the network connection, and restarting after a delay. By trying to restart the terminal's network connection, the terminal's 4G and 5G networks return to normal.

由于终端的网络连接重新启动,则可以终止当前运行的优化程序,将计数器的计数值清零。终端重新获取温度等级和第一网络的第一质量等级,在温度等级和第一质量等级满足预设条件的情况下,重新执行预设条件对应的优化程序。Since the network connection of the terminal is restarted, the currently running optimization program may be terminated, and the count value of the counter may be cleared. The terminal reacquires the temperature level and the first quality level of the first network, and re-executes the optimization program corresponding to the preset condition when the temperature level and the first quality level meet the preset condition.

本申请实施例中的终端的控制装置可以是装置,也可以是终端中的部件、集成电路、或芯片。该装置可以是移动终端,也可以为非移动终端。示例性的,移动终端可以为手机、平板电脑、笔记本电脑、掌上电脑、车载终端、可穿戴设备、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本或者个人数字助理(personal digitalassistant,PDA)等,非移动终端可以为服务器、网络附属存储器(Network AttachedStorage,NAS)、个人计算机(personal computer,PC)、电视机(television,TV)、柜员机或者自助机等,本申请实施例不作具体限定。The device for controlling the terminal in the embodiment of the present application may be a device, or may be a component, an integrated circuit, or a chip in the terminal. The device may be a mobile terminal or a non-mobile terminal. Exemplary, the mobile terminal may be a mobile phone, tablet computer, notebook computer, palmtop computer, vehicle-mounted terminal, wearable device, ultra-mobile personal computer (ultra-mobile personal computer, UMPC), netbook or personal digital assistant (personal digital assistant, PDA), etc., and the non-mobile terminal may be a server, network attached storage (Network Attached Storage, NAS), personal computer (personal computer, PC), television (television, TV) ), teller machines or self-service machines, etc., are not specifically limited in this embodiment of the present application.

本申请实施例中的终端的控制装置可以为具有操作系统的装置。该操作系统可以为安卓(Android)操作系统,可以为iOS操作系统,还可以为其他可能的操作系统,本申请实施例不作具体限定。The device for controlling the terminal in the embodiment of the present application may be a device with an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in this embodiment of the present application.

可选的,本申请实施例还提供一种电子设备1900,包括处理器1910,存储器1909,存储在存储器1909上并可在处理器1910上运行的程序或指令,该程序或指令被处理器1910执行时实现上述网络连接方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。Optionally, the embodiment of the present application further provides an electronic device 1900, including a processor 1910, a memory 1909, and a program or instruction stored in the memory 1909 and operable on the processor 1910. When the program or instruction is executed by the processor 1910, the various processes of the above-mentioned network connection method embodiment can be achieved, and the same technical effect can be achieved. To avoid repetition, details are not repeated here.

需要注意的是,本申请实施例中的电子设备包括上述的移动电子设备和非移动电子设备。It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.

图9为实现本申请实施例的一种电子设备的硬件结构示意图。FIG. 9 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.

该电子设备1900包括但不限于:射频单元1901、网络模块1902、音频输出单元1903、输入单元1904、传感器1905、显示单元1906、用户输入单元1907、接口单元1908、存储器1909、以及处理器1910等部件。The electronic device 1900 includes, but is not limited to: a radio frequency unit 1901, a network module 1902, an audio output unit 1903, an input unit 1904, a sensor 1905, a display unit 1906, a user input unit 1907, an interface unit 1908, a memory 1909, and a processor 1910.

本领域技术人员可以理解,电子设备1900还可以包括给各个部件供电的电源1911(比如电池),电源1911可以通过电源管理系统与处理器1910逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。图9中示出的电子设备结构并不构成对电子设备的限定,电子设备可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置,在此不再赘述。Those skilled in the art can understand that the electronic device 1900 can also include a power supply 1911 (such as a battery) for supplying power to various components, and the power supply 1911 can be logically connected to the processor 1910 through a power management system, so as to implement functions such as management of charging, discharging, and power consumption management through the power management system. The structure of the electronic device shown in FIG. 9 does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine some components, or arrange different components, which will not be repeated here.

其中,射频单元1901用于发射和接收上述第一网络的射频信号和第二网络的射频信号。网络模块1902用于连接第一网络和第二网络,并获取第一网络和第二网络的网络连接信息,以确定对应的网络质量等级。Wherein, the radio frequency unit 1901 is configured to transmit and receive the radio frequency signal of the first network and the radio frequency signal of the second network. The network module 1902 is configured to connect the first network and the second network, and acquire network connection information of the first network and the second network, so as to determine corresponding network quality levels.

传感器1905能够获取电子设备的温度信息,进而确定电子设备的温度等级。The sensor 1905 can acquire temperature information of the electronic device, and then determine the temperature level of the electronic device.

处理器1910用于在温度等级和第一质量等级满足预设条件的情况下,控制电子设备切换至第二网络,并执行预设条件对应的优化程序。The processor 1910 is configured to control the electronic device to switch to the second network and execute an optimization program corresponding to the preset condition when the temperature level and the first quality level meet the preset condition.

应理解的是,本申请实施例中,射频单元1901可用于收发信息或收发通话过程中的信号,具体的,接收基站的下行数据或向基站发送上行数据。射频单元1901包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器、双工器等。It should be understood that, in the embodiment of the present application, the radio frequency unit 1901 can be used to send and receive information or send and receive signals during a call, specifically, receive downlink data from a base station or send uplink data to a base station. The radio frequency unit 1901 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, and the like.

网络模块1902为用户提供了无线的宽带互联网访问,如帮助用户收发电子邮件、浏览网页和访问流式媒体等。The network module 1902 provides users with wireless broadband Internet access, such as helping users to send and receive emails, browse web pages, and access streaming media.

音频输出单元1903可以将射频单元1901或网络模块1902接收的或者在存储器1909中存储的音频数据转换成音频信号并且输出为声音。而且,音频输出单元1903还可以提供与电子设备1900执行的特定功能相关的音频输出(例如,呼叫信号接收声音、消息接收声音等等)。音频输出单元1903包括扬声器、蜂鸣器以及受话器等。The audio output unit 1903 may convert audio data received by the radio frequency unit 1901 or the network module 1902 or stored in the memory 1909 into an audio signal and output as sound. Also, the audio output unit 1903 can also provide audio output related to a specific function performed by the electronic device 1900 (for example, a call signal reception sound, a message reception sound, etc.). The audio output unit 1903 includes a speaker, a buzzer, a receiver, and the like.

输入单元1904用于接收音频或视频信号。输入单元1904可以包括图形处理器(Graphics Processing Unit,GPU)5082和麦克风5084,图形处理器5082对在视频捕获模式或图像捕获模式中由图像捕获装置(如摄像头)获得的静态图片或视频的图像数据进行处理。处理后的图像帧可以显示在显示单元1906上,或者存储在存储器1909(或其它存储介质)中,或者经由射频单元1901或网络模块1902发送。麦克风5084可以接收声音,并且能够将声音处理为音频数据,处理后的音频数据可以在电话通话模式的情况下转换为可经由射频单元1901发送到移动通信基站的格式输出。The input unit 1904 is used to receive audio or video signals. The input unit 1904 may include a graphics processor (Graphics Processing Unit, GPU) 5082 and a microphone 5084. The graphics processor 5082 processes image data of still pictures or videos obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The processed image frames can be displayed on the display unit 1906 , or stored in the memory 1909 (or other storage medium), or sent via the radio frequency unit 1901 or the network module 1902 . The microphone 5084 can receive sound, and can process the sound into audio data, and the processed audio data can be converted into an output format that can be sent to the mobile communication base station via the radio frequency unit 1901 in the case of a phone call mode.

电子设备1900还包括至少一种传感器1905,比如指纹传感器、压力传感器、虹膜传感器、分子传感器、陀螺仪、气压计、湿度计、温度计、红外线传感器、光传感器、运动传感器以及其他传感器。Electronic device 1900 also includes at least one sensor 1905, such as a fingerprint sensor, pressure sensor, iris sensor, molecular sensor, gyroscope, barometer, hygrometer, thermometer, infrared sensor, light sensor, motion sensor, and other sensors.

显示单元1906用于显示由用户输入的信息或提供给用户的信息。显示单元1906可包括显示面板5122,可以采用液晶显示器、有机发光二极管等形式来配置显示面板5122。The display unit 1906 is used to display information input by the user or information provided to the user. The display unit 1906 may include a display panel 5122, and the display panel 5122 may be configured in the form of a liquid crystal display, an organic light emitting diode, or the like.

用户输入单元1907可用于接收输入的数字或字符信息,以及产生与电子设备的用户设置以及功能控制有关的键信号输入。具体地,用户输入单元1907包括触控面板5142以及其他输入设备5144。触控面板5142也称为触摸屏,可获取用户在其上或附近的触摸操作。触控面板5142可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器1910,接收处理器1910发来的命令并加以执行。其他输入设备5144可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆,在此不再赘述。The user input unit 1907 can be used to receive input number or character information, and generate key signal input related to user settings and function control of the electronic device. Specifically, the user input unit 1907 includes a touch panel 5142 and other input devices 5144 . The touch panel 5142 is also referred to as a touch screen, and can acquire user's touch operations on or near it. The touch panel 5142 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 processor 1910, and receives and executes the command sent by the processor 1910. Other input devices 5144 may include, but are not limited to, physical keyboards, function keys (such as volume control keys, switch keys, etc.), trackballs, mice, and joysticks, which will not be repeated here.

进一步的,触控面板5142可覆盖在显示面板5122上,当触控面板5142检测到在其上或附近的触摸操作后,传送给处理器1910以确定触摸事件的类型,随后处理器1910根据触摸事件的类型在显示面板5122上提供相应的视觉输出。触控面板5142与显示面板5122可作为两个独立的部件,也可以集成为一个部件。Further, the touch panel 5142 can be covered on the display panel 5122, and when the touch panel 5142 detects a touch operation on or near it, the touch operation is sent to the processor 1910 to determine the type of the touch event, and then the processor 1910 provides corresponding visual output on the display panel 5122 according to the type of the touch event. The touch panel 5142 and the display panel 5122 can be used as two independent components, or can be integrated into one component.

接口单元1908为外部装置与电子设备1900连接的接口。例如,外部装置可以包括有线或无线头戴式耳机端口、外部电源(或电池充电器)端口、有线或无线数据端口、存储卡端口、用于连接具有识别模块的装置的端口、音频输入/输出(I/O)端口、视频I/O端口、耳机端口等等。接口单元1908可以用于接收来自外部装置的输入(例如,数据信息、电力等等)并且将接收到的输入传输到电子设备1900内的一个或多个元件或者可以用于在电子设备1900和外部装置之间传输数据。The interface unit 1908 is an interface for connecting an external device to the electronic device 1900 . For example, an external device may include a wired or wireless headset port, an external power (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, an audio input/output (I/O) port, a video I/O port, a headphone port, and the like. The interface unit 1908 may be used to receive input (eg, data information, power, etc.) from an external device and transmit the received input to one or more elements within the electronic device 1900 or may be used to transmit data between the electronic device 1900 and an external device.

存储器1909可用于存储软件程序以及各种数据。存储器1909可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据移动终端的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器1909可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 1909 can be used to store software programs as well as various data. The memory 1909 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, at least one application program required by a function (such as a sound playback function, an image playback function, etc.); In addition, the memory 1909 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 devices.

处理器1910通过运行或执行存储在存储器1909内的软件程序和/或模块,以及调用存储在存储器1909内的数据,执行电子设备1900的各种功能和处理数据,从而对电子设备1900进行整体监控。处理器1910可包括一个或多个处理单元;优选的,处理器1910可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。The processor 1910 executes various functions of the electronic device 1900 and processes data by running or executing software programs and/or modules stored in the memory 1909 , and calling data stored in the memory 1909 , so as to monitor the electronic device 1900 as a whole. The processor 1910 may include one or more processing units; preferably, the processor 1910 may integrate an application processor and a modem processor, wherein the application processor mainly processes operating systems, user interfaces, and application programs, and the modem processor mainly processes wireless communications.

电子设备1900还可以包括给各个部件供电的电源1911,优选的,电源1911可以通过电源管理系统与处理器1910逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The electronic device 1900 may also include a power supply 1911 for supplying power to various components. Preferably, the power supply 1911 may be logically connected to the processor 1910 through a power management system, so that functions such as charging, discharging, and power consumption management may be implemented through the power management system.

本申请实施例还提供一种可读存储介质,可读存储介质上存储有程序或指令,该程序或指令被处理器执行时实现上述网络连接方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。The embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the foregoing network connection method embodiment can be achieved, and the same technical effect can be achieved. To avoid repetition, details are not repeated here.

其中,处理器为上述实施例中的电子设备中的处理器。可读存储介质,包括计算机可读存储介质,如计算机只读存储器(Read-Only Memory,ROM)、随机存取存储器(RandomAccess Memory,RAM)、磁碟或者光盘等。Wherein, the processor is the processor in the electronic device in the foregoing embodiments. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory (Read-Only Memory, ROM), a random access memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and the like.

本申请实施例另提供了一种芯片,芯片包括处理器和通信接口,通信接口和处理器耦合,处理器用于运行程序或指令,实现上述网络连接方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。The embodiment of the present application further provides a chip, the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned network connection method embodiments, and can achieve the same technical effect. To avoid repetition, details are not repeated here.

应理解,本申请实施例提到的芯片还可以称为系统级芯片、系统芯片、芯片系统或片上系统芯片等。It should be understood that the chips mentioned in the embodiments of the present application may also be called system-on-chip, system-on-chip, system-on-a-chip, or system-on-a-chip.

需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。此外,需要指出的是,本申请实施方式中的方法和装置的范围不限按示出或讨论的顺序来执行功能,还可包括根据所涉及的功能按基本同时的方式或按相反的顺序来执行功能,例如,可以按不同于所描述的次序来执行所描述的方法,并且还可以添加、省去、或组合各种步骤。另外,参照某些示例所描述的特征可在其他示例中被组合。It should be noted that, in this document, the term "comprising", "comprising" or any other variation thereof is intended to cover a non-exclusive inclusion, such that a process, method, article or device comprising a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such a process, method, article or device. Without further limitations, an element defined by the phrase "comprising a ..." does not preclude the presence of additional identical elements in the process, method, article, or apparatus comprising that element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved. Additionally, features described with reference to certain examples may be combined in other examples.

通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus a necessary general-purpose hardware platform, and of course also by hardware, but in many cases the former is a better implementation. Based on such an understanding, the technical solution of the present application can be embodied in the form of a software product in essence or the part that contributes to the prior art. The computer software product is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk), and includes several instructions to make a terminal (which can be a mobile phone, computer, server, air conditioner, or network equipment, etc.) execute the method described in each embodiment of the application.

上面结合附图对本申请的实施例进行了描述,但是本申请并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本申请的启示下,在不脱离本申请宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本申请的保护之内。The embodiments of the present application have been described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific embodiments. The above-mentioned specific embodiments are only illustrative and not restrictive. Under the inspiration of this application, those skilled in the art can also make many forms without departing from the purpose of the application and the scope of protection of the claims, all of which belong to the protection of the present application.

Claims (11)

1.一种网络连接方法,其特征在于,包括:1. A network connection method, characterized in that, comprising: 在终端连接至第一网络的情况下,获取所述终端的温度等级和所述第一网络的第一质量等级;If the terminal is connected to the first network, acquiring the temperature level of the terminal and the first quality level of the first network; 在所述温度等级和所述第一质量等级满足预设条件的情况下,控制所述终端切换至第二网络,并执行所述预设条件对应的优化程序;When the temperature level and the first quality level meet a preset condition, control the terminal to switch to a second network, and execute an optimization program corresponding to the preset condition; 所述预设条件包括第一条件,所述第一条件为:The preset conditions include a first condition, and the first condition is: 所述温度等级与所述第一质量等级的和大于或等于预设的第一阈值,且所述温度等级等于所述第一阈值;The sum of the temperature level and the first quality level is greater than or equal to a preset first threshold, and the temperature level is equal to the first threshold; 所述预设条件包括第二条件,所述第二条件为:The preset conditions include a second condition, and the second condition is: 所述温度等级与所述第一质量等级的和大于或等于所述第一阈值,且所述第一质量等级等于所述第一阈值。The sum of the temperature level and the first quality level is greater than or equal to the first threshold, and the first quality level is equal to the first threshold. 2.根据权利要求1所述的方法,其特征在于,所述获取所述终端的温度等级和所述第一网络的第一质量等级,包括:2. The method according to claim 1, wherein the acquiring the temperature level of the terminal and the first quality level of the first network comprises: 获取所述终端的当前温度值,根据所述当前温度值确定所述温度等级;acquiring the current temperature value of the terminal, and determining the temperature level according to the current temperature value; 获取所述第一网络的网络连接信息,根据所述第一网络的网络连接信息确定所述第一质量等级。Acquire network connection information of the first network, and determine the first quality level according to the network connection information of the first network. 3.根据权利要求1所述的方法,其特征在于,在所述温度等级和所述第一质量等级满足所述第一条件的情况下,所述执行所述预设条件对应的优化程序,包括:3. The method according to claim 1, wherein when the temperature level and the first quality level meet the first condition, the execution of the optimization program corresponding to the preset condition comprises: 禁止所述终端连接至所述第一网络,直至所述温度等级小于第二阈值。Prohibiting the terminal from connecting to the first network until the temperature level is less than a second threshold. 4.根据权利要求1所述的方法,其特征在于,在所述执行所述预设条件对应的优化程序之前,所述方法还包括:4. The method according to claim 1, wherein, before the optimization program corresponding to the preset condition is executed, the method further comprises: 将计数器的计数值设置为N;Set the count value of the counter to N; 在所述温度等级和所述第一质量等级满足所述第二条件的情况下,所述执行所述预设条件对应的优化程序,包括:When the temperature level and the first quality level meet the second condition, the execution of the optimization program corresponding to the preset condition includes: 禁止所述终端连接至所述第一网络,并启动计时器;prohibiting the terminal from connecting to the first network, and starting a timer; 在计时时长达到预设时长阈值的情况下,控制所述终端重新连接至所述第一网络;controlling the terminal to reconnect to the first network when the timing duration reaches a preset duration threshold; 其中,N为大于0的自然数,所述时长阈值等于所述计数值与预设的单位时长的乘积。Wherein, N is a natural number greater than 0, and the duration threshold is equal to the product of the count value and a preset unit duration. 5.根据权利要求4所述的方法,其特征在于,在所述控制所述终端重新连接至所述第一网络之后,所述方法还包括:5. The method according to claim 4, wherein after said controlling said terminal to reconnect to said first network, said method further comprises: 在第一预设时长内,所述第一质量等级小于第三阈值的情况下,将所述计数器清零;If the first quality level is less than a third threshold within a first preset time period, clearing the counter; 在所述第一预设时长内,所述第一质量等级不小于第三阈值的情况下,将所述计数器的计数值设置为N+1,并再次执行所述预设条件对应的优化程序。If the first quality level is not less than a third threshold within the first preset time period, the count value of the counter is set to N+1, and the optimization program corresponding to the preset condition is executed again. 6.根据权利要求4所述的方法,其特征在于,所述预设条件包括第三条件,所述第三条件为:6. The method according to claim 4, wherein the preset condition comprises a third condition, and the third condition is: 所述温度等级与所述第一质量等级的和大于或等于所述第一阈值,且所述温度等级和所述第一质量等级均小于所述第一阈值。The sum of the temperature level and the first quality level is greater than or equal to the first threshold, and both the temperature level and the first quality level are smaller than the first threshold. 7.根据权利要求6所述的方法,其特征在于,在所述温度等级和所述第一质量等级满足所述第三条件的情况下,所述执行所述预设条件对应的优化程序,包括:7. The method according to claim 6, wherein when the temperature level and the first quality level meet the third condition, the execution of the optimization program corresponding to the preset condition comprises: 控制所述终端切换至所述第一网络;controlling the terminal to switch to the first network; 在所述温度等级和所述第一质量等级仍满足所述第三条件的情况下,控制所述终端断开所述第一网络,启动计时器;When the temperature level and the first quality level still meet the third condition, control the terminal to disconnect the first network and start a timer; 在计时时长达到所述时长阈值的情况下,控制所述终端重新连接至所述第一网络。When the timing duration reaches the duration threshold, the terminal is controlled to reconnect to the first network. 8.根据权利要求7所述的方法,其特征在于,在所述控制所述终端重新连接至所述第一网络之后,所述方法还包括:8. The method according to claim 7, characterized in that, after said controlling said terminal to reconnect to said first network, said method further comprises: 在所述温度等级和所述第一质量等级不再满足所述第三条件的情况下,将所述计数器清零;If the temperature level and the first quality level no longer meet the third condition, clearing the counter; 在所述温度等级和所述第一质量等级仍满足所述第三条件的情况下,将所述计数器的计数设置为N+1,并再次执行所述预设条件对应的优化程序。In the case that the temperature level and the first quality level still meet the third condition, the count of the counter is set to N+1, and the optimization program corresponding to the preset condition is executed again. 9.根据权利要求1至8中任一项所述的方法,其特征在于,在所述控制所述终端切换至第二网络之后,所述方法还包括:9. The method according to any one of claims 1 to 8, characterized in that, after the controlling the terminal to switch to the second network, the method further comprises: 获取所述第二网络的网络连接信息,根据所述第二网络的网络连接信息确定第二质量等级;acquiring network connection information of the second network, and determining a second quality level according to the network connection information of the second network; 在所述第二质量等级大于第四阈值的情况下,获取当前小区的小区状态信息;If the second quality level is greater than a fourth threshold, acquire cell state information of the current cell; 在所述小区状态信息为异常状态的情况下,控制所述终端在第二预设时长内停止连接所述当前小区。When the cell status information is abnormal, the terminal is controlled to stop connecting to the current cell within a second preset time period. 10.根据权利要求9所述的方法,其特征在于,还包括:10. The method of claim 9, further comprising: 在所述第二质量等级大于第五阈值的情况下,控制所述终端在第三预设时长内断开网络连接;When the second quality level is greater than a fifth threshold, controlling the terminal to disconnect from the network within a third preset duration; 其中,所述第五阈值大于所述第四阈值。Wherein, the fifth threshold is greater than the fourth threshold. 11.一种网络连接装置,其特征在于,包括:11. A network connection device, comprising: 获取模块,用于在终端连接至第一网络的情况下,获取所述终端的温度等级和所述第一网络的第一质量等级;An acquisition module, configured to acquire the temperature level of the terminal and the first quality level of the first network when the terminal is connected to the first network; 控制模块,用于在所述温度等级和所述第一质量等级满足预设条件的情况下,控制所述终端切换至第二网络,并执行所述预设条件对应的优化程序;A control module, configured to control the terminal to switch to a second network when the temperature level and the first quality level meet a preset condition, and execute an optimization program corresponding to the preset condition; 所述预设条件包括第一条件,所述第一条件为:The preset conditions include a first condition, and the first condition is: 所述温度等级与所述第一质量等级的和大于或等于预设的第一阈值,且所述温度等级等于所述第一阈值;The sum of the temperature level and the first quality level is greater than or equal to a preset first threshold, and the temperature level is equal to the first threshold; 所述预设条件包括第二条件,所述第二条件为:The preset conditions include a second condition, and the second condition is: 所述温度等级与所述第一质量等级的和大于或等于所述第一阈值,且所述第一质量等级等于所述第一阈值。The sum of the temperature level and the first quality level is greater than or equal to the first threshold, and the first quality level is equal to the first threshold.
CN202110204759.1A 2021-02-24 2021-02-24 Network connection method and device Active CN113015226B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202110204759.1A CN113015226B (en) 2021-02-24 2021-02-24 Network connection method and device
PCT/CN2022/076560 WO2022179425A1 (en) 2021-02-24 2022-02-17 Network connection method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110204759.1A CN113015226B (en) 2021-02-24 2021-02-24 Network connection method and device

Publications (2)

Publication Number Publication Date
CN113015226A CN113015226A (en) 2021-06-22
CN113015226B true CN113015226B (en) 2023-07-25

Family

ID=76408907

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110204759.1A Active CN113015226B (en) 2021-02-24 2021-02-24 Network connection method and device

Country Status (2)

Country Link
CN (1) CN113015226B (en)
WO (1) WO2022179425A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113015226B (en) * 2021-02-24 2023-07-25 维沃移动通信有限公司 Network connection method and device
CN114698013A (en) * 2022-03-21 2022-07-01 Oppo广东移动通信有限公司 Network reconnection method, device, mobile terminal and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102176782A (en) * 2011-01-10 2011-09-07 华为终端有限公司 Wireless terminal equipment and thermal protection method thereof
CN111601377A (en) * 2020-05-15 2020-08-28 北京小米移动软件有限公司 Temperature control method, device and storage medium

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102394978B1 (en) * 2015-09-18 2022-05-09 삼성전자주식회사 Method for handover in wireless communication system and apparatus therefore
CN105307228B (en) * 2015-10-23 2018-09-04 广东欧珀移动通信有限公司 A kind of method for switching network of mobile terminal, device and mobile terminal
KR102402639B1 (en) * 2017-11-24 2022-05-26 삼성전자주식회사 Electronic device and method for communicating thereof
US10880805B2 (en) * 2019-05-01 2020-12-29 At&T Intellectual Property I, L.P. Mitigating user equipment overheating for 5G or other next generation network
CN110213794B (en) * 2019-05-08 2023-03-17 成都市联洲国际技术有限公司 Temperature adjusting method and device, terminal equipment and storage medium
CN110300446B (en) * 2019-06-28 2022-03-22 南昌黑鲨科技有限公司 Network connection control method, system, intelligent terminal and computer readable storage medium
CN113015226B (en) * 2021-02-24 2023-07-25 维沃移动通信有限公司 Network connection method and device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102176782A (en) * 2011-01-10 2011-09-07 华为终端有限公司 Wireless terminal equipment and thermal protection method thereof
CN111601377A (en) * 2020-05-15 2020-08-28 北京小米移动软件有限公司 Temperature control method, device and storage medium

Also Published As

Publication number Publication date
WO2022179425A1 (en) 2022-09-01
CN113015226A (en) 2021-06-22

Similar Documents

Publication Publication Date Title
CN110198550B (en) Auxiliary cell group maintenance method, terminal equipment and network node
CN111615141B (en) Measurement method, measurement configuration method, terminal and network equipment
RU2769399C1 (en) Reconfiguration method and user equipment
KR101985359B1 (en) A method and apparatus for interaction between a terminal and a network device
CN109803347B (en) Service processing method and mobile communication terminal
CN108200632B (en) Method for accessing terminal to LTE network and terminal
CN110505638B (en) Measurement control method, terminal and network side equipment
CN110300404A (en) A kind of network control method and mobile terminal
CN111988771B (en) Wireless connection control method, device and electronic equipment
CN113015226B (en) Network connection method and device
CN112469096B (en) Cell switching method and device
CN110505664B (en) Parameter adjusting method, device, terminal and storage medium
CN110022567A (en) A kind of data transmission method and user terminal
WO2023060988A1 (en) Reestablishment method in communication abnormality, terminal device, and storage medium
CN112601241B (en) Network access method and device
CN111417173B (en) Current interruption recovery method and electronic device
CN111436090A (en) PLMN synchronization method, terminal and storage medium
CN113472493B (en) A method for determining a reference signal and related equipment
US20230088033A1 (en) Wi-fi control method and apparatus and electronic device
CN110611920A (en) A wireless link monitoring method and terminal
WO2020048477A1 (en) Terminal camping method, information transmission method, terminal, and network device
US11412433B2 (en) Method of processing beam failure recovery and user equipment
WO2018120032A1 (en) Cell switching method and terminal device
CN108271243B (en) A location area update method and terminal device
CN114650616A (en) Network mode control method and device

Legal Events

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