CN114449599B - Network link switching method based on electronic equipment position and electronic equipment - Google Patents

Network link switching method based on electronic equipment position and electronic equipment Download PDF

Info

Publication number
CN114449599B
CN114449599B CN202110876161.7A CN202110876161A CN114449599B CN 114449599 B CN114449599 B CN 114449599B CN 202110876161 A CN202110876161 A CN 202110876161A CN 114449599 B CN114449599 B CN 114449599B
Authority
CN
China
Prior art keywords
network
quality
electronic device
network quality
superior
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
CN202110876161.7A
Other languages
Chinese (zh)
Other versions
CN114449599A (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.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202110876161.7A priority Critical patent/CN114449599B/en
Priority to CN202310481503.4A priority patent/CN116614848A/en
Publication of CN114449599A publication Critical patent/CN114449599A/en
Application granted granted Critical
Publication of CN114449599B publication Critical patent/CN114449599B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/0005Control or signalling for completing the hand-off
    • H04W36/0083Determination of parameters used for hand-off, e.g. generation or modification of neighbour cell lists
    • H04W36/0085Hand-off measurements
    • 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
    • H04W36/30Reselection being triggered by specific parameters by measured or perceived connection quality data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/24Reselection being triggered by specific parameters
    • H04W36/32Reselection being triggered by specific parameters by location or mobility data, e.g. speed data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W88/00Devices specially adapted for wireless communication networks, e.g. terminals, base stations or access point devices
    • H04W88/02Terminal devices
    • H04W88/06Terminal devices adapted for operation in multiple networks or having at least two operational modes, e.g. multi-mode terminals
    • 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

Abstract

The embodiment of the application provides a network link switching method based on the position of electronic equipment and the electronic equipment, wherein the method is executed by the electronic equipment and comprises the following steps: the electronic device currently uses a Wi-Fi1 network to execute network services; detecting network quality of the Wi-Fi2 network, the first cellular network and the second cellular network under the condition that the electronic equipment meets preset conditions, wherein the preset conditions comprise that the electronic equipment is in an elevator state or in a weak signal scene; when the network quality of the Wi-Fi1 network is detected to not reach the preset network quality, switching the service flow data of the network service on the Wi-Fi1 network to the first cellular network, wherein the network quality of the first cellular network is superior to that of the Wi-Fi1 network. In the method, in the scene that the network is easy to be blocked in an elevator and the like, the electronic equipment shortens the service blocking time and improves the use experience of a user by detecting other network links in advance.

Description

Network link switching method based on electronic equipment position and electronic equipment
Technical Field
The application relates to the technical field of electronics, in particular to a network link switching method based on the position of electronic equipment and the electronic equipment.
Background
The full network aggregation technology (linkturo engine, abbreviated as linktturbo) is a technology for simultaneously using wireless fidelity (wireless fidelity, wi-Fi) and a cellular network at an electronic equipment side, and can bring mobile internet experience of high network speed aggregation and stable low time delay to users through the linktturbo. After the electronic device opens the linkbit function, the network required by the Application (APP) can be intelligently identified in the use process, so as to realize intelligent allocation and optimization, for example, the network with high traffic demand (such as online video or online game) calls Wi-Fi preferentially, and the network with low traffic demand (such as online shopping) uses a cellular network, so as to optimize the network environment to the greatest extent.
In the above-mentioned all network environment, if the network quality of one network link a is poor, the electronic device may detect the network quality of other network links, and switch the traffic data processed on the network link a to the traffic data processed on the network link B.
Disclosure of Invention
The application provides a network link switching method based on an electronic equipment position and the electronic equipment, which can shorten the service blocking time length and improve the use experience of a user in the scene that the elevator and the like are easy to generate network blocking.
In a first aspect, the present application provides a network link switching method based on a location of an electronic device, where the method is executed by the electronic device, the electronic device supports a Wi-Fi1 network in a 2.4GHz band and a Wi-Fi2 network in a 5GHz band, the electronic device carries a first SIM card and a second SIM card, the first SIM card corresponds to a first cellular network, and the second SIM card corresponds to a second cellular network, where the method includes: the electronic device currently uses a Wi-Fi1 network to execute network services; detecting network quality of the Wi-Fi2 network, the first cellular network and the second cellular network under the condition that the electronic equipment meets preset conditions, wherein the preset conditions comprise that the electronic equipment is in an elevator state or in a weak signal scene; when the network quality of the Wi-Fi1 network is detected to not reach the preset network quality, switching the service flow data of the network service on the Wi-Fi1 network to the first cellular network, wherein the network quality of the first cellular network is superior to that of the Wi-Fi1 network.
In the implementation manner, when the electronic device is in an elevator state or in a weak signal scene such as an underground garage, the detection of other network links is pulled up, and when the network quality of the current network link (i.e. Wi-Fi1 network) is detected to not reach the preset network quality, the other network link with better quality (i.e. first cellular network) is detected, and the traffic flow data processed on the Wi-Fi1 network is directly switched to the first cellular network for processing. Therefore, in the scene that the network is blocked easily in an elevator and the like, the electronic equipment shortens the service blocking time and improves the use experience of a user by detecting other network links in advance.
With reference to the first aspect, in some implementations of the first aspect, a network quality of the first cellular network reaches a preset network quality.
In combination with the first aspect and the implementation manner, the electronic device switches the Wi-Fi1 network with the network quality not reaching the preset network quality to the first cellular network with the network quality reaching the preset network quality, so that the smoothness of processing the network service can be improved to a greater extent, and the service blocking duration is shortened.
With reference to the first aspect, in some implementations of the first aspect, the network quality of the Wi-Fi2 network, the first cellular network, and the second cellular network do not reach a preset network quality, but the network quality of the first cellular network is better than the network quality of the Wi-Fi1 network.
With reference to the first aspect and the foregoing implementation manner, although the network quality of the Wi-Fi2 network, the first cellular network, and the second cellular network detected by the electronic device do not reach the preset network quality, the network quality of the first cellular network is better than the network quality of the Wi-Fi1 network, and then, switching the traffic flow data on the Wi-Fi1 network to the first cellular network may reduce the traffic jam phenomenon to a certain extent.
With reference to the first aspect, in some implementations of the first aspect, the method further includes: when the network quality of the Wi-Fi1 network is detected to reach the preset network quality, but the network quality of the first cellular network is superior to that of the Wi-Fi1 network, switching the service flow data of the network service on the Wi-Fi1 network to the first cellular network.
With reference to the first aspect and the foregoing implementation manner, although the network quality of the Wi-Fi1 network detected by the electronic device has reached the preset network quality, a better first cellular network is detected, and then the electronic device may also switch the traffic data on the Wi-Fi1 network to the first cellular network, so as to further improve the processing efficiency of the network service.
With reference to the first aspect, in some implementations of the first aspect, the detecting network quality of the Wi-Fi2 network, the first cellular network, and the second cellular network includes: transmitting data packets to a detection server through network links corresponding to a Wi-Fi2 network, a first cellular network and a second cellular network respectively; and determining network quality of the Wi-Fi2 network, the first cellular network and the second cellular network according to at least one index of the round trip delay, the packet loss rate, the packet error rate and the sending rate of the sending data packet.
With reference to the first aspect and the implementation manner, the electronic device sends a data packet to the detection server through the network link to detect network quality of the Wi-Fi2 network, the first cellular network and the second cellular network, so that accuracy of the detected network quality can be improved, and an accurate data basis is provided for subsequent network link switching.
With reference to the first aspect, in some implementations of the first aspect, the data packet is an internet packet explorer ping packet, where the ping packet includes an internet protocol IP address field, a data packet type field, and a probe server domain name field.
With reference to the first aspect and the implementation manner, the electronic device accurately determines the target detection server by sending the ping packet, so as to further improve accuracy of the detected network quality.
With reference to the first aspect, in some implementations of the first aspect, the sending, by the network links corresponding to the Wi-Fi2 network, the first cellular network, and the second cellular network, the data packet to the probe server includes: according to the network priorities of the Wi-Fi2 network, the first cellular network and the second cellular network, respectively sending data packets to the detection server through network links corresponding to the Wi-Fi2 network, the first cellular network and the second cellular network; or simultaneously sending the data packets to the probe server through network links corresponding to the Wi-Fi2 network, the first cellular network and the second cellular network respectively.
With reference to the first aspect and the implementation manner, if the electronic device detects the Wi-Fi2 network, the first cellular network, and the second cellular network according to the network priorities of the networks, the detection can be stopped when the switchable network link is detected, so as to reduce communication power consumption between the electronic device and the detection server and reduce working pressure of the electronic device. If the electronic device detects the Wi-Fi2 network, the first cellular network and the second cellular network at the same time, the detection efficiency can be improved to a certain extent.
With reference to the first aspect, in some implementations of the first aspect, the method further includes: acquiring sensor data acquired by a sensor of the electronic equipment; and determining that the electronic equipment is in an elevator state according to the sensor data.
With reference to the first aspect and the implementation manner, the electronic device determines the state of the electronic device according to the sensor data collected by the internal sensor, so as to determine whether the electronic device is in an elevator state, and execute the network link switching process when the electronic device is in the elevator state, so as to shorten the service clamping duration in a scene of easily generating network clamping such as an elevator.
With reference to the first aspect, in some implementations of the first aspect, the sensor data includes acceleration sensor data.
With reference to the first aspect and the implementation manner, the electronic device determines whether the elevator is in an elevator state according to the data of the acceleration sensor, so as to improve accuracy of a determination result.
With reference to the first aspect, in some implementations of the first aspect, the method includes: the electronic device currently uses a Wi-Fi1 network to execute network services; under the condition that the electronic equipment is in an elevator state, data packets are sent to a detection server through network links corresponding to a Wi-Fi2 network, a first cellular network and a second cellular network respectively; determining network quality of the Wi-Fi2 network, the first cellular network and the second cellular network according to at least one index of round trip delay, packet loss rate, packet error rate and transmission rate of the transmitted data packet; detecting network quality of a Wi-Fi1 network; when the network quality of the Wi-Fi1 network is detected to be not up to the preset network quality, switching the service flow data of the network service on the Wi-Fi1 network to the first cellular network.
With reference to the first aspect and the implementation manner, when the electronic device is in an elevator state, the electronic device pulls up detection of other network links, and when detecting that the network quality of the current network link (i.e. Wi-Fi1 network) does not reach the preset network quality, the electronic device detects that other network links with better quality (i.e. first cellular network) already exist, and directly switches the traffic data processed on the Wi-Fi1 network to be processed on the first cellular network. Therefore, in the scene that the network is blocked easily in an elevator and the like, the electronic equipment shortens the service blocking time and improves the use experience of a user by detecting other network links in advance.
In a second aspect, the present application provides an apparatus, which is included in an electronic device, and which has a function of implementing the electronic device behavior in the first aspect and possible implementations of the first aspect. The functions may be realized by hardware, or may be realized by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the functions described above. Such as a receiving module or unit, a processing module or unit, etc.
In a third aspect, the present application provides an electronic device, the electronic device comprising: a processor, a memory, and an interface; the processor, the memory and the interface cooperate with each other such that the electronic device performs any one of the methods of the technical solutions of the first aspect.
In a fourth aspect, the present application provides a chip comprising a processor. The processor is configured to read and execute a computer program stored in the memory to perform the method of the first aspect and any possible implementation thereof.
Optionally, the chip further comprises a memory, and the memory is connected with the processor through a circuit or a wire.
Further optionally, the chip further comprises a communication interface.
In a fifth aspect, the present application provides a computer readable storage medium, in which a computer program is stored, which when executed by a processor causes the processor to perform any one of the methods of the first aspect.
In a sixth aspect, the present application provides a computer program product comprising: computer program code which, when run on an electronic device, causes the electronic device to perform any one of the methods of the solutions of the first aspect.
Drawings
FIG. 1 is a schematic diagram of an example of a LinkTurbo technique principle provided in an embodiment of the present application;
FIG. 2 is a schematic diagram of another example LinkTurbo technique principle provided in an embodiment of the present application;
FIG. 3 is a schematic diagram illustrating an example of a network link switching process provided by the prior art;
fig. 4 is a schematic diagram of an example network link switching process according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of an example of an electronic device according to an embodiment of the present application;
FIG. 6 is a block diagram of an example sensor hub provided in an embodiment of the present application;
FIG. 7 is a block diagram of a software architecture of an example electronic device according to an embodiment of the present application;
FIG. 8 (a) is a schematic diagram of an exemplary setup interface according to an embodiment of the present application;
fig. 8 (b) is a schematic diagram of an example WLAN setup interface provided in an embodiment of the present application;
fig. 8 (c) is a schematic diagram of an example of a network acceleration setting interface according to an embodiment of the present application;
Fig. 9 is a schematic diagram of an exemplary SIM card management setting interface according to an embodiment of the present application;
fig. 10 is a flowchart of an example of a network link switching method based on a location of an electronic device according to an embodiment of the present application;
fig. 11 is a schematic diagram of an example of detecting network quality of a cell 1 according to an embodiment of the present application;
fig. 12 is a schematic flow chart of an example of detection of Wi-Fi2, cell 1 and cell 2 provided in the embodiment of the present application;
fig. 13 is a schematic flow chart of another example of detecting Wi-Fi2, cell 1 and cell 2 according to an embodiment of the present application;
fig. 14 is a flowchart of another example of a network link switching method based on a location of an electronic device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be described below with reference to the drawings in the embodiments of the present application. Wherein, in the description of the embodiments of the present application, "/" means or is meant unless otherwise indicated, for example, a/B may represent a or B; "and/or" herein is merely an association relationship describing an association object, and means that three relationships may exist, for example, a and/or B may mean: a exists alone, A and B exist together, and B exists alone. In addition, in the description of the embodiments of the present application, "plurality" means two or more than two.
The terms "first," "second," "third," and the like, are used below for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first", "a second", or a third "may explicitly or implicitly include one or more such feature.
First, we introduce a linktree technique, which in one embodiment, as shown in fig. 1, can use a multiplexing control protocol (multipath transmission control protocol, MP-TCP) and a multiplexing user datagram protocol (multipath user datagram protocol, MP-UDP) simultaneously, and by combining the MP-TCP protocol and the MP-UDP protocol, can use the cellular network and Wi-Fi simultaneously, thereby providing a mobile internet experience with high network speed and stable low latency for users. The MP-UDP protocol is adopted without establishing a link, has high transmission speed and small time delay, and is suitable for real-time APP (such as video APP or game APP) with high response speed requirements, while the MP-TCP protocol is adopted with slightly lower transmission speed, and is suitable for non-real-time APP (such as social APP or shopping APP) with low response speed requirements.
In another embodiment, as shown in fig. 2, the linkbroo technology may employ MP-Flow protocol to implement simultaneous use of cellular network and Wi-Fi, and allocate different networks for traffic demands of different APPs. For example, a Wi-Fi network is assigned to a video APP or game APP, and a cellular network is assigned to a social APP or shopping APP.
In a scene that a user takes an elevator with electronic equipment, assuming that the electronic equipment has opened a LinkTurbo function and the user currently uses a video APP to watch online videos, at the moment, a Wi-Fi network (marked as a first network link) outside the elevator is used for providing network services for the video APP, and after the video APP enters the elevator, the network quality of the Wi-Fi network is poor, so that the normal operation of the video APP is seriously influenced, for example, the phenomenon of blocking and the like occurs in video playing. In view of this problem, as shown in fig. 3, when the electronic device in the conventional technology detects that the network quality of the first network link does not reach the preset network quality, the electronic device initiates activation or detection of other network links, and switches the service flow data of the video APP to be processed on the available second network link if the available second network link exists. As can be seen from fig. 3, the process of switching network links by the electronic device is serial, where the activation or detection of other network links is most time-consuming, usually takes 1-2 seconds(s), and then the process of switching traffic data of the video APP by the electronic device onto the available second network link usually requires 3-5 seconds, i.e. 3-5 seconds for video katon recovery, and the recovery time is long, which easily results in poor user experience.
In view of this, the embodiment of the application provides a network link switching method based on the location of an electronic device, as shown in fig. 4, when the electronic device detects that the electronic device enters an elevator, the electronic device initiates an activation or detection process for other network links, and then when the electronic device detects that the network quality of a first network link does not reach a preset network quality, the electronic device detects that an available second network link has been detected, and then the traffic data processed on the first network link is directly switched to the available second network link for processing. Therefore, in the scene that the network is blocked easily in an elevator and the like, the electronic equipment shortens the service blocking time and improves the use experience of a user by activating or detecting other network links in advance.
It should be noted that, the network link switching method based on the location of the electronic device provided in the embodiment of the present application may be applied to an electronic device having a linkbit function, such as a mobile phone, a tablet computer, a wearable device, a vehicle-mounted device, an augmented reality (augmented reality, AR)/Virtual Reality (VR) device, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (personal digital assistant, PDA), and the like, where the embodiment of the present application does not limit the specific type of the electronic device.
Fig. 5 is a schematic structural diagram of an electronic device 100 according to an embodiment of the present application. The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (universal serial bus, USB) interface 130, a charge management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, keys 190, a motor 191, an indicator 192, a camera 193, a display 194, and a subscriber identity module (subscriber identification module, SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyro sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, and the like.
It is to be understood that the structure illustrated in the embodiments of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, electronic device 100 may include more or fewer components than shown, or certain components may be combined, or certain components may be split, or different arrangements of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
The processor 110 may include one or more processing units, such as: the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), a controller, a memory, a video codec, a digital signal processor (digital signal processor, DSP), a baseband processor, and/or a neural network processor (neural-network processing unit, NPU), etc. Wherein the different processing units may be separate devices or may be integrated in one or more processors.
The controller may be a neural hub and a command center of the electronic device 100, among others. The controller can generate operation control signals according to the instruction operation codes and the time sequence signals to finish the control of instruction fetching and instruction execution.
A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may hold instructions or data that the processor 110 has just used or recycled. If the processor 110 needs to reuse the instruction or data, it may be called directly from memory. Repeated accesses are avoided and the latency of the processor 110 is reduced, thereby improving the efficiency of the system.
In some embodiments, the processor 110 may include one or more interfaces. The interfaces may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous receiver transmitter (universal asynchronous receiver/transmitter, UART) interface, a mobile industry processor interface (mobile industry processor interface, MIPI), a general-purpose input/output (GPIO) interface, a subscriber identity module (subscriber identity module, SIM) interface, and/or a universal serial bus (universal serial bus, USB) interface, among others.
The I2C interface is a bi-directional synchronous serial bus comprising a serial data line (SDA) and a serial clock line (derail clock line, SCL). In some embodiments, the processor 110 may contain multiple sets of I2C buses. The processor 110 may be coupled to the touch sensor 180K, charger, flash, camera 193, etc., respectively, through different I2C bus interfaces. For example: the processor 110 may be coupled to the touch sensor 180K through an I2C interface, such that the processor 110 communicates with the touch sensor 180K through an I2C bus interface to implement a touch function of the electronic device 100.
The I2S interface may be used for audio communication. In some embodiments, the processor 110 may contain multiple sets of I2S buses. The processor 110 may be coupled to the audio module 170 via an I2S bus to enable communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 may transmit an audio signal to the wireless communication module 160 through the I2S interface, to implement a function of answering a call through the bluetooth headset.
PCM interfaces may also be used for audio communication to sample, quantize and encode analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface. In some embodiments, the audio module 170 may also transmit audio signals to the wireless communication module 160 through the PCM interface to implement a function of answering a call through the bluetooth headset. Both the I2S interface and the PCM interface may be used for audio communication.
The UART interface is a universal serial data bus for asynchronous communications. The bus may be a bi-directional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is typically used to connect the processor 110 with the wireless communication module 160. For example: the processor 110 communicates with a bluetooth module in the wireless communication module 160 through a UART interface to implement a bluetooth function. In some embodiments, the audio module 170 may transmit an audio signal to the wireless communication module 160 through a UART interface, to implement a function of playing music through a bluetooth headset.
The MIPI interface may be used to connect the processor 110 to peripheral devices such as a display 194, a camera 193, and the like. The MIPI interfaces include camera serial interfaces (camera serial interface, CSI), display serial interfaces (display serial interface, DSI), and the like. In some embodiments, processor 110 and camera 193 communicate through a CSI interface to implement the photographing functions of electronic device 100. The processor 110 and the display 194 communicate via a DSI interface to implement the display functionality of the electronic device 100.
The GPIO interface may be configured by software. The GPIO interface may be configured as a control signal or as a data signal. In some embodiments, a GPIO interface may be used to connect the processor 110 with the camera 193, the display 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like. The GPIO interface may also be configured as an I2C interface, an I2S interface, a UART interface, an MIPI interface, etc.
The USB interface 130 is an interface conforming to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, or the like. The USB interface 130 may be used to connect a charger to charge the electronic device 100, and may also be used to transfer data between the electronic device 100 and a peripheral device. And can also be used for connecting with a headset, and playing audio through the headset. The interface may also be used to connect other electronic devices, such as AR devices, etc.
It should be understood that the interfacing relationship between the modules illustrated in the embodiments of the present application is only illustrative, and does not limit the structure of the electronic device 100. In other embodiments of the present application, the electronic device 100 may also use different interfacing manners, or a combination of multiple interfacing manners in the foregoing embodiments.
The charge management module 140 is configured to receive a charge input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charge management module 140 may receive a charging input of a wired charger through the USB interface 130. In some wireless charging embodiments, the charge management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100. The charging management module 140 may also supply power to the electronic device through the power management module 141 while charging the battery 142.
The power management module 141 is used for connecting the battery 142, and the charge management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and/or the charge management module 140 and provides power to the processor 110, the internal memory 121, the external memory, the display 194, the camera 193, the wireless communication module 160, and the like. The power management module 141 may also be configured to monitor battery capacity, battery cycle number, battery health (leakage, impedance) and other parameters. In other embodiments, the power management module 141 may also be provided in the processor 110. In other embodiments, the power management module 141 and the charge management module 140 may be disposed in the same device.
The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, a modem processor, a baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals. The structures of the antennas 1 and 2 in fig. 5 are only one example. Each antenna in the electronic device 100 may be used to cover a single or multiple communication bands. Different antennas may also be multiplexed to improve the utilization of the antennas. For example: the antenna 1 may be multiplexed into a diversity antenna of a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The mobile communication module 150 may provide a solution for wireless communication including 2G/3G/4G/5G, etc., applied to the electronic device 100. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (low noise amplifier, LNA), etc. The mobile communication module 150 may receive electromagnetic waves from the antenna 1, perform processes such as filtering, amplifying, and the like on the received electromagnetic waves, and transmit the processed electromagnetic waves to the modem processor for demodulation. The mobile communication module 150 can amplify the signal modulated by the modem processor, and convert the signal into electromagnetic waves through the antenna 1 to radiate. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be provided in the same device as at least some of the modules of the processor 110.
The modem processor may include a modulator and a demodulator. The modulator is used for modulating the low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used for demodulating the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low frequency baseband signal to the baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and then transferred to the application processor. The application processor outputs sound signals through an audio device (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or video through the display screen 194. In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be provided in the same device as the mobile communication module 150 or other functional module, independent of the processor 110.
The wireless communication module 160 may provide solutions for wireless communication including wireless local area network (wireless local area networks, WLAN) (e.g., wireless fidelity (wireless fidelity, wi-Fi) network), bluetooth (BT), global navigation satellite system (global navigation satellite system, GNSS), frequency modulation (frequency modulation, FM), near field wireless communication technology (near field communication, NFC), infrared technology (IR), etc., as applied to the electronic device 100. The wireless communication module 160 may be one or more devices that integrate at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the electromagnetic wave signals, filters the electromagnetic wave signals, and transmits the processed signals to the processor 110. The wireless communication module 160 may also receive a signal to be transmitted from the processor 110, frequency modulate it, amplify it, and convert it to electromagnetic waves for radiation via the antenna 2.
In some embodiments, antenna 1 and mobile communication module 150 of electronic device 100 are coupled, and antenna 2 and wireless communication module 160 are coupled, such that electronic device 100 may communicate with a network and other devices through wireless communication techniques. Wireless communication techniques may include global system for mobile communications (global system for mobile communications, GSM), general packet radio service (general packet radio service, GPRS), code division multiple access (code division multiple access, CDMA), wideband code division multiple access (wideband code division multiple access, WCDMA), time division code division multiple access (time-division code division multiple access, TD-SCDMA), long term evolution (long term evolution, LTE), BT, GNSS, WLAN, NFC, FM, and/or IR techniques, among others. The GNSS may include a global satellite positioning system (global positioning system, GPS), a global navigation satellite system (global navigation satellite system, GLONASS), a beidou satellite navigation system (beidou navigation satellite system, BDS), a quasi zenith satellite system (quasi-zenith satellite system, QZSS) and/or a satellite based augmentation system (satellite based augmentation systems, SBAS).
The electronic device 100 implements display functions through a GPU, a display screen 194, an application processor, and the like. The GPU is a microprocessor for image processing, and is connected to the display 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 110 may include one or more GPUs that execute program instructions to generate or change display information.
The display screen 194 is used to display images, videos, and the like. The display 194 includes a display panel. The display panel may employ a liquid crystal display (liquid crystal display, LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED) or an active-matrix organic light-emitting diode (matrix organic light emitting diode), a flexible light-emitting diode (flex), a mini, a Micro led, a Micro-OLED, a quantum dot light-emitting diode (quantum dot light emitting diodes, QLED), or the like. In some embodiments, the electronic device 100 may include 1 or N display screens 194, N being a positive integer greater than 1.
The electronic device 100 may implement photographing functions through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
The ISP is used to process data fed back by the camera 193. For example, when photographing, the shutter is opened, light is transmitted to the camera photosensitive element through the lens, the optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, so that the electrical signal is converted into an image visible to naked eyes. ISP can also optimize the noise, brightness and skin color of the image. The ISP can also optimize parameters such as exposure, color temperature and the like of a shooting scene. In some embodiments, the ISP may be provided in the camera 193.
The camera 193 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image onto the photosensitive element. The photosensitive element may be a charge coupled device (charge coupled device, CCD) or a Complementary Metal Oxide Semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, which is then transferred to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV, or the like format. In some embodiments, electronic device 100 may include 1 or N cameras 193, N being a positive integer greater than 1.
The digital signal processor is used for processing digital signals, and can process other digital signals besides digital image signals. For example, when the electronic device 100 selects a frequency bin, the digital signal processor is used to fourier transform the frequency bin energy, or the like.
Video codecs are used to compress or decompress digital video. The electronic device 100 may support one or more video codecs. In this way, the electronic device 100 may play or record video in a variety of encoding formats, such as: dynamic picture experts group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4, etc.
The NPU is a neural-network (NN) computing processor, and can rapidly process input information by referencing a biological neural network structure, for example, referencing a transmission mode between human brain neurons, and can also continuously perform self-learning. Applications such as intelligent awareness of the electronic device 100 may be implemented through the NPU, for example: image recognition, face recognition, speech recognition, text understanding, etc.
The external memory interface 120 may be used to connect an external memory card, such as a Micro SD card, to enable expansion of the memory capabilities of the electronic device 100. The external memory card communicates with the processor 110 through an external memory interface 120 to implement data storage functions. For example, files such as music, video, etc. are stored in an external memory card.
The internal memory 121 may be used to store computer-executable program code that includes instructions. The processor 110 executes various functional applications of the electronic device 100 and data processing by executing instructions stored in the internal memory 121. The internal memory 121 may include a storage program area and a storage data area. The storage program area may store an application program (such as a sound playing function, an image playing function, etc.) required for at least one function of the operating system, etc. The storage data area may store data created during use of the electronic device 100 (e.g., audio data, phonebook, etc.), and so on. In addition, the internal memory 121 may include a high-speed random access memory, and may further include a nonvolatile memory such as at least one magnetic disk storage device, a flash memory device, a universal flash memory (universal flash storage, UFS), and the like.
The electronic device 100 may implement audio functions through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, an application processor, and the like. Such as music playing, recording, etc.
The audio module 170 is used to convert digital audio information into an analog audio signal output and also to convert an analog audio input into a digital audio signal. The audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be disposed in the processor 110, or a portion of the functional modules of the audio module 170 may be disposed in the processor 110.
The speaker 170A, also referred to as a "horn," is used to convert audio electrical signals into sound signals. The electronic device 100 may listen to music, or to hands-free conversations, through the speaker 170A.
A receiver 170B, also referred to as a "earpiece", is used to convert the audio electrical signal into a sound signal. When electronic device 100 is answering a telephone call or voice message, voice may be received by placing receiver 170B in close proximity to the human ear.
Microphone 170C, also referred to as a "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or transmitting voice information, the user can sound near the microphone 170C through the mouth, inputting a sound signal to the microphone 170C. The electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C, and may implement a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may also be provided with three, four, or more microphones 170C to enable collection of sound signals, noise reduction, identification of sound sources, directional recording functions, etc.
The earphone interface 170D is used to connect a wired earphone. The headset interface 170D may be a USB interface 130 or a 3.5mm open mobile electronic device platform (open mobile terminal platform, OMTP) standard interface, a american cellular telecommunications industry association (cellular telecommunications industry association of the USA, CTIA) standard interface.
The pressure sensor 180A is used to sense a pressure signal, and may convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A may be disposed on the display screen 194. The pressure sensor 180A is of various types, such as a resistive pressure sensor, an inductive pressure sensor, a capacitive pressure sensor, and the like. The capacitive pressure sensor may be a capacitive pressure sensor comprising at least two parallel plates with conductive material. The capacitance between the electrodes changes when a force is applied to the pressure sensor 180A. The electronic device 100 determines the strength of the pressure from the change in capacitance. When a touch operation is applied to the display screen 194, the electronic apparatus 100 detects the touch operation intensity according to the pressure sensor 180A. The electronic device 100 may also calculate the location of the touch based on the detection signal of the pressure sensor 180A. In some embodiments, touch operations that act on the same touch location, but at different touch operation strengths, may correspond to different operation instructions. For example: and executing an instruction for checking the short message when the touch operation with the touch operation intensity smaller than the first pressure threshold acts on the short message application icon. And executing an instruction for newly creating the short message when the touch operation with the touch operation intensity being greater than or equal to the first pressure threshold acts on the short message application icon.
The gyro sensor 180B may be used to determine a motion gesture of the electronic device 100. In some embodiments, the angular velocity of electronic device 100 about three axes (i.e., x, y, and z axes) may be determined by gyro sensor 180B. The gyro sensor 180B may be used for photographing anti-shake. For example, when the shutter is pressed, the gyro sensor 180B detects the shake angle of the electronic device 100, calculates the distance to be compensated by the lens module according to the angle, and makes the lens counteract the shake of the electronic device 100 through the reverse motion, so as to realize anti-shake. The gyro sensor 180B may also be used for navigating, somatosensory game scenes.
The air pressure sensor 180C is used to measure air pressure. In some embodiments, electronic device 100 calculates altitude from barometric pressure values measured by barometric pressure sensor 180C, aiding in positioning and navigation.
The magnetic sensor 180D includes a hall sensor. The electronic device 100 may detect the opening and closing of the flip cover using the magnetic sensor 180D. In some embodiments, when the electronic device 100 is a flip machine, the electronic device 100 may detect the opening and closing of the flip according to the magnetic sensor 180D. And then according to the detected opening and closing state of the leather sheath or the opening and closing state of the flip, the characteristics of automatic unlocking of the flip and the like are set.
The acceleration sensor 180E may detect the magnitude of acceleration of the electronic device 100 in various directions (typically three axes). The magnitude and direction of gravity may be detected when the electronic device 100 is stationary. The electronic equipment gesture recognition method can also be used for recognizing the gesture of the electronic equipment, and is applied to horizontal and vertical screen switching, pedometers and other applications.
A distance sensor 180F for measuring a distance. The electronic device 100 may measure the distance by infrared or laser. In some embodiments, the electronic device 100 may range using the distance sensor 180F to achieve quick focus.
The proximity light sensor 180G may include, for example, a Light Emitting Diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic device 100 emits infrared light outward through the light emitting diode. The electronic device 100 detects infrared reflected light from nearby objects using a photodiode. When sufficient reflected light is detected, it may be determined that there is an object in the vicinity of the electronic device 100. When insufficient reflected light is detected, the electronic device 100 may determine that there is no object in the vicinity of the electronic device 100. The electronic device 100 can detect that the user holds the electronic device 100 close to the ear by using the proximity light sensor 180G, so as to automatically extinguish the screen for the purpose of saving power. The proximity light sensor 180G may also be used in holster mode, pocket mode to automatically unlock and lock the screen.
The ambient light sensor 180L is used to sense ambient light level. The electronic device 100 may adaptively adjust the brightness of the display 194 based on the perceived ambient light level. The ambient light sensor 180L may also be used to automatically adjust white balance when taking a photograph. Ambient light sensor 180L may also cooperate with proximity light sensor 180G to detect whether electronic device 100 is in a pocket to prevent false touches.
The fingerprint sensor 180H is used to collect a fingerprint. The electronic device 100 may utilize the collected fingerprint feature to unlock the fingerprint, access the application lock, photograph the fingerprint, answer the incoming call, etc.
The temperature sensor 180J is for detecting temperature. In some embodiments, the electronic device 100 performs a temperature processing strategy using the temperature detected by the temperature sensor 180J. For example, when the temperature reported by temperature sensor 180J exceeds a threshold, electronic device 100 performs a reduction in the performance of a processor located in the vicinity of temperature sensor 180J in order to reduce power consumption to implement thermal protection. In other embodiments, when the temperature is below another threshold, the electronic device 100 heats the battery 142 to avoid the low temperature causing the electronic device 100 to be abnormally shut down. In other embodiments, when the temperature is below a further threshold, the electronic device 100 performs boosting of the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperatures.
The touch sensor 180K, also referred to as a "touch panel". The touch sensor 180K may be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, which is also called a "touch screen". The touch sensor 180K is for detecting a touch operation acting thereon or thereabout. The touch sensor may communicate the detected touch operation to the application processor to determine the touch event type. Visual output related to touch operations may be provided through the display 194. In other embodiments, the touch sensor 180K may also be disposed on the surface of the electronic device 100 at a different location than the display 194.
The bone conduction sensor 180M may acquire a vibration signal. In some embodiments, bone conduction sensor 180M may acquire a vibration signal of a human vocal tract vibrating bone pieces. The bone conduction sensor 180M may also contact the pulse of the human body to receive the blood pressure pulsation signal. In some embodiments, bone conduction sensor 180M may also be provided in a headset, in combination with an osteoinductive headset. The audio module 170 may parse out a voice signal based on the vibration signal of the vocal part vibration bone piece obtained by the bone conduction sensor 180M, and implement a voice function. The application processor can analyze heart rate information based on the blood pressure beat signals acquired by the bone conduction sensor 180M, so that a heart rate detection function is realized.
In one embodiment, the electronic device 100 also includes a Sensor Hub (or Sensor Hub), otherwise known as a Sensor Hub, sensor co-processor, that is primarily connected to and processes data from the Sensor module 180 with low power consumption. As shown in FIG. 6, sensor Hub may include, but is not limited to, low power processing modules or processing circuits such as application processors, coprocessors, microprocessors (micro-programmed control unit, MCU), and the like. In general, sensor Hub can process data of sensors such as the above-described pressure Sensor 180A, gyro Sensor 180B, air pressure Sensor 180C, magnetic Sensor 180D, acceleration Sensor 180E, distance Sensor 180F, proximity Sensor 180G, fingerprint Sensor 180H, temperature Sensor 180J, touch Sensor 180K, ambient light Sensor 180L, bone conduction Sensor 180M, and the like, and perform fusion processing of the respective Sensor data.
According to different electronic devices and service scene requirements, the current Sensor Hub is mainly divided into three types: one is to place Sensor Hub as a separate chip between the application processor and various sensors; the other is to combine Sensor Hub with various sensors, receive the data of various sensors for fusion, and then provide the fused data to an application processor; and the application processor integrates the Sensor Hub, and various sensors provide data to the Sensor Hub in the application processor after the fusion processing of the Sensor Hub.
In one embodiment, the Sensor Hub may determine whether the electronic device is in an overweight or weightless state according to the data of the air pressure Sensor 180C or the acceleration Sensor 180E, so as to determine whether the electronic device enters the elevator with the user currently.
The keys 190 include a power-on key, a volume key, etc. The keys 190 may be mechanical keys. Or may be a touch key. The electronic device 100 may receive key inputs, generating key signal inputs related to user settings and function controls of the electronic device 100.
The motor 191 may generate a vibration cue. The motor 191 may be used for incoming call vibration alerting as well as for touch vibration feedback. For example, touch operations acting on different applications (e.g., photographing, audio playing, etc.) may correspond to different vibration feedback effects. The motor 191 may also correspond to different vibration feedback effects by touching different areas of the display screen 194. Different application scenarios (such as time reminding, receiving information, alarm clock, game, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect may also support customization.
The indicator 192 may be an indicator light, may be used to indicate a state of charge, a change in charge, a message indicating a missed call, a notification, etc.
The SIM card interface 195 is used to connect a SIM card. The SIM card may be inserted into the SIM card interface 195, or removed from the SIM card interface 195 to enable contact and separation with the electronic device 100. The electronic device 100 may support 1 or N SIM card interfaces, N being a positive integer greater than 1. The SIM card interface 195 may support Nano SIM cards, micro SIM cards, and the like. The same SIM card interface 195 may be used to insert multiple cards simultaneously. The types of the plurality of cards may be the same or different. The SIM card interface 195 may also be compatible with different types of SIM cards. The SIM card interface 195 may also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to realize functions such as communication and data communication. In some embodiments, the electronic device 100 employs esims, i.e.: an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.
The software system of the electronic device 100 may employ a layered architecture, an event driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. In this embodiment, taking an Android system with a layered architecture as an example, a software structure of the electronic device 100 is illustrated.
Fig. 7 is a software configuration block diagram of the electronic device 100 of the embodiment of the present application. The layered architecture divides the software into several layers, each with distinct roles and branches. The layers communicate with each other through a software interface. In some embodiments, the Android system is divided into four layers, from top to bottom, an application layer, an application framework layer, an Zhuoyun row (Android run) and system libraries, and a kernel layer, respectively. The application layer may include a series of application packages.
As shown in fig. 7, the application package may include applications for cameras, gallery, calendar, phone calls, maps, navigation, WLAN, bluetooth, music, video, short messages, etc.
The application framework layer provides an application programming interface (application programming interface, API) and programming framework for application programs of the application layer. The application framework layer includes a number of predefined functions.
As shown in fig. 7, the application framework layer may include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, and the like.
The window manager is used for managing window programs. The window manager can acquire the size of the display screen, judge whether a status bar exists, lock the screen, intercept the screen and the like.
The content provider is used to store and retrieve data and make such data accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phonebooks, etc.
The view system includes visual controls, such as controls to display text, controls to display pictures, and the like. The view system may be used to build applications. The display interface may be composed of one or more views. For example, a display interface including a text message notification icon may include a view displaying text and a view displaying a picture.
The telephony manager is used to provide the communication functions of the electronic device 100. Such as the management of call status (including on, hung-up, etc.).
The resource manager provides various resources for the application program, such as localization strings, icons, pictures, layout files, video files, and the like.
The notification manager allows the application to display notification information in a status bar, can be used to communicate notification type messages, can automatically disappear after a short dwell, and does not require user interaction. Such as notification manager is used to inform that the download is complete, message alerts, etc. The notification manager may also be a notification in the form of a chart or scroll bar text that appears on the system top status bar, such as a notification of a background running application, or a notification that appears on the screen in the form of a dialog window. For example, a text message is prompted in a status bar, a prompt tone is emitted, the electronic device vibrates, and an indicator light blinks, etc.
Android runtimes include core libraries and virtual machines. Android run time is responsible for scheduling and management of the Android system.
The core library consists of two parts: one part is a function which needs to be called by java language, and the other part is a core library of android.
The application layer and the application framework layer run in a virtual machine. The virtual machine executes java files of the application program layer and the application program framework layer as binary files. The virtual machine is used for executing the functions of object life cycle management, stack management, thread management, security and exception management, garbage collection and the like.
The system library may include a plurality of functional modules. For example: surface manager (surface manager), media library (media library), three-dimensional graphics processing library (e.g., openGL ES), 2D graphics engine (e.g., SGL), etc.
The surface manager is used to manage the display subsystem and provides a fusion of 2D and 3D layers for multiple applications.
Media libraries support a variety of commonly used audio, video format playback and recording, still image files, and the like. The media library may support a variety of audio and video encoding formats, such as MPEG4, h.264, MP3, AAC, AMR, JPG, PNG, etc.
The three-dimensional graphic processing library is used for realizing three-dimensional graphic drawing, image rendering, synthesis, layer processing and the like.
The 2D graphics engine is a drawing engine for 2D drawing.
The kernel layer is a layer between hardware and software. The inner core layer at least comprises a display driver, a camera driver, an audio driver and a sensor driver.
For easy understanding, the following embodiments of the present application will take an electronic device having a structure shown in fig. 5 and fig. 7 as an example, and specifically describe a network link switching method based on a location of the electronic device provided in the embodiments of the present application with reference to the drawings and application scenarios.
In one embodiment, to facilitate the user to turn on the linkbit function, the electronic device may provide the user with an interface for turning on the linkbit function, which may be shown in fig. 8. On the interface shown in fig. 8 (a), after the user clicks the "WLAN" option 81, the user can jump to the interface shown in fig. 8 (b), and then the user clicks the "network acceleration" option 82 again, so that the user can jump to the interface shown in fig. 8 (c). On this interface, the user can turn on the LinkTurbo function by clicking the "network acceleration" switch 83, at which time the electronic device can use Wi-Fi and cellular networks simultaneously.
For example, currently electronic devices are in a Wi-Fi1 network environment, and when a user opens a video APP to view video, the electronic device may provide network services using Wi-Fi 1. When a user opens a shopping APP to browse merchandise, the electronic device may provide network services using a cellular network. When a user downloads a large volume of resources, the electronic device may provide network services using both Wi-Fi1 and the cellular network.
In another embodiment, the electronic device is currently in a dual Wi-Fi network environment of Wi-Fi1 and Wi-Fi2, for example, wi-Fi1 is a 2.4GHz band network and Wi-Fi2 is a 5GHz band network, and if the electronic device supports dual Wi-Fi connection, after the user turns on the linkbit function, the electronic device may use Wi-Fi1, wi-Fi2 and cellular network simultaneously.
In yet another embodiment, if the electronic device further supports the main and sub card service, that is, two SIM cards are installed in the electronic device, one SIM card corresponds to cell 1 and the other SIM card corresponds to cell 2; after the linkbroo function is started, the user turns on the "intelligent switch network card" switch 91 through the interface shown in fig. 9, so that the electronic device can use Wi-Fi1, wi-Fi2, cellular 1 and cellular 2 networks at the same time.
In view of the above scenario, in one embodiment, if one APP in the electronic device is running in the foreground, or one APP is downloading resources in the background, the electronic device may be considered to be executing a network service, and the electronic device may execute a network link switching method based on the location of the electronic device in the following embodiment. In another embodiment, if the electronic device does not run the APP or the electronic device is in the screen locking state, the electronic device may be considered to not execute the network service, and the electronic device does not need to execute the network link switching method based on the location of the electronic device in the following embodiment.
Assuming that the electronic device is performing network traffic using Wi-Fi1 (denoted as first network link), the electronic device can detect whether it is in an elevator state and detect the network quality of the first network link, and perform a handover of the network link if a network link handover condition is satisfied. As shown in fig. 10, an embodiment of the present application provides an example of a network link switching method based on a location of an electronic device, where the method includes:
First, network quality of other network links is detected in case the electronic device is in an elevator state.
Among the network links used by the electronic device, the other network links except the first network link are the rest of network links. For example, after the electronic device turns on the linkbit function, four networks of Wi-Fi1, wi-Fi2, cell 1 and cell 2 may be connected at the same time, where the first network link is Wi-Fi1, and the other network links are Wi-Fi2, cell 1 and cell 2.
For determining whether the electronic device is in an elevator state, in an embodiment, the electronic device may use the Sensor Hub to determine whether the electronic device is in an overweight or weightless state according to data of the pressure Sensor or the acceleration Sensor, so as to determine whether the electronic device is in an elevator state. In another embodiment, the electronic device may record the name Wi-Fi1 of the first network link, and if the network link is a network link (such as a home network) that is frequently used, the user may be considered to take the electronic device away from home, i.e. take an elevator, if the electronic device is disconnected from the network link, and then determine that the electronic device is in an elevator state. In yet another embodiment, if a card device with radio frequency identification technology (radio frequency identification, RFID) is installed in the elevator, the electronic device can determine that the electronic device is in the elevator state when it receives the radio frequency signal of the card device. In yet another embodiment, if the camera of the electronic device captures an identification image within the elevator (e.g., an elevator door or an identification with an "elevator" letter), it may be determined that the electronic device is in an elevator state. It should be noted that, the method for determining that the electronic device is in the elevator state is not limited in the embodiment of the present application.
Then, after determining that the electronic device is in an elevator state, the electronic device may begin to probe the network quality of other network links, i.e., probe the network quality of Wi-Fi2, cell 1, and cell 2. In one embodiment, when the Sensor Hub determines that the electronic device is in an elevator state, a notification may be sent to the linkbrood, and after the linkbrood receives the notification, the linkbrood starts to detect the network quality of other network links. The network quality of the network link may be measured by using an index such as a received signal strength indicator (received signal strength indication, RSSI), a quality of service (quality of service, qoS), or a quality of experience (quality of experience, qoE), and specifically may be determined according to at least one index value of a round-trip time (RTT), a packet loss rate (packet loss rate), a packet error rate, and a transmission rate of a transmitted data packet.
In one embodiment, the electronic device may probe Wi-Fi2, cell 1, and cell 2 for network quality one by one according to network priority. In another embodiment, the electronic device may detect network quality for Wi-Fi2, cell 1, and cell 2 simultaneously. As shown in fig. 11, taking the network quality of the detecting cell 1 as an example, in the process of detecting the network quality, the electronic device may send a group of data packets to the detecting server through the base station corresponding to the network of the cell 1, calculate at least one index value of round trip delay, packet loss rate, packet error rate and sending rate for sending the data packets, and then determine the network quality of the cell 1 according to the calculation result. If the calculation result is greater than or equal to the preset threshold value, determining that the network quality of the honeycomb 1 reaches the preset network quality; if the calculation result is smaller than the preset threshold value, determining that the network quality of the cell 1 does not reach the preset network quality.
In one embodiment, the electronic device may determine the calculation result corresponding to the cell 1 according to one of the round trip delay, the packet loss rate, the packet error rate, and the transmission rate of the transmitted data packet. In another embodiment, the electronic device may determine the calculation result corresponding to the cell 1 according to the weighted results of the plurality of index values. Alternatively, the data packet may be a null packet or an internet packet explorer (packet internet groper, ping packet), and the ping packet may include data such as an internet protocol address (internet protocol address, IP address), a data packet type, and a probe server domain name.
For the example of fig. 11 described above, in one embodiment, the electronic device may send a packet to the probe server only once, and determine the network quality of cell 1 based on the result of this probe. In another embodiment, the electronic device may send a plurality of data packets to the probe server, and determine the network quality of the cell 1 according to the plurality of probing results; for example, in the case that the network quality detected each time reaches the preset network quality, it is determined that the network quality of the cell 1 reaches the preset network quality, or in the case that the network quality detected more than the preset ratio (for example, 80%) times reaches the preset network quality, it is determined that the network quality of the cell 1 reaches the preset network quality. In addition, there may be one or a plurality of the probe servers, and when the electronic device transmits the data packet to the probe server a plurality of times, the data packet may be sequentially transmitted to one probe server or may be simultaneously transmitted to a plurality of probe servers.
Next, the electronic device may determine whether the network link switching condition is satisfied, and perform switching of the network link if the condition is satisfied in three ways:
the first way is: if the network quality of the first network link is detected to not reach the preset network quality and the network quality of the second network link reaches the preset network quality, switching the service flow data on the first network link to the second network link.
The second network link is a network link with network quality reaching a preset network quality among other network links. For example, the other network links include Wi-Fi2, cell 1 and cell 2, and after the above detection process, the network quality of Wi-Fi2 does not reach the preset network quality, the network quality of cell 1 reaches the preset network quality, and the network quality of cell 2 does not reach the preset network quality, then cell 1 is the second network link.
In one embodiment, while the electronic device is executing the network traffic, the electronic device may continually detect the network quality of the first network link occupied by the network traffic. When the electronic equipment performs interaction data with the service server, at least one index value of round trip delay, packet loss rate, packet error rate and transmission rate of the data packet can be calculated, and then the network quality of the first network link is determined according to the calculation result; it will be appreciated that the method for determining the network quality of the first network link may refer to the above procedure for determining the network quality of the cell 1, and will not be described in detail herein.
When the electronic device detects that the first network link does not reach the preset network quality, the electronic device can directly switch the service flow data of the network service to the second network link because the electronic device detects the network quality of other network links, i.e. can determine which network link reaches the preset network quality (marked as the second network link). Illustratively, if the above-mentioned cell 1 is the second network link, the traffic flow data of the network traffic is switched from Wi-Fi1 to cell 1.
In one embodiment, the electronic device may detect the network quality of the first network link at preset time intervals. As an implementation manner, if the electronic device detects that the network quality of the first network link does not reach the preset network quality only once, the service flow data on the first network link is switched to the second network link. As another implementation manner, if the electronic device detects that the network quality of the first network link does not reach the preset network quality for a preset number of times (for example, 2 times), the service flow data on the first network link is switched to the second network link, so as to avoid error influence caused by jitter of the first network link.
The second way is: if the network quality of the first network link is detected to not reach the preset network quality, and the network quality of the second network link is detected to not reach the preset network quality, but the network quality of the second network link is better than the network quality of the first network link, switching the service flow data on the first network link to the second network link.
The second network link is one of other network links, and although the detected network quality of the second network link does not reach the preset network quality, the network quality is better than that of the first network link, so that the service blocking phenomenon is reduced to a certain extent when the service flow data on the first network link is switched to the second network link. The process of detecting the network quality of the first network link in this embodiment is similar to the first manner, and will not be described herein.
For example, the other network links include Wi-Fi2, cell 1 and cell 2, and the above detection process is performed to obtain that the network quality of Wi-Fi2 does not reach the preset network quality, the network quality of cell 1 does not reach the preset network quality, and the network quality of cell 2 does not reach the preset network quality, but the network quality of cell 1 is better than the network quality of the first network link, and then cell 1 is the second network link.
In one embodiment, the electronic device may determine whether the network quality of the second network link is better than the network quality of the first network link according to the calculated index value of the transmission data packet. For example, if the index value of the second network link under a certain designated index is higher than the index value of the first network link under the index, determining that the network quality of the second network link is better than the network quality of the first network link; or if the weighted result of the second network link under the multiple index values is higher than the weighted result of the first network link under the multiple index values, determining that the network quality of the second network link is better than the network quality of the first network link.
Third mode: if the network quality of the first network link is detected to reach the preset network quality, but the network quality of the second network link is better than the network quality of the first network link, switching the service flow data on the first network link to the second network link.
The second network link is one of other network links, and although the detected network quality of the first network link has reached the preset network quality, a better second network link is detected, so that the electronic device can switch the service flow data on the first network link to the second network link, thereby further improving the processing efficiency of the network service. The process of detecting the network quality of the first network link and determining whether the network quality of the second network link is better than the network quality of the first network link in this embodiment can be referred to the description of the above embodiments, and will not be repeated here.
After the electronic device switches the traffic data on the first network link to the second network link, the second network link may be used as a new first network link, and the network quality of the first network link may be continuously detected. If the new first network link meets the network link switching condition, the electronic equipment can check whether other network links detected before have available network links, and if so, the electronic equipment switches to the new network link; alternatively, the electronic device again probes the network quality of the other network links to determine a new second network link.
According to the network link switching method based on the electronic equipment position, when the electronic equipment is in an elevator state, detection of other network links is pulled up, and when the network quality of the first network link is detected to not reach the preset network quality, an available second network link is detected, and the service flow data processed on the first network link is directly switched to the first network link for processing. Therefore, in the scene that the network is blocked easily in an elevator and the like, the electronic equipment shortens the service blocking time and improves the use experience of a user by detecting other network links in advance.
In one embodiment, in the process of detecting the network quality of Wi-Fi2, cell 1 and cell 2 one by one according to the network priority, the electronic device may select one of the network links as the second network link according to the detected network quality of Wi-Fi2, cell 1 and cell 2 after all of Wi-Fi2, cell 1 and cell 2 are detected by the electronic device. Alternatively, if there are a plurality of selectable network links, the electronic device may randomly select one of the network links as the second network link, or the electronic device may select a network link with a higher network priority as the second network link.
Illustratively, taking the network link switching procedure described in the first manner as an example, as shown in fig. 12, assuming that the network priority of Wi-Fi2, cell 1 and cell 2 is Wi-Fi2> cell 1> cell 2, the electronic device first detects Wi-Fi2 to obtain the network quality of Wi-Fi2, then detects cell 1 to obtain the network quality of cell 1, and finally detects cell 2 to obtain the network quality of cell 2. If the electronic device detects Wi-Fi2, cell 1 and cell 2 completely, and the obtained result is that the network quality of Wi-Fi2 reaches the preset network quality, the network quality of cell 1 reaches the preset network quality, and the network quality of cell 2 does not reach the preset network quality, then the electronic device may select any one of Wi-Fi2 and cell 1 as the second network link, or may select Wi-Fi2 with a high network priority as the second network link. If no network link with the network quality reaching the preset network quality exists at present, the service flow data is not switched temporarily.
In another embodiment, in the process of detecting the network quality by the electronic device for detecting the network quality of Wi-Fi2, cell 1 and cell 2 at the same time, a network link with one network quality reaching the preset network quality may be selected as the second network link according to the detected network quality of Wi-Fi2, cell 1 and cell 2.
In the above embodiment, the detection of the electronic device on other network links is performed when the electronic device detects that the electronic device is in an elevator state, and the electronic device can detect the available network links in advance, and when detecting that the network quality of the first network link does not reach the preset network quality, the electronic device can directly switch the service flow data processed on the first network link to the second network link for processing, thereby shortening the service blocking duration.
In yet another embodiment, the electronic device detects network quality of Wi-Fi2, cell 1 and cell 2 one by one according to the network priority, and if it is determined that the network link switching condition is met in the detection process, the electronic device may stop the detection, and use the detected network link as the second network link.
For example, continuing the network link switching process described in the first manner, as shown in fig. 13, assuming that the network priorities of Wi-Fi2, cell 1 and cell 2 are Wi-Fi2> cell 1> cell 2, the electronic device first detects Wi-Fi2 to obtain the network quality of Wi-Fi2, and if the network quality of Wi-Fi2 reaches the preset network quality, takes Wi-Fi2 as the second network link, and does not need to detect cell 1 and cell 2 any more; if the network quality of Wi-Fi2 does not reach the preset network quality, detecting the cell 1 to obtain the network quality of the cell 1. If the network quality of the cell 1 reaches the preset network quality, taking the cell 1 as a second network link, and detecting the cell 2 is not needed; if the network quality of the cell 1 does not reach the preset network quality, finally detecting the cell 2 to obtain the network quality of the cell 2. If the network quality of the cell 2 reaches the preset network quality, taking the cell 2 as a second network link; if the network quality of the cell 2 does not reach the preset network quality, the service flow data is not switched for a while.
In the above embodiment, when the electronic device detects other network links, if the network link that can be switched is detected, the detection is stopped, so that the communication power consumption between the electronic device and the detection server can be reduced, and the working pressure of the electronic device can be reduced.
As can be seen from the above description, the electronic device may determine the network quality of the first network link according to at least one index value of round trip delay, packet loss rate, packet error rate, and transmission rate of the transmission data. In one embodiment, the electronic device may determine which index value is used according to the service type of the network service, for example, an index value of round trip delay is used by the service of the network game, and an index value of packet loss rate is used by the service of the online video. For network game services, if the round trip delay of the first network link is greater than a preset delay threshold, determining that the network quality of the first network link does not reach the preset network quality; for the online video service, if the packet loss rate of the first network link is greater than a preset ratio, determining that the network quality of the first network link reaches the preset network quality.
In this embodiment, the electronic device may also determine the second network link based on the traffic type of the network traffic and the detected results of the other network links. As an implementation manner, in the result of the detected other network links, as long as the index value corresponding to the service type reaches the preset threshold value, the network link whose index value reaches the preset threshold value may be used as the second network link. Illustratively, assuming that the detected round trip delay, packet loss rate, and transmission rate of Wi-Fi2 are (a 1, b1, c 1), the round trip delay, packet loss rate, and transmission rate of cell 1 are (a 2, b2, c 2), the round trip delay, packet loss rate, and transmission rate of cell 2 are (a 3, b3, c 3), and an index value of the round trip delay is employed for the network game-like traffic. If the round trip time delay a2 of the cell 1 is smaller than or equal to the preset time delay threshold, the cell 1 can be used as the second network link, and the service flow data of the network game can be switched to the cell 1 for processing under the condition that the network quality of the first network link does not reach the preset network quality.
As another possible way, in the result of the detected other network links, as long as there is an index value corresponding to the traffic type that is better than the index value of the first network link, the network link whose index value is better than the index value of the first network link is regarded as the second network link. Illustratively, assuming that the detected round trip delay, packet loss rate, and transmission rate of Wi-Fi2 are (a 1, b1, c 1), the round trip delay, packet loss rate, and transmission rate of cell 1 are (a 2, b2, c 2), the round trip delay, packet loss rate, and transmission rate of cell 2 are (a 3, b3, c 3), and an index value of the round trip delay is employed for the network game-like traffic. If the round trip delay a3 of the cell 2 is smaller than the round trip delay of the first network link, the cell 2 can be used as a second network link, and the service flow data of the network game can be switched to the cell 2 for processing under the condition that the network quality of the first network link does not reach the preset network quality.
In another embodiment, when the electronic device determines which index value is adopted according to the service type of the network service, the index value can be detected and calculated only when detecting the network quality of other network links, and other index values are not required to be calculated, so that the calculation amount of the electronic device can be reduced, and the detection efficiency can be improved. For example, if the network game service adopts the index value of the round trip delay, the electronic device does not need to calculate the packet loss rate and the sending rate. In addition, when detecting the network quality of the first network link, only the index value may be calculated, and no other index value may be calculated.
In the above embodiment, the electronic device determines the index value according to the service type of the foreground service, so as to adapt to different requirements of different service types, and further improve the use experience of the user.
As for the above-described network link switching method based on the location of the electronic device, the network link switching process described in the first manner is taken as an example, and an embodiment is described below. As shown in fig. 14, when the electronic device has a running network service, it is assumed that a first network link occupied by the network service is Wi-Fi1; at this time, on one hand, the electronic device adopts Sensor Hub to judge whether to be in an elevator state, and detects the network quality of other network links by LinkTurbo when being in the elevator state; on the other hand, the linkbrood also continuously detects the network quality of the first network link.
If the network quality of the first network link does not reach the preset network quality and a second network link with the network quality reaching the preset network quality exists, switching the service flow data of the network service on the first network link to the second network link; for example, traffic flow data is handed over from Wi-Fi1 to cell 1. Then, the second network link is used as a new first network link, and the LinkTurb continues to detect the network quality of the first network link.
If the network quality of the first network link reaches the preset network quality, continuing to detect the network quality of the first network link.
If the network quality of the first network link does not reach the preset network quality, but no available network link with the network quality reaching the preset network quality exists, the service flow data of the network service is not switched temporarily.
In the above embodiment, when the electronic device is in an elevator state, the electronic device pulls up detection of other network links, and when detecting that the network quality of the first network link does not reach the preset network quality, the electronic device detects that the second network link is available, and directly switches the service flow data processed on the first network link to the second network link for processing. Therefore, in the scene that the network is blocked easily in an elevator and the like, the electronic equipment shortens the service blocking time and improves the use experience of a user by detecting other network links in advance.
In another scenario: when a user downloads a large amount of resources, the electronic device simultaneously uses Wi-Fi1 and the cell 1 to provide a network service, namely, one part of traffic flow data of the download task is processed by Wi-Fi1, and the other part of traffic flow data is processed by cell 1. At this time, if the electronic device is in an elevator state, the network quality of Wi-Fi2 and cell 2 may be detected, and if it is detected that the network quality of Wi-Fi1 does not reach the preset network quality, but the network quality of cell 1 reaches the preset network quality, only a part of the traffic data processed on Wi-Fi1 may be switched to other available network links for processing, for example, to cell 1, or to network links meeting the conditions in Wi-Fi2 and cell 2.
In addition, in an embodiment, the switching process of the network link provided in the embodiment of the present application may also be applicable to other weak signal scenarios, such as an underground garage scenario, after a user uses an electronic device to execute a network service and enters the underground garage, if the electronic device is located at the position of the underground garage through a GPS location technology or the photographing device photographs an identification image of the underground garage, the network quality of other network links may be detected, and in the case that the network link switching condition in the above embodiment is satisfied, the service flow data on the first network link executing the network service is switched to be processed on the second network link.
In yet another embodiment, the electronic device may further collect network signals of each network at the weak signal location, establish a signal fingerprint library of the location, and directly obtain, from the signal fingerprint library, a network reaching a preset network quality when the electronic device reaches the location again, and switch the traffic data to the network link reaching the preset network quality when the network quality of the first network link for processing the network service does not reach the preset network quality.
Examples of the network link switching method based on the location of the electronic device provided in the embodiments of the present application are described above in detail. It will be appreciated that the electronic device, in order to achieve the above-described functions, includes corresponding hardware and/or software modules that perform the respective functions. Those of skill in the art will readily appreciate that the elements and algorithm steps of the examples described in connection with the embodiments disclosed herein may be implemented as hardware or combinations of hardware and computer software. Whether a function is implemented as hardware or computer software driven hardware depends upon the particular application and design constraints imposed on the solution. Those skilled in the art may implement the described functionality using different approaches for each particular application in conjunction with the embodiments, but such implementation is not to be considered as outside the scope of this application.
The embodiment of the present application may divide the functional modules of the electronic device according to the above method examples, for example, may divide each function into each functional module corresponding to each function, for example, a detection unit, a processing unit, a display unit, or the like, or may integrate two or more functions into one module. The integrated modules may be implemented in hardware or in software functional modules. It should be noted that, in the embodiment of the present application, the division of the modules is schematic, which is merely a logic function division, and other division manners may be implemented in actual implementation.
It should be noted that, all relevant contents of each step related to the above method embodiment may be cited to the functional description of the corresponding functional module, which is not described herein.
The electronic device provided in this embodiment is configured to perform the network link switching method based on the location of the electronic device, so that the same effect as that of the implementation method can be achieved.
In case an integrated unit is employed, the electronic device may further comprise a processing module, a storage module and a communication module. The processing module can be used for controlling and managing the actions of the electronic equipment. The memory module may be used to support the electronic device to execute stored program code, data, etc. And the communication module can be used for supporting the communication between the electronic device and other devices.
Wherein the processing module may be a processor or a controller. Which may implement or perform the various exemplary logic blocks, modules, and circuits described in connection with this disclosure. A processor may also be a combination that performs computing functions, e.g., including one or more microprocessors, digital signal processing (digital signal processing, DSP) and microprocessor combinations, and the like. The memory module may be a memory. The communication module can be a radio frequency circuit, a Bluetooth chip, a Wi-Fi chip and other equipment which interact with other electronic equipment.
In one embodiment, when the processing module is a processor and the storage module is a memory, the electronic device according to this embodiment may be a device having the structure shown in fig. 5.
The embodiment of the application further provides a computer readable storage medium, in which a computer program is stored, which when executed by a processor, causes the processor to execute the network link switching method based on the location of the electronic device of any of the above embodiments.
The embodiment of the application also provides a computer program product, which when run on a computer, causes the computer to execute the related steps to implement the network link switching method based on the electronic device position in the embodiment.
In addition, embodiments of the present application also provide an apparatus, which may be specifically a chip, a component, or a module, and may include a processor and a memory connected to each other; the memory is configured to store computer-executable instructions, and when the apparatus is running, the processor may execute the computer-executable instructions stored in the memory, so that the chip performs the network link switching method based on the location of the electronic device in the above method embodiments.
The electronic device, the computer readable storage medium, the computer program product or the chip provided in this embodiment are used to execute the corresponding method provided above, so that the beneficial effects thereof can be referred to the beneficial effects in the corresponding method provided above, and will not be described herein.
It will be appreciated by those skilled in the art that, for convenience and brevity of description, only the above-described division of the functional modules is illustrated, and in practical application, the above-described functional allocation may be performed by different functional modules according to needs, i.e. the internal structure of the apparatus is divided into different functional modules to perform all or part of the functions described above.
In the several embodiments provided in this application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of modules or units is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another apparatus, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and the parts shown as units may be one physical unit or a plurality of physical units, may be located in one place, or may be distributed in a plurality of different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a readable storage medium. Based on such understanding, the technical solution of the embodiments of the present application may be essentially or a part contributing to the prior art or all or part of the technical solution may be embodied in the form of a software product stored in a storage medium, including several instructions to cause a device (may be a single-chip microcomputer, a chip or the like) or a processor (processor) to perform all or part of the steps of the methods of the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read Only Memory (ROM), a random access memory (random access memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The foregoing is merely specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily think about changes or substitutions within the technical scope of the present application, and the changes and substitutions are intended to be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (21)

1. A network link switching method based on a location of an electronic device, the method being performed by the electronic device, wherein the electronic device is currently connected with a Wi-Fi1 network in a 2.4GHz band and a Wi-Fi2 network in a 5GHz band, the electronic device carrying a first SIM card and a second SIM card, the first SIM card corresponding to a first cellular network, and the second SIM card corresponding to a second cellular network, the method comprising:
the electronic equipment currently uses the Wi-Fi1 network to execute network service;
under the condition that the electronic equipment meets a preset condition, detecting the network quality of a first network according to an index corresponding to the service type of the network service, wherein the first network is one or more of the Wi-Fi2 network, the first cellular network and the second cellular network, and the preset condition comprises that the electronic equipment is in an elevator state or in a weak signal scene;
when the network quality of the Wi-Fi1 network is detected to not reach the preset network quality, switching the service flow data of the network service on the Wi-Fi1 network to a second network, wherein the second network is a network with the network quality reaching the preset network quality in the first network, or the second network is a network with the network quality not reaching the preset network quality in the first network, but the network quality of the second network is superior to that of the Wi-Fi1 network;
When the network quality of the Wi-Fi1 network is detected to reach the preset network quality, but the network quality of a second network is superior to the network quality of the Wi-Fi1 network, switching the service flow data of the network service on the Wi-Fi1 network to the second network, wherein the second network is one network in the first network.
2. The method of claim 1, wherein detecting the network quality of the first network comprises:
detecting the network quality of each network in the first network one by one according to the network priority;
or alternatively, the process may be performed,
and simultaneously detecting the network quality of each network in the first network.
3. The method of claim 2, wherein detecting network quality of each of the first networks one by one based on network priority comprises:
if the network quality of each network in the first network is detected to be finished, one network with the network quality superior to that of the Wi-Fi1 network is provided, the network with the network quality superior to that of the Wi-Fi1 network is taken as the second network;
if the network quality of each network in the first network is detected to be finished, and a plurality of networks with the network quality superior to that of the Wi-Fi1 network exist, randomly selecting one network from the networks with the network quality superior to that of the Wi-Fi1 network as the second network, or taking the network with the highest network priority among the networks with the network quality superior to that of the Wi-Fi1 network as the second network.
4. The method of claim 2, wherein detecting network quality of each of the first networks one by one based on network priority comprises:
and in the process of detecting the network quality of each network in the first network one by one, if the network quality of the detected network is better than that of the Wi-Fi1 network, stopping detecting other networks in the first network, and taking the network with the detected network quality of the detected network better than that of the Wi-Fi1 network as the second network.
5. The method of claim 2, wherein the simultaneously probing the network quality of each of the first networks comprises:
if the network quality of each network in the first network is detected to be finished, one network with the network quality superior to that of the Wi-Fi1 network is provided, the network with the network quality superior to that of the Wi-Fi1 network is taken as the second network;
if the network quality of each network in the first network is detected to be finished, and a plurality of networks with the network quality superior to that of the Wi-Fi1 network exist, randomly selecting one network from the networks with the network quality superior to that of the Wi-Fi1 network as the second network, or taking the network with the highest network priority among the networks with the network quality superior to that of the Wi-Fi1 network as the second network.
6. The method according to claim 1, wherein detecting the network quality of the first network according to the index corresponding to the service type of the network service comprises:
transmitting data packets to a detection server through network links corresponding to each network in the first network respectively;
and determining the network quality of each network in the first network according to the index value under the index when the data packet is sent.
7. The method of claim 6, wherein determining the network quality of each of the first networks based on the index value under the index when the data packet is transmitted comprises:
for a third network in the first network, if the index value of the third network under the index reaches a preset threshold value, determining that the network quality of the third network reaches the preset network quality, wherein the third network is any network in the first network;
or alternatively, the process may be performed,
and if the index value of the third network under the index is larger than the index value of the Wi-Fi1 network under the index, determining that the network quality of the third network is better than the network quality of the Wi-Fi1 network.
8. The method of claim 6 or 7, wherein the data packet is an internet packet explorer ping packet, the ping packet comprising an internet protocol, IP, address, packet type, and probe server domain name fields.
9. The method according to claim 1, wherein the method further comprises:
acquiring sensor data acquired by a sensor of the electronic equipment;
and determining that the electronic equipment is in an elevator state according to the sensor data.
10. The method of claim 9, wherein the sensor data comprises acceleration sensor data.
11. An electronic device, comprising:
one or more processors;
one or more memories;
the electronic equipment is currently connected with a Wi-Fi1 network in a 2.4GHz frequency band and a Wi-Fi2 network in a 5GHz frequency band, and carries a first SIM card and a second SIM card, wherein the first SIM card corresponds to a first cellular network, and the second SIM card corresponds to a second cellular network;
the memory stores one or more programs that, when executed by the processor, cause the electronic device to perform the steps of:
The electronic equipment currently uses the Wi-Fi1 network to execute network service;
under the condition that the electronic equipment meets a preset condition, detecting the network quality of a first network according to an index corresponding to the service type of the network service, wherein the first network is one or more of the Wi-Fi2 network, the first cellular network and the second cellular network, and the preset condition comprises that the electronic equipment is in an elevator state or in a weak signal scene;
when the network quality of the Wi-Fi1 network is detected to not reach the preset network quality, switching the service flow data of the network service on the Wi-Fi1 network to a second network, wherein the second network is a network with the network quality reaching the preset network quality in the first network, or the second network is a network with the network quality not reaching the preset network quality in the first network, but the network quality of the second network is superior to that of the Wi-Fi1 network;
when the network quality of the Wi-Fi1 network is detected to reach the preset network quality, but the network quality of a second network is superior to the network quality of the Wi-Fi1 network, switching the service flow data of the network service on the Wi-Fi1 network to the second network, wherein the second network is one network in the first network.
12. The electronic device of claim 11, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
detecting the network quality of each network in the first network one by one according to the network priority;
or alternatively, the process may be performed,
and simultaneously detecting the network quality of each network in the first network.
13. The electronic device of claim 12, wherein in the case where the electronic device detects network quality of each of the first networks one by one according to network priority, the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
if the network quality of each network in the first network is detected to be finished, one network with the network quality superior to that of the Wi-Fi1 network is provided, the network with the network quality superior to that of the Wi-Fi1 network is taken as the second network;
if the network quality of each network in the first network is detected to be finished, and a plurality of networks with the network quality superior to that of the Wi-Fi1 network exist, randomly selecting one network from the networks with the network quality superior to that of the Wi-Fi1 network as the second network, or taking the network with the highest network priority among the networks with the network quality superior to that of the Wi-Fi1 network as the second network.
14. The electronic device of claim 12, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
and in the process of detecting the network quality of each network in the first network one by one, if the network quality of the detected network is better than that of the Wi-Fi1 network, stopping detecting other networks in the first network, and taking the network with the detected network quality of the detected network better than that of the Wi-Fi1 network as the second network.
15. The electronic device of claim 12, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of, in the case where the electronic device concurrently detects network quality for each of the first networks:
if the network quality of each network in the first network is detected to be finished, one network with the network quality superior to that of the Wi-Fi1 network is provided, the network with the network quality superior to that of the Wi-Fi1 network is taken as the second network;
if the network quality of each network in the first network is detected to be finished, and a plurality of networks with the network quality superior to that of the Wi-Fi1 network exist, randomly selecting one network from the networks with the network quality superior to that of the Wi-Fi1 network as the second network, or taking the network with the highest network priority among the networks with the network quality superior to that of the Wi-Fi1 network as the second network.
16. The electronic device of claim 11, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
transmitting data packets to a detection server through network links corresponding to each network in the first network respectively;
and determining the network quality of each network in the first network according to the index value under the index when the data packet is sent.
17. The electronic device of claim 16, wherein the determining the network quality of each of the first networks based on the index value under the index when the data packet is sent comprises:
for a third network in the first network, if the index value of the third network under the index reaches a preset threshold value, determining that the network quality of the third network reaches the preset network quality, wherein the third network is any network in the first network;
or alternatively, the process may be performed,
and if the index value of the third network under the index is larger than the index value of the Wi-Fi1 network under the index, determining that the network quality of the third network is better than the network quality of the Wi-Fi1 network.
18. The electronic device of claim 16 or 17, wherein the data packet is a ping packet comprising an internet protocol, IP, address field, a data packet type field, and a probe server domain name field.
19. The electronic device of claim 11, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
acquiring sensor data acquired by a sensor of the electronic equipment;
and determining that the electronic equipment is in an elevator state according to the sensor data.
20. The electronic device of claim 19, wherein the sensor data comprises acceleration sensor data.
21. A computer readable storage medium, characterized in that the computer readable storage medium has stored therein a computer program which, when executed by a processor, causes the processor to perform the method of any of claims 1 to 10.
CN202110876161.7A 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment Active CN114449599B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202110876161.7A CN114449599B (en) 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment
CN202310481503.4A CN116614848A (en) 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110876161.7A CN114449599B (en) 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment

Related Child Applications (1)

Application Number Title Priority Date Filing Date
CN202310481503.4A Division CN116614848A (en) 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment

Publications (2)

Publication Number Publication Date
CN114449599A CN114449599A (en) 2022-05-06
CN114449599B true CN114449599B (en) 2023-05-12

Family

ID=81362612

Family Applications (2)

Application Number Title Priority Date Filing Date
CN202110876161.7A Active CN114449599B (en) 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment
CN202310481503.4A Pending CN116614848A (en) 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment

Family Applications After (1)

Application Number Title Priority Date Filing Date
CN202310481503.4A Pending CN116614848A (en) 2021-07-30 2021-07-30 Network link switching method based on electronic equipment position and electronic equipment

Country Status (1)

Country Link
CN (2) CN114449599B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023216236A1 (en) * 2022-05-13 2023-11-16 北京小米移动软件有限公司 Network access method and apparatus, and communication device and storage medium
CN117354876A (en) * 2022-06-29 2024-01-05 华为技术有限公司 Data migration method, electronic equipment and networking system
CN116744328B (en) * 2022-10-17 2024-04-23 荣耀终端有限公司 Network acceleration method and device
CN116709442A (en) * 2022-10-17 2023-09-05 荣耀终端有限公司 Wireless network switching method and electronic equipment
CN116709369A (en) * 2022-10-21 2023-09-05 荣耀终端有限公司 Network acceleration method and electronic equipment
CN115767602B (en) * 2022-11-01 2023-07-07 荣耀终端有限公司 Automatic error correction method for equipment protocol subsystem abnormality and electronic equipment
CN116232959B (en) * 2023-02-21 2023-11-21 荣耀终端有限公司 Network quality detection method and device
CN116390142B (en) * 2023-02-23 2023-11-28 荣耀终端有限公司 Network detection method and electronic equipment

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112954749A (en) * 2019-12-11 2021-06-11 华为技术有限公司 Network switching method and electronic equipment

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106332209B (en) * 2015-09-22 2019-11-29 北京智谷睿拓技术服务有限公司 Switching method and switching device
CN109041148B (en) * 2018-08-27 2021-01-08 维沃移动通信有限公司 Mobile terminal operation method and mobile terminal
US10993082B2 (en) * 2018-09-27 2021-04-27 Amber Solutions, Inc. Methods and apparatus for device location services
CN111132270A (en) * 2018-11-01 2020-05-08 华为终端有限公司 Method and terminal equipment for rapidly searching high-standard network
CN112243278A (en) * 2020-10-16 2021-01-19 Oppo广东移动通信有限公司 Cell search method, device, chip, mobile terminal and storage medium
CN113055962B (en) * 2021-03-05 2022-07-26 南昌黑鲨科技有限公司 Multi-network switching method and system of intelligent terminal and computer readable storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112954749A (en) * 2019-12-11 2021-06-11 华为技术有限公司 Network switching method and electronic equipment

Also Published As

Publication number Publication date
CN114449599A (en) 2022-05-06
CN116614848A (en) 2023-08-18

Similar Documents

Publication Publication Date Title
CN114449599B (en) Network link switching method based on electronic equipment position and electronic equipment
CN115696483B (en) Network link switching method based on electronic equipment state and electronic equipment
CN112954749B (en) Network switching method and electronic equipment
CN114079893B (en) Bluetooth communication method, terminal device and computer readable storage medium
CN113973398B (en) Wireless network connection method, electronic equipment and chip system
CN113641271B (en) Application window management method, terminal device and computer readable storage medium
JP7193647B2 (en) Connection establishment method and terminal device
CN115333941B (en) Method for acquiring application running condition and related equipment
CN113243126B (en) Network management method for terminal and terminal
CN114828098B (en) Data transmission method and electronic equipment
CN113645595B (en) Equipment interaction method and device
CN116389884B (en) Thumbnail display method and terminal equipment
CN116321265B (en) Network quality evaluation method, electronic device and storage medium
CN115460445B (en) Screen projection method of electronic equipment and electronic equipment
CN115513571B (en) Control method of battery temperature and terminal equipment
CN113254409B (en) File sharing method, system and related equipment
CN116703741B (en) Image contrast generation method and device and electronic equipment
CN116232959B (en) Network quality detection method and device
CN114077323B (en) Touch screen false touch prevention method of electronic equipment, electronic equipment and chip system
CN117154900B (en) Charging control method and electronic equipment
CN116048831B (en) Target signal processing method and electronic equipment
CN114205318B (en) Head portrait display method and electronic equipment
CN111801931B (en) Method for switching on and hanging up telephone when call occurs SRVCC switch
CN117348894A (en) Software upgrading method, terminal equipment and system
CN117354876A (en) Data migration method, electronic equipment and networking system

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