Network connection method and device, terminal equipment, server and storage medium

文档序号:196495 发布日期:2021-11-02 浏览:38次 中文

阅读说明:本技术 网络连接方法及装置、终端设备、服务器、存储介质 (Network connection method and device, terminal equipment, server and storage medium ) 是由 索传奇 于 2021-07-16 设计创作,主要内容包括:一种网络连接方法及装置、终端设备、服务器、存储介质,应用于第一终端设备,该第一终端设备与服务器通信连接,该方法包括:向服务器发送网络共享请求,该网络共享请求包括第一终端设备对应的位置信息,用于请求服务器根据该位置信息确定为第一终端设备提供网络接入的目标终端设备;获取服务器反馈的上述目标终端设备的设备信息;根据该设备信息接入上述目标终端设备提供的目标网络。实施本申请实施例,能够实现终端设备之间的网络带宽共享,从而减少整体上的带宽浪费,并提升终端设备进行网络连接的可靠性。(A network connection method and device, terminal equipment, a server and a storage medium are applied to first terminal equipment, the first terminal equipment is in communication connection with the server, and the method comprises the following steps: sending a network sharing request to a server, wherein the network sharing request comprises position information corresponding to the first terminal device and is used for requesting the server to determine a target terminal device for providing network access for the first terminal device according to the position information; acquiring the device information of the target terminal device fed back by the server; and accessing the target network provided by the target terminal equipment according to the equipment information. By implementing the embodiment of the application, the network bandwidth sharing among the terminal devices can be realized, so that the bandwidth waste on the whole is reduced, and the reliability of network connection of the terminal devices is improved.)

1. A network connection method is applied to a first terminal device, wherein the first terminal device is in communication connection with a server, and the method comprises the following steps:

sending a network sharing request to the server, wherein the network sharing request comprises position information corresponding to the first terminal device and is used for requesting the server to determine a target terminal device for providing network access for the first terminal device according to the position information;

acquiring the device information of the target terminal device fed back by the server;

and accessing a target network provided by the target terminal equipment according to the equipment information.

2. The method of claim 1, wherein prior to said sending a network sharing request to the server, the method further comprises:

and acquiring the position information corresponding to the first terminal equipment in a positioning mode corresponding to the scene where the first terminal equipment is located.

3. The method according to claim 1 or 2, wherein the target terminal device is a terminal device determined by the server from one or more second terminal devices within a location range corresponding to the location information in a scene where the first terminal device is located.

4. The method according to claim 3, wherein the target terminal device is a second terminal device of the one or more second terminal devices whose network configuration information meets the network configuration condition of the first terminal device, and the device information of the target terminal device includes network configuration information corresponding to the target terminal device.

5. The method of claim 4, wherein the accessing the target network provided by the target terminal device according to the device information comprises:

establishing communication connection with the target terminal equipment according to the network configuration information corresponding to the target terminal equipment;

sending first communication data to the target terminal device based on the communication connection, and forwarding the first communication data to network equipment in a target network provided by the target terminal device through the target terminal device; and/or receiving second communication data which is obtained by the target terminal device from network equipment in a target network provided by the target terminal device and forwarded to the first terminal device based on the communication connection.

6. The method according to claim 4, wherein the target terminal device includes a plurality of target terminal devices, the device information of the target terminal device further includes a network connection status corresponding to the target terminal device, and the accessing the target network provided by the target terminal device according to the device information includes:

establishing communication connection with a plurality of target terminal devices according to network configuration information corresponding to the target terminal devices respectively;

selecting one target terminal device from the plurality of target terminal devices according to the network connection state corresponding to each target terminal device, and sending first communication data to the selected target terminal device based on the communication connection with the selected target terminal device, so that the first communication data is forwarded to the network device in the target network provided by the selected target terminal device through the selected target terminal device; and/or receiving second communication data which is acquired by the selected target terminal device from the network device in the target network provided by the selected target terminal device and forwarded to the first terminal device.

7. A network connection method is applied to a server which is in communication connection with a first terminal device, and comprises the following steps:

acquiring a network sharing request sent by the first terminal device, wherein the network sharing request comprises position information corresponding to the first terminal device;

responding to the network sharing request, and determining target terminal equipment for providing network access for the first terminal equipment according to the position information;

and sending the equipment information of the target terminal equipment to the first terminal equipment so that the first terminal equipment is accessed to a target network provided by the target terminal equipment according to the equipment information.

8. The method of claim 7, wherein the determining, in response to the network sharing request, a target terminal device providing network access for the first terminal device according to the location information comprises:

determining one or more second terminal devices in a position range corresponding to the position information under the scene where the first terminal device is located;

and determining the target terminal equipment corresponding to the position information from the one or more second terminal equipments.

9. The method according to claim 8, wherein the determining the target terminal device corresponding to the location information from the one or more second terminal devices includes:

respectively sending a network access request to each second terminal device, where the network access request is used to request the second terminal device to provide network access for the first terminal device;

acquiring network configuration information fed back by each second terminal device in response to the network access request;

determining a target terminal device with network configuration information matched with the network configuration conditions of the first terminal device from the one or more second terminal devices according to the network configuration information corresponding to each second terminal device;

the sending the device information of the target terminal device to the first terminal device includes:

and generating corresponding equipment information according to the network configuration information corresponding to the target terminal equipment, and sending the equipment information to the first terminal equipment.

10. The method according to claim 9, wherein the determining, from the one or more second terminal devices, a target terminal device whose network configuration information matches the network configuration condition of the first terminal device according to the network configuration information of each second terminal device includes:

adding the second terminal equipment which receives the network access request into a to-be-selected equipment list according to the network configuration information of each second terminal equipment;

determining the service supporting type of each second terminal device according to the network configuration information of each second terminal device in the device list to be selected;

and determining the target terminal equipment matched with the network configuration condition of the first terminal equipment from the equipment list to be selected according to the service supporting type of each second terminal equipment.

11. The method according to claim 9, wherein the target terminal device includes a plurality of target terminal devices, the device information of the target terminal device further includes a network connection state corresponding to the target terminal device, and the generating corresponding device information according to the network configuration information corresponding to the target terminal device and sending the device information to the first terminal device includes:

generating corresponding equipment information according to the network configuration information and the network connection state corresponding to the target terminal equipment;

and sending the device information of the target terminal devices to the first terminal device to trigger the first terminal device to respectively establish communication connection with the target terminal devices according to the network configuration information corresponding to the target terminal devices, and selecting one of the target terminal devices from the target terminal devices according to the network connection state corresponding to each target terminal device, wherein the selected target terminal device is used for forwarding the first communication data sent by the first terminal device to the network device in the target network provided by the selected target terminal device, and/or forwarding the second communication data sent by the network device to the first terminal device.

12. A network connection device is applied to a first terminal device, the first terminal device is in communication connection with a server, and the network connection device comprises:

a request sending unit, configured to send a network sharing request to the server, where the network sharing request includes location information corresponding to the first terminal device, and is used to request the server to determine, according to the location information, a target terminal device that provides network access for the first terminal device;

an information obtaining unit, configured to obtain device information of the target terminal device, which is fed back by the server;

and the network connection unit is used for accessing a target network provided by the target terminal equipment according to the equipment information.

13. A network connection device is applied to a server which is in communication connection with a first terminal device, and comprises:

a request obtaining unit, configured to obtain a network sharing request sent by the first terminal device, where the network sharing request includes location information corresponding to the first terminal device;

a determining unit, configured to determine, in response to the network sharing request, a target terminal device that provides network access for the first terminal device according to the location information;

and the information sending unit is used for sending the equipment information of the target terminal equipment to the first terminal equipment so as to enable the first terminal equipment to access a target network provided by the target terminal equipment according to the equipment information.

14. A terminal device comprising a memory and a processor, the memory having stored thereon a computer program which, when executed by the processor, causes the processor to carry out the method of any one of claims 1 to 6.

15. A server, comprising a memory and a processor, the memory having stored therein a computer program that, when executed by the processor, causes the processor to carry out the method of any one of claims 7 to 11.

16. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the method of any one of claims 1 to 6, or the method of any one of claims 7 to 11.

Technical Field

The present application relates to the field of network communication technologies, and in particular, to a network connection method and apparatus, a terminal device, a server, and a storage medium.

Background

Currently, when a user connects to a network using a terminal device such as a mobile phone, a computer, or a smart wearable device, the user needs to connect to Wi-Fi (Wireless Fidelity) in advance or consume data traffic to access a mobile communication network. However, in practice, it is found that different users have different network connection conditions, some users may have a relatively sufficient bandwidth, and the network connection is relatively stable, while another user may face the problems of insufficient data traffic, poor networking signal, and the like, which results in the waste of the bandwidth as a whole and also reduces the reliability of the network connection performed by the terminal device.

Disclosure of Invention

The embodiment of the application discloses a network connection method and device, terminal equipment, a server and a storage medium, which can realize network bandwidth sharing among the terminal equipment, thereby reducing the bandwidth waste on the whole and improving the reliability of network connection of the terminal equipment.

A first aspect of an embodiment of the present application discloses a network connection method, which is applied to a first terminal device, where the first terminal device is in communication connection with a server, and the method includes:

sending a network sharing request to the server, wherein the network sharing request comprises position information corresponding to the first terminal device and is used for requesting the server to determine a target terminal device for providing network access for the first terminal device according to the position information;

acquiring the device information of the target terminal device fed back by the server;

and accessing a target network provided by the target terminal equipment according to the equipment information.

A second aspect of the embodiments of the present application discloses a network connection device, which is applied to a first terminal device, where the first terminal device is in communication connection with a server, and the network connection device includes:

a request sending unit, configured to send a network sharing request to the server, where the network sharing request includes location information corresponding to the first terminal device, and is used to request the server to determine, according to the location information, a target terminal device that provides network access for the first terminal device;

an information obtaining unit, configured to obtain device information of the target terminal device, which is fed back by the server;

and the network connection unit is used for accessing a target network provided by the target terminal equipment according to the equipment information.

A third aspect of the embodiments of the present application discloses a terminal device, which includes a memory and a processor, where the memory stores a computer program, and when the computer program is executed by the processor, the processor is enabled to execute all or part of the steps in any one of the network connection methods disclosed in the first aspect of the embodiments of the present application.

A fourth aspect of the embodiments of the present application discloses a computer-readable storage medium, which stores a computer program, where the computer program enables a computer to execute all or part of the steps in any one of the network connection methods disclosed in the first aspect of the embodiments of the present application.

Compared with the related art, the embodiment of the application has the following beneficial effects:

in this embodiment, a first terminal device applying a network connection method may be in communication connection with a server, and send a network sharing request to the server, where the network sharing request may include location information corresponding to the first terminal device, and is used to request the server to determine, according to the location information, a target terminal device that provides network access for the first terminal device. Further, the first terminal device may further obtain the target terminal device fed back by the server. Therefore, by implementing the embodiment of the application, the first terminal device can report the position information of the first terminal device to the server, so that the server can determine the nearby target terminal device capable of performing network sharing according to the position information, and then the first terminal device can be accessed to the target network provided by the target terminal device, thereby realizing the network connection of the first terminal device. Based on the network connection mode, the target terminal device can be used as a relay node for connecting the first terminal device with an external network, and when the first terminal device faces the conditions of poor network signals, insufficient data flow and the like, stable and high-quality network connection can be realized through the relay node, so that network bandwidth sharing among the terminal devices is realized, and the idle or surplus bandwidth resources of the target terminal device are favorably used, so that the bandwidth waste on the whole is reduced; and the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection is avoided, so that the reliability of network connection of the terminal equipment is improved.

Drawings

In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without creative efforts.

Fig. 1 is a schematic view of an application scenario of a network connection method disclosed in an embodiment of the present application;

fig. 2 is a timing diagram of a network connection method disclosed in an embodiment of the present application;

fig. 3 is a flowchart illustrating a network connection method according to an embodiment of the present application;

fig. 4 is a schematic flow chart illustrating another network connection method disclosed in the embodiments of the present application;

fig. 5 is a flowchart illustrating a further network connection method disclosed in an embodiment of the present application;

fig. 6 is a schematic diagram of a first terminal device and a plurality of target terminal devices connected according to an embodiment of the present application;

fig. 7 is a flowchart illustrating a further network connection method disclosed in an embodiment of the present application;

fig. 8 is a flowchart illustrating a further network connection method disclosed in an embodiment of the present application;

FIG. 9 is a block diagram of a network connection device according to an embodiment of the present disclosure;

FIG. 10 is a modular schematic diagram of another network connection device disclosed in an embodiment of the present application;

fig. 11 is a schematic block diagram of a terminal device disclosed in an embodiment of the present application;

fig. 12 is a schematic block diagram of a server according to an embodiment of the present disclosure.

Detailed Description

The technical solutions in the embodiments of the present application will be described clearly and completely with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.

It should be noted that the terms "comprises" and "comprising," and any variations thereof, in the embodiments of the present application, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.

The embodiment of the application discloses a network connection method and device, terminal equipment, a server and a storage medium, which can realize network bandwidth sharing among the terminal equipment, thereby reducing the bandwidth waste on the whole and improving the reliability of network connection of the terminal equipment.

The following detailed description is made with reference to the accompanying drawings.

Referring to fig. 1, fig. 1 is a schematic view of an application scenario of a network connection method disclosed in an embodiment of the present application, and includes a first terminal device 10, a server 20, and a target terminal device 30. The first terminal device 10 may be in communication connection with the server 20, so that data interactive transmission may be performed between the two. Illustratively, when the first terminal device 10 needs to access the network, a network sharing request may be sent to the server 20 to request the server 20 to determine a target terminal device 30 capable of providing the network access service for the first terminal device 10. The target terminal device 30 may establish a communication connection with the server 20 in advance, or may establish a communication connection with the server 20 when the server 20 searches or queries the corresponding target terminal device 30 in response to the network sharing request. On this basis, the determined target terminal device 30 may further establish a communication connection with the first terminal device 10, and further may access the first terminal device 10 to a target network provided by the target terminal device 30. It will be appreciated that the target network may comprise an external network, i.e. a network to which the target terminal device 30 is connected via Wi-Fi (Wireless Fidelity) or data traffic. Specifically, the first terminal device 10 accesses the target network, which may mean that the first terminal device 10 performs communication data transmission with a network device such as a terminal and a server in an external network through the target terminal device 30, that is, the target terminal device 30 may forward the first communication data sent by the first terminal device 10 to the network device, or forward the second communication data sent by the network device to the first terminal device 10.

For example, the first terminal device 10 may include various devices or systems with networking functions, such as a mobile phone, a smart wearable device, an in-vehicle terminal, a tablet Computer, a PC (Personal Computer), a PDA (Personal Digital Assistant), and the like, which are not specifically limited in the embodiment of the present application. It should be noted that the target terminal device 30 may be a device or a system of the same type as the first terminal device 10, such as a mobile phone and a computer; or may be a different type of device or system than the first terminal device 10.

For example, the server 20 may include a server module disposed in the cloud, so as to determine, by the server module, a target terminal device 30 capable of providing a network access service for the first terminal device 10 in response to the network sharing request sent by the first terminal device 10. In some embodiments, the functions implemented by the server 20 may also be implemented by a device located at a base station (including a cellular network base station, a Wi-Fi base station, etc.), a router, etc. that is directly connected to the first terminal device 10.

In the embodiment of the present application, when the first terminal device 10 faces a situation of poor network signal, insufficient data traffic, and the like, a network sharing request may be sent to the server 20, where the network sharing request may include the location information corresponding to the first terminal device 10. After receiving the network sharing request, the server 20 may respond to the network sharing request and determine the target terminal device 30 capable of providing network access for the first terminal device 10 according to the location information. On this basis, the server 20 may transmit the device information of the target terminal device 30 to the first terminal device 10, so that the first terminal device 10 may access the target network provided by the target terminal device 30 according to the device information. Illustratively, the target terminal device 30 may be connected to the base station 40, and may further serve as a relay node for the first terminal device 10 to communicate with the base station 40, so that the first terminal device 10 may implement network connection through a connection path formed by the target terminal device 30 and the base station 40, and may then perform communication data transmission with a network device in an external network.

To better describe the application scenario of the embodiment of the present application, fig. 2 discloses a timing chart of a network connection method of the embodiment of the present application. As shown in fig. 2, the method may include:

202. the first terminal device sends a network sharing request to the server, wherein the network sharing request comprises the position information corresponding to the first terminal device.

204. And the server responds to the network sharing request and determines target terminal equipment for providing network access for the first terminal equipment according to the position information.

After acquiring the network sharing request sent by the first terminal device, the server may analyze the network sharing request, and extract the location information corresponding to the first terminal device from the network sharing request. Illustratively, the location information may include geographic location information represented by geographic coordinates, a scene (such as an indoor scene, an outdoor scene, and the like) in which the first terminal device is located, a location range in which the first terminal device is located may be identified by a nearby base station, a router, and the like.

206. And the server sends the equipment information of the target terminal equipment to the first terminal equipment.

208. And the first terminal equipment accesses a target network provided by the target terminal equipment according to the equipment information.

After receiving the device information sent by the server, the first terminal device may search for a target terminal device located nearby according to the device information, and establish a communication connection with the target terminal device according to the device information, so as to access a target network provided by the target terminal device. Illustratively, the target network may comprise a network to which the target terminal device is connected via Wi-Fi or data traffic.

By implementing the method, the first terminal device can report the position information to the server, so that the server can determine the target terminal device which can perform network sharing nearby according to the position information, and then the first terminal device can be accessed to the target network provided by the target terminal device, thereby realizing the network connection of the first terminal device. Based on the network connection mode, the target terminal device can be used as a relay node for connecting the first terminal device with an external network, and when the first terminal device faces the conditions of poor network signals, insufficient data flow and the like, stable and high-quality network connection can be realized through the relay node, so that network bandwidth sharing among a plurality of terminal devices is realized, and the idle or surplus bandwidth resources of the target terminal device are favorably used so as to reduce the whole bandwidth waste; and the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved.

Referring to fig. 3, fig. 3 is a flowchart illustrating a network connection method according to an embodiment of the present application, where the method may be applied to the first terminal device, and the first terminal device may be communicatively connected to a server. As shown in fig. 3, the network connection method may include the steps of:

302. and sending a network sharing request to the server, wherein the network sharing request comprises the position information corresponding to the first terminal equipment and is used for requesting the server to determine target terminal equipment for providing network access for the first terminal equipment according to the position information.

For example, the location information corresponding to the first terminal device may include a geographic location of the first terminal device, which is represented by geographic coordinates, a scene (such as an indoor scene, an outdoor scene, and the like) in which the first terminal device is located, and a location range in which the first terminal device is located, which is indicated by a nearby base station, a router, and the like.

Based on the location information, the network sharing request sent by the first terminal device may be used to request a target terminal device matched with the location information to provide a network access service for the first terminal device. For example, the target terminal device may be a terminal device that matches the geographic location of the first terminal device (e.g., is within a certain distance range centered on the geographic location), may be a terminal device that is in the same scene as the first terminal device, and may be a terminal device that is connected to the same base station or router (or a base station or a router in the same range) as the first terminal device. Therefore, when the first terminal equipment needs to be connected with an external network, network connection can be achieved through the target terminal equipment corresponding to the position information of the first terminal equipment, the first terminal equipment is prevented from being incapable of networking when the first terminal equipment faces the conditions of poor network signals, insufficient data flow and the like, and the reliability of network connection of the terminal equipment is improved.

In this embodiment of the application, the first terminal device may establish a communication connection with the server, so that when the first terminal device needs to connect to an external network, a network sharing request including the location information may be actively sent to the server, so as to request the server to determine, according to the location information, a target terminal device capable of providing network access for the first terminal device. Optionally, the first terminal device may limit a network type requesting access through a network sharing request sent by the first terminal device, such as a 5G (5th Generation Mobile Communication Technology, fifth Generation Mobile Communication Technology) network, a 4G network, and the like, which is not specifically limited in the embodiment of the present application.

For example, after receiving the network sharing request, the server may respond to the network sharing request, and determine the target terminal device corresponding to the location information by searching, querying, matching, and the like. On this basis, the server may obtain the device information of the target terminal device, and may further send the device information to the first terminal device in the subsequent steps, so that the first terminal device may access the target network provided by the target terminal device according to the device information. The target network provided by the target terminal device may include an external network, that is, a network to which the target terminal device is connected through Wi-Fi or data traffic, etc.

It can be understood that, in the above process, the server may obtain the device information of the target terminal device after determining the target terminal device. In some embodiments, the server may also obtain the device information of the target terminal device in the process of determining the target terminal device. For example, the server may obtain the device information of the plurality of second terminal devices, and then determine the target terminal device from the plurality of second terminal devices according to the device information, that is, obtain the device information of the target terminal device at the same time.

304. And acquiring the device information of the target terminal device fed back by the server.

In the embodiment of the application, after the first terminal device obtains the device information of the target terminal device fed back by the server, the first terminal device may establish a communication connection with the target terminal device according to the device information in the subsequent steps, and then access to the target network provided by the target terminal device.

Illustratively, the device information of the target terminal device may include network configuration information, network connection status, and the like of the target terminal device. Specifically, the network configuration information of the target terminal device may include communication interface information (such as an IP address, a communication port, and the like) required to establish a communication connection with the target terminal device, security authentication information (such as a device name, an account name, a password, and the like), a supported service type (such as whether Wi-Fi hotspot service is supported, 5G ProSe service is supported), and the like. The network connection status of the target terminal device may include various networking statuses of the target terminal device, such as network on-off status, network bandwidth, network quality (which may be evaluated by congestion rate, packet loss rate, etc.) and the like in different areas and at different times.

For example, when the device information of the target terminal device includes communication interface information, the first terminal device may obtain the communication interface information, and establish a communication connection with the target terminal device according to the communication interface information in a subsequent step. It should be noted that the communication interface information alone is usually not sufficient to establish a communication connection between the first terminal device and the target terminal device. In some embodiments, the first terminal device further needs to determine whether the target terminal device supports the corresponding network access service according to the support service type of the target terminal device, and start the corresponding support service of the first terminal device. For example, if the target terminal device supports Wi-Fi hotspot service, the first terminal device needs to support and start Wi-Fi to search and access a wireless hotspot provided by the target terminal device; for another example, if the target terminal device supports a 5G ProSe service (5G proximity service), the first terminal device also needs to support and turn on the 5G ProSe service to search for a target terminal device located nearby. In other embodiments, the first terminal device further needs to perform corresponding security authentication according to the security authentication information of the target terminal device. For example, after obtaining the security authentication information (such as an account name, a password, and the like) of the target terminal device, when communication connection needs to be established with the target terminal device, the first terminal device may pass identity verification provided by the target terminal device according to the security authentication information, and may further access a target network provided by the target terminal device in a subsequent step.

It should be noted that, based on the network configuration information of a specific terminal device, a sensing network corresponding to the terminal device may be established, so as to confirm other terminal devices that are trusted and accessible around the terminal device. Illustratively, by establishing the sensing network corresponding to the first terminal device, the first terminal device can conveniently switch communication connections with different target terminal devices in time, so that the first terminal device can be ensured to maintain continuous network connections, accidental network disconnection is avoided, and the reliability of network connection of the terminal device is greatly improved.

For another example, when the device information of the target terminal device includes a network connection state, the first terminal device may obtain the network connection state, so as to determine whether to establish a communication connection with the target terminal device according to the network connection state in a subsequent step. It should be noted that, based on the network connection states of a large number of terminal devices in different areas and at different times, a corresponding QoS (Quality of Service) map may be established, so as to help the first terminal device to predict the area and time of the weak network that may face the problem of poor network signal, and the like, so that the first terminal device may establish a communication connection with the target terminal device in advance, and access the target network provided by the target terminal device in advance. By implementing the method, the probability of accidental network disconnection of the terminal equipment is further reduced, and the stability and reliability of network connection of the terminal equipment are improved.

306. And accessing the target network provided by the target terminal equipment according to the equipment information.

The target network provided by the target terminal device may include an external network, that is, a network to which the target terminal device is connected through Wi-Fi or data traffic.

In this embodiment, after obtaining the device information of the target terminal device fed back by the server, the first terminal device may search for the target terminal device located nearby according to the device information, and establish a communication connection with the target terminal device according to the device information. On this basis, the first terminal device may access the target network provided by the target terminal device, and perform data transmission between the first terminal device and the target network with the target terminal device as a relay node, thereby implementing network connection of the first terminal device.

It can be seen that, with the network connection method described in the foregoing embodiment, the first terminal device may use the target terminal device as a relay node for connecting the target terminal device with an external network, and when the first terminal device faces conditions of poor network signals, insufficient data traffic, and the like, stable and high-quality network connection may still be achieved through the relay node, so that network bandwidth sharing among multiple terminal devices is achieved, which is not only beneficial to using spare or surplus bandwidth resources of the target terminal device, so as to reduce the overall bandwidth waste; and the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved.

Referring to fig. 4, fig. 4 is a flowchart illustrating another network connection method disclosed in the embodiment of the present application, where the method may be applied to the first terminal device, and the first terminal device may be communicatively connected to a server. As shown in fig. 4, the network connection method may include the steps of:

402. and acquiring the position information corresponding to the first terminal equipment in a positioning mode corresponding to the scene where the first terminal equipment is located.

In this embodiment, before sending the network sharing request including the location information to the server, the first terminal device may first obtain the location information corresponding to itself. The location information may include geographic location information represented by geographic coordinates, a scene (such as an indoor scene, an outdoor scene, and the like) where the first terminal device is located, and a location range where the first terminal device is located may be identified by a nearby base station, a router, and the like.

For example, when the first terminal device is in different scenes, the position information corresponding to the first terminal device may be collected in different positioning manners. In an embodiment, if the first terminal device is located in an indoor scene (e.g., a mall, a school, an office building, a subway, etc.), the radio frequency fingerprint positioning information may be collected to serve as the corresponding location information of the first terminal device. In another embodiment, if the first terminal device is located in an outdoor scene (such as a pedestrian street, a square, etc.), the first terminal device may acquire GNSS (Global Navigation Satellite System) positioning information thereof as the corresponding position information of the first terminal device.

By implementing the method, the most appropriate positioning mode in the scene can be adopted to acquire the position information corresponding to the first terminal equipment aiming at the specific scene of the first terminal equipment, so that the problems of inaccurate GNSS positioning information in an indoor scene and insufficient radio frequency fingerprint precision in an outdoor scene are solved, the accuracy of acquiring the position information of the terminal equipment is effectively improved, and the method is beneficial to determining the appropriate target terminal equipment through the server in the subsequent steps to provide network access for the first terminal equipment.

404. And sending a network sharing request to the server, wherein the network sharing request comprises the position information corresponding to the first terminal equipment and is used for requesting the server to determine target terminal equipment for providing network access for the first terminal equipment according to the position information.

406. And acquiring the device information of the target terminal device fed back by the server.

Step 404 and step 406 are similar to step 302 and step 304, and are not described herein again.

408. And establishing communication connection with the target terminal equipment according to the network configuration information corresponding to the target terminal equipment.

The network configuration information corresponding to the target terminal device may include communication interface information (such as an IP address, a communication port, and the like) required to establish a communication connection with the target terminal device, security authentication information (such as a device name, an account name, a password, and the like), a type of service supported (such as whether Wi-Fi hotspot service is supported, 5G ProSe service is supported), and the like. Optionally, for example, the supported service type includes a Wi-Fi hotspot service, the network configuration information may be further subdivided into whether to support a Wi-Fi 6 technology, whether to support a Wi-Fi 5G band, and the like. According to the network configuration information, the first terminal device can search the target terminal device located nearby, establish communication connection with the target terminal device after passing identity authentication, and further access the target network provided by the target terminal device in the subsequent steps, so that data transmission between the first terminal device and an external network is performed through the target terminal device.

In some embodiments, the target terminal device may be a terminal device determined by the server from one or more second terminal devices within a location range corresponding to the location information in a scene where the first terminal device is located. For example, after the first terminal device sends the network sharing request including the location information of the first terminal device to the server, the server may extract a scene where the first terminal device is located according to the network sharing request, and determine a location range matching the scene, so as to determine a target terminal device from one or more second terminal devices in the location range corresponding to the location information of the first terminal device.

For example, if the first terminal device is located in an indoor subway car scene, the position range matched with the scene may be defined by a rectangular frame corresponding to a plane of the subway car, and the server may determine the target terminal device from the second terminal devices located in the same subway car as the first terminal device. If the first terminal device is located in an indoor subway hall scene, the position range of the scene matching can be defined by a spherical space (the second terminal device may not be located on the same plane as the first terminal device due to the existence of stairs, elevators and the like) with the first terminal device as the center and the designated distance as the radius, and the server can determine the target terminal device from the second terminal device located in the spherical space.

As an optional implementation manner, the server may further determine, according to the network configuration information corresponding to each second terminal device, a terminal device that meets the network configuration condition of the first terminal device from the one or more second terminal devices. The device information of the target terminal device may include network configuration information corresponding to the target terminal device. On this basis, after the server determines the target terminal device, the target terminal device may actively send the device information thereof to the server, so that the server forwards the device information to the first terminal device.

Illustratively, the network configuration condition of the first terminal device may include communication interface information (such as an IP address, a communication port, and the like) used by the first terminal device, security authentication information (such as a supported security protocol, an encryption manner, and the like), a supported service type (such as whether a Wi-Fi hotspot service is supported, a 5G ProSe service is supported), and the like. Specifically, for example, the first terminal device may send a network sharing request including the location information and the network configuration condition of the first terminal device to the server, so that the server extracts the location information and the network configuration condition corresponding to the first terminal device according to the network sharing request, and further may query, as the target terminal device, the terminal device that meets the network configuration condition from the one or more second terminal devices corresponding to the location information. By implementing the method, the bidirectional selection of the first terminal equipment and the target terminal equipment can be realized, the target terminal equipment with the highest matching degree with the first terminal equipment is obtained, and the reliability of the relay network connection by utilizing the target terminal equipment is favorably improved.

410. Sending first communication data to target terminal equipment based on the communication connection, and forwarding the first communication data to network equipment in a target network provided by the target terminal equipment through the target terminal equipment; and/or receiving second communication data which is acquired by the target terminal device from the network device in the target network provided by the target terminal device and forwarded to the first terminal device based on the communication connection.

In the embodiment of the application, after the first terminal device establishes the communication connection with the target terminal device, data transmission can be directly performed between the first terminal device and the target terminal device. On this basis, the first terminal device may take the target terminal device as its relay node connected to the external network. Specifically, the first terminal device may perform communication data transmission with a network device such as a terminal and a server in an external network through the target terminal device, that is, the target terminal device may forward first communication data sent by the first terminal device to the network device, or forward second communication data sent by the network device to the first terminal device. By implementing the method, when the first terminal device faces the conditions of poor network signals, insufficient data flow and the like, stable and high-quality network connection can be realized through the target terminal device serving as the relay node, so that the reliability of network connection of the terminal device is improved.

It can be seen that, by implementing the network connection method described in the foregoing embodiment, network bandwidth sharing among multiple terminal devices can be achieved, which is not only beneficial to using free or surplus bandwidth resources of a target terminal device, so as to reduce overall bandwidth waste; the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved; in addition, positioning is carried out according to the scene where the first terminal device is located, so that the accuracy of acquiring the position information of the terminal device is effectively improved, and the determination of a proper target terminal device is facilitated to provide network access for the first terminal device; in addition, the bidirectional selection of the first terminal device and the target terminal device is realized, so that the target terminal device with the highest matching degree with the first terminal device can be obtained, and the reliability of the relay network connection by using the target terminal device is further improved.

Referring to fig. 5, fig. 5 is a flowchart illustrating a further network connection method disclosed in the embodiment of the present application, where the method can be applied to the first terminal device, and the first terminal device can be communicatively connected to a server. As shown in fig. 5, the network connection method may include the steps of:

502. and acquiring the position information corresponding to the first terminal equipment in a positioning mode corresponding to the scene where the first terminal equipment is located.

Step 502 is similar to step 402, and is not described herein again.

504. And sending a network sharing request to the server, wherein the network sharing request comprises the position information corresponding to the first terminal equipment and is used for requesting the server to determine target terminal equipment for providing network access for the first terminal equipment according to the position information.

506. And acquiring the device information of the target terminal device fed back by the server.

Step 504 and step 506 are similar to step 302 and step 304, and are not described herein again.

508. And establishing communication connection with the target terminal devices according to the network configuration information corresponding to the target terminal devices.

Wherein step 508 is similar to step 408. It should be noted that the first terminal device may establish communication connection with multiple target terminal devices at the same time, so that the multiple target terminal devices may all be added to the to-be-connected device list. The device to be connected list may be used to store a target terminal device that has acquired the access right but has not actually accessed to its target network (i.e., does not actually use its data traffic).

Exemplarily, please refer to fig. 6, and fig. 6 is a schematic diagram illustrating a connection between a first terminal device and a plurality of target terminal devices according to an embodiment of the present application. As shown in fig. 6, the first terminal device 10 can simultaneously connect with a plurality of target terminal devices 30. Alternatively, the first terminal device 10 and the different target terminal devices 30 may implement connection based on different service types (e.g., Wi-Fi hotspot service, 5G ProSe service, etc.), and even based on the same service type, the connection may be distinguished according to different specific use technologies or communication frequency bands (e.g., 2.4G and 5G dual channels may be used for Wi-Fi technology), so that as many target terminal devices as possible may be connected. It will be appreciated that for each target terminal device 30, it may be connected to the same base station 40 or to different base stations 40.

510. Selecting one target terminal device from the plurality of target terminal devices according to the network connection state corresponding to each target terminal device, and sending first communication data to the selected target terminal device based on the communication connection with the selected target terminal device so as to forward the first communication data to the network device in the target network provided by the selected target terminal device through the selected target terminal device; and/or receiving second communication data which is acquired by the selected target terminal device from the network device in the target network provided by the selected target terminal device and forwarded to the first terminal device.

In this embodiment, when the first terminal device needs to connect to the network, it may select one of the target terminal devices from the list of devices to be connected, and access to the target network provided by the target terminal device. For example, the selection may be a random selection, or may be selected according to a certain order (for example, according to a priority of the network configuration information, from a high order to a low order, and according to a relative distance, from a small order to a large order), and is not specifically limited in this embodiment. By implementing the method, the first terminal device establishes communication connection with a plurality of target terminal devices in advance, so that the first terminal device can be accessed to a target network provided by one target terminal device at any time, and the first terminal device can still ensure that the first terminal device can enjoy network service with good continuity even if the first terminal device is in motion.

It can be seen that, by implementing the network connection described in the above implementation, network bandwidth sharing among multiple terminal devices can be achieved, which is beneficial to using free or redundant bandwidth resources of the target terminal device, so as to reduce the bandwidth waste as a whole; the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved; in addition, by establishing communication connection with a plurality of target terminal devices simultaneously and accessing the appropriate target terminal device when the first terminal device needs to perform network connection, continuous network service can be ensured, and the stability and reliability of network connection performed by the terminal device are further improved.

Referring to fig. 7, fig. 7 is a flowchart illustrating a further network connection method disclosed in the embodiment of the present application, where the method may be applied to the server, and the server may be communicatively connected to the first terminal device. As shown in fig. 7, the network connection method may include the steps of:

702. and acquiring a network sharing request sent by the first terminal equipment, wherein the network sharing request comprises the position information corresponding to the first terminal equipment.

In this embodiment of the application, the server may establish a communication connection with the first terminal device, so that when the first terminal device needs to connect to an external network and sends a network sharing request including location information of the first terminal device to the server, the server may receive the network sharing request, extract the location information in the network sharing request in subsequent steps, and determine a target terminal device capable of providing network access for the first terminal device according to the location information.

704. And responding to the network sharing request, and determining the target terminal equipment for providing network access for the first terminal equipment according to the position information.

For example, after receiving the network sharing request, the server may respond to the network sharing request, and determine the target terminal device corresponding to the location information by searching, querying, matching, and the like. On this basis, the server may obtain the device information of the target terminal device, and may further send the device information to the first terminal device in the subsequent steps, so that the first terminal device may access the target network provided by the target terminal device according to the device information. The target network provided by the target terminal device may include an external network, that is, a network to which the target terminal device is connected through Wi-Fi or data traffic, etc.

706. And sending the equipment information of the target terminal equipment to the first terminal equipment so that the first terminal equipment accesses a target network provided by the target terminal equipment according to the equipment information.

In the embodiment of the application, after determining the target terminal device, the server may obtain device information corresponding to the target terminal device. On this basis, the server may package the device information and feed the device information back to the first terminal device through a communication connection between the server and the first terminal device. After the first terminal device obtains the device information of the target terminal device fed back by the server, the first terminal device can establish communication connection with the target terminal device according to the device information, and then access to a target network provided by the target terminal device.

Illustratively, the device information of the target terminal device may include network configuration information, network connection status, and the like of the target terminal device. Specifically, the network configuration information of the target terminal device may include communication interface information (such as an IP address, a communication port, and the like) required to establish a communication connection with the target terminal device, security authentication information (such as a device name, an account name, a password, and the like), a supported service type (such as whether Wi-Fi hotspot service is supported, 5G ProSe service is supported), and the like. The network connection status of the target terminal device may include various networking statuses of the target terminal device, such as network on-off status, network bandwidth, network quality (which may be evaluated by congestion rate, packet loss rate, etc.) and the like in different areas and at different times.

It can be seen that, by implementing the network connection method described in the above implementation, the server may determine a suitable target terminal device to serve as a relay node for connecting the first terminal device with an external network, and when the first terminal device faces conditions of poor network signals, insufficient data traffic, and the like, stable and high-quality network connection may still be achieved through the relay node, so that network bandwidth sharing among a plurality of terminal devices is achieved, which is beneficial to using idle or surplus bandwidth resources of the target terminal device, so as to reduce the overall bandwidth waste; and the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved.

Referring to fig. 8, fig. 8 is a flowchart illustrating a further network connection method disclosed in the embodiment of the present application, where the method may be applied to the server, and the server may be communicatively connected to the first terminal device. As shown in fig. 8, the network connection method may include the steps of:

802. and acquiring a network sharing request sent by the first terminal equipment, wherein the network sharing request comprises the position information corresponding to the first terminal equipment.

Step 802 is similar to the above steps, and is not described herein again.

804. And determining one or more second terminal devices in the position range corresponding to the position information under the scene where the first terminal device is located.

In this embodiment, the server may obtain a scene where the first terminal device is located according to the location information corresponding to the first terminal device. Further, in a scene where the first terminal device is located, the server may determine the terminal device from one or more second terminal devices within a location range corresponding to the location information. For example, after the first terminal device sends the network sharing request including the location information of the first terminal device to the server, the server may extract a scene where the first terminal device is located according to the network sharing request, and determine a location range matching the scene, so as to determine a target terminal device from one or more second terminal devices in the location range corresponding to the location information of the first terminal device.

For example, if the first terminal device is located in an indoor subway car scene, the position range matched with the scene may be defined by a rectangular frame corresponding to a plane of the subway car, and the server may determine the target terminal device from the second terminal devices located in the same subway car as the first terminal device. If the first terminal device is located in an indoor subway hall scene, the position range of the scene matching can be defined by a spherical space (the second terminal device may not be located on the same plane as the first terminal device due to the existence of stairs, elevators and the like) with the first terminal device as the center and the designated distance as the radius, and the server can determine the target terminal device from the second terminal device located in the spherical space.

806. And respectively sending a network access request to each second terminal device, wherein the network access request is used for requesting the second terminal device to provide network access for the first terminal device.

The network access request may include a network configuration condition of the first terminal device, so that a target terminal device meeting the network configuration condition may be determined from the one or more second terminal devices. Illustratively, the network configuration condition of the first terminal device may include communication interface information (such as an IP address, a communication port, and the like) used by the first terminal device, security authentication information (such as a supported security protocol, an encryption manner, and the like), a supported service type (such as whether a Wi-Fi hotspot service is supported, a 5G ProSe service is supported), and the like. Specifically, for example, the first terminal device may send a network sharing request including the location information and the network configuration condition of the first terminal device to the server, so that the server extracts the location information and the network configuration condition corresponding to the first terminal device according to the network sharing request, and further may query, as the target terminal device, the terminal device that meets the network configuration condition from the one or more second terminal devices corresponding to the location information. By implementing the method, the bidirectional selection of the first terminal equipment and the target terminal equipment can be realized, the target terminal equipment with the highest matching degree with the first terminal equipment is obtained, and the reliability of the relay network connection by utilizing the target terminal equipment is favorably improved.

808. And acquiring network configuration information fed back by each second terminal device in response to the network access request.

810. And determining the target terminal equipment of which the network configuration information is matched with the network configuration condition of the first terminal equipment from the one or more second terminal equipment according to the network configuration information corresponding to each second terminal equipment.

In this embodiment, the server may respectively determine and filter the network configuration information corresponding to each second terminal device, so as to determine, in combination with the network configuration condition of the first terminal device, a target terminal device that meets the network configuration condition.

For example, the server may add the second terminal device that receives the network access request to the device to be selected list according to the network configuration information of each second terminal device, so as to implement bidirectional selection between the first terminal device and the target terminal device. On this basis, the server may determine, according to the network configuration information of each second terminal device in the device list to be selected, a service type supported by each second terminal device (e.g., whether to support Wi-Fi hotspot service, 5 gpp ase service, or the like, or further, whether to support Wi-Fi 6 technology, whether to support Wi-Fi 5G band, or the like), and may further determine, according to the service type supported by each second terminal device, a target terminal device that matches the network configuration condition of the first terminal device from the device list to be selected.

812. And generating corresponding equipment information according to the network configuration information corresponding to the target terminal equipment, and sending the equipment information to the first terminal equipment.

Step 812 is similar to step 706, and is not described herein again.

As an optional implementation manner, the target terminal device may further include a plurality of target terminal devices, and the device information of the target terminal device may further include a network connection state corresponding to the target terminal device, so that when the server generates the device information corresponding to the target terminal device, the server may generate corresponding device information according to the network configuration information and the network connection state corresponding to the plurality of target terminal devices, and send the device information of the plurality of target terminal devices to the first terminal device. On this basis, the first terminal device may be triggered to establish communication connection with the plurality of target terminal devices according to the network configuration information corresponding to the plurality of target terminal devices, and select one of the plurality of target terminal devices according to the network connection state corresponding to each target terminal device, and perform data transmission between the first terminal device and the target network provided by the selected target terminal device through the selected target terminal device. Specifically, the selected target terminal device may be configured to forward the first communication data sent by the first terminal device to a network device in a target network provided by the selected target terminal device; meanwhile, the method can also be used for forwarding the second communication data sent by the network device to the first terminal device. By implementing the method, the first terminal equipment can be accessed to the target network, and communication with the network equipment in the target network is realized.

Therefore, by implementing the network connection method described in the above implementation, network bandwidth sharing among multiple terminal devices can be achieved, which is beneficial to using free or redundant bandwidth resources of the target terminal device, so as to reduce the overall bandwidth waste; the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved; in addition, the target terminal equipment is determined based on the network configuration information and the like, so that the accuracy of determining the target terminal equipment is improved, and the selection of proper target terminal equipment is facilitated to provide network access for the first terminal equipment; in addition, by establishing communication connection with a plurality of target terminal devices simultaneously and accessing the appropriate target terminal device when the first terminal device needs to perform network connection, continuous network service can be ensured, and the stability and reliability of network connection performed by the terminal device are further improved.

Referring to fig. 9, fig. 9 is a schematic block diagram of a network connection device according to an embodiment of the present disclosure, where the network connection device may be applied to the first terminal device, and the first terminal device may be communicatively connected to a server. As shown in fig. 9, the network connection apparatus may include a request sending unit 901, an information acquiring unit 902, and a network connecting unit 903, in which:

a request sending unit 901, configured to send a network sharing request to a server, where the network sharing request includes location information corresponding to a first terminal device, and is used to request the server to determine, according to the location information, a target terminal device that provides network access for the first terminal device;

an information obtaining unit 902, configured to obtain device information of the target terminal device fed back by the server;

a network connection unit 903, configured to access a target network provided by the target terminal device according to the device information.

It can be seen that, by using the network connection device described in the foregoing embodiment, the first terminal device may use the target terminal device as a relay node for connecting the target terminal device with an external network, and when the first terminal device faces conditions of poor network signals, insufficient data traffic, and the like, stable and high-quality network connection may still be achieved through the relay node, so that network bandwidth sharing among multiple terminal devices is achieved, which is beneficial to using spare or surplus bandwidth resources of the target terminal device, so as to reduce the bandwidth waste as a whole; and the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved.

In an embodiment, the network connection apparatus may further include a positioning unit, not shown in the drawing, where the positioning unit may be configured to acquire the position information corresponding to the first terminal device in a positioning manner corresponding to a scene where the first terminal device is located before the request sending unit 901 sends the network sharing request to the server.

Therefore, the network connection device described in the above embodiment can be used for positioning the scene where the first terminal device is located, so that the accuracy of acquiring the position information of the terminal device is effectively improved, and the network connection device is helpful for determining a proper target terminal device to provide network access for the first terminal device.

In an embodiment, the target terminal device may be a terminal device determined by the server from one or more second terminal devices within a location range corresponding to the location information in a scene where the first terminal device is located.

Further, the target terminal device may also be a second terminal device that meets the network configuration condition of the first terminal device and is determined by the server from one or more second terminal devices according to the network configuration information corresponding to each second terminal device, where the device information of the target terminal device includes the network configuration information corresponding to the target terminal device.

Further, the device information of the target terminal device may be sent to the server after being determined by the target terminal device.

It can be seen that, by using the network connection device described in the foregoing embodiment, through implementing bidirectional selection between the first terminal device and the target terminal device, it is beneficial to obtain the target terminal device with the highest matching degree with the first terminal device, and the reliability of performing relay network connection by using the target terminal device is further improved.

In an embodiment, the network connection unit 903 may be specifically configured to establish a communication connection with the target terminal device according to network configuration information corresponding to the target terminal device;

based on the communication connection, sending first communication data to the target terminal device, and forwarding the first communication data to network equipment in a target network provided by the target terminal device through the target terminal device; and/or receiving second communication data which is acquired by the target terminal device from the network device in the target network provided by the target terminal device and forwarded to the first terminal device based on the communication connection.

In an embodiment, the target terminal device may include a plurality of target terminal devices, and the network connection unit 903 may be specifically configured to establish communication connection with the plurality of target terminal devices according to network configuration information corresponding to the plurality of target terminal devices, respectively;

selecting one target terminal device from the plurality of target terminal devices according to the network connection state corresponding to each target terminal device, and sending first communication data to the selected target terminal device based on the communication connection between the selected target terminal device and the selected target terminal device so as to forward the first communication data to the network device in the target network provided by the selected target terminal device through the selected target terminal device; and/or receiving second communication data which is acquired by the selected target terminal device from the network device in the target network provided by the selected target terminal device and forwarded to the first terminal device.

It can be seen that, by using the network connection device described in the foregoing embodiment, network bandwidth sharing among multiple terminal devices can be achieved, which is beneficial to using idle or redundant bandwidth resources of a target terminal device, so as to reduce bandwidth waste as a whole; the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved; in addition, by establishing communication connection with a plurality of target terminal devices simultaneously and accessing the appropriate target terminal device when the first terminal device needs to perform network connection, continuous network service can be ensured, and the stability and reliability of network connection performed by the terminal device are further improved.

Referring to fig. 10, fig. 10 is a schematic block diagram of another network connection device disclosed in the embodiment of the present application, where the network connection device may be applied to the server, and the server may be communicatively connected to the first terminal device. As shown in fig. 10, the network connection apparatus may include a request acquisition unit 1001, a determination unit 1002, and an information transmission unit 1003, wherein:

a request obtaining unit 1001, configured to obtain a network sharing request sent by a first terminal device, where the network sharing request includes location information corresponding to the first terminal device;

a determining unit 1002, configured to determine, in response to the network sharing request, a target terminal device that provides network access for the first terminal device according to the location information;

an information sending unit 1003, configured to send device information of the target terminal device to the first terminal device, so that the first terminal device accesses a target network provided by the target terminal device according to the device information.

It can be seen that, by using the network connection device described in the foregoing embodiment, the server may determine a suitable target terminal device to serve as a relay node for connecting the first terminal device with an external network, and when the first terminal device faces conditions of poor network signals, insufficient data traffic, and the like, stable and high-quality network connection may still be achieved through the relay node, so that network bandwidth sharing among multiple terminal devices is achieved, which is beneficial to using spare or surplus bandwidth resources of the target terminal device, so as to reduce bandwidth waste as a whole; and the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved.

In an embodiment, the determining unit 1002 may include a first determining subunit and a second determining subunit, not shown in the figure, wherein:

the first determining subunit is configured to determine, in a scene where the first terminal device is located, one or more second terminal devices within a position range corresponding to the position information;

and the second determining subunit is configured to determine, from the one or more second terminal devices, a target terminal device corresponding to the location information.

In an embodiment, the second determining subunit may be specifically configured to send a network access request to each second terminal device, where the network access request is used to request the second terminal device to provide network access for the first terminal device; acquiring network configuration information fed back by each second terminal device in response to the network access request; determining a target terminal device of which the network configuration information is matched with the network configuration condition of the first terminal device from the one or more second terminal devices according to the network configuration information corresponding to each second terminal device;

the information sending unit 1003 may be specifically configured to generate corresponding device information according to the network configuration information corresponding to the target terminal device, and send the device information to the first terminal device.

In an embodiment, when the second determining subunit determines, according to the network configuration information corresponding to each second terminal device, a target terminal device whose network configuration information matches the network configuration condition of the first terminal device from the one or more second terminal devices, the method may include the following steps:

according to the network configuration information of each second terminal device, adding the second terminal device which receives the network access request into a device list to be selected;

determining the type of the support service of each second terminal device according to the network configuration information of each second terminal device in the device list to be selected;

and according to the service supporting type of each second terminal device, determining a target terminal device matched with the network configuration condition of the first terminal device from the device to be selected list.

In an embodiment, the target terminal device may include a plurality of target terminal devices, and the device information of the target terminal device may further include a network connection state corresponding to the target terminal device, and the information sending unit 1003 may be specifically configured to generate corresponding device information according to the network configuration information and the network connection state corresponding to the plurality of target terminal devices, respectively, and send the device information of the plurality of target terminal devices to the first terminal device, so as to trigger the first terminal device to establish communication connection with the plurality of target terminal devices according to the network configuration information corresponding to the plurality of target terminal devices, respectively, and select one of the target terminal devices from the plurality of target terminal devices according to the network connection state corresponding to each target terminal device, where the selected target terminal device may be used to forward the first communication data sent by the first terminal device to the network device in the target network provided by the selected target terminal device And/or forwarding the second communication data sent by the network equipment to the first terminal equipment.

It can be seen that, by using the network connection device described in the foregoing embodiment, network bandwidth sharing among multiple terminal devices can be achieved, which is beneficial to using idle or redundant bandwidth resources of a target terminal device, so as to reduce bandwidth waste as a whole; the first terminal equipment can be ensured to maintain continuous network connection, and accidental network disconnection caused by poor network signals, insufficient data flow and the like is avoided, so that the reliability of network connection of the terminal equipment is improved; in addition, the target terminal equipment is determined based on the network configuration information and the like, so that the accuracy of determining the target terminal equipment is improved, and the selection of proper target terminal equipment is facilitated to provide network access for the first terminal equipment; in addition, by establishing communication connection with a plurality of target terminal devices simultaneously and accessing the appropriate target terminal device when the first terminal device needs to perform network connection, continuous network service can be ensured, and the stability and reliability of network connection performed by the terminal device are further improved.

Referring to fig. 11, fig. 11 is a schematic block diagram of a terminal device according to an embodiment of the present disclosure. As shown in fig. 11, the terminal device may include:

a memory 1101 storing executable program code;

a processor 1102 coupled with a memory 1101;

the processor 1102 calls the executable program code stored in the memory 1101 to execute all or part of the steps of any one of the network connection methods applied to the first terminal device described in the above embodiments.

Referring to fig. 12, fig. 12 is a schematic block diagram of a server according to an embodiment of the present disclosure. As shown in fig. 12, the server may include:

a memory 1201 in which executable program code is stored;

a processor 1202 coupled with a memory 1201;

the processor 1202 calls the executable program code stored in the memory 1201 to perform all or part of the steps of any one of the network connection methods applied to the server described in the above embodiments.

Furthermore, the present application further discloses a computer-readable storage medium storing a computer program for electronic data exchange, wherein the computer program causes a computer to execute all or part of the steps of any one of the network connection methods applied to the first terminal device or applied to the server described in the above embodiments.

It will be understood by those skilled in the art that all or part of the steps in the methods of the embodiments described above may be implemented by hardware instructions of a program, and the program may be stored in a computer-readable storage medium, where the storage medium includes Read-Only Memory (ROM), Random Access Memory (RAM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), One-time Programmable Read-Only Memory (OTPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Compact Disc Read-Only Memory (CD-ROM), or other Memory, such as a magnetic disk, or a combination thereof, A tape memory, or any other medium readable by a computer that can be used to carry or store data.

The network connection method and apparatus, the terminal device, the server, and the storage medium disclosed in the embodiments of the present application are introduced in detail, and a specific example is applied in the present application to explain the principle and the implementation of the present application, and the description of the embodiments is only used to help understand the method and the core idea of the present application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

27页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种智能寻车方法、寻车系统及其汽车

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类