CN108307359A - A kind of method, terminal and system that hot spot is shared - Google Patents
A kind of method, terminal and system that hot spot is shared Download PDFInfo
- Publication number
- CN108307359A CN108307359A CN201610754318.8A CN201610754318A CN108307359A CN 108307359 A CN108307359 A CN 108307359A CN 201610754318 A CN201610754318 A CN 201610754318A CN 108307359 A CN108307359 A CN 108307359A
- Authority
- CN
- China
- Prior art keywords
- wifi
- hotspot
- terminal
- network protocol
- protocol data
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W48/00—Access restriction; Network selection; Access point selection
- H04W48/08—Access restriction or access information delivery, e.g. discovery data delivery
- H04W48/10—Access restriction or access information delivery, e.g. discovery data delivery using broadcasted information
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W28/00—Network traffic management; Network resource management
- H04W28/02—Traffic management, e.g. flow control or congestion control
- H04W28/10—Flow control between communication endpoints
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W48/00—Access restriction; Network selection; Access point selection
- H04W48/16—Discovering, processing access restriction or access information
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W8/00—Network data management
- H04W8/005—Discovery of network devices, e.g. terminals
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Databases & Information Systems (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
本发明实施例公开了一种热点共享方法、终端和系统,该方法可以包括:第一终端开启WiFi热点;第一终端通过将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据;第一终端将更新的WiFi网络协议数据进行SSID广播。
The embodiment of the present invention discloses a hotspot sharing method, terminal and system. The method may include: the first terminal opens a WiFi hotspot; the first terminal acquires an updated WiFi hotspot by adding hotspot indication information to existing WiFi network protocol data. Network protocol data; the first terminal broadcasts the updated WiFi network protocol data through SSID.
Description
技术领域technical field
本发明涉及无线网络技术,尤其涉及一种热点共享的方法、终端和系统。The present invention relates to wireless network technology, and in particular to a hotspot sharing method, terminal and system.
背景技术Background technique
当前,移动设备使用越来越广泛、频繁,而公共WiFi网络又还没有完全普及,日常生活中我们会碰到手机流量套餐使用完,流量不够用而又有流量使用需求(比如下载一个急用的应用),且身边又没有对应的WiFi热点的情况,通常会让朋友共享一个手机热点供我们使用。At present, mobile devices are used more and more widely and frequently, and public WiFi networks have not yet been fully popularized. application), and there is no corresponding WiFi hotspot around, usually let friends share a mobile phone hotspot for us to use.
当我们连上对方手机热点的时候,我们的手机并不知道对方是手机开的热点,因此会将对方分享的手机热点作为一个固定的WiFi热点来处理,而手机后台有很多运行任务在网络状态改变,且发现网络类型是WiFi的时候,会进行相关同步和更新动作,更有甚者,会进行后台升级。因此我们连上这个手机热点,下载我们所需要的东西后,往往发现对方实际提供的流量远大于我们真正使用的流量,这个就是手机热点共享造成的后台大流量消耗问题的原因。When we connect to the hotspot of the other party's mobile phone, our mobile phone does not know that the other party is a hotspot opened by the mobile phone, so it will treat the mobile hotspot shared by the other party as a fixed WiFi hotspot, and there are many running tasks in the background of the mobile phone in the network state When it is found that the network type is WiFi, it will perform related synchronization and update actions, and what’s more, it will perform background upgrades. Therefore, when we connect to this mobile phone hotspot and download what we need, we often find that the traffic actually provided by the other party is much larger than the traffic we actually use. This is the reason for the large background traffic consumption problem caused by mobile hotspot sharing.
发明内容Contents of the invention
为解决现有存在的技术问题,本发明实施例期望提供一种热点共享方法、终端和系统,解决热点共享造成的后台大流量消耗问题。In order to solve the existing technical problems, the embodiments of the present invention expect to provide a hotspot sharing method, terminal and system to solve the problem of large background traffic consumption caused by hotspot sharing.
为达到上述目的,本发明实施例的技术方案是这样实现的:In order to achieve the above object, the technical solution of the embodiment of the present invention is achieved in this way:
第一方面,本发明实施例提供了一种热点共享方法,所述方法应用于提供WiFi热点共享的第一终端侧,所述方法包括:In the first aspect, an embodiment of the present invention provides a hotspot sharing method, the method is applied to a first terminal side that provides WiFi hotspot sharing, and the method includes:
所述第一终端开启WiFi热点;The first terminal opens a WiFi hotspot;
所述第一终端通过将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据;The first terminal acquires updated WiFi network protocol data by adding hotspot indication information to existing WiFi network protocol data;
所述第一终端将所述更新的WiFi网络协议数据进行SSID广播。The first terminal broadcasts the updated WiFi network protocol data through SSID.
在上述方案中,所述热点指示信息用于表征更新的WiFi网络协议数据由所述第一终端通过WiFi热点共享提供。In the above solution, the hotspot indication information is used to indicate that the updated WiFi network protocol data is provided by the first terminal through WiFi hotspot sharing.
在上述方案中,所述第一终端通过将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据,包括:In the above solution, the first terminal obtains updated WiFi network protocol data by adding hotspot indication information to existing WiFi network protocol data, including:
所述第一终端将所述热点指示信息添加在现有的WiFi网络协议数据帧中的预留空位,获取更新的WiFi网络协议数据。The first terminal adds the hotspot indication information to a reserved space in an existing WiFi network protocol data frame to obtain updated WiFi network protocol data.
在上述方案中,所述第一终端通过将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据,包括:In the above solution, the first terminal obtains updated WiFi network protocol data by adding hotspot indication information to existing WiFi network protocol data, including:
所述第一终端在开启WiFi热点之后,调用hostapd进程完成配置文件的设置;以及,After the first terminal turns on the WiFi hotspot, it calls the hostapd process to complete the setting of the configuration file; and,
所述第一终端通过hostapd进程指示WiFi驱动在WiFi网络协议中添加热点指示信息,获取更新的WiFi网络协议数据。The first terminal instructs the WiFi driver to add hotspot indication information in the WiFi network protocol through the hostapd process, and acquires updated WiFi network protocol data.
相应地,所述hostapd进程和WiFi驱动均在第一终端内部,所述第一终端通过hostapd进程指示WiFi驱动在WiFi网络协议中添加热点指示信息,包括:Correspondingly, both the hostapd process and the WiFi driver are inside the first terminal, and the first terminal instructs the WiFi driver to add hotspot indication information in the WiFi network protocol through the hostapd process, including:
所述hostapd进程向所述WiFi驱动发送热点指示信息添加请求;以及,The hostapd process sends a hotspot indication information addition request to the WiFi driver; and,
所述WiFi驱动在所述WiFi网络协议数据帧的预留空位添加热点指示信息。The WiFi driver adds hotspot indication information in the reserved space of the WiFi network protocol data frame.
第二方面,本发明实施例提供了一种热点共享方法,所述方法应用于使用WiFi热点共享的第二终端侧,所述方法包括:In a second aspect, an embodiment of the present invention provides a hotspot sharing method, the method is applied to a second terminal side that uses WiFi hotspot sharing, and the method includes:
所述第二终端扫描WiFi热点的SSID时,获取WiFi网络协议数据;When the second terminal scans the SSID of the WiFi hotspot, obtains the WiFi network protocol data;
所述第二终端对所述WiFi网络协议数据进行解析;The second terminal analyzes the WiFi network protocol data;
当所述WiFi网络协议数据包含热点指示信息时,所述第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。When the WiFi network protocol data includes hotspot indication information, the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and performs flow control on network access after accessing the WiFi hotspot.
在上述方案中,所述热点指示信息用于表征所述第二终端获取的WiFi网络协议数据由第一终端通过WiFi热点共享提供。In the above solution, the hotspot indication information is used to indicate that the WiFi network protocol data acquired by the second terminal is provided by the first terminal through WiFi hotspot sharing.
相应地,当所述WiFi网络协议数据包含热点指示信息时,所述第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制,包括:Correspondingly, when the WiFi network protocol data includes hotspot indication information, the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and performs flow control on network access after accessing the WiFi hotspot, including:
当所述WiFi网络协议数据帧的预留空位包含热点指示信息时,所述第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。When the reserved space of the WiFi network protocol data frame contains hotspot indication information, the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and performs flow control on network access after accessing the WiFi hotspot.
在上述方案中,所述第二终端扫描WiFi热点的SSID时,获取WiFi网络协议数据,包括:In the above solution, when the second terminal scans the SSID of the WiFi hotspot, it obtains the WiFi network protocol data, including:
所述第二终端在预设距离内扫描WiFi热点的SSID;以及,The second terminal scans the SSID of the WiFi hotspot within a preset distance; and,
所述第二终端扫描到所述WiFi热点的SSID后,通过SSID获取对应的WiFi网络协议数据。After the second terminal scans the SSID of the WiFi hotspot, it acquires corresponding WiFi network protocol data through the SSID.
在上述方案中,当所述WiFi网络协议数据不包含热点指示信息时,所述方法还包括:所述第二终端接入所述WiFi网络协议数据对应的WiFi热点,并按照现有的WiFi热点连接方式进行连接。In the above scheme, when the WiFi network protocol data does not contain hotspot indication information, the method further includes: the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and according to the existing WiFi hotspot Connection method to connect.
相应地,所述对接入WiFi热点后的网络访问进行流量控制,具体包括:Correspondingly, the flow control of the network access after accessing the WiFi hotspot specifically includes:
所述第二终端需要进行流量使用时,所述第二终端显示提示消息;其中,所述提示消息用于提示是否进行流量使用,具体包括:When the second terminal needs to use traffic, the second terminal displays a prompt message; wherein, the prompt message is used to prompt whether to use traffic, specifically including:
当所述第二终端接收到针对所述提示消息的第一响应指令时,所述第二终端提示用户进行确定下载,且断开用户的后台应用下载数据;When the second terminal receives the first response instruction for the prompt message, the second terminal prompts the user to confirm the download, and disconnects the user's background application to download data;
当所述第二终端接收到针对所述提示消息的第二响应指令时,所述第二终端下载过程及后台的应用下载不需要进行用户提示。When the second terminal receives the second response instruction to the prompt message, the downloading process of the second terminal and the background application downloading do not require user prompting.
第三方面,本发明实施例提供了一种用于提供WiFi热点共享的第一终端,所述第一终端包括:开启模块、第一获取模块和广播模块;其中,In a third aspect, an embodiment of the present invention provides a first terminal for providing WiFi hotspot sharing, where the first terminal includes: an opening module, a first acquiring module, and a broadcasting module; wherein,
所述开启模块,用于开启WiFi热点;The opening module is used to open the WiFi hotspot;
所述第一获取模块,用于将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据;The first obtaining module is used to add hotspot indication information to existing WiFi network protocol data, and obtain updated WiFi network protocol data;
所述广播模块,用于将更新的WiFi网络协议数据进行SSID广播。The broadcast module is used to broadcast the updated WiFi network protocol data through SSID.
在上述方案中,所述热点指示信息用于表征更新的WiFi网络协议数据由所述第一终端通过WiFi热点共享提供。In the above solution, the hotspot indication information is used to indicate that the updated WiFi network protocol data is provided by the first terminal through WiFi hotspot sharing.
在上述方案中,所述第一获取模块,用于将所述热点指示信息添加在现有的WiFi网络协议数据帧中的预留空位,获取更新的WiFi网络协议数据。In the above solution, the first obtaining module is configured to add the hotspot indication information to a reserved space in an existing WiFi network protocol data frame, and obtain updated WiFi network protocol data.
相应地,所述第一获取模块,用于Correspondingly, the first acquisition module is used for
调用hostapd进程完成配置文件的设置;Call the hostapd process to complete the setting of the configuration file;
以及,通过hostapd进程指示WiFi驱动在WiFi网络协议中添加热点指示信息,获取更新的WiFi网络协议数据。And, the hostapd process instructs the WiFi driver to add hotspot indication information in the WiFi network protocol to obtain updated WiFi network protocol data.
第四方面,本发明实施例提供了一种用于使用WiFi热点共享的第二终端,所述第二终端包括:扫描模块、第二获取模块、解析模块及控制模块,其中,In the fourth aspect, the embodiment of the present invention provides a second terminal for sharing with WiFi hotspots, the second terminal includes: a scanning module, a second acquisition module, an analysis module, and a control module, wherein,
所述扫描模块,用于扫描WiFi热点的SSID;The scanning module is used to scan the SSID of the WiFi hotspot;
所述第二获取模块,用于当所述扫描模块扫描WiFi热点的SSID时,获取WiFi网络协议数据;The second obtaining module is used to obtain WiFi network protocol data when the scanning module scans the SSID of the WiFi hotspot;
所述解析模块,用于对WiFi网络协议数据进行解析;The analysis module is used to analyze the WiFi network protocol data;
所述控制模块,用于当解析的WiFi网络协议数据包含热点指示信息时,接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。The control module is configured to access the WiFi hotspot corresponding to the WiFi network protocol data when the parsed WiFi network protocol data contains hotspot indication information, and perform flow control on network access after accessing the WiFi hotspot.
在上述方案中,所述热点指示信息用于表征所述第二终端获取的WiFi网络协议数据由第一终端通过WiFi热点共享提供。In the above solution, the hotspot indication information is used to indicate that the WiFi network protocol data acquired by the second terminal is provided by the first terminal through WiFi hotspot sharing.
在上述方案中,所述控制模块,用于当所述WiFi网络协议数据帧的预留空位包含热点指示信息时,接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。In the above solution, the control module is configured to access the WiFi hotspot corresponding to the WiFi network protocol data when the reserved space of the WiFi network protocol data frame contains hotspot indication information, and to access the WiFi hotspot traffic control for network access.
在上述方案中,所述扫描模块,用于在预设距离内扫描WiFi热点的SSID,并扫描到所述WiFi热点的SSID时,触发所述第二获取模块。In the above solution, the scanning module is configured to scan the SSID of the WiFi hotspot within a preset distance, and trigger the second acquisition module when the SSID of the WiFi hotspot is scanned.
在上述方案中,所述解析模块,用于对所述WiFi网络协议数据帧的解析。In the above solution, the parsing module is configured to parse the WiFi network protocol data frame.
在上述方案中,当所述WiFi网络协议数据不包含热点指示信息时,所述第二终端还包括接入模块,所述接入模块用于接入WiFi热点,并按照现有的WiFi热点连接方式进行连接。In the above solution, when the WiFi network protocol data does not include hotspot indication information, the second terminal further includes an access module, and the access module is used to access a WiFi hotspot, and connect to the WiFi hotspot according to the existing WiFi hotspot way to connect.
在上述方案中,所述控制模块,具体包括:In the above scheme, the control module specifically includes:
当需要进行流量使用时,显示提示消息;其中,所述提示消息用于提示是否进行流量使用,具体包括:When traffic usage is required, a prompt message is displayed; wherein, the prompt message is used to prompt whether to use traffic, specifically including:
当接收到针对所述提示消息的第一响应指令时,提示用户进行确定下载,且断开用户的后台应用下载数据;When receiving the first response instruction for the prompt message, prompt the user to confirm the download, and disconnect the user's background application to download data;
当接收到针对所述提示消息的第二响应指令时,在下载过程及后台的应用下载时不需要进行用户提示。When the second response instruction to the prompt message is received, no user prompt is required during the download process and background application download.
第五方面,本发明实施例提供了一种热点共享的系统,所述系统包括:用于提供WiFi热点共享的第一终端和用于使用WiFi热点共享的第二终端,其中,In a fifth aspect, an embodiment of the present invention provides a hotspot sharing system, the system comprising: a first terminal for providing WiFi hotspot sharing and a second terminal for using WiFi hotspot sharing, wherein,
所述第一终端,用于开启WiFi热点;以及,The first terminal is configured to enable a WiFi hotspot; and,
通过将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据;以及,Obtain updated WiFi network protocol data by adding hotspot indication information to existing WiFi network protocol data; and,
将更新的WiFi网络协议数据进行SSID广播;Broadcast the updated WiFi network protocol data to SSID;
所述第二终端,用于扫描WiFi热点的SSID时,获取WiFi网络协议数据;以及,The second terminal is used to obtain WiFi network protocol data when scanning the SSID of the WiFi hotspot; and,
对WiFi网络协议数据进行解析;以及,parsing the WiFi network protocol data; and,
当解析的WiFi网络协议数据包含热点指示信息时,第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。When the analyzed WiFi network protocol data contains hotspot indication information, the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and performs flow control on network access after accessing the WiFi hotspot.
本发明实施例提供了一种热点共享方法、终端和系统,第一终端对添加了热点指示信息的WiFi网络协议数据进行服务集标识(SSID,Service Set Identifier)广播,及第二终端对扫描的SSID对应WiFi网络协议数据的解析,当解析的WiFi网络协议数据包含热点指示信息时,第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制,解决热点共享造成的后台大流量消耗问题。Embodiments of the present invention provide a hotspot sharing method, terminal, and system. The first terminal broadcasts a Service Set Identifier (SSID, Service Set Identifier) to WiFi network protocol data added with hotspot indication information, and the second terminal broadcasts the scanned The SSID corresponds to the analysis of WiFi network protocol data. When the analyzed WiFi network protocol data contains hotspot indication information, the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and performs traffic flow for network access after accessing the WiFi hotspot. Control and solve the problem of large background traffic consumption caused by hotspot sharing.
附图说明Description of drawings
图1为本发明实施例提供的一种热点共享的场景示意图;FIG. 1 is a schematic diagram of a hotspot sharing scenario provided by an embodiment of the present invention;
图2为本发明实施例提供的一种热点提供终端的方法流程示意图;FIG. 2 is a schematic flowchart of a method for providing a hotspot terminal according to an embodiment of the present invention;
图3为本发明实施例提供的一种更新的WiFi网络协议数据帧示意图;FIG. 3 is a schematic diagram of an updated WiFi network protocol data frame provided by an embodiment of the present invention;
图4为本发明实施例提供的另一种热点提供的方法流程示意图;FIG. 4 is a schematic flowchart of another hotspot providing method provided by an embodiment of the present invention;
图5为本发明实施例提供的一种热点接入终端的方法流程示意图;FIG. 5 is a schematic flowchart of a method for accessing a terminal by a hotspot according to an embodiment of the present invention;
图6为本发明实施例提供的一种终端显示流量控制提示界面示意图;FIG. 6 is a schematic diagram of a terminal displaying a flow control prompt interface provided by an embodiment of the present invention;
图7为本发明实施例提供的一种热点分享方法的详细流程示意意图;FIG. 7 is a schematic diagram of a detailed flow of a hotspot sharing method provided by an embodiment of the present invention;
图8为本发明实施例提供的一种热点提供终端的结构示意图;FIG. 8 is a schematic structural diagram of a hotspot providing terminal provided by an embodiment of the present invention;
图9为本发明实施例提供的一种热点接入终端结构示意图;FIG. 9 is a schematic structural diagram of a hotspot access terminal provided by an embodiment of the present invention;
图10为本发明实施例提供的另一种热点接入终端结构示意图;FIG. 10 is a schematic structural diagram of another hotspot access terminal provided by an embodiment of the present invention;
图11为本发明实施例提供的一种热点共享系统的结构示意图。FIG. 11 is a schematic structural diagram of a hotspot sharing system provided by an embodiment of the present invention.
具体实施方式Detailed ways
下面将结合本发明实施例中的附图,对发明实施例中的技术方案进行清楚、完整地描述。The following will clearly and completely describe the technical solutions in the embodiments of the invention with reference to the drawings in the embodiments of the invention.
参见图1,其示出了本发明实施例提供的一种进行热点共享的场景示意图,可以理解的,该场景仅用于说明本发明实施例的技术方案,并不对本发明实施例进行任何的具体限定。在热点分享过程中,通常包括第一终端10和第二终端20组成,两者之间通过空口网络进行通信。Referring to Fig. 1, it shows a schematic diagram of a hotspot sharing scene provided by an embodiment of the present invention. It can be understood that this scene is only used to illustrate the technical solution of the embodiment of the present invention, and does not make any implication for the embodiment of the present invention. Specific limits. During the hotspot sharing process, it usually consists of a first terminal 10 and a second terminal 20, and the two communicate through an air interface network.
基于上述场景示例,本发明实施例的基本思想是:第一终端10在开启WiFi热点功能后,所述第一终端添加热点标记信息至现有的WiFi网络协议数据,以使得第二终端20在接入第一终端10所开启的WiFi网络时,根据热点标记信息对对接入WiFi热点后的网络访问进行流量控制,从而解决热点共享造成的后台大流量消耗问题。Based on the above scenario example, the basic idea of the embodiment of the present invention is: after the first terminal 10 turns on the WiFi hotspot function, the first terminal adds hotspot tag information to the existing WiFi network protocol data, so that the second terminal 20 When accessing the WiFi network enabled by the first terminal 10, flow control is performed on network access after accessing the WiFi hotspot according to the hotspot tag information, thereby solving the problem of large background traffic consumption caused by hotspot sharing.
实施例一Embodiment one
参见图2,其示出了本发明实施例提供的一种热点提供终端的方法流程,该方法可以应用于提供WiFi热点共享的第一终端侧,该方法可以包括:Referring to FIG. 2, it shows a method flow of a hotspot providing terminal provided by an embodiment of the present invention. The method can be applied to the first terminal side that provides WiFi hotspot sharing. The method can include:
S201:第一终端开启WiFi热点;S201: the first terminal turns on the WiFi hotspot;
S202:第一终端通过将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据;S202: The first terminal acquires updated WiFi network protocol data by adding hotspot indication information to existing WiFi network protocol data;
S203:第一终端将更新的WiFi网络协议数据进行SSID广播。S203: The first terminal broadcasts the updated WiFi network protocol data on the SSID.
对于步骤S202,需要说明的是,热点指示信息用于表征更新的WiFi网络协议数据由第一终端通过WiFi热点共享提供,所述热点指示信息的具体形式可以是字符标记或者字符串标记,例如:“phoneWifiType”字符串,本发明不限于以上两种方式,还可以是其他标记方式;For step S202, it should be noted that the hotspot indication information is used to represent the updated WiFi network protocol data provided by the first terminal through WiFi hotspot sharing, and the specific form of the hotspot indication information may be a character mark or a string mark, for example: "phoneWifiType" character string, the present invention is not limited to the above two methods, and other marking methods can also be used;
优选地,将热点指示信息添加至现有的WiFi网络协议数据中,具体可以在现有的WiFi网络协议数据帧指定位置增加热点标记信息,例如,所述热点标记信息具体可以添加至WiFi网络协议数据帧的预留空位;Preferably, the hot spot indication information is added to the existing WiFi network protocol data, specifically, hot spot tag information can be added at the specified position of the existing WiFi network protocol data frame, for example, the hot spot tag information can specifically be added to the WiFi network protocol Reserved slots for data frames;
所述现有的WiFi网络协议数据及现有的WiFi网络协议数据帧对应于现有WiFi网络协议所述现有的WiFi网络协议用于表征在进行网络访问时,下载过程及后台的应用下载不需要进行用户提示。The existing WiFi network protocol data and the existing WiFi network protocol data frame correspond to the existing WiFi network protocol. The existing WiFi network protocol is used to indicate that the downloading process and background application downloading are not performed during network access. A user prompt is required.
相应地,本实施例将添加热点指示信息后的WiFi网络协议数据称为更新的WiFi网络协议数据,所述更新的WiFi网络协议数据对应的WiFi网络协议数据帧可以如图3所示;Correspondingly, in this embodiment, the WiFi network protocol data after the hotspot indication information is added is called updated WiFi network protocol data, and the WiFi network protocol data frame corresponding to the updated WiFi network protocol data can be as shown in FIG. 3 ;
其中,MAC header对应WiFi网络数据帧的头信息,Information Elements andFixed Fileds对应WiFi网络数据帧的数据体,FCS对应WiFi网络数据帧的校验位,每个字段上方的数字表示对应字段的字节长度,所述热点指示信息位于数据帧的数据体斜线填充字段,其具体标记方式可以为“phoneWifiType”字符串。Among them, MAC header corresponds to the header information of the WiFi network data frame, Information Elements and Fixed Fileds correspond to the data body of the WiFi network data frame, FCS corresponds to the check digit of the WiFi network data frame, and the number above each field indicates the byte length of the corresponding field , the hotspot indication information is located in the data body slash fill field of the data frame, and its specific marking method may be a "phoneWifiType" character string.
对于步骤S203,在具体实现过程中,第一终端可以采用空口网络对更新的WiFi网络协议数据进行SSID广播;For step S203, in the specific implementation process, the first terminal may use the air interface network to perform SSID broadcast on the updated WiFi network protocol data;
需要说明的是,SSID为其他热点接入终端搜索WiFi热点提供一个接口,其他热点接入终端通过搜索WiFi热点的SSID,可以获取SSID对应的WiFi网络协议数据,这是本领域技术人员的惯用技术手段,本发明实施例在此不作具体赘述。It should be noted that the SSID provides an interface for other hotspot access terminals to search for WiFi hotspots. Other hotspot access terminals can obtain the WiFi network protocol data corresponding to the SSID by searching for the SSID of the WiFi hotspot. This is a common technique for those skilled in the art. Means, the embodiment of the present invention will not be described in detail here.
示例性地,参见图4,第一终端通过将热点指示信息添加至WiFi网络协议数据,获取更新的WiFi网络协议数据的具体过程可以包括:Exemplarily, referring to FIG. 4, the specific process for the first terminal to obtain updated WiFi network protocol data by adding hotspot indication information to the WiFi network protocol data may include:
S2021:第一终端在开启WiFi热点之后,调用hostapd进程完成配置文件的设置;S2021: After the first terminal turns on the WiFi hotspot, call the hostapd process to complete the setting of the configuration file;
其中,所述配置文件包括:SSID、热点的物理地址(BSSID,Basic Service SetIdentifier)、认证方式和密码等信息;Wherein, the configuration file includes information such as: SSID, the physical address of the hotspot (BSSID, Basic Service SetIdentifier), authentication method and password;
S2022:第一终端通过hostapd进程指示WiFi驱动在WiFi网络协议中添加热点指示信息,获取更新的WiFi网络协议数据。S2022: The first terminal instructs the WiFi driver to add hotspot indication information in the WiFi network protocol through the hostapd process, and acquires updated WiFi network protocol data.
具体地,hostapd进程和WiFi驱动均在第一终端内部,因此,步骤S2022具体可以包括:Specifically, both the hostapd process and the WiFi driver are inside the first terminal, therefore, step S2022 may specifically include:
hostapd进程向WiFi驱动发送热点指示信息添加请求;以及,The hostapd process sends a hotspot indication information addition request to the WiFi driver; and,
WiFi驱动在WiFi网络协议数据帧的预留空位添加热点指示信息。The WiFi driver adds hotspot indication information in the reserved space of the WiFi network protocol data frame.
本实施例提供了一种热点共享方法,由于实施例中更新的WiFi网络协议数据中增加了热点指示信息,在对更新的WiFi网络协议数据进行SSID广播时,可以区别现有的WiFi网络协议数据,从而解决热点共享造成的后台大流量消耗问题。This embodiment provides a hotspot sharing method. Since hotspot indication information is added to the updated WiFi network protocol data in the embodiment, the existing WiFi network protocol data can be distinguished when performing SSID broadcast on the updated WiFi network protocol data. , so as to solve the problem of large background traffic consumption caused by hotspot sharing.
实施例二Embodiment two
参见图5,其示出了本发明实施例提供的一种热点接入终端的方法流程,该方法可以用于使用WiFi热点共享的第二终端侧,该方法可以包括:Referring to FIG. 5 , it shows a flow of a hotspot access terminal method provided by an embodiment of the present invention. The method can be used on the second terminal side using WiFi hotspot sharing. The method can include:
S501:第二终端扫描WiFi热点的SSID时,获取WiFi网络协议数据;S501: When the second terminal scans the SSID of the WiFi hotspot, obtain the WiFi network protocol data;
S502:第二终端对WiFi网络协议数据进行解析;S502: The second terminal analyzes the WiFi network protocol data;
S503:当解析的WiFi网络协议数据包含热点指示信息时,第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。S503: When the parsed WiFi network protocol data includes hotspot indication information, the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and performs flow control on network access after accessing the WiFi hotspot.
对于热点指示信息,需要说明的是,热点指示信息可以用于表征第二终端获取的WiFi网络协议数据由实施例一中第一终端提供,其具体形式可以是字符标记或者字符串标记,例如:“phoneWifiType”字符串,本发明不限于以上两种方式,还可以是其他标记方式;Regarding the hotspot indication information, it should be noted that the hotspot indication information can be used to indicate that the WiFi network protocol data acquired by the second terminal is provided by the first terminal in Embodiment 1, and its specific form can be a character mark or a string mark, for example: "phoneWifiType" character string, the present invention is not limited to the above two methods, and other marking methods can also be used;
优选地,第二终端解析的WiFi网络协议数据包含的热点指示信息,可以位于现有WiFi网络协议数据帧预留空位,例如图2所示,“phoneWifiType”字符串可以位于WiFi网络协议数据帧的预留空位;Preferably, the hotspot indication information contained in the WiFi network protocol data analyzed by the second terminal may be located in the reserved space of the existing WiFi network protocol data frame, for example, as shown in Figure 2, the "phoneWifiType" character string may be located in the WiFi network protocol data frame reserve space;
所述现有的WiFi网络协议数据帧及现有的WiFi网络协议数据对应于现有WiFi网络协议,所述现有WiFi网络协议用于表征在进行网络访问时,下载过程及后台的应用下载不需要进行用户提示。The existing WiFi network protocol data frame and the existing WiFi network protocol data correspond to the existing WiFi network protocol, and the existing WiFi network protocol is used to indicate that the download process and the application download in the background are different during network access. A user prompt is required.
对于S501,需要说明的是,第二终端对WiFi热点的SSID进行扫描,具体指第二终端是在预设距离内对WiFi热点的SSID进行扫描;For S501, it should be noted that the second terminal scans the SSID of the WiFi hotspot, specifically referring to that the second terminal scans the SSID of the WiFi hotspot within a preset distance;
所述预设距离是第二终端能够扫描到WiFi热点的最大距离,比如:可以扫描距离第二终端十米范围内的所有WiFi热点;The preset distance is the maximum distance that the second terminal can scan to WiFi hotspots, for example: all WiFi hotspots within ten meters from the second terminal can be scanned;
可以理解的,第二终端通过空口网络扫描预设范围内各WiFi热点的SSID,可能会扫描到多个WiFi热点,本发明适用于扫描到的各WiFi热点不可用或者无法通过密码连接,且必须连入第一终端通过WiFi热点共享提供的WiFi热点实现网络连接的情况。It can be understood that the second terminal scans the SSID of each WiFi hotspot within the preset range through the air interface network, and may scan multiple WiFi hotspots. Connecting to the situation where the first terminal realizes the network connection through the WiFi hotspot provided by WiFi hotspot sharing.
对于S502,需要说明的是,第二终端对所述WiFi网络协议数据的解析具体指第二终端对所述WiFi网络协议数据帧的解析,所述解析过程与现有的WiFi网络协议数据的解析过程一致,本实施例不做赘述。For S502, it should be noted that the analysis of the WiFi network protocol data by the second terminal specifically refers to the analysis of the WiFi network protocol data frame by the second terminal, and the analysis process is different from the analysis of the existing WiFi network protocol data. The process is the same, and will not be repeated in this embodiment.
对于图5所示的技术方案,需要说明的是,当WiFi网络协议数据不包含热点指示信息时,所述图5的技术方案还可以包括:第二终端接入WiFi热点,并按照现有的WiFi热点连接方式进行连接;可以理解地,当第二终端按照现有的WiFi热点连接方式进行连接时,第二终端按照正常的WiFi连接进行网络访问,比如,第二终端下载过程及后台的应用下载不需要进行用户提示。For the technical solution shown in Figure 5, it should be noted that when the WiFi network protocol data does not contain hotspot indication information, the technical solution in Figure 5 may also include: the second terminal accesses the WiFi hotspot, and according to the existing WiFi hotspot connection; understandably, when the second terminal connects according to the existing WiFi hotspot connection, the second terminal performs network access according to the normal WiFi connection, for example, the download process of the second terminal and the application in the background Downloads do not require user prompting.
示例性地,第二终端对接入WiFi热点后的网络访问进行流量控制,可以包括:Exemplarily, the second terminal controls the flow of network access after accessing the WiFi hotspot, which may include:
所述第二终端需要进行流量使用时,所述第二终端显示提示消息;其中,所述提示消息用于提示是否进行流量使用,具体包括:When the second terminal needs to use traffic, the second terminal displays a prompt message; wherein, the prompt message is used to prompt whether to use traffic, specifically including:
当所述第二终端接收到针对所述提示消息的第一响应指令时,所述第二终端提示用户进行确定下载,且断开用户的后台应用下载数据;When the second terminal receives the first response instruction for the prompt message, the second terminal prompts the user to confirm the download, and disconnects the user's background application to download data;
当所述第二终端接收到针对所述提示消息的第二响应指令时,所述第二终端下载过程及后台的应用下载不需要进行用户提示。When the second terminal receives the second response instruction to the prompt message, the downloading process of the second terminal and the background application downloading do not require user prompting.
具体地,当第二终端接入实施例一中第一终端提供的WiFi热点,并且第二终端需要进行流量使用时,第二终端可以向用户发送提示消息,用于提示用户是否进行流量使用;在具体实现过程中,可以通过在第二终端的显示屏幕上以对话框进行提示,具体进行提示的终端显示界面如图6所示。Specifically, when the second terminal accesses the WiFi hotspot provided by the first terminal in Embodiment 1, and the second terminal needs to use traffic, the second terminal may send a prompt message to the user to prompt the user whether to use traffic; In a specific implementation process, a dialog box may be used to prompt on the display screen of the second terminal, and the specific terminal display interface for prompting is shown in FIG. 6 .
本实施例提供了一种热点共享方法,由于本实施例中第二终端通过解析WiFi网络协议数据,确定WiFi网络协议数据中包含热点指示信息,第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制,从而解决热点共享造成的后台大流量消耗问题。This embodiment provides a hotspot sharing method. Since the second terminal in this embodiment determines that the WiFi network protocol data contains hotspot indication information by analyzing the WiFi network protocol data, the second terminal accesses the WiFi network protocol data corresponding to the WiFi hotspot, and control the flow of network access after accessing the WiFi hotspot, so as to solve the problem of large background traffic consumption caused by hotspot sharing.
实施例三Embodiment Three
参见图7,其示出了本发明实施例提供的一种热点共享方法的详细流程,该方法可以用于提供WiFi热点共享的第一终端及使用WiFi热点共享的第二终端,该详细流程可以包括:Referring to FIG. 7 , it shows a detailed flow of a hotspot sharing method provided by an embodiment of the present invention. The method can be used to provide a first terminal for WiFi hotspot sharing and a second terminal for using WiFi hotspot sharing. The detailed flow can be include:
S701:第一终端开启WiFi热点;S701: the first terminal turns on the WiFi hotspot;
S702:第一终端在现有的WiFi网络协议数据帧的预留空位添加“phoneWifiType”字符串,获取更新的WiFi网络协议数据;S702: The first terminal adds a "phoneWifiType" character string to the reserved space of the existing WiFi network protocol data frame to obtain updated WiFi network protocol data;
在本实施例中,“phoneWifiType”字符串用于表征第一终端通过WiFi热点共享提供的WiFi网络协议数据为更新的WiFi网络协议数据,以及用于表征第二终端获取的WiFi热点网络协议由第一终端通过WiFi热点共享提供;In this embodiment, the "phoneWifiType" character string is used to indicate that the WiFi network protocol data provided by the first terminal through WiFi hotspot sharing is updated WiFi network protocol data, and is used to indicate that the WiFi hotspot network protocol obtained by the second terminal is obtained by the second terminal. One terminal is provided through WiFi hotspot sharing;
其中,用于表征更新的WiFi网络协议数据由热点提供终端通过WiFi热点共享提供的标记信息可以称为热点标记信息,“phoneWifiType”字符串作为热点标记信息的一种具体方式,还可以采用字符形式进行标记,本发明不限于以上两种方式,还可以是其他标记方式;Among them, the WiFi network protocol data used to represent the update is provided by the hotspot provider terminal through WiFi hotspot sharing and can be called hotspot tag information, and the "phoneWifiType" string is a specific way of hotspot tag information, and it can also be in the form of characters To mark, the present invention is not limited to the above two ways, and other marking ways are also possible;
以及,所述现有的WiFi网络协议数据帧对应于现有WiFi网络协议,所述现有的WiFi网络协议用于表征在进行网络访问时,下载过程及后台的应用下载不需要进行用户提示。And, the existing WiFi network protocol data frame corresponds to the existing WiFi network protocol, and the existing WiFi network protocol is used to indicate that the download process and background application download do not require user prompts during network access.
S703:第一终端将更新的WiFi网络协议数据通过空口网络进行SSID广播;S703: The first terminal broadcasts the updated WiFi network protocol data through the air interface network for the SSID;
对于步骤S703,需要说明的是,空口网络作为无线通讯中一种常用的技术手段,第一终端与第二终端的通讯方式还可以采用蓝牙或者其他通讯方式,本发明对第一终端侧与第二终端侧的通讯方式不作具体限定;Regarding step S703, it should be noted that the air interface network is a commonly used technical means in wireless communication, and the communication method between the first terminal and the second terminal can also adopt Bluetooth or other communication methods. The communication method on the second terminal side is not specifically limited;
以及,所述现有的WiFi网络协议数据对应于现有WiFi网络协议,所述现有的WiFi网络协议用于表征在进行网络访问时,下载过程及后台的应用下载不需要进行用户提示。And, the existing WiFi network protocol data corresponds to the existing WiFi network protocol, and the existing WiFi network protocol is used to indicate that the downloading process and background application download do not require user prompts during network access.
S704:第二终端扫描预设距离内WiFi热点的SSID时,获取第一终端WiFi热点的SSID对应的WiFi网络协议数据;S704: When the second terminal scans the SSID of the WiFi hotspot within the preset distance, acquire the WiFi network protocol data corresponding to the SSID of the WiFi hotspot of the first terminal;
对于步骤S704,需要说明的是,第二终端是进行预设距离内WiFi热点的SSID扫描,所述的预设距离是第二终端可以扫描到WiFi热点的最大距离,比如:可以扫描距离第二终端十米范围内的所有WiFi热点;For step S704, it should be noted that the second terminal scans the SSID of WiFi hotspots within a preset distance. The preset distance is the maximum distance that the second terminal can scan to WiFi hotspots. All WiFi hotspots within ten meters of the terminal;
以及,第二终端扫描到各WiFi热点的SSID之后,第二终端可以将SSID作为连接热点的入口,获取所述SSID对应WiFi网络协议数据;And, after the second terminal scans the SSID of each WiFi hotspot, the second terminal can use the SSID as an entry to connect to the hotspot, and obtain the WiFi network protocol data corresponding to the SSID;
可以理解的,第二终端扫描WiFi热点的SSID时,第一终端在第二终端的扫描范围内,保证第二终端通过空口网络可以扫描到第一终端的SSID,获取所述SSID对应WiFi网络协议数据。It can be understood that when the second terminal scans the SSID of the WiFi hotspot, the first terminal is within the scanning range of the second terminal to ensure that the second terminal can scan the SSID of the first terminal through the air interface network, and obtain the WiFi network protocol corresponding to the SSID data.
S705:第二终端对第一终端的WiFi网络协议数据进行解析;并确定所述WiFi网络协议数据帧中是否存在“phoneWifiType”字符串;当存在时,转至S706;否则转至S707;S705: The second terminal analyzes the WiFi network protocol data of the first terminal; and determines whether there is a "phoneWifiType" character string in the WiFi network protocol data frame; if yes, go to S706; otherwise, go to S707;
S706:第二终端接入第一终端的WiFi网络协议数据对应的WiFi热点,并对接入WIFI热点后的网络访问进行流量控制;当第二终端接入第一终端WiFi网络协议数据对应的WiFi热点后,具体流量控制方式可以为:使用流量的时候提示用户进行确定下载,且断开用户的后台应用下载数据;S706: The second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data of the first terminal, and performs flow control on network access after accessing the WiFi hotspot; when the second terminal accesses the WiFi corresponding to the WiFi network protocol data of the first terminal After the hotspot, the specific flow control method can be: when using the flow, prompt the user to confirm the download, and disconnect the user's background application to download data;
S707:第二终端接入第一终端的WiFi热点,并按照正常的WiFi热点连接方式进行连接;可以理解地,当第二终端按照现有的WiFi热点连接方式进行连接后,第二终端按照正常的WiFi连接进行网络访问,比如,第二终端下载过程及后台的应用下载不需要进行用户提示;S707: The second terminal accesses the WiFi hotspot of the first terminal, and connects according to the normal WiFi hotspot connection method; WiFi connection for network access, for example, the download process of the second terminal and the application download in the background do not need to prompt the user;
S708:第二终端完成热点连接。S708: The second terminal completes the hotspot connection.
本实施例提供了一种手机热点分享的详细流程,第一终端将添加了热点指示信息的WiFi网络协议数据进行SSID广播,第二终端扫描到所述第一终端的SSID,获取所述SSID对应的WiFi网络协议数据,解析所述WiFi网络协议数据包含热点标记信息,第二终端确认接入的WiFi热点由第一终端通过WiFi热点共享提供,所述第二终端接入第一终端对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制,从而解决热点共享造成的后台大流量消耗问题。This embodiment provides a detailed flow of mobile phone hotspot sharing. The first terminal broadcasts the WiFi network protocol data with hotspot indication information added to the SSID, and the second terminal scans the SSID of the first terminal to obtain the SSID corresponding to the SSID. WiFi network protocol data, analyzing the WiFi network protocol data contains hotspot tag information, the second terminal confirms that the accessed WiFi hotspot is provided by the first terminal through WiFi hotspot sharing, and the second terminal accesses the WiFi corresponding to the first terminal Hotspots, and control the flow of network access after accessing WiFi hotspots, so as to solve the problem of large background traffic consumption caused by hotspot sharing.
实施例四Embodiment four
基于前述实施例相同的技术构思,参见图8,其示出了本发明实施例的第一终端80,其特征在于,所述第一终端80包括:开启模块801、第一获取模块802及广播模块803,其中,Based on the same technical idea of the foregoing embodiments, referring to FIG. 8 , it shows a first terminal 80 according to an embodiment of the present invention, wherein the first terminal 80 includes: an opening module 801, a first obtaining module 802 and a broadcast module 803, wherein,
开启模块801,用于开启WiFi热点;Turn on the module 801, which is used to turn on the WiFi hotspot;
第一获取模块801,用于将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据;The first acquisition module 801 is configured to add hotspot indication information to existing WiFi network protocol data, and obtain updated WiFi network protocol data;
广播模块802,用于将更新的WiFi网络协议数据进行SSID广播。The broadcast module 802 is configured to broadcast the updated WiFi network protocol data on the SSID.
在上述方案中,热点指示信息,具体用于:In the above solution, the hotspot indication information is specifically used for:
表征更新的WiFi网络协议数据由第一终端通过WiFi热点共享提供,所述热点指示信息的具体形式可以是字符标记或者字符串标记,例如:“phoneWifiType”字符串,本发明不限于以上两种方式,还可以是其他标记方式;The updated WiFi network protocol data is provided by the first terminal through WiFi hotspot sharing, and the specific form of the hotspot indication information can be a character mark or a character string mark, for example: "phoneWifiType" character string, the present invention is not limited to the above two methods , can also be other marking methods;
优选地,将热点指示信息添加至现有的WiFi网络协议数据中,具体可以在现有的WiFi网络协议数据帧指定位置增加热点标记信息,例如,所述热点标记信息具体可以添加至WiFi网络协议数据帧的预留空位。Preferably, the hot spot indication information is added to the existing WiFi network protocol data, specifically, hot spot tag information can be added at the specified position of the existing WiFi network protocol data frame, for example, the hot spot tag information can specifically be added to the WiFi network protocol Reserved slots for data frames.
所述现有的WiFi网络协议数据及现有的WiFi网络协议数据帧对应于现有WiFi网络协议,所述现有的WiFi网络协议用于表征在进行网络访问时,下载过程及后台的应用下载不需要进行用户提示。The existing WiFi network protocol data and the existing WiFi network protocol data frame correspond to the existing WiFi network protocol, and the existing WiFi network protocol is used to characterize the download process and the background application download when performing network access No user prompting is required.
所述第一获取模块802,具体用于:The first obtaining module 802 is specifically used for:
调用hostapd进程完成配置文件的设置;其中,所述配置文件包括:SSID、热点的物理地址(BSSID,Basic Service Set Identifier)、认证方式和密码等信息;Call hostapd process to finish the setting of configuration file; Wherein, described configuration file includes: the physical address (BSSID, Basic Service Set Identifier) of SSID, hotspot, information such as authentication mode and password;
以及,通过hostapd进程指示WiFi驱动在WiFi网络协议中添加热点指示信息,获取更新的WiFi网络协议数据。And, the hostapd process instructs the WiFi driver to add hotspot indication information in the WiFi network protocol to obtain updated WiFi network protocol data.
相应地,所述广播模块803,具体用于:Correspondingly, the broadcast module 803 is specifically used for:
将更新的WiFi网络协议数据通过空口网络进行SSID广播。Broadcast the updated WiFi network protocol data through the air interface network for SSID.
本实施例提供的第一终端80,由于实施例中更新的WiFi网络协议数据中添加了热点指示信息,在对更新的WiFi网络协议数据进行SSID广播时,可以区别现有的WiFi网络协议数据,从而解决热点共享造成的后台大流量消耗问题。The first terminal 80 provided in this embodiment, since the hotspot indication information is added to the updated WiFi network protocol data in the embodiment, when performing SSID broadcast on the updated WiFi network protocol data, it can distinguish the existing WiFi network protocol data, So as to solve the problem of large background traffic consumption caused by hotspot sharing.
实施例五Embodiment five
基于前述实施例相同的技术构思,参见图9,其示出了本发明实施例的第二终端90,其特征在于,所述第二终端90包括:扫描模块901、第二获取模块902、解析模块903及控制模块904,其中,Based on the same technical idea of the foregoing embodiments, referring to FIG. 9 , it shows a second terminal 90 according to an embodiment of the present invention, wherein the second terminal 90 includes: a scanning module 901, a second acquiring module 902, an analysis module Module 903 and control module 904, wherein,
扫描模块901,用于扫描WiFi热点的SSID;Scanning module 901, for scanning the SSID of WiFi hotspot;
第二获取模块902,用于当所述扫描模块扫描WiFi热点的SSID时,获取WiFi网络协议数据;The second obtaining module 902 is used to obtain WiFi network protocol data when the scanning module scans the SSID of the WiFi hotspot;
解析模块903,用于对WiFi网络协议数据进行解析;Parsing module 903, for parsing WiFi network protocol data;
控制模块904,用于当解析的WiFi网络协议数据包含热点指示信息时,接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。The control module 904 is configured to access the WiFi hotspot corresponding to the WiFi network protocol data when the parsed WiFi network protocol data contains hotspot indication information, and control the flow of network access after accessing the WiFi hotspot.
在上述方案中,对于热点指示信息,具体用于表征第二终端获取的WiFi网络协议数据由实施例四中广播模块提供,其具体形式可以是字符标记或者字符串标记,例如:“phoneWifiType”字符串,本发明不限于以上两种方式,还可以是其他标记方式;In the above solution, for the hotspot indication information, the WiFi network protocol data specifically used to characterize the acquisition of the second terminal is provided by the broadcast module in Embodiment 4, and its specific form may be a character mark or a string mark, for example: "phoneWifiType" character String, the present invention is not limited to the above two methods, but also other marking methods;
优选地,第二终端解析的WiFi网络协议数据包含的热点指示信息,可以位于现有的WiFi网络协议数据帧的指定位置,例如图2所示,“phoneWifiType”字符串可以位于WiFi网络协议数据帧的预留空位;Preferably, the hotspot indication information contained in the WiFi network protocol data analyzed by the second terminal may be located at a specified position of an existing WiFi network protocol data frame, for example, as shown in FIG. 2, the "phoneWifiType" character string may be located in a WiFi network protocol data frame reserved space for
所述现有的WiFi网络协议数据帧对应于现有WiFi网络协议,所述现有的WiFi网络协议用于表征在进行网络访问时,下载过程及后台的应用下载不需要进行用户提示。The existing WiFi network protocol data frame corresponds to the existing WiFi network protocol, and the existing WiFi network protocol is used to indicate that the download process and background application download do not require user prompts during network access.
对于扫描模块901,具体用于:For the scanning module 901, it is specifically used for:
对WiFi热点的SSID进行扫描具体指第二终端是在预设距离内对WiFi热点的SSID进行扫描;Scanning the SSID of the WiFi hotspot specifically means that the second terminal scans the SSID of the WiFi hotspot within a preset distance;
所述的预设距离是第二终端能够扫描到WiFi热点的最大距离,比如:可以扫描距离第二终端十米范围内的所有WiFi热点。The preset distance is the maximum distance that the second terminal can scan to WiFi hotspots, for example, all WiFi hotspots within ten meters away from the second terminal can be scanned.
对于解析模块902,具体用于:For the parsing module 902, it is specifically used for:
对所述WiFi网络协议数据帧的解析,所述解析过程与现有的WiFi网络协议数据的解析过程一致;For the analysis of the WiFi network protocol data frame, the analysis process is consistent with the analysis process of the existing WiFi network protocol data;
所述现有的WiFi网络协议数据对应于现有WiFi网络协议,所述现有的WiFi网络协议用于表征在进行网络访问时,下载过程及后台的应用下载不需要进行用户提示。The existing WiFi network protocol data corresponds to the existing WiFi network protocol, and the existing WiFi network protocol is used to indicate that the download process and background application download do not require user prompts during network access.
对于本实施例,需要说明的是,当WiFi网络协议数据不包含热点指示信息时,参见图10,所述第二终端还包括接入模块905,用于接入WiFi热点,并按照现有的WiFi热点连接方式进行连接,进一步地,接入模块905具体用于:For this embodiment, it should be noted that when the WiFi network protocol data does not contain hotspot indication information, see FIG. 10, the second terminal further includes an access module 905 for accessing a WiFi hotspot, WiFi hotspot connection mode to connect, further, the access module 905 is specifically used for:
按照现有的WiFi热点连接方式进行连接后,进行网络访问时下载过程及后台的应用下载时不需要进行用户提示。After connecting according to the existing WiFi hotspot connection mode, there is no need for user prompts during the downloading process during network access and background application downloading.
进一步地,对于控制模块904,具体用于:Further, for the control module 904, it is specifically used for:
当需要进行流量使用时,显示提示消息;其中,所述提示消息用于提示是否进行流量使用,具体包括:When traffic usage is required, a prompt message is displayed; wherein, the prompt message is used to prompt whether to use traffic, specifically including:
当接收到针对所述提示消息的第一响应指令时,提示用户进行确定下载,且断开用户的后台应用下载数据;When receiving the first response instruction for the prompt message, prompt the user to confirm the download, and disconnect the user's background application to download data;
当接收到针对所述提示消息的第二响应指令时,在下载过程及后台的应用下载时不需要进行用户提示。When the second response instruction to the prompt message is received, no user prompt is required during the download process and background application download.
本实施例提供的第二终端90,解析模块903解析WiFi网络协议数据,控制模块904确定WiFi网络协议数据中包含热点指示信息时,接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制,从而解决热点共享造成的后台大流量消耗问题。In the second terminal 90 provided in this embodiment, the analysis module 903 analyzes the WiFi network protocol data, and the control module 904 determines that the WiFi network protocol data contains hotspot indication information, accesses the WiFi hotspot corresponding to the WiFi network protocol data, and connects After entering the WiFi hotspot, the network access is controlled to solve the problem of large background traffic consumption caused by hotspot sharing.
此外,基于前述实施例相同的技术构思,参见图11,本发明实施例还提供了一种热点共享系统110,该系统包括用于提供WiFi热点共享的第一终端80和用于使用WiFi热点共享的第二终端90,其中,In addition, based on the same technical concept as the foregoing embodiments, referring to FIG. 11 , the embodiment of the present invention also provides a hotspot sharing system 110, which includes a first terminal 80 for providing WiFi hotspot sharing and a terminal 80 for using WiFi hotspot sharing. The second terminal 90, wherein,
第一终端80,用于开启WiFi热点;以及,The first terminal 80 is used to open a WiFi hotspot; and,
通过将热点指示信息添加至现有的WiFi网络协议数据,获取更新的WiFi网络协议数据;以及,Obtain updated WiFi network protocol data by adding hotspot indication information to existing WiFi network protocol data; and,
将更新的WiFi网络协议数据进行SSID广播;Broadcast the updated WiFi network protocol data to SSID;
第二终端90,用于扫描WiFi热点的SSID时,获取WiFi网络协议数据;以及,The second terminal 90 is used to acquire WiFi network protocol data when scanning the SSID of the WiFi hotspot; and,
对WiFi网络协议数据进行解析;以及,parsing the WiFi network protocol data; and,
当解析的WiFi网络协议数据包含热点指示信息时,第二终端接入所述WiFi网络协议数据对应的WiFi热点,并对接入WiFi热点后的网络访问进行流量控制。When the analyzed WiFi network protocol data contains hotspot indication information, the second terminal accesses the WiFi hotspot corresponding to the WiFi network protocol data, and performs flow control on network access after accessing the WiFi hotspot.
本领域内的技术人员应该明白,本发明的实施例可提供方法、系统、或者计算机程序产品。因此,本发明可采用硬件实施例、软件实施例、获结合软件和硬件方面的实施例的形式。而且,本发明可采用在一个或多个其中包含由计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art should understand that the embodiments of the present invention may provide methods, systems, or computer program products. Accordingly, the present invention can take the form of a hardware embodiment, a software embodiment, an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage and optical storage, etc.) having computer-usable program code embodied therein.
本发明时参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现程序图和/或方框图中每一流程和/获方框、以及流程图和/或方框图中的流程和/或的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或者其他可编程数据处理设备的处理器易产生一个机器,是的通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或者多个方框中指定的功能的装置。The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It should be understood that each flow and/or block in the program diagram and/or block diagram, and the flow and/or combinations in the flowchart and/or block diagram can be realized by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, special purpose computer, embedded processor, or other programmable data processing device to produce a machine, yes, generated by the instructions executed by the processor of the computer or other programmable data processing device Means for realizing the functions specified in one or more procedures of the flowchart and/or one or more blocks of the block diagram.
这些计算机程序指令也可以存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算及可读存储器中的指令产生包括指令装置的制造品。该指令装置实现在流程图中一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in computer readable memory capable of directing a computer or other programmable data processing apparatus to operate in a specific manner, such that the instructions stored in the computing and readable memory produce an article of manufacture comprising instruction means. The instruction means implements the functions specified in one or more procedures in the flowchart and/or one or more blocks in the block diagram.
这些计算机程序指令也可装载在计算机或其他可编程处理设备上,使得在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded on a computer or other programmable processing equipment, so that the instructions executed on the computer or other programmable equipment are used to implement a process or multiple processes in the flowchart and/or a block in the block diagram or Steps for functions specified in multiple boxes.
以上,仅为本发明的较佳实施例而已,并非用于限定本发明的保护范围。The above are only preferred embodiments of the present invention, and are not intended to limit the protection scope of the present invention.
Claims (23)
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610754318.8A CN108307359A (en) | 2016-08-29 | 2016-08-29 | A kind of method, terminal and system that hot spot is shared |
PCT/CN2017/085229 WO2018040621A1 (en) | 2016-08-29 | 2017-05-19 | Hotspot sharing method, terminal, system and computer storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610754318.8A CN108307359A (en) | 2016-08-29 | 2016-08-29 | A kind of method, terminal and system that hot spot is shared |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108307359A true CN108307359A (en) | 2018-07-20 |
Family
ID=61301353
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610754318.8A Pending CN108307359A (en) | 2016-08-29 | 2016-08-29 | A kind of method, terminal and system that hot spot is shared |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN108307359A (en) |
WO (1) | WO2018040621A1 (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2020083346A1 (en) * | 2018-10-26 | 2020-04-30 | 中兴通讯股份有限公司 | Method and apparatus for controlling terminal device, and terminal device readable storage medium |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111970676B (en) * | 2019-05-20 | 2023-07-18 | 北京小米移动软件有限公司 | WiFi hot spot access method, device, equipment and storage medium |
US11190597B1 (en) | 2020-07-09 | 2021-11-30 | International Business Machines Corporation | Network bandwidth sharing |
CN113472611A (en) * | 2021-07-26 | 2021-10-01 | 东莞市金锐显数码科技有限公司 | Method and device for acquiring WiFi signal strength and readable storage medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2013031144A (en) * | 2011-07-27 | 2013-02-07 | Visionalist Co Ltd | Simple-operation-type system and program for radio data transmission/reception |
JP2013131993A (en) * | 2011-12-22 | 2013-07-04 | Nec Access Technica Ltd | Radio access point device, radio access point connection method, and radio access point connection program |
CN104363588A (en) * | 2014-11-19 | 2015-02-18 | 贵州万臻时代通讯技术有限公司 | Mobile terminal internet access control method and mobile terminal |
CN105430713A (en) * | 2015-11-30 | 2016-03-23 | 东莞酷派软件技术有限公司 | A wireless fidelity WiFi hotspot identification method and terminal |
CN105451269A (en) * | 2014-07-04 | 2016-03-30 | 阿里巴巴集团控股有限公司 | Wireless internet access traffic control method and device |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103167581A (en) * | 2011-12-14 | 2013-06-19 | 北京千橡网景科技发展有限公司 | Method and device for utilizing shared network connection information to access to short distance wireless network |
CN103096384B (en) * | 2012-12-17 | 2016-04-06 | 东莞宇龙通信科技有限公司 | Limit the method from machine surfing flow and system thereof |
CN103402230A (en) * | 2013-08-14 | 2013-11-20 | 杭州浦禾通信技术有限公司 | Method and system for surfing Internet through mobile hot spots |
US20150270879A1 (en) * | 2014-04-22 | 2015-09-24 | Magnolia Broadband Inc. | System and method for explicit channel sounding between access points |
-
2016
- 2016-08-29 CN CN201610754318.8A patent/CN108307359A/en active Pending
-
2017
- 2017-05-19 WO PCT/CN2017/085229 patent/WO2018040621A1/en active Application Filing
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2013031144A (en) * | 2011-07-27 | 2013-02-07 | Visionalist Co Ltd | Simple-operation-type system and program for radio data transmission/reception |
JP2013131993A (en) * | 2011-12-22 | 2013-07-04 | Nec Access Technica Ltd | Radio access point device, radio access point connection method, and radio access point connection program |
CN105451269A (en) * | 2014-07-04 | 2016-03-30 | 阿里巴巴集团控股有限公司 | Wireless internet access traffic control method and device |
CN104363588A (en) * | 2014-11-19 | 2015-02-18 | 贵州万臻时代通讯技术有限公司 | Mobile terminal internet access control method and mobile terminal |
CN105430713A (en) * | 2015-11-30 | 2016-03-23 | 东莞酷派软件技术有限公司 | A wireless fidelity WiFi hotspot identification method and terminal |
Non-Patent Citations (2)
Title |
---|
全国计算机专业技术之歌考试真题研究组: "《全国计算机技术与软件专业技术资格(水平)考试历年真题必练 含关键考点点评 网络设计师 第2版》", 30 June 2015 * |
王江伟,刘青: "《玩转树莓派》", 30 September 2013 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2020083346A1 (en) * | 2018-10-26 | 2020-04-30 | 中兴通讯股份有限公司 | Method and apparatus for controlling terminal device, and terminal device readable storage medium |
CN111107614A (en) * | 2018-10-26 | 2020-05-05 | 中兴通讯股份有限公司 | Terminal device control method and device and terminal device readable storage medium |
CN111107614B (en) * | 2018-10-26 | 2022-03-04 | 中兴通讯股份有限公司 | Terminal device control method and device and terminal device readable storage medium |
Also Published As
Publication number | Publication date |
---|---|
WO2018040621A1 (en) | 2018-03-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP4007321A1 (en) | Information sharing method, terminal apparatus, storage medium, and computer program product | |
CN102448064B (en) | By the access of non-3 GPP access network | |
KR101663011B1 (en) | Terminal and method for processing tethering service thereof | |
US11039299B2 (en) | ESIM card activation method, wireless router, and user terminal | |
CN111954208B (en) | Secure communication method and device | |
CN107529160B (en) | VoWiFi network access method and system, terminal and wireless access point equipment | |
US20200288331A1 (en) | Method and apparatus for connecting to access point in wlan network | |
CN109041140B (en) | Method for rapidly switching wireless network, intelligent hardware and terminal equipment | |
ES2989346T3 (en) | Wireless network channel usage indication | |
CN108307359A (en) | A kind of method, terminal and system that hot spot is shared | |
CN110798814B (en) | Indirect communication method, relay node, network equipment and system | |
US9241232B2 (en) | Method and apparatus for machine communication | |
KR101460766B1 (en) | A security setting system and its control method using a cluster function in a wireless network system | |
CN104853410A (en) | Network access method and mobile communication terminal | |
WO2016179966A1 (en) | Method for realizing network access, terminal and computer storage medium | |
EP3585106A1 (en) | Method and apparatus for processing service set identifier, and terminal | |
EP3651040A1 (en) | Apparatus and method for remotely managing devices, and program therefor | |
CN116600250B (en) | Network access mode determining method, device, equipment, medium and product | |
CN109219045A (en) | A kind of router connection method, device, electronic equipment and system | |
CN108156602A (en) | For the method, apparatus and wireless access points with terminal equipment in communication | |
CN109275125B (en) | Resource sharing method, device, equipment and storage medium | |
WO2016112706A1 (en) | Hotspot accessing method and device, and terminal | |
CN114125919B (en) | Test method and device | |
CN114222353B (en) | Method and device for fast network access and electronic equipment | |
WO2018149136A1 (en) | Wireless fidelity (wifi) connection method and related product |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20180720 |
|
RJ01 | Rejection of invention patent application after publication |