Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. 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 invention.
Fig. 1 is a schematic block diagram of a communication system of an embodiment of the present invention. As shown in fig. 1, a communication system of an embodiment of the present invention may include a first mobile terminal and a second mobile terminal. The second mobile terminal is a mobile terminal for establishing a Wireless Fidelity (WIFI) hotspot, and an internal module of the second mobile terminal can comprise a Setting module (Setting), a frame module (Framework) and a WIFI hotspot module (WIFI hotspot); the Setting module (Setting) is positioned at the application layer and used for Setting and managing the WIFI hotspot; the WIFI hotspot module (WIFI HotPoint) is positioned on a WIFI driving layer and used for establishing a WIFI hotspot; the Framework module (Framework) is located between the application layer and the drive layer and used for a Setting module (Setting) of the packaging application layer to call a call interface of a WIFI hotspot module (WIFI HotPoint) of the drive layer. The first mobile terminal is a mobile terminal accessed to a WIFI hotspot, and internal modules of the first mobile terminal can comprise an Application (APP), a Framework module (Framework) and a WIFI Driver module (WIFI Driver); the APP is positioned in an application layer and can perform related data flow operation according to the type of an access network; the WIFI Driver module (WIFI Driver) is positioned on the Driver layer and used for acquiring WIFI network information of the accessed WIFI hotspot; the Framework module (Framework) is located between the application layer and the drive layer and used for packaging a calling interface of WIFI network information of an APP access drive layer of the application layer and a WIFI hotspot module (WIFI HotPoint), and the Framework module (Framework) can transmit the underlying network information to the APP of the application layer.
In the communication system in the prior art, a system framework shown in fig. 1 may be adopted to implement a process of accessing a first mobile terminal to a WIFI hotspot established by a second mobile terminal. However, in the prior art, the first mobile terminal cannot identify whether the accessed WIFI hotspot is a self-established WIFI hotspot of the mobile terminal, and some applications related to large-traffic operation may be started, so that traffic of the mobile data network of the second mobile terminal is greatly consumed.
In order to solve the problem that a large amount of traffic of a mobile data network is consumed due to the fact that a WIFI hotspot established by a mobile terminal cannot be identified, the embodiment of the invention provides a mobile data sharing method and the mobile terminal.
The mobile data sharing method and the mobile terminal of the embodiment of the present invention can be extended on the system framework of the embodiment shown in fig. 1, for example, a WIFI hotspot module (WIFI hotspot) of the second mobile terminal can extend WIFI network information, and identify a network type and the like in an extension parameter of the WIFI network information; for another example, the Framework module (Framework) of the first mobile terminal may transfer the underlying network information to the APP of the application layer by means of an extended field or a virtual network, and so on. Of course, it should be understood that the system block diagram of the communication system shown in fig. 1 is only one application scenario of the embodiment of the present invention, and the embodiment of the present invention is not limited thereto. The method of the embodiment of the present invention is described below with reference to the system block diagram of fig. 1.
It should be understood that the first mobile terminal mentioned throughout the present disclosure represents a mobile terminal accessing a WIFI hotspot, and the second mobile terminal mentioned throughout the present disclosure represents a mobile terminal establishing a WIFI hotspot, and will not be described again.
Fig. 2 is a schematic diagram of a mobile data sharing method according to an embodiment of the invention. The method of fig. 2 is performed by a first mobile terminal. In the embodiment of the invention, the first mobile terminal can be mobile terminal equipment such as a smart phone. The first mobile terminal of the embodiment of the present invention may be the first mobile terminal of the embodiment shown in fig. 1.
And 201, sending a first request to a WIFI hotspot, wherein the first request is used for accessing the WIFI hotspot, and the WIFI hotspot is a self-established WIFI hotspot of a second mobile terminal.
The first mobile terminal can send a first request to a WIFI hotspot established by the second mobile terminal to request to access the WIFI hotspot.
For example, in a typical access manner, a first mobile terminal may request access to a WIFI hotspot by: the method comprises the steps that a first mobile terminal obtains an accessible WIFI hotspot list by scanning hotspots; the method comprises the steps that a first mobile terminal selects one WIFI hotspot from WIFI hotspots to send an access request to access the WIFI hotspot; and the WIFI hotspot allows the first mobile terminal to access according to the access request of the first mobile terminal, and feeds back the response of the access request to the first mobile terminal.
Taking the android system as an example, in the android in the prior art, a list of wiconfiguration objects can be returned by a wifimanager.
202, receiving WIFI network information of the WIFI hotspot, wherein the WIFI network information carries tag information indicating that the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal.
The WIFI network information of the embodiment of the invention can be expanded in the information of the WIFI network information transmission in the prior art. In the WIFI network information, except for the tag information, the rest may be similar to the WIFI network information of the WIFI hotspot acquired by the mobile terminal in the prior art.
Optionally, in a specific embodiment, the WIFI network information is WIFI network information of a WIFI hotspot acquired by the first mobile terminal in a stage of scanning the WIFI hotspot.
Taking an Android system as an example, in an Android system in the prior art, after a first mobile terminal enters a Setting module (Setting) and clicks a Scan (Scan), a startScan method of WifiManager is called, and after a Scan process is finished, a Scan result can be obtained through a WifiNative Scan result method. At this time, Service Set Identifier (SSID) parameters, Channel parameters, and the like of the WIFI hotspot may be obtained. The SSID parameter includes a Basic Service Set Identifier (BSSID) parameter indicating a Media Access Control (MAC) address of the WIFI hotspot, and an Extended Service Set Identifier (ESSID) parameter indicating a name of the WIFI hotspot. In the scanResults method of the Android system, BSSID parameter is usually BSSID, ESSID, and Channel parameter is freq.
In the embodiment of the invention, identification information can be added to the WIFI network information fed back by the scanResults to indicate whether the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal, and the expanded bit is the marking information of the embodiment of the invention. Of course, the use of other ways of representing the label information is not excluded. If the WIFI hotspot is not the self-established WIFI hotspot of the mobile terminal, the marking information can be omitted.
In the embodiment of the present invention, step 202 may be performed before step 201.
Optionally, in another specific embodiment, the WIFI network information is WIFI network information that is fed back by the WIFI hotspot according to the first request of step 201.
Also taking the Android system as an example, in the Android system in the prior art, the SDK of the Android provides a WifiInfo object, which can be obtained through wifimanager. Through WIFIInfo, the first mobile terminal may obtain basic service set identification BSSID attributes, Internet Protocol (IP) address, connection speed, MAC address, signal of 802.11n network, SSID, and the like. The calling mode is shown in table 1:
table 1:
calling a function
|
Returning content
|
getBSSID()
|
Obtaining BSSID attributes
|
getDetailedStateOf()
|
Obtaining connectivity of a client
|
getHiddenSSID()
|
Obtaining whether SSID is hidden
|
getIpAddress()
|
Obtaining an IP address
|
getLinkSpeed()
|
Obtaining speed of connection
|
getMacAddress()
|
Obtaining a Mac address
|
getRssi()
|
Obtaining signals for 802.11n networks
|
getSSID()
|
Acquisition of SSID
|
getSupplicanState()
|
Obtaining information of specific client states |
In the embodiment of the invention, the WifiInfo object can be expanded, and an identification message is added to indicate whether the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal, wherein the expanded bit is the marking information of the embodiment of the invention. Of course, the use of other ways of representing the label information is not excluded. If the WIFI hotspot is not the self-established WIFI hotspot of the mobile terminal, the marking information can be omitted.
In the embodiment of the present invention, step 202 may be performed after step 201.
And 203, determining not to start the specific service operation, or determining to stop the started specific service operation, or requesting confirmation to the user of the first mobile terminal whether to allow the specific service operation.
It should be understood that certain business operations of embodiments of the present invention include business operations involving large volumes of data, which may include, for example, uploading and downloading of video, audio, or pictures, etc.
When the first mobile terminal determines that the WIFI network information carries the mark information indicating that the WIFI hotspot is the self-established WIFI hotspot of the mobile terminal, the first mobile terminal needs to determine whether to perform specific service operation.
Alternatively, the first mobile terminal may determine to stop a particular service operation already in progress.
Or, alternatively, the first mobile terminal may determine not to initiate a particular service operation that is ready to be initiated.
Or, optionally, the first mobile terminal may send request confirmation information to a user of the first mobile terminal, where the request confirmation information is used to request the user to determine whether to allow the specific service operation.
In the embodiment of the invention, the first mobile terminal determines whether to perform specific service operation according to the mark information which is carried in the WIFI network information and used for indicating that the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal, so that the large consumption of mobile data network flow can be avoided, and the loss of users can be avoided.
Optionally, the method further comprises: if the user of the first mobile terminal allows the specific service operation, switching the current network connection of the first mobile terminal to a mobile data network of the first mobile terminal; the specific business operation is executed.
In some specific scenarios, a user may need to perform the operations of that particular service regardless of whether a significant amount of mobile data network traffic needs to be consumed. In the embodiment of the invention, the request confirmation information is sent to the user, and after the user confirms that the specific service operation is allowed, the current network connection of the first mobile terminal is switched to the mobile data network of the first mobile terminal, so that the flow of the mobile data network of other people is prevented from being greatly consumed.
Of course, it should be understood that, in the embodiment of the present invention, the first mobile terminal may also perform the specific service operation directly through the WIFI hotspot without switching the current network connection, and the specific implementation thereof may refer to the prior art.
Optionally, the method may further comprise: and the first mobile terminal sends prompt information to the WIFI hotspot, wherein the prompt information is used for prompting a second mobile terminal sharing the WIFI hotspot that the first mobile terminal is executing the specific service operation. In the embodiment of the invention, after the first mobile terminal executes the specific service operation, the prompt message can be sent to the WIFI hotspot to remind the user of the second mobile terminal, so that the situation that the user of the second mobile terminal is unconsciously moving data flow and is greatly consumed is avoided.
Optionally, the method may further comprise: and sending a second request to the WIFI hotspot, wherein the second request is used for requesting a second mobile terminal sharing the WIFI hotspot to allow the first mobile terminal to execute the specific service operation.
Further, the method further comprises: receiving a response of the second mobile terminal to the second request; if the response indicates that the second mobile terminal allows the first mobile terminal to perform the specific service operation, performing the specific service operation; or, if the response indicates that the second mobile terminal does not allow the first mobile terminal to perform the specific service operation, switching the current network connection of the first mobile terminal to the mobile data network of the first mobile terminal.
In the embodiment of the invention, the first mobile terminal sends the second request to the WIFI hotspot when the specific service operation needs to be executed so as to request the second mobile terminal sharing the WIFI hotspot to allow the first mobile terminal to execute the specific service operation, thereby avoiding the situation that a user of the second mobile terminal is unconsciously and greatly consumed in mobile data traffic.
Optionally, as an embodiment, the specific service operation is configured by a user of the first mobile terminal. For example, a user of a first mobile terminal may configure an operation of a transmission service involving pictures, audio, video, etc. to be a specific service operation, and so on.
Or, optionally, as another embodiment, the specific service operation is configured for the first mobile terminal by the second mobile terminal. For example, the second mobile terminal sends configuration information to all mobile terminals accessing the WIFI hotspot through the WIFI hotspot, and configures an operation of a transmission service related to pictures, audio, video, and the like as a specific service operation, and the like.
Or, optionally, as yet another embodiment, the specific service operation is an operation that the first mobile terminal preset at the time of factory shipment can preset a transmission service related to pictures, audio, video, and the like as the specific service operation at the time of factory shipment, and the like.
Or, optionally, the specific service operation is configured when an associated application of the first mobile terminal is configured by a user of the first mobile terminal, wherein the associated application refers to an application that is allowed to be started only when the first mobile terminal is allowed to perform the specific service operation. For example, a user of the first mobile terminal may set an APP such as a mobile phone map and an instant messaging tool as an associated application of a specific service operation, and when the first mobile terminal does not allow the specific service operation to be executed, the APP such as the mobile phone map and the instant messaging tool cannot be started; when the first mobile terminal allows the specific business operation to be executed, the APP such as a mobile phone map, an instant messaging tool and the like is allowed to be started.
The method of the embodiments of the present invention will be further described with reference to specific embodiments.
Fig. 3 is an interaction flowchart of a mobile data sharing method according to an embodiment of the present invention. In fig. 3, the second mobile terminal is a mobile terminal for establishing a WIFI hotspot, and the first mobile terminal is a mobile terminal for accessing the WIFI hotspot.
301, the second mobile terminal establishes a first WIFI hotspot and broadcasts first WIFI network information of the first WIFI hotspot.
Similar to the second mobile terminal in fig. 1, the second mobile terminal in the embodiment of the present invention may establish a WIFI hotspot through a Setting module (Setting) located in an application layer, and set a WIFI mode of the WIFI hotspot as a mobile data sharing mode, so that other mobile terminals may search for the WIFI hotspot, and thus select the WIFI hotspot to perform an access operation.
Certainly, the second mobile terminal may also establish the WIFI hotspot through another functional module, and the embodiment of the present invention is not limited herein.
In order to distinguish from other WIFI hotspots, the embodiment of the present invention designates the WIFI hotspot established by the second mobile terminal as the first WIFI hotspot.
After the second mobile terminal establishes the first WIFI hotspot, the WIFI network information of the first WIFI hotspot can be broadcasted, so that the surrounding mobile terminals can search the WIFI hotspot.
In the prior art, for example, Android is used, and the WIFI network information may include parameters such as a Service Set Identifier (SSID) parameter and a Channel parameter of a WIFI hotspot. The SSID parameter includes a Basic Service Set Identifier (BSSID) parameter indicating a Media Access Control (MAC) address of the WIFI hotspot, and an Extended Service Set Identifier (ESSID) parameter indicating a name of the WIFI hotspot. In the embodiment of the invention, an identification field can be expanded in the first WIFI network information to indicate whether the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal. For example, one bit may be used to indicate whether the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal, 1 indicates that the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal, and 0 indicates that the WIFI hotspot is not a self-established WIFI hotspot of the mobile terminal. In particular, if the WIFI hotspot is not a self-established WIFI hotspot of the mobile terminal, the identification field in the first WIFI network information may be omitted.
302, a first mobile terminal scans for WIFI hotspots.
The method for scanning the WIFI hotspot by the first mobile terminal may refer to the prior art. For example, in the Android system, after a first mobile terminal enters a Setting module (Setting) and clicks a Scan (Scan), a startScan method of WifiManager is called, and after the Scan process is finished, a Scan result can be obtained through a Scan results method of WifiNative. At this time, parameters such as a Service Set Identifier (SSID) parameter and a Channel parameter of the WIFI hotspot may be obtained. The SSID parameter includes a Basic Service Set Identifier (BSSID) parameter indicating a Media Access Control (MAC) address of the WIFI hotspot, and an Extended Service Set Identifier (ESSID) parameter indicating a name of the WIFI hotspot. In the scanResults method of the Android system, BSSID parameter is usually BSSID, ESSID, and Channel parameter is freq.
If the second mobile terminal records the identification information indicating whether the WIFI hotspot is the self-established WIFI hotspot of the mobile terminal in the first WIFI network information, the first mobile terminal can read the identification information from the first WIFI network information. At this time, the first mobile terminal may extend the corresponding Scan method and extract the identification information from the Scan results method.
303, the first mobile terminal sends a first request to the first WIFI hotspot.
The first mobile terminal can obtain a list containing a plurality of WIFI hotspots through scanning.
In the embodiment of the invention, the first mobile terminal selects the first WIFI hotspot established by the second mobile terminal to access. The first mobile terminal can send a first request to the first WIFI hotspot, and the first request is used for requesting to access the first WIFI hotspot.
Taking the android system as an example, in the android in the prior art, a list of wiconfiguration objects can be returned by a wifimanager.
And 304, the first WIFI hotspot feeds back second WIFI network information.
The first WIFI hotspot responds to the first request of the first mobile terminal, and the first mobile terminal is allowed to join the first WIFI hotspot. Meanwhile, the second mobile terminal feeds back the WIFI network information of the first WIFI hotspot to the first mobile terminal through the first WIFI hotspot. In order to distinguish from the WIFI network information broadcasted at the stage of establishing the WIFI hotspot, the WIFI network information at this stage is not called as second WIFI network information.
In the embodiment of the present invention, the second mobile terminal may also carry mark information in the second WIFI network information, where the mark information is used to indicate that the first WIFI hotspot is a self-established WIFI hotspot of the mobile terminal.
As shown in the system diagram of fig. 1, the second mobile terminal may receive the first request from the first mobile terminal through the underlying WIFI hotspot module. For the first mobile terminal, the second mobile terminal is equivalent to an Access Point (AP) device, and provides a service of the WIFI hotspot.
The second mobile terminal can feed back second WIFI network information of the first WIFI hotspot from the first WIFI hotspot to the first mobile terminal through the WIFI HotPoint module according to the first request of the first mobile terminal. In the embodiment of the invention, the second WIFI network information of the first WIFI hotspot can be expanded on the basis of the second WIFI network information fed back by the WIFI hotspot in the prior art, and a flag bit is added to carry the mark information.
Of course, it should be understood that, in the embodiment of the present invention, the second mobile terminal may also carry the identification information in the first WIFI network information, and may also carry the identification information in the second WIFI network information.
The first mobile terminal may store a WIFI network information record of the first WIFI network information and the second WIFI network information in a storage space (e.g., a memory space, etc.) of the first mobile terminal.
305, the APP of the first mobile terminal obtains the authority information for executing the specific service operation, and determines whether to start the specific service operation according to the authority information for executing the specific service operation.
It should be understood that, in the embodiment of the present invention, the specific service operation includes an operation involving large-flow data, such as an operation of uploading and downloading video, audio, or pictures.
When a first mobile terminal needs to perform a specific service operation, the specific service operation is performed through a related APP. The APP can determine whether the first WIFI hotspot accessed by the first mobile terminal is a self-established WIFI hotspot of the mobile terminal through the interface.
For example, in a specific implementation manner, the APP in the first mobile terminal may obtain the WIFI network information of the first WIFI hotspot through the interface. Specifically, for example, in the system block diagram shown in fig. 1, the APP in the mobile terminal 2 may read WIFI network information from a WIFI Driver module at a bottom layer of the first mobile terminal through an interface of a Framework, so as to obtain the identification information.
After the APP obtains the WIFI network information returned by the interface of the Framework, whether the WIFI network information has a zone bit carrying the mark information or not can be judged.
If the flag bit does not exist, the first WIFI hotspot is not the self-established WIFI hotspot of the mobile terminal, and specific service operation can be started.
If the flag bit exists, the first WIFI hotspot is the self-established WIFI hotspot of the mobile terminal, the specific service operation is determined not to be started, the started specific service operation is determined to be stopped, or request confirmation information is sent to a user of the first mobile terminal, and the request confirmation information is used for requesting to confirm whether the specific service operation is carried out.
If the APP requests the user of the first mobile terminal to confirm whether to perform the specific service operation, after the APP obtains the confirmation of the user of the first mobile terminal, the specific service operation can be directly performed, or the first mobile terminal is prompted to switch the current network connection of the first mobile terminal to the mobile data network of the first mobile terminal, and the specific service operation is performed through the mobile data network of the first mobile terminal.
Alternatively, for example, in another specific implementation, the first mobile terminal may set a specific business operation mode in which the relevant app is allowed to execute when the specific business operation mode is turned on. When the first mobile terminal determines that the first WIFI hotspot is the self-established WIFI hotspot of the mobile terminal, the specific service operation mode can be determined to be closed. When the app is ready to start, information of a specific business operation mode is read through the interface, and it is then determined whether a specific business operation is started.
It should be understood that the APP of the embodiment of the present invention may be regarded as an internal implementation of the first mobile terminal, and the first mobile terminal including the APP as a whole is used to execute the method of the embodiment shown in fig. 2.
According to the method provided by the embodiment of the invention, by expanding the WIFI network information, the mark information for representing the self-built WIFI hotspot of the mobile terminal is added, and whether the specific service operation is carried out or not is determined according to whether the first WIFI hotspot is the self-built WIFI hotspot of the mobile terminal, so that unnecessary mobile data network flow consumption can be avoided, and the loss of a user is avoided.
And 306, the first mobile terminal sends a second request to the first WIFI hotspot.
It should be understood that, if the first mobile terminal needs to perform the specific service operation, the first mobile terminal may further send a second request to the first WIFI hotspot, requesting a user of the second mobile terminal sharing the first WIFI hotspot to allow the first mobile terminal to perform the specific service operation.
307, the second mobile terminal feeds back a response of the second request.
The second mobile terminal may feed back a response of the second request to the first mobile terminal according to the second request of the first mobile terminal.
Wherein the response indicates that the second mobile terminal allows the first mobile terminal to perform the specific service operation, or the response indicates that the second mobile terminal does not allow the first mobile terminal to perform the specific service operation.
If the response indicates that the second mobile terminal allows the first mobile terminal to perform the specific service operation, the first mobile terminal performs the specific service operation; or, if the response indicates that the second mobile terminal does not allow the first mobile terminal to execute the specific service operation, the first mobile terminal switches the current network connection of the first mobile terminal to the mobile data network of the first mobile terminal and executes the specific service operation; or, if the response indicates that the second mobile terminal does not allow the first mobile terminal to perform the specific service operation, the first mobile terminal does not perform the specific service operation.
It should be understood that the particular business operation may be of some specific business type.
For example, the first mobile terminal may also configure the specific service operation before accessing the WIFI hotspot or after accessing the WIFI hotspot. In particular, the user of the first mobile terminal may configure the type of service to which the particular service operation relates, e.g., the user of the first mobile terminal may configure an operation of a transmission service involving pictures, audio, video, etc. to be the particular service operation, and so on.
Or, the specific service operation may also be configured by the first mobile terminal according to configuration information sent by the WIFI hotspot. The second mobile terminal may send configuration information to the first mobile terminal through the WIFI hotspot, where the configuration information includes a service type included in the specific service operation, and the like.
Alternatively, the specific service operation may be pre-configured by the first mobile terminal at the time of factory shipment.
In addition, the specific business operation may be associated with some applications. These associated applications are applications that are allowed to be started only if the first mobile terminal is allowed to perform the specific service operation. The user of the first mobile terminal may configure the associated application for that particular service operation.
Other embodiments of the present invention are similar and will not be described again.
Fig. 4 is an interaction flowchart of a mobile data sharing method according to another embodiment of the present invention. In fig. 4, the second mobile terminal is a mobile terminal for establishing a WIFI hotspot, and the first mobile terminal is a mobile terminal for accessing the WIFI hotspot.
401, the second mobile terminal establishes a first WIFI hotspot and broadcasts first WIFI network information of the first WIFI hotspot.
402, the first mobile terminal scans for WIFI hotspots.
403, the first mobile terminal sends a first request to the first WIFI hotspot.
And 404, feeding back second WIFI network information by the first WIFI hotspot.
405, the APP of the first mobile terminal obtains permission information for executing the specific service operation, and determines whether to start the specific service operation according to the permission information for executing the specific service operation.
The specific implementation of steps 401 and 405 can refer to steps 301 and 305 of fig. 3, and the embodiment of the present invention is not described herein again.
406, the first mobile terminal sends a prompt message to the first WIFI hotspot.
And if the first mobile terminal already starts to execute the specific service operation, the first mobile terminal sends prompt information to the first WIFI hotspot, wherein the prompt information is used for prompting a second terminal sharing the WIFI hotspot that the first mobile terminal is executing the specific service operation.
The second mobile terminal determines whether to disconnect the first mobile terminal 407.
And the second mobile terminal can determine whether to disconnect the first mobile terminal after receiving the prompt message.
In the embodiment of the invention, after the first mobile terminal executes the specific service operation, the prompt message can be sent to the WIFI hotspot to remind the user of the second mobile terminal, so that the situation that the user of the second mobile terminal is unconsciously moving data flow and is greatly consumed is avoided.
Fig. 5 is an interaction flowchart of a mobile data sharing method according to still another embodiment of the invention. In fig. 5, the second mobile terminal is a mobile terminal for establishing a WIFI hotspot, and the first mobile terminal is a mobile terminal for accessing the WIFI hotspot.
501, the second mobile terminal establishes a first WIFI hotspot and broadcasts first WIFI network information of the first WIFI hotspot.
502, a first mobile terminal scans for WIFI hotspots.
503, the first mobile terminal sends a first request to the first WIFI hotspot.
And 504, feeding back the second WIFI network information by the first WIFI hotspot.
505, the APP of the first mobile terminal obtains authority information for executing the specific service operation, and determines whether to start the specific service operation according to the authority information for executing the specific service operation.
The specific implementation of steps 501-505 can refer to steps 301-305 in fig. 3, and the embodiment of the present invention is not described herein again.
The second mobile terminal monitors 506 the data traffic from the first mobile terminal.
The second mobile terminal can monitor the data flow from the first mobile terminal, so that the first mobile terminal is prevented from generating a large amount of data flow
And 507, the second mobile terminal determines whether to disconnect the first mobile terminal according to the data flow of the first mobile terminal.
The second mobile terminal may determine whether to disconnect the first mobile terminal according to the data traffic of the first mobile terminal.
For example, the second mobile terminal may determine whether to disconnect the first mobile terminal according to the total amount of data traffic of the first mobile terminal, and disconnect the first mobile terminal when the total amount of data traffic of the first mobile terminal is greater than a first predetermined threshold.
For another example, the second mobile terminal may determine whether to disconnect the first mobile terminal according to the data traffic of the first mobile terminal within a predetermined time, and disconnect the first mobile terminal when the data traffic of the first mobile terminal within the predetermined time is greater than a second predetermined threshold.
In the embodiment of the invention, the second mobile terminal determines whether to disconnect the first mobile terminal or not by monitoring the data traffic from the second mobile terminal and according to the total amount of the data traffic of the first mobile terminal, so that the data traffic of the second mobile terminal is prevented from being greatly consumed.
Fig. 6 is a diagram illustrating a mobile data sharing method according to another embodiment of the invention. The method of fig. 6 is performed by a second mobile terminal. In the embodiment of the invention, the second mobile terminal can be mobile terminal equipment such as a smart phone. The method of the embodiment of the present invention is described below with reference to the system block diagram of fig. 1. The second mobile terminal of the embodiment of the present invention may be the second mobile terminal of the embodiment shown in fig. 1.
601, establishing a WIFI hotspot.
And the second mobile terminal establishes a WIFI hotspot and sets the WIFI mode as a mobile data sharing mode so that other mobile terminals can access the mobile data network of the second mobile terminal through the WIFI hotspot.
As shown in the system block diagram of fig. 1, a user of the second mobile terminal may establish a WIFI hotspot in the Setting module, and set a WIFI mode of the WIFI hotspot as a mobile data sharing mode.
602, a first request for accessing the WIFI hotspot by a first mobile terminal is received and the first mobile terminal is allowed to access the WIFI hotspot.
The second mobile terminal may receive a first request of the first mobile terminal, where the first request is used to request access to the WIFI hotspot.
The second mobile terminal can allow the first mobile terminal to access the WIFI hotspot according to the first request.
It should be understood that the specific implementation of steps 601 and 602 may refer to methods in the prior art, and the embodiments of the present invention are not described herein again.
603, sending the WIFI network information of the WIFI hotspot to the first mobile terminal.
The WIFI network information carries mark information used for representing the mobile terminal to establish a WIFI hotspot.
It should be understood that, in the embodiment of the present invention, the second mobile terminal may carry, in the WIFI network information broadcasted after the WIFI hotspot is established, tag information indicating the mobile terminal self-established WIFI hotspot, or carry, in the WIFI network information fed back after the mobile terminal accesses the WIFI hotspot, tag information indicating the mobile terminal self-established WIFI hotspot. The specific implementation manner of the method can refer to step 202 in the embodiment shown in fig. 2, and the embodiment of the present invention is not described herein again.
In the embodiment of the invention, the second mobile terminal sends the WIFI network information to the first mobile terminal, and carries the mark information for indicating that the WIFI hotspot is the self-established WIFI hotspot of the mobile terminal, so that the first mobile terminal can confirm whether to execute specific business operation according to the mark information, thereby avoiding unnecessary mobile data network flow consumption and avoiding user loss.
Optionally, as an embodiment, the method further includes: receiving a second request of the first mobile terminal, wherein the second request is used for requesting to allow the first mobile terminal to execute specific service operation; requesting a user of the second mobile terminal to confirm whether to perform the specific service operation; and sending a response of the second request to the first mobile terminal, wherein the response is used for indicating that the user of the second mobile terminal allows the first mobile terminal to execute the specific service operation or indicating that the user of the second mobile terminal does not allow the first mobile terminal to execute the specific service operation. In the embodiment of the invention, the second mobile terminal determines whether to allow the first mobile terminal to execute the specific service operation according to the second request of the first mobile terminal, thereby avoiding the situation that a user of the second mobile terminal is unconsciously and greatly consumed by the mobile data flow.
Optionally, as another embodiment, the method further includes: receiving prompt information sent by a first mobile terminal, wherein the prompt information is used for prompting a second mobile terminal sharing the WIFI hotspot that the first mobile terminal is executing the specific service operation; and determining whether to disconnect the first mobile terminal according to the prompt message. In the embodiment of the invention, the second mobile terminal determines whether to disconnect the first mobile terminal according to the prompt message sent to the WIFI hotspot after the first mobile terminal executes the specific service operation, so that the situation that a user of the second mobile terminal is unconsciously aware that the mobile data flow is greatly consumed is avoided.
Optionally, as a further embodiment, the method further comprises: monitoring data traffic from the first mobile terminal; and if the data flow is greater than a preset threshold value in a preset time, disconnecting the first mobile terminal. In the embodiment of the invention, the second mobile terminal determines whether to disconnect the first mobile terminal or not by monitoring the data traffic from the second mobile terminal and according to the total amount of the data traffic of the first mobile terminal, so that the data traffic of the second mobile terminal is prevented from being greatly consumed.
Optionally, the method may further comprise: and sending configuration information of the specific service operation to the first mobile terminal, wherein the configuration information comprises the service type contained in the specific service operation.
The method executed by the second mobile terminal in the embodiment shown in fig. 6 can refer to the method executed by the second mobile terminal in the embodiments shown in fig. 3 to 5, and the embodiments of the present invention are not described herein again.
Fig. 7 is a diagram illustrating a mobile data sharing method according to still another embodiment of the invention. The method of fig. 7 is performed by a first mobile terminal. In the embodiment of the invention, the first mobile terminal can be mobile terminal equipment such as a smart phone. The method of the embodiment of the present invention is described below with reference to the system block diagram of fig. 1. The first mobile terminal of the embodiment of the present invention may be the first mobile terminal of the embodiment shown in fig. 1.
701, sending a first request to a WIFI hotspot, where the first request is used to access the WIFI hotspot, and the WIFI hotspot is a self-established WIFI hotspot of a second mobile terminal and is virtualized by the second mobile terminal as a first mobile data network.
In the embodiment of the invention, the WIFI hotspot accessed by the first mobile terminal is a WIFI network self-established by the mobile terminal and is virtualized to be a first mobile data network.
And 702, receiving WIFI network information sent by the WIFI hotspot, where the WIFI network information carries a parameter of a first mobile data network virtualized by the WIFI hotspot.
Similar to step 202 of fig. 2, the WIFI network information may be WIFI network information of a WIFI hotspot acquired by the first mobile terminal in a stage of scanning the WIFI hotspot, or the WIFI network information is WIFI network information fed back by the WIFI hotspot according to the first request of step 701.
The way to carry the parameters of the first mobile data network in the WIFI network information may refer to step 202 of fig. 2, which only differs from step 202 in that step 202 is an identification bit, and the parameters of the first mobile data network need a longer extension field.
Optionally, the first mobile data network may be a mobile data network currently accessed by the second mobile terminal that establishes the WIFI hotspot. Depending on the type of the first mobile data network, the first mobile terminal may perform service operations specific to the first mobile data network.
Of course, it should be understood that the first mobile data network may also be a mobile data network unrelated to the mobile data network currently accessed by the second mobile terminal establishing the WIFI hotspot.
And 703 virtualizing a network currently accessed by the first mobile terminal as a mobile data network according to the WIFI network information, where the virtualized mobile data network is configured to determine not to start a specific service operation according to an accessed network type, or determine to stop the started specific service operation, or request a user of the first mobile terminal to determine whether to perform the specific service operation.
It should be understood that certain business operations of embodiments of the present invention include business operations involving large volumes of data, which may include, for example, uploading and downloading of video, audio, or pictures, etc.
It should be understood that, in the embodiment of the present invention, the first mobile terminal may virtualize the WIFI hotspot as the first mobile data network, or virtualize the WIFI hotspot as a mobile data network of the first mobile terminal itself.
Alternatively, the first mobile terminal may determine to stop a particular service operation already in progress.
Or, alternatively, the first mobile terminal may determine not to initiate a particular service operation that is ready to be initiated.
Or, optionally, the first mobile terminal may send request confirmation information to a user of the first mobile terminal, where the request confirmation information is used to request the user to determine whether to allow the specific service operation.
In the embodiment of the invention, the first mobile terminal virtualizes the WIFI hotspot as the first mobile data network according to the parameter of the virtual first mobile data network in the WIFI network information of the WIFI hotspot, so that the first mobile terminal determines whether to perform specific business operation, the flow of the mobile data network can be prevented from being greatly consumed, and the loss of a user can be avoided.
Optionally, the method further comprises: if the user of the first mobile terminal allows the specific service operation, switching the current network connection of the first mobile terminal to a mobile data network of the first mobile terminal; the specific business operation is executed.
In some specific scenarios, a user may need to perform the operations of that particular service regardless of whether a significant amount of mobile data network traffic needs to be consumed. In the embodiment of the invention, the request confirmation information is sent to the user, and after the user confirms that the specific service operation is allowed, the current network connection of the first mobile terminal is switched to the mobile data network of the first mobile terminal, so that the flow of the mobile data network of other people is prevented from being greatly consumed.
Of course, it should be understood that, in the embodiment of the present invention, the first mobile terminal may also perform the specific service operation directly through the WIFI hotspot without switching the current network connection, and the specific implementation thereof may refer to the prior art.
Optionally, the method may further comprise: and the first mobile terminal sends prompt information to the WIFI hotspot, wherein the prompt information is used for prompting a second mobile terminal sharing the WIFI hotspot that the first mobile terminal is executing the specific service operation. In the embodiment of the invention, after the first mobile terminal executes the specific service operation, the prompt message can be sent to the WIFI hotspot to remind the user of the second mobile terminal, so that the situation that the user of the second mobile terminal is unconsciously moving data flow and is greatly consumed is avoided.
Optionally, the method may further comprise: and sending a second request to the WIFI hotspot, wherein the second request is used for requesting a second mobile terminal sharing the WIFI hotspot to allow the first mobile terminal to execute the specific service operation.
Further, the method further comprises: receiving a response of the second mobile terminal to the second request; if the response indicates that the second mobile terminal allows the first mobile terminal to perform the specific service operation, performing the specific service operation; or, if the response indicates that the second mobile terminal does not allow the first mobile terminal to perform the specific service operation, switching the current network connection of the first mobile terminal to the mobile data network of the first mobile terminal.
In the embodiment of the invention, the first mobile terminal sends the second request to the WIFI hotspot when the specific service operation needs to be executed so as to request the second mobile terminal sharing the WIFI hotspot to allow the first mobile terminal to execute the specific service operation, thereby avoiding the situation that a user of the second mobile terminal is unconsciously and greatly consumed in mobile data traffic.
Optionally, as an embodiment, the specific service operation is configured by a user of the first mobile terminal. For example, a user of a first mobile terminal may configure an operation of a transmission service involving pictures, audio, video, etc. to be a specific service operation, and so on.
Or, optionally, as another embodiment, the specific service operation is configured for the first mobile terminal by the second mobile terminal. For example, the second mobile terminal sends configuration information to all mobile terminals accessing the WIFI hotspot through the WIFI hotspot, and configures an operation of a transmission service related to pictures, audio, video, and the like as a specific service operation, and the like.
Or, optionally, as yet another embodiment, the specific service operation is an operation that the first mobile terminal preset at the time of factory shipment can preset a transmission service related to pictures, audio, video, and the like as the specific service operation at the time of factory shipment, and the like.
Or, optionally, the specific service operation is configured when an associated application of the first mobile terminal is configured by a user of the first mobile terminal, wherein the associated application refers to an application that is allowed to be started only when the first mobile terminal is allowed to perform the specific service operation. For example, a user of the first mobile terminal may set an APP such as a mobile phone map and an instant messaging tool as an associated application of a specific service operation, and when the first mobile terminal does not allow the specific service operation to be executed, the APP such as the mobile phone map and the instant messaging tool cannot be started; when the first mobile terminal allows the specific business operation to be executed, the APP such as a mobile phone map, an instant messaging tool and the like is allowed to be started.
The method of the embodiments of the present invention will be further described with reference to specific embodiments.
Fig. 8 is an interaction flowchart of a mobile data sharing method according to still another embodiment of the present invention. In fig. 8, the second mobile terminal is a mobile terminal for establishing a WIFI hotspot, and the first mobile terminal is a mobile terminal for accessing the WIFI hotspot.
801, the second mobile terminal establishes a WIFI hotspot, virtualizes the WIFI hotspot as a first mobile data network, and broadcasts first WIFI network information of the first WIFI hotspot.
Similar to the second mobile terminal in fig. 1, the second mobile terminal in the embodiment of the present invention may establish a WIFI hotspot through a Setting module (Setting) located in an application layer, and set a WIFI mode of the WIFI hotspot as a mobile data sharing mode, so that other mobile terminals may search for the WIFI hotspot, and thus select the WIFI hotspot to perform an access operation.
In order to distinguish from other WIFI hotspots, the embodiment of the present invention designates the WIFI hotspot established by the second mobile terminal as the first WIFI hotspot.
In the embodiment of the invention, after the second mobile terminal establishes the first WIFI hotspot, the first WIFI hotspot can be virtualized to be the first mobile data network. Specifically, for example, the second mobile terminal may prompt the user whether to virtualize the provided WIFI hotspot as the first mobile data network, and virtualize the WIFI hotspot as the first mobile data network after receiving confirmation from the user. Alternatively, the first mobile data network may be a mobile data network to which the second mobile terminal is currently accessing. It should of course be understood that the first mobile data network may also be a mobile data network independent of the mobile data network currently accessed by the second mobile terminal.
After the second mobile terminal establishes the first WIFI hotspot, the WIFI network information of the first WIFI hotspot can be broadcasted, so that the surrounding mobile terminals can search the WIFI hotspot.
Similar to step 801 of the embodiment shown in fig. 3, in the embodiment of the present invention, one or more fields may be extended in the first WIFI network information, so as to carry parameters of the first mobile data network virtualized by the WIFI hotspot. In particular, if the WIFI hotspot is not a self-established WIFI hotspot of the mobile terminal, the identification field in the first WIFI network information may be omitted.
And 802, the first mobile terminal scans WIFI hotspots.
803, the second mobile terminal sends the first request to the first WIFI hotspot.
The specific implementation of step 802-.
And 804, the first WIFI hotspot receives the access of the first mobile terminal and feeds back WIFI network information.
The first WIFI hotspot responds to the first request of the first mobile terminal, and the first mobile terminal is allowed to join the first WIFI hotspot. Meanwhile, the second mobile terminal feeds back the WIFI network information of the first WIFI hotspot to the first mobile terminal through the first WIFI hotspot. In order to distinguish from the WIFI network information broadcasted at the stage of establishing the WIFI hotspot, the WIFI network information at this stage is not called as second WIFI network information.
And the first WIFI hotspot feeds back second WIFI network information according to the first request of the first mobile terminal. In the embodiment of the present invention, the second mobile terminal may also carry the parameter of the first mobile data network virtualized by the WIFI hotspot in the second WIFI network information.
As shown in the system diagram of fig. 1, the second mobile terminal may receive the first request from the first mobile terminal through the underlying WIFI hotspot module. For the first mobile terminal, the second mobile terminal is equivalent to an Access Point (AP) device, and provides a service of the WIFI hotspot.
The second mobile terminal can feed back second WIFI network information of the first WIFI hotspot from the first WIFI hotspot to the first mobile terminal through the WIFI HotPoint module according to the first request of the first mobile terminal. In the embodiment of the present invention, the second WIFI network information of the first WIFI hotspot may be extended based on the WIFI network information fed back by the WIFI hotspot in the prior art, and the extended content may include a parameter of a mobile data network virtualized by the first WIFI hotspot, and is used by the first mobile terminal to virtualize the accessed first WIFI hotspot into the first mobile data network and feed back the first WIFI hotspot as an APP accessing network information in the first mobile terminal.
For example, after a first mobile terminal accesses a first WIFI hotspot of a second mobile terminal, parameters of a first mobile data network virtualized by the first WIFI hotspot are returned through an extension field of WIFI network information, including a network type and operator information, and the like. The network type may specifically include a second Generation mobile communication technology (2-Generation, 2G), an Enhanced Data Rate for GSM Evolution (EDGE), a third Generation mobile communication technology (3rd-Generation, 3G), a fourth Generation mobile communication technology (4th-Generation, 4G), and the like.
805, the first mobile terminal virtualizes the accessed first WIFI hotspot as a mobile data network.
After the first mobile terminal accesses the first WIFI hotspot, second WIFI network information of the first WIFI hotspot can be obtained. In the embodiment of the invention, the first mobile terminal can virtualize the first WIFI hotspot as the mobile data network according to the parameters of the mobile data network in the WIFI network information.
For example, as shown in the system block diagram of fig. 1, the first mobile terminal may read, through the Framework module, WIFI network information of a first WIFI hotspot currently accessed in the WIFI Driver module. After the first mobile terminal acquires the current access network information, the first mobile terminal judges that the mobile terminal establishes a WIFI hotspot, can further acquire a parameter of a first mobile data network virtualized by the first WIFI hotspot through an extension field of the WIFI network information, and virtualizes the first WIFI hotspot as the first mobile data network. When the APP in the first mobile terminal obtains the current access network information of the first mobile terminal, the first mobile terminal can feed back the information of the first mobile data network to the APP.
It should be understood that the mobile data network virtualized by the first mobile terminal may also be the mobile data network of the first mobile terminal itself, or a preset mobile data network, and so on.
806, the APP of the first mobile terminal obtains the permission information for executing the specific service operation, and determines whether to start the specific service operation according to the permission information for executing the specific service operation.
It should be understood that, in the embodiment of the present invention, the specific service operation includes an operation involving large-flow data, such as an operation of uploading and downloading video, audio, or pictures.
When a first mobile terminal needs to perform a specific service operation, the specific service operation is performed through a related APP. The APP can determine whether the first WIFI hotspot accessed by the first mobile terminal is a self-established WIFI hotspot of the mobile terminal through the interface.
And the APP in the first mobile terminal acquires the current network information through an interface of a Framework layer. Because the first mobile terminal virtualizes the accessed first WIFI hotspot as a mobile data network, current network information obtained by the APP in the first mobile terminal through the interface of the Framework layer is the virtual mobile data network. Taking the Android system as an example, APP may obtain current network information through standard interfaces such as ConnectivityManager and TelephonyManager of Framework.
After obtaining the access network information returned by the interface of the Framework, the APP can judge that the network type of the current access network is a mobile data network. At this time, the APP determines not to start the specific service operation, or determines to stop the started specific service operation, or sends request confirmation information to the user of the first mobile terminal, where the request confirmation information is used to request confirmation of whether to perform the specific service operation.
If the APP requests the user of the first mobile terminal to confirm whether to perform the specific service operation, after the APP obtains the confirmation of the user of the first mobile terminal, the specific service operation can be directly performed, or the first mobile terminal is prompted to switch the current network connection of the first mobile terminal to the mobile data network of the first mobile terminal, and the specific service operation is performed through the mobile data network of the first mobile terminal.
Alternatively, for example, in another specific implementation, the first mobile terminal may set a specific business operation mode in which the relevant app is allowed to execute when the specific business operation mode is turned on. When the first mobile terminal virtualizes the accessed WIFI hotspot as a mobile data network, it can be determined that the specific service operation mode is closed. When the app is ready to start, information of a specific business operation mode is read through the interface, and it is then determined whether a specific business operation is started.
It should be understood that the APP of the embodiment of the present invention may be regarded as an internal implementation of the first mobile terminal, and the first mobile terminal including the APP is used as a whole to execute the method of the embodiment shown in fig. 8.
According to the method provided by the embodiment of the invention, the accessed WIFI hotspot is virtualized to be the mobile data network according to the parameter of the first virtual mobile data network in the WIFI network information, and whether specific business operation is performed or not is determined according to whether the accessed network is the mobile data network or not, so that unnecessary mobile data network flow consumption can be avoided, and the loss of users can be avoided.
807, the first mobile terminal sends a second request to the first WIFI hotspot.
It should be understood that, if the first mobile terminal needs to perform the specific service operation, the first mobile terminal may further send a second request to the first WIFI hotspot, requesting a user of the second mobile terminal sharing the first WIFI hotspot to allow the first mobile terminal to perform the specific service operation.
808, the second mobile terminal feeds back a response of the second request.
The second mobile terminal may feed back a response of the second request to the first mobile terminal according to the second request of the first mobile terminal.
Wherein the response indicates that the second mobile terminal allows the first mobile terminal to perform the specific service operation, or the response indicates that the second mobile terminal does not allow the first mobile terminal to perform the specific service operation.
If the response indicates that the second mobile terminal allows the first mobile terminal to perform the specific service operation, the first mobile terminal performs the specific service operation; or, if the response indicates that the second mobile terminal does not allow the first mobile terminal to execute the specific service operation, the first mobile terminal switches the current network connection of the first mobile terminal to the mobile data network of the first mobile terminal and executes the specific service operation; or, if the response indicates that the second mobile terminal does not allow the first mobile terminal to perform the specific service operation, the first mobile terminal does not perform the specific service operation.
Fig. 9 is an interaction flowchart of a mobile data sharing method according to still another embodiment of the invention. In fig. 9, the second mobile terminal is a mobile terminal for establishing a WIFI hotspot, and the first mobile terminal is a mobile terminal for accessing the WIFI hotspot.
And 901, establishing a WIFI hotspot by the second mobile terminal, virtualizing the WIFI hotspot as a first mobile data network, and broadcasting first WIFI network information of the first WIFI hotspot.
And 902, the first mobile terminal scans the WIFI hotspot.
903, the first mobile terminal sends a first request to the first WIFI hotspot.
And 904, feeding back the second WIFI network information by the first WIFI hotspot.
905, the first mobile terminal virtualizes the accessed first WIFI hotspot as a mobile data network.
And 906, the APP of the first mobile terminal acquires the authority information for executing the specific service operation, and determines whether to start the specific service operation according to the authority information for executing the specific service operation.
The specific implementation of steps 901-906 can refer to steps 301-305 of fig. 3, and the embodiment of the present invention is not described herein again.
907, the first mobile terminal sends prompt information to the first WIFI hotspot.
And if the first mobile terminal already starts to execute the specific service operation, the first mobile terminal sends prompt information to the first WIFI hotspot, wherein the prompt information is used for prompting a second terminal sharing the WIFI hotspot that the first mobile terminal is executing the specific service operation.
The second mobile terminal determines 908 whether to disconnect the first mobile terminal.
And the second mobile terminal can determine whether to disconnect the first mobile terminal after receiving the prompt message.
In the embodiment of the invention, after the first mobile terminal executes the specific service operation, the prompt message can be sent to the WIFI hotspot to remind the user of the second mobile terminal, so that the situation that the user of the second mobile terminal is unconsciously moving data flow and is greatly consumed is avoided.
Fig. 10 is an interaction flowchart of a mobile data sharing method according to still another embodiment of the present invention. In fig. 10, the second mobile terminal is a mobile terminal for establishing a WIFI hotspot, and the first mobile terminal is a mobile terminal for accessing the WIFI hotspot.
100I, the second mobile terminal establishes a WIFI hotspot, virtualizes the WIFI hotspot as a first mobile data network, and broadcasts first WIFI network information of the first WIFI hotspot.
1002, the first mobile terminal scans WIFI hotspots.
1003, the first mobile terminal sends a first request to the first WIFI hotspot.
And 1004, the first WIFI hotspot feeds back second WIFI network information.
And 1005, virtualizing the accessed first WIFI hotspot as a mobile data network by the first mobile terminal.
And 1006, the APP of the first mobile terminal acquires the authority information for executing the specific service operation, and determines whether to start the specific service operation according to the authority information for executing the specific service operation.
The specific implementation of steps 1001-1006 can refer to steps 301-305 in fig. 3, and the embodiment of the present invention is not described herein again.
1007, the second mobile terminal monitors the data traffic from the first mobile terminal.
The second mobile terminal can monitor the data flow from the first mobile terminal, so that the first mobile terminal is prevented from generating a large amount of data flow
The second mobile terminal determines, 1008, whether to disconnect the first mobile terminal based on the data traffic of the first mobile terminal.
The second mobile terminal may determine whether to disconnect the first mobile terminal according to the data traffic of the first mobile terminal.
For example, the second mobile terminal may determine whether to disconnect the first mobile terminal according to the total amount of data traffic of the first mobile terminal, and disconnect the first mobile terminal when the total amount of data traffic of the first mobile terminal is greater than a first predetermined threshold.
For another example, the second mobile terminal may determine whether to disconnect the first mobile terminal according to the data traffic of the first mobile terminal within a predetermined time, and disconnect the first mobile terminal when the data traffic of the first mobile terminal within the predetermined time is greater than a second predetermined threshold.
In the embodiment of the invention, the second mobile terminal determines whether to disconnect the first mobile terminal or not by monitoring the data traffic from the second mobile terminal and according to the total amount of the data traffic of the first mobile terminal, so that the data traffic of the second mobile terminal is prevented from being greatly consumed.
Fig. 11 is a flowchart of a mobile data sharing method according to still another embodiment of the present invention. The method of fig. 11 is performed by a second mobile terminal. In the embodiment of the invention, the second mobile terminal can be mobile terminal equipment such as a smart phone. The method of the embodiment of the present invention is described below with reference to the system block diagram of fig. 1. The second mobile terminal of the embodiment of the present invention may be the second mobile terminal of the embodiment shown in fig. 1.
And 1101, establishing a WIFI hotspot, and virtualizing the WIFI hotspot as a first mobile data network.
And the second mobile terminal establishes a WIFI hotspot and sets the WIFI mode as a mobile data sharing mode so that other mobile terminals can access the mobile data network of the second mobile terminal through the WIFI hotspot.
As shown in the system block diagram of fig. 1, a user of the second mobile terminal may establish a WIFI hotspot in the Setting module, and set a WIFI mode of the WIFI hotspot as a mobile data sharing mode.
In addition, in the embodiment of the present invention, the second mobile terminal further needs to virtualize the WIFI hotspot as the first mobile data network. In particular, the first mobile data network may be, for example, a mobile data network to which the second mobile terminal is currently accessing. Certainly, the WIFI hotspot of the second mobile terminal may also be virtualized as another mobile data network.
1102, receiving a first request for a first mobile terminal to access the WIFI hotspot and allowing the first mobile terminal to access the WIFI hotspot.
The second mobile terminal may receive a first request of the first mobile terminal, where the first request is used to request access to the WIFI hotspot.
The second mobile terminal can allow the first mobile terminal to access the WIFI hotspot according to the first request.
It should be understood that the step 1102 may be implemented by a method in the prior art, and the embodiment of the present invention is not described herein again.
1103, sending WIFI network information of the WIFI hotspot to the first mobile terminal, where the WIFI network information includes a parameter of the first mobile data network, and is used for virtualizing the accessed WIFI hotspot as the first mobile data network by the first mobile terminal.
It should be understood that, in the embodiment of the present invention, the second mobile terminal may carry the parameter of the first mobile data network in the WIFI network information broadcasted after the WIFI hotspot is established, or carry the parameter of the first mobile data network in the WIFI network information fed back after the mobile terminal accesses the WIFI hotspot. The specific implementation manner of the method can refer to step 202 in the embodiment shown in fig. 2, and the embodiment of the present invention is not described herein again.
In the embodiment of the invention, the second mobile terminal sends the WIFI network information to the first mobile terminal, and carries the parameters for the first mobile data network, so that the first mobile terminal can virtualize the WIFI hotspot as the first mobile data network according to the parameters of the first mobile data network, and the first mobile terminal can determine whether to perform specific business operation, thereby avoiding the large consumption of mobile data network flow and avoiding the loss of users.
Optionally, as an embodiment, the method further includes: receiving a second request of the first mobile terminal, wherein the second request is used for requesting to allow the first mobile terminal to execute specific service operation; requesting a user of the second mobile terminal to confirm whether to perform the specific service operation; and sending a response of the second request to the first mobile terminal, wherein the response is used for indicating that the user of the second mobile terminal allows the first mobile terminal to execute the specific service operation or indicating that the user of the second mobile terminal does not allow the first mobile terminal to execute the specific service operation. In the embodiment of the invention, the second mobile terminal determines whether to allow the first mobile terminal to execute the specific service operation according to the second request of the first mobile terminal, thereby avoiding the situation that a user of the second mobile terminal is unconsciously and greatly consumed by the mobile data flow.
Optionally, as another embodiment, the method further includes: receiving prompt information sent by a first mobile terminal, wherein the prompt information is used for prompting a second mobile terminal sharing the WIFI hotspot that the first mobile terminal is executing the specific service operation; and determining whether to disconnect the first mobile terminal according to the prompt message. In the embodiment of the invention, the second mobile terminal determines whether to disconnect the first mobile terminal according to the prompt message sent to the WIFI hotspot after the first mobile terminal executes the specific service operation, so that the situation that a user of the second mobile terminal is unconsciously aware that the mobile data flow is greatly consumed is avoided.
Optionally, as a further embodiment, the method further comprises: the method further comprises the following steps: monitoring data traffic from the first mobile terminal; and if the data flow is greater than a preset threshold value in a preset time, disconnecting the first mobile terminal. In the embodiment of the invention, the second mobile terminal determines whether to disconnect the first mobile terminal or not by monitoring the data traffic from the second mobile terminal and according to the total amount of the data traffic of the first mobile terminal, so that the data traffic of the second mobile terminal is prevented from being greatly consumed.
Optionally, the method further comprises: and sending configuration information of the specific service operation to the first mobile terminal, wherein the configuration information comprises the service type contained in the specific service operation.
The method executed by the first mobile terminal in the embodiment shown in fig. 11 can refer to the method executed by the second mobile terminal in the embodiments shown in fig. 8 to 10, and the embodiments of the present invention are not described herein again.
An embodiment of the present invention further discloses a first mobile terminal, which is configured to execute the method executed by the first mobile terminal in the embodiments shown in fig. 2 to 5. In particular, the first mobile terminal may comprise means for performing the method performed by the first mobile terminal in the embodiment shown in fig. 2.
Another embodiment of the present invention further discloses a second mobile terminal, which is configured to execute the method executed by the second mobile terminal in the embodiments shown in fig. 3 to 6. In particular, the second mobile terminal may comprise means for performing the method performed by the second mobile terminal in the embodiment shown in fig. 6.
Another embodiment of the present invention further provides another first mobile terminal, configured to execute the method performed by the first mobile terminal in the embodiments shown in fig. 7 to 10. In particular, the second mobile terminal may comprise means for performing the method performed by the first mobile terminal in the embodiment shown in fig. 7.
Still another embodiment of the present invention further discloses a second mobile terminal, which is configured to execute the method executed by the second mobile terminal in the embodiments shown in fig. 8-11. In particular, the second mobile terminal may comprise means for performing the method performed by the second mobile terminal in the embodiment shown in fig. 11.
Fig. 12 is a schematic structural diagram of a first mobile terminal 1200 according to an embodiment of the present invention. The first mobile terminal 1200 may include a processor 1202, a transmitter 1201, and a receiver 1204. Optionally, a memory 1203 is also included.
The receiver 1204, the transmitter 1201, the processor 1202 and the memory 1203 are interconnected by a bus 1206 system. The bus 1206 may be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. For ease of illustration, only one double-headed arrow is shown in FIG. 12, but that does not indicate only one bus or one type of bus. In particular applications, transmitter 1201 and receiver 1204 may be coupled to an antenna 1205.
A memory 1203 is used for storing the program. In particular, the program may include program code comprising computer operating instructions. The memory 1203 may include both read-only memory and random access memory and provides instructions and data to the processor 1202. The memory 1203 may comprise high-speed RAM memory, and may also include non-volatile memory (e.g., at least 1 disk memory).
Optionally, a memory 1203 is included for storing the program. In particular, the program may include program code comprising computer operating instructions. The memory 1203 may include both read-only memory and random access memory and provides instructions and data to the processor 1202. The memory 1203 may comprise high-speed RAM memory, and may also include non-volatile memory (e.g., at least 1 disk memory).
The processor 1202 is configured to execute the following operations, optionally, to execute a program stored in the memory 1203, and specifically to execute the following operations:
sending a first request to a WIFI hotspot through a transmitter 1201, wherein the first request is used for accessing the WIFI hotspot, and the WIFI hotspot is a self-established WIFI hotspot of a second mobile terminal;
receiving WIFI network information of the WIFI hotspot through a receiver 1204, wherein the WIFI network information carries mark information indicating that the WIFI hotspot is a self-established WIFI hotspot of the mobile terminal;
determining not to start a specific service operation, or determining to stop the specific service operation that has been started, or requesting confirmation from a user of the first mobile terminal whether the specific service operation is allowed to be performed.
The processor 1202 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware or instructions in the form of software in the processor 1202. The Processor 1202 may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components; the various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 1203, and the processor 1202 reads the information in the memory 1203, and completes the steps of the above method in combination with the hardware thereof.
Optionally, the WIFI network information of the WIFI hotspot is obtained when the first mobile terminal searches for the WIFI hotspot; or the WIFI network information of the WIFI hotspot is the WIFI network information fed back by the WIFI hotspot according to the first request.
The processor 1202 may also execute the method in the embodiment shown in fig. 2, and implement the functions of the first mobile terminal in the embodiments shown in fig. 2 to 5, which are not described herein again in the embodiments of the present invention.
Fig. 13 is a schematic structural diagram of a second mobile terminal 1300 according to an embodiment of the present invention. The second mobile terminal 1300 may include a processor 1302, a transmitter 1301, and a receiver 1304. Optionally, a memory 1303 is also included.
The receiver 1304, transmitter 1301, processor 1302 and memory 1303 are interconnected by a bus 1306 system. The bus 1306 may be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. For ease of illustration, only one double-headed arrow is shown in FIG. 13, but that does not indicate only one bus or one type of bus. In particular applications, transmitter 1301 and receiver 1304 may be coupled to an antenna 1305.
And a memory 1303 for storing programs. In particular, the program may include program code comprising computer operating instructions. Memory 1303 may include read-only memory and random-access memory, and provides instructions and data to processor 1302. The memory 1303 may include a high-speed RAM memory, and may further include a non-volatile memory (e.g., at least 1 disk memory).
Optionally, a memory 1303 is included for storing the program. In particular, the program may include program code comprising computer operating instructions. Memory 1303 may include read-only memory and random-access memory, and provides instructions and data to processor 1302. The memory 1303 may include a high-speed RAM memory, and may further include a non-volatile memory (e.g., at least 1 disk memory).
The processor 1302 is configured to execute the following operations, optionally, execute the program stored in the memory 1303, and specifically, execute the following operations:
establishing a WIFI hotspot;
receiving, by a receiver 1304, a first request for a first mobile terminal to access the WIFI hotspot and allowing the first mobile terminal to access the WIFI hotspot;
and sending the WIFI network information of the WIFI hotspot to the first mobile terminal through the transmitter 1301, wherein the WIFI network information carries mark information used for representing the mobile terminal to establish the WIFI hotspot.
The processor 1302 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware or instructions in the form of software in the processor 1302. The Processor 1302 may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components; the various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 1303, and the processor 1302 reads information in the memory 1303 and completes the steps of the method in combination with hardware thereof.
Optionally, the WIFI network information of the WIFI hotspot is WIFI network information that is sent by the second mobile terminal through broadcasting after the WIFI hotspot is established; or the WIFI network information of the WIFI hotspot is WIFI network information fed back by the second mobile terminal according to the first request.
The processor 1302 may further execute the method of the embodiment shown in fig. 6, and implement the functions of the second mobile terminal in the embodiments shown in fig. 3 to 6, which are not described herein again in the embodiments of the present invention.
Fig. 14 is a schematic structural diagram of a first mobile terminal 1400 according to still another embodiment of the present invention. First mobile terminal 1400 may include a processor 1402, a transmitter 1401, and a receiver 1404. Optionally, a memory 1403 is also included.
The receiver 1404, transmitter 1401, processor 1402 and memory 1403 are interconnected by a bus 1406 system. The bus 1406 may be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. For ease of illustration, only one double-headed arrow is shown in FIG. 14, but that does not indicate only one bus or one type of bus. In particular applications, transmitter 1401 and receiver 1404 may be coupled to antenna 1405.
A memory 1403 for storing the program. In particular, the program may include program code comprising computer operating instructions. Memory 1403 may include both read-only memory and random access memory, and provides instructions and data to processor 1402. Memory 1403 may include high-speed RAM memory, and may also include non-volatile memory, such as at least 1 disk memory.
Optionally, a memory 1403 is included for storing the program. In particular, the program may include program code comprising computer operating instructions. Memory 1403 may include both read-only memory and random access memory, and provides instructions and data to processor 1402. Memory 1403 may include high-speed RAM memory, and may also include non-volatile memory, such as at least 1 disk memory.
A processor 1402 configured to execute the following operations, optionally, the program stored in the memory 1403, and specifically configured to execute the following operations:
sending a first request to a WIFI hotspot through a transmitter 1401, the first request being used to access the WIFI hotspot, the WIFI hotspot being a self-established WIFI hotspot of a second mobile terminal and being virtualized by the second mobile terminal as a first mobile data network;
receiving, by a receiver 1404, WIFI network information sent by the WIFI hotspot, where the WIFI network information carries a parameter of a first mobile data network virtualized by the WIFI hotspot;
virtualizing a network currently accessed by the first mobile terminal as a mobile data network according to the WIFI network information, where the virtualized mobile data network is configured to determine not to start a specific service operation according to an accessed network type, or determine to stop the started specific service operation, or request a user of the first mobile terminal to determine whether to allow the specific service operation.
The processor 1402 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware or instructions in the form of software in the processor 1402. The Processor 1402 may be a general-purpose Processor including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components; the various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 1403, and the processor 1402 reads the information in the memory 1403, and completes the steps of the above method in combination with the hardware thereof.
Optionally, the WIFI network information of the WIFI hotspot is obtained when the first mobile terminal searches for the WIFI hotspot; or the WIFI network information of the WIFI hotspot is the WIFI network information fed back by the WIFI hotspot according to the first request.
The processor 1402 may also execute the method of the embodiment shown in fig. 7, and implement the functions of the first mobile terminal in the embodiments shown in fig. 7-10, which are not described herein again in the embodiments of the present invention.
Fig. 15 is a schematic structural diagram of a second mobile terminal 1500 according to still another embodiment of the present invention. The second mobile terminal 1500 may include a processor 1502, a transmitter 1501 and a receiver 1504. Optionally, a memory 1503 is also included.
The receiver 1504, transmitter 1501, processor 1502 and memory 1503 are interconnected by a bus 1506 system. The bus 1506 may be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. For ease of illustration, only one double-headed arrow is shown in FIG. 15, but that does not indicate only one bus or one type of bus. In particular applications, the transmitter 1501 and receiver 1504 may be coupled to an antenna 1505.
The memory 1503 stores programs. In particular, the program may include program code comprising computer operating instructions. The memory 1503 may include read-only memory and random access memory, and provides instructions and data to the processor 1502. Memory 1503 may include high-speed RAM memory and may also include non-volatile memory, such as at least 1 disk memory.
Optionally, a memory 1503 is included for storing the program. In particular, the program may include program code comprising computer operating instructions. The memory 1503 may include read-only memory and random access memory, and provides instructions and data to the processor 1502. Memory 1503 may include high-speed RAM memory and may also include non-volatile memory, such as at least 1 disk memory.
The processor 1502 is configured to execute the following operations, optionally, the program stored in the memory 1503, and specifically configured to execute the following operations:
establishing a WIFI hotspot, and virtualizing the WIFI hotspot as a first mobile data network;
receiving, by a receiver 1504, a first request for a first mobile terminal to access the WIFI hotspot and allowing the first mobile terminal to access the WIFI hotspot;
and sending the WIFI network information of the WIFI hotspot to the first mobile terminal through the transmitter 1501, where the WIFI network information includes a parameter of the first mobile data network, and is used for the first mobile terminal to virtualize the accessed WIFI hotspot as the first mobile data network.
The processor 1502 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by instructions in the form of hardware, integrated logic circuits, or software in the processor 1502. The Processor 1502 may be a general-purpose Processor including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components; the various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 1503, and the processor 1502 reads the information in the memory 1503 to complete the steps of the method in combination with the hardware thereof.
Optionally, the WIFI network information of the WIFI hotspot is WIFI network information that is sent by the second mobile terminal through broadcasting after the WIFI hotspot is established; or the WIFI network information of the WIFI hotspot is WIFI network information fed back by the second mobile terminal according to the first request.
The processor 1502 may also execute the method of the embodiment shown in fig. 11 and implement the functions of the second mobile terminal in the embodiments shown in fig. 8 to 11, which are not described herein again in the embodiments of the present invention.
It should be understood that, in various embodiments of the present invention, the sequence numbers of the above-mentioned processes do not mean the execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and all the changes or substitutions should be covered within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the appended claims.