CN109089246B - Data transmission method and related product - Google Patents

Data transmission method and related product Download PDF

Info

Publication number
CN109089246B
CN109089246B CN201810913287.5A CN201810913287A CN109089246B CN 109089246 B CN109089246 B CN 109089246B CN 201810913287 A CN201810913287 A CN 201810913287A CN 109089246 B CN109089246 B CN 109089246B
Authority
CN
China
Prior art keywords
data
target
devices
target data
target device
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810913287.5A
Other languages
Chinese (zh)
Other versions
CN109089246A (en
Inventor
柯世兴
胡亚东
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201810913287.5A priority Critical patent/CN109089246B/en
Publication of CN109089246A publication Critical patent/CN109089246A/en
Application granted granted Critical
Publication of CN109089246B publication Critical patent/CN109089246B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/70Services for machine-to-machine communication [M2M] or machine type communication [MTC]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/20Manipulation of established connections
    • H04W76/23Manipulation of direct-mode connections
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/005Discovery of network devices, e.g. terminals

Abstract

The embodiment of the application discloses a data transmission method and a related product, comprising the following steps: when the target data playing request is detected, and the data transmission speed of the mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for a first device to request target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data; receiving response messages from the plurality of second devices, wherein the response messages are used for indicating that the plurality of second devices contain target data; selecting at least one target device for providing target data from a plurality of second devices; negotiating a transmission channel of target data with at least one target device; target data is received from at least one target device over the negotiated transmission channel. The embodiment of the application is favorable for realizing that the electronic equipment acquires audio and video data under the condition that no mobile network data exists, and improves the convenience of data transmission.

Description

Data transmission method and related product
Technical Field
The present application relates to the field of electronic device technologies, and in particular, to a data transmission method and a related product.
Background
With the great popularity and rapid development of electronic devices (e.g., smart phones), more and more applications are installed in the electronic devices of users, such as video-type applications, game-type applications, music-type applications, etc., wherein the use of the numerous applications depends on the mobile data network.
At present, people often have the problem that audio data or video data cannot be normally watched under the condition that the mobile data network has poor signals or the data flow of the mobile data network is used up, so that the normal use of users is influenced.
Disclosure of Invention
The embodiment of the application provides a data transmission method and a related product, which can realize that electronic equipment acquires audio and video data under the condition of no mobile network data and improve the convenience of data transmission.
In a first aspect, an embodiment of the present application provides a data transmission method, which is applied to a first device, where the first device is a Neighbor Awareness Network (NAN) device in a NAN network, and the method includes:
when a target data playing request is detected and the data transmission speed of a mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data;
receiving response messages from a plurality of second devices, the response messages indicating that the plurality of second devices contain the target data;
selecting at least one target device from the plurality of second devices for providing the target data;
negotiating a transmission channel of the target data with the at least one target device;
receiving the target data from the at least one target device through the negotiated transmission channel.
In a second aspect, an embodiment of the present application provides a data transmission apparatus, which is applied to a first device, where the first device is a Neighbor Awareness Network (NAN) device in a NAN network, and the data transmission apparatus includes a broadcasting unit, a receiving unit, a selecting unit, and a communication unit, where:
the broadcast unit is configured to broadcast a first message when a target data play request is detected and a data transmission speed of a mobile network is lower than a preset speed threshold, where the first message is used for the first device to request the target data from a plurality of devices in the NAN network except the first device, and the target data is audio data and/or video data;
the receiving unit is configured to receive response messages from a plurality of second devices, where the response messages are used to indicate that the plurality of second devices contain the target data;
the selecting unit is used for selecting at least one target device for providing the target data from the plurality of second devices;
the communication unit is used for negotiating a transmission channel of the target data with the at least one target device;
the receiving unit is further configured to receive the target data from the at least one target device through the negotiated transmission channel.
In a third aspect, an embodiment of the present application provides a first device, including: a processor, memory, and one or more programs; the one or more programs are stored in the above memory and configured to be executed by the processor, the programs including instructions for performing the steps described in any of the methods of the first aspect of the embodiments of the present application.
In a fourth aspect, this application provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program for electronic data exchange, the computer program specifically includes instructions for performing some or all of the steps described in any one of the methods of the first aspect of this application, and the computer includes a first device.
In a fifth aspect, the present application provides a computer program product, wherein the computer program product comprises a non-transitory computer-readable storage medium storing a computer program, the computer program being operable to cause a computer to perform some or all of the steps as described in any one of the methods of the first aspect of the embodiments of the present application. The computer program product may be a software installation package, the computer comprising a first device.
It can be seen that, in the embodiment of the present application, the first device first detects a request for playing the target data, and when the data transmission speed of the mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data, then, receiving response messages from a plurality of second devices, the response messages being used to indicate that the plurality of second devices contain the target data, then, selecting at least one target device for providing the target data from the plurality of second devices, then, negotiating a transmission channel for the target data with the at least one target device, and finally, receiving the target data from the at least one target device through the negotiated transmission channel. It can be seen that when the first device needs target data but the data transmission speed of the mobile network is lower than the preset speed threshold, the target data is acquired from the target device including the target data through the NAN network by broadcasting the first message to other devices in the NAN network without the need of the mobile network or wasting data traffic, which is beneficial to the electronic device to acquire audio and video data without the mobile network data, and improves the convenience of data transmission.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic diagram of a DW of a cluster of a NAN network disclosed in an embodiment of the present application;
fig. 2 is a schematic flow chart of a data transmission method disclosed in an embodiment of the present application;
fig. 3 is a schematic flow chart of another data transmission method disclosed in the embodiments of the present application;
fig. 4 is a schematic flow chart of another data transmission method disclosed in the embodiments of the present application;
FIG. 5 is a schematic structural diagram of a first apparatus disclosed in an embodiment of the present application;
fig. 6 is a block diagram of functional units of a data transmission device disclosed in an embodiment of the present application.
Detailed Description
In order to make the technical solutions of the present application better understood, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The terms "first," "second," and the like in the description and claims of the present application and in the above-described drawings are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
The electronic device according to the embodiment of the present application may include various handheld devices, vehicle-mounted devices, wearable devices, computing devices or other processing devices connected to a wireless modem, which have wireless communication functions, and various forms of User Equipment (UE), Mobile Stations (MS), terminal devices (terminal device), and the like. For convenience of description, the above-mentioned devices are collectively referred to as electronic devices, and the first device and the second device described below are both the electronic devices. The following describes embodiments of the present application in detail.
Firstly, a NAN mechanism is briefly introduced, a Neighbor Awareness Network (NAN) mechanism is a standard formulated by a wireless fidelity Wi-Fi alliance, the standard is used for synchronizing all devices (namely NAN devices) participating in the NAN mechanism under the condition that no central node exists, maintaining work and Service Discovery work of the NAN mechanism are performed in a Discovery Window (DW) agreed by the NAN mechanism, Service Discovery is realized by sending a Service Discovery Frame (SDF) message, and the Service Discovery Frame message comprises an inquiry message or a broadcast message. The device may establish a corresponding connection based on the information obtained in the service discovery and then perform data transmission.
Specifically, in the standard specified by the Wi-Fi alliance, channel 6 may be used as the discovery channel in the NAN mechanism, and on channel 6, the duration of the discovery time window DW is fixed for each cluster, and the time interval between any two DWs adjacent to the cluster is also fixed.
In the NAN mechanism, a Discovery Window (DW) is set, and NAN devices perform service discovery in the DW. In the NAN mechanism, a DW is generally set in each 512 TUs (time unit), wherein the duration of one TU is about 1024 μ s, and the duration of the DW is generally 16 TUs, that is, in the NAN mechanism, a DW is generally set every 496 TUs. In the NAN mechanism, one or more NAN devices form a Cluster (also called a neighbor awareness network), when a Cluster enters a DW, a NAN device in the Cluster in a master node (master), an anchor master node (AM), a master node (non-master synchronization, non-master sync) state and the like sends a synchronization beacon frame (sync beacon) message, where the message carries information of the AM in the Cluster, and the NAN device receiving the message synchronizes with the AM in the Cluster.
For example, as shown in fig. 1, which is a schematic diagram of a DW of a cluster, according to a standard established by the Wi-Fi alliance, in the DW, NAN devices in the cluster may send a service discovery frame SDF message in the DW to perform service discovery, and in a time other than the DW, NAN devices in the cluster may send a discovery beacon (discovery beacon) message to announce the existence of the cluster. Each NAN device in the cluster may perform service discovery in the DW to discover other NAN devices with which data transmission can be performed. After service discovery, at least two NAN devices which need to perform data transmission with each other may agree on a time frequency resource and a network connection mode in the DW, and after the DW is finished, assemble a corresponding NAN network without a center node on the agreed time frequency resource according to the agreed network connection mode.
The flow of completing service discovery by the NAN device is as follows:
1. after a device activates the NAN function (i.e., becomes a NAN device), it may set itself as an AM, create a Cluster, set a Cluster Identity (Identity, ID) value of the Cluster based on its MAC (Media Access Control) address, and set the TSF as an integer multiple of 512 TU.
2. Once the NAN device receives a Beacon frame (i.e., a sync Beacon, hereinafter, referred to as Beacon frame) sent by a NAN device from one or more other clusters, it may determine whether the NAN device wants to join the Cluster of the other peer.
In the Beacon frame, information of the corresponding Cluster is generally carried, and specifically, information of an AM in the corresponding Cluster may be specifically carried, and may include one or more of an Anchor Master node rank (AMR), a Master node rank (MR), a Master node priority (Master priority, MP), an Anchor Master node priority (AMP), a Random Factor (RF), an Anchor Master node signal Transmission Time (AMBTT), a Time Synchronization Function (TSF), a Cluster ID, and a Cluster rank (CG).
One NAN device may send information of the AM of the Cluster to which the NAN device belongs to other NAN devices by sending the Beacon frame, and similarly, one NAN device may also receive the Beacon frame sent by the Cluster or the NAN devices in other clusters.
After receiving a Beacon frame, the NAN device may determine whether the Beacon frame is from a NAN device in the Cluster to which the NAN device belongs or from NAN devices in other clusters, if the Beacon frame is from NAN devices in other clusters, the NAN device may determine whether a value of Cluster level CG in the received Beacon frame is greater than a value of Cluster level CG of the NAN device, if the value is greater than the value, the NAN device adds the Cluster corresponding to the received Beacon frame, otherwise, the NAN device does not perform processing. This completes the aggregation of NAN devices, i.e., NAN devices will join Cluster with a higher value of Cluster level CG.
3. If the determination is made that the other party's Cluster is to be added, the synchronization is achieved with the AM in the added Cluster after the other party's Cluster is added, specifically, each item of parameter information in the AM of the self is synchronized with the AM in the added Cluster, for example, the TSF of the AM in the Cluster is updated to the TSF of the AM in the added Cluster.
4. After synchronization, when a DW of a joined Cluster arrives, the NAN device sends an SDF (Service Discovery frame) message in the DW to perform Service Discovery, where the SDF message may carry, for example, Service Discovery (Service Subscription) information for querying a required Service or may carry, for example, Service publication (Service Publish) information for publishing a Service that the NAN device can provide, and after receiving the SDF message sent by the NAN device, other NAN devices may reply the SDF message to the NAN device in the DW if it is determined that the SDF message is satisfied, that is, Service matching can be performed.
Similarly, in the DW, the NAN device may also receive an SDF message sent by another NAN device for service discovery, and if the NAN device determines that the received SDF message is satisfied, the NAN device may also reply the SDF message to the corresponding NAN device in the DW.
Various types of information contained in the AM are explained below.
The anchor master node level AMR, which is generally a maximum value of 8 bytes (byte), is the MR value of AM.
The master node level MR, which generally takes a maximum value of 8 bytes, is calculated according to the MP value, the RF value, and the MAC address of the NAN device, and indicates the will of the NAN device to act as a master. The larger the value of MR, the higher will the NAN device want to be master. MR can also be considered as an alternative expression of MP.
The master node priority MP, which generally takes a maximum value of 1 byte, indicates the willingness of the NAN device to act as a master. The larger the value of MP, the higher will the NAN device want to be master.
The anchor master node priority AMP, which generally takes a maximum value of 1 byte, is the value of the MP of the AM.
The random factor RF, which generally takes a maximum value of 1 byte, is a random number selected by the NAN device.
The anchor master node signal transmission time AMBTT generally takes a maximum value of 4 bytes, and shows the sending time of the Beacon frame of the AM. Generally, a NAN device sending a Beacon frame carries an AMBTT, and is used for synchronizing the time of other NAN devices with an AM corresponding to the AMBTT.
The time synchronization function TSF, which generally takes a maximum value of 8 bytes, indicates a synchronization function of the NAN device, so that a timer (timer) of the NAN device receiving the TSF is synchronized with a time of the AM corresponding to the NAN device sending the TSF. The TSF may also represent time information.
The Cluster identity identifier Cluster ID generally takes a maximum value of 6 bytes, and is carried in an Address (Address) 3 field in the Beacon frame.
The Cluster level CG generally takes a maximum value of 8 bytes, represents the level of Cluster, is used for comparing different Clusters during combination, and the Cluster with a small CG value is combined into the Cluster with a large CG value.
The service discovery frame SDF message is introduced below.
The SDF message is an Action Frame (Action Frame) specially defined for service discovery, and can be roughly divided into three types according to different functions: the SDF issues a Publish message, subscribes to a Subscribe message, and replies to a Follow-Up message, and generally, an indication bit is included in the SDF message to indicate which SDF message the SDF message is.
SDF Publish message: the NAN equipment is used for publishing services which can be provided by the NAN equipment or replying to the received SDF Subscribe messages sent by other NAN equipment;
SDF Subscribe message: for finding the service to be used;
SDF Follow-Up message: for replying to received SDF Publish messages or for negotiating more information.
Referring to fig. 2, fig. 2 is a flowchart illustrating a data transmission method according to an embodiment of the present application, where the data transmission method is applied to a first device, where the first device is a neighbor aware network NAN device in a NAN network, and as shown in the drawing, the data transmission method includes:
s201, when a first device detects that a target data playing request is met and the data transmission speed of a mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data;
the broadcasting of the first message may be that when the user enjoys video or music, the electronic device detects that there is no mobile network signal, or the data transmission speed of the mobile network is lower than a preset speed threshold, the first message is broadcasted to search for a required target data service, so that the first device may continue to play video or music even without the mobile network, and the first message may specifically be an sdfsubscript message.
The broadcasting of the first message may also be actively triggered when the user thinks that the remaining data traffic is small, for example, triggered by selecting a video request function key of the first device, and the triggering condition is not limited uniquely.
S202, the first device receives response messages from a plurality of second devices, and the response messages are used for indicating that the plurality of second devices contain the target data;
the first message may contain a name identifier of the target data, and the second device may extract a keyword of the name identifier in the first message when receiving the first message; searching local resources of the second equipment according to the keywords; and when the local resource is detected to contain the target data, the response message is sent to the first equipment, and when the local resource is detected not to contain the target data, the response message does not need to be sent to the first equipment.
The response message may specifically be an SDF Publish message.
The plurality of second devices may include all data of the target data, or may include partial data of the target data, which is not limited herein.
The plurality of second devices may include devices in the NAN network or devices in other NAN networks, the devices in the other NAN networks may receive the first message and send the response message through a relay device in the NAN network, the relay device is a NAN device having a relay function and is a NAN device existing in at least two NAN networks, and the relay device may forward the first message to the other NAN networks after receiving the first message broadcast by the first device.
S203, the first device selecting at least one target device for providing the target data from the plurality of second devices;
the specific implementation manner of selecting, by the first device, at least one target device for providing the target data from the plurality of second devices may be various, for example, the second device corresponding to the received first response message may be selected as the target device, or a device with a large amount of power in the plurality of second devices may be selected as the target device, and the like, which is not limited herein.
S204, the first device negotiates a transmission channel of the target data with the at least one target device.
In a specific implementation, for a transmission channel between the first device and at least one target device, the negotiation process may be that the first device performs transmission channel negotiation with the at least one target device through an SDF Follow-Up message.
S205, the first device receives the target data from the at least one target device through the negotiated transmission channel.
The first device may receive target data from at least one target device through each transmission channel, where the target data may also be transmitted through a transmission channel between the second device and the relay device and a transmission channel between the relay device and the first device, which is not limited herein.
It can be seen that, in the embodiment of the present application, the first device first detects a request for playing the target data, and when the data transmission speed of the mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data, then, receiving response messages from a plurality of second devices, the response messages being used to indicate that the plurality of second devices contain the target data, then, selecting at least one target device for providing the target data from the plurality of second devices, then, negotiating a transmission channel for the target data with the at least one target device, and finally, receiving the target data from the at least one target device through the negotiated transmission channel. It can be seen that when the first device needs target data but the data transmission speed of the mobile network is lower than the preset speed threshold, the target data is acquired from the target device including the target data through the NAN network by broadcasting the first message to other devices in the NAN network without the need of the mobile network or wasting data traffic, which is beneficial to the electronic device to acquire audio and video data without the mobile network data, and improves the convenience of data transmission.
In one possible example, the selecting at least one target device from the plurality of second devices for providing the target data includes:
determining the number of the at least one target device according to the data volume of the target data;
selecting the at least one target device for providing the target data from the plurality of second devices according to the number of the at least one target device;
the receiving the target data from the at least one target device through the negotiated transmission channel includes:
dividing the target data into a plurality of data segment tasks according to the number of the at least one target device, and distributing the data segment tasks to the at least one target device through the negotiated transmission channel;
and simultaneously receiving data segments in the target data corresponding to each target device from the at least one target device through the negotiated transmission channel.
The first device may pre-store a mapping relationship between the data amount interval and the number of the at least one target device, and the first device may determine the number of the at least one target device according to the mapping relationship.
The number of the plurality of data segment tasks is the same as the number of the at least one target device or the number of the data segment tasks is a multiple of the number of the at least one target device, which is not limited herein, and if each target device has two or more data segment tasks, the data segment before the time node corresponding to the data segment may be sent to the first device, and then the data segment after the time node corresponding to the data segment may be sent.
The dividing of the target data into a plurality of data segment tasks may be an average dividing of the target data into a plurality of data segment tasks, or a dividing of the target data into a plurality of data segment tasks with different data volumes according to performances (such as response speed, received signal strength, and the like) of different target devices, which is not limited herein.
The specific implementation manner of allocating the negotiated transmission channel to the at least one target device may be to send a start time point and an end time point of a data segment task to the at least one target device through an SDF Follow-Up message.
It can be seen that, in this example, the first device divides the target data into a plurality of data segments, and receives the data segments through a plurality of target devices, so as to facilitate the speed of data acquisition.
In this possible example, the selecting the at least one target device for providing the target data from the plurality of second devices according to the number of the at least one target device includes:
determining response speeds of the plurality of second devices according to the receiving time of the response message;
selecting the at least one target device for providing the target data from the plurality of second devices according to the order of the response speed and the number of the at least one target device.
And selecting the at least one target device according to the sequence of the response speed from fast to slow, wherein the response speed is faster as the receiving time is smaller.
As can be seen, in this example, the first device determines the at least one target device according to the response speeds of the plurality of second devices, instead of randomly selecting a target device from the plurality of second devices, and selects a target device with a fast response speed, which is beneficial to increasing the speed of target data transmission and increasing the data transmission efficiency.
In one possible example, the selecting the at least one target device for providing the target data from the plurality of second devices according to the number of the at least one target device includes:
determining Received Signal Strength (RSSI) of the plurality of second devices according to the response message;
selecting the at least one target device for providing the target data from the plurality of second devices according to the RSSI signal strength sequence and the number of the at least one target device.
And selecting the at least one target device according to the sequence of the RSSI from strong to weak.
As can be seen, in this example, the first device determines the at least one target device according to the RSSI signal strengths of the plurality of second devices, instead of randomly selecting a target device from the plurality of second devices, and selects a target device with a fast response speed, which is beneficial to improving the stability of target data transmission.
In this possible example, the number of the at least one target device is 1, and the selecting the at least one target device for providing the target data from the plurality of second devices according to the RSSI signal strength order and the number of the at least one target device includes:
selecting the second device with the strongest RSSI from the plurality of second devices as a first target device for providing the target data;
judging whether the first target equipment contains all data of the target data;
and when the first target device is judged to only contain partial data of the target data, selecting second devices containing data except the partial data in the target data from the plurality of second devices as second target devices.
The specific implementation manner of selecting the second device, which includes the data other than the partial data in the target data, from the plurality of second devices as the second target device may be to select the second device including the data other than the partial data in the target data from a fast to a slow response speed, or to select the second device including the data other than the partial data in the target data from a strong to a weak RSSI, which is not limited herein.
As can be seen, in this example, after the first device selects the target device, when it is determined that the first target device only includes partial data of the target data, the second target device is selected, which is beneficial to improving the integrity of data transmission.
In one possible example, the response message includes device capability information, and the selecting the at least one target device from the plurality of second devices for providing the target data according to the number of the at least one target device includes:
determining a selection sequence of the plurality of second devices according to the device capability information;
and selecting the at least one target device for providing the target data from the plurality of second devices according to the selection sequence and the number of the at least one target device, wherein all the at least one target device comprises all data of the target data.
The device capability information may include remaining power, CPU operating frequency, quality of target data resources, and the like, and the device capability information is associated with target data provision capability of the second device, and if the target data resources are tv drama videos, the device capability may further include the number of episodes after the current episode can be provided, so that the second device with a large amount of episode data can be used for data transmission all the time, the second device does not need to be replaced many times, and stability of data transmission is ensured.
The specific implementation manner of determining the selection order of the plurality of second devices according to the device capability information may be various, for example, the selection order may be firstly sorted according to the remaining power amount, when the remaining power amounts of any two second devices are the same, the two second devices are sorted according to other capability information, or each different capability information may correspond to an influence factor, the total score of each device is calculated according to the influence factor and the capability information, and the plurality of second devices are sorted according to the scores from high to low, which is not limited herein.
As can be seen, in this example, the first device sorts the plurality of second devices according to the device capability information of the local terminal carried by the second devices, and then selects at least one target device, which is beneficial to improving the stability of data transmission and avoiding the situation that transmission is interrupted or slow in transmission when the target data is not completely transmitted due to weak device capability.
In one possible example, prior to the broadcasting the first message, the method further comprises:
enabling a NAN function;
detecting the distance between the first equipment and each equipment in a preset area through the NAN function according to a preset ranging strategy;
screening the plurality of devices with the distances smaller than a preset distance threshold;
forming the NAN network with the plurality of devices and completing synchronization of each device in the NAN network.
First, the first device sends an FTM Request (FTM Request) to each device (e.g., hereinafter, referred to as a reference NAN device) in a preset area where the first device is to be subjected to ranging, where the FTM Request is used to Request a periodic time window, and after receiving the FTM Request, the reference NAN device may reply a message indicating acceptance or resetting of the time window according to its resource condition, capability, and the like. Wherein, the FTM Request is an Action Frame.
2. The reference NAN device and the first device both begin time capture if the preset time window is accepted by the reference NAN device. The time when the reference NAN device captures the reply message for the FTM Request from the reference NAN device to the first device is t1, and the time when the first device captures the reply message for the FTM Request received by the reference NAN device is t 2.
3. The first device replies an ACK (Acknowledgement) to the reply message to the reference NAN device, and captures a time when the ACK is sent as t3, and captures a time when the ACK is received as t 4.
4. If the first device is to complete ranging, the reference NAN device sends a ranging message to the first device, where the ranging message carries t1 and t 4.
Thus, the first device obtains four times, i.e. Time t1, Time t2, Time t3, and Time t4, so that the Round-Trip Time RTT (Round-Trip Time) of the message can be calculated as:
RTT=[(t4–t1)–(t3–t2)] (1)
the distance d between the first device and the reference NAN device may then be calculated as:
d=1/2*RTT*c (2)
where c is the speed of light, and may also be equal to the transmission speed of Wi-Fi signals.
Therefore, in this example, the first device triggers the NAN function based on the request, the NAN function is kept closed in a normal state, the electric quantity is saved, the first device can quickly screen out the potential devices conforming to the NAN network based on the distance detection, and the efficiency of NAN network creation is improved.
Referring to fig. 3, fig. 3 is a schematic flow chart of another data transmission method provided in the embodiment of the present application and applied to a first device, where the first device is a neighbor aware network NAN device in a NAN network, and as shown in the figure, the data transmission method includes:
s301, when detecting that a request for playing target data is received and a data transmission speed of a mobile network is lower than a preset speed threshold, a first device broadcasts a first message, where the first message is used for the first device to request the target data from a plurality of devices in the NAN network, except for the first device, and the target data is audio data and/or video data.
S302, the first device receives response messages from a plurality of second devices, and the response messages are used for indicating that the plurality of second devices contain the target data.
S303, the first device determines the number of at least one target device according to the data volume of the target data.
S304, the first device selects at least one target device for providing the target data from the plurality of second devices according to the number of the at least one target device.
S305, the first device negotiates a transmission channel of the target data with the at least one target device.
S306, the first device divides the target data into a plurality of data segment tasks according to the number of the at least one target device, and distributes the data segment tasks to the at least one target device through the negotiated transmission channel.
S307, the first device receives, through the negotiated transmission channel, a data segment in the target data corresponding to each target device from the at least one target device at the same time.
It can be seen that, in the embodiment of the present application, the first device first detects a request for playing the target data, and when the data transmission speed of the mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data, then, receiving response messages from a plurality of second devices, the response messages being used to indicate that the plurality of second devices contain the target data, then, selecting at least one target device for providing the target data from the plurality of second devices, then, negotiating a transmission channel for the target data with the at least one target device, and finally, receiving the target data from the at least one target device through the negotiated transmission channel. It can be seen that when the first device needs target data but the data transmission speed of the mobile network is lower than the preset speed threshold, the target data is acquired from the target device including the target data through the NAN network by broadcasting the first message to other devices in the NAN network without the need of the mobile network or wasting data traffic, which is beneficial to the electronic device to acquire audio and video data without the mobile network data, and improves the convenience of data transmission.
In addition, the first device divides the target data into a plurality of data segments, and the data segments are received by the plurality of target devices respectively, so that the data acquisition speed is improved, and the reasonability of data acquisition is improved by determining the number of the target devices according to the data volume.
Referring to fig. 4 in a manner consistent with the embodiment shown in fig. 2, fig. 4 is a flowchart illustrating another data transmission method provided in the embodiment of the present application, and the data transmission method is applied to a first device, where the first device is a neighbor aware network NAN device in a NAN network, and as shown in the figure, the data transmission method includes:
s401, when a target data playing request is detected and the data transmission speed of the mobile network is lower than a preset speed threshold value, the first device starts a NAN function, and the target data are audio data and/or video data.
S402, the first device detects the distance between the first device and each device in a preset area through the NAN function according to a preset ranging strategy.
S403, the first device screens the devices with the distance smaller than a preset distance threshold value.
S404, the first device and the plurality of devices form the NAN network and complete the synchronization of each device in the NAN network.
S405, the first device broadcasts a first message, where the first message is used for the first device to request the target data from the plurality of devices in the NAN network except the first device.
S406, the first device receives response messages from a plurality of second devices, wherein the response messages are used for indicating that the plurality of second devices contain the target data.
S407, the first device selects at least one target device for providing the target data from the plurality of second devices.
S408, the first device negotiates a transmission channel of the target data with the at least one target device.
S409, the first device receives the target data from the at least one target device through the negotiated transmission channel.
It can be seen that, in the embodiment of the present application, the first device first detects a request for playing the target data, and when the data transmission speed of the mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data, then, receiving response messages from a plurality of second devices, the response messages being used to indicate that the plurality of second devices contain the target data, then, selecting at least one target device for providing the target data from the plurality of second devices, then, negotiating a transmission channel for the target data with the at least one target device, and finally, receiving the target data from the at least one target device through the negotiated transmission channel. It can be seen that when the first device needs target data but the data transmission speed of the mobile network is lower than the preset speed threshold, the target data is acquired from the target device including the target data through the NAN network by broadcasting the first message to other devices in the NAN network without the need of the mobile network or wasting data traffic, which is beneficial to the electronic device to acquire audio and video data without the mobile network data, and improves the convenience of data transmission.
In addition, the first device triggers the NAN function based on the request, the NAN function is kept closed in a normal state, electric quantity is saved, potential devices meeting the NAN network can be rapidly screened out based on distance detection, and high efficiency of NAN network creation is improved.
Consistent with the embodiments shown in fig. 2, fig. 3, and fig. 4, please refer to fig. 5, fig. 5 is a schematic structural diagram of a first device according to an embodiment of the present application, as shown, the first device is a neighbor aware network NAN device in a NAN network, the first device includes a processor 501, a memory 502, a communication interface 503, and one or more programs 504, wherein the one or more programs 504 are stored in the memory 502 and configured to be executed by the processor 501, and the programs include instructions for performing the following steps;
when a target data playing request is detected and the data transmission speed of a mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data;
receiving response messages from a plurality of second devices, the response messages indicating that the plurality of second devices contain the target data;
selecting at least one target device from the plurality of second devices for providing the target data;
negotiating a transmission channel of the target data with the at least one target device;
receiving the target data from the at least one target device through the negotiated transmission channel.
It can be seen that, in the embodiment of the present application, the first device first detects a request for playing the target data, and when the data transmission speed of the mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data, then, receiving response messages from a plurality of second devices, the response messages being used to indicate that the plurality of second devices contain the target data, then, selecting at least one target device for providing the target data from the plurality of second devices, then, negotiating a transmission channel for the target data with the at least one target device, and finally, receiving the target data from the at least one target device through the negotiated transmission channel. It can be seen that when the first device needs target data but the data transmission speed of the mobile network is lower than the preset speed threshold, the target data is acquired from the target device including the target data through the NAN network by broadcasting the first message to other devices in the NAN network without the need of the mobile network or wasting data traffic, which is beneficial to the electronic device to acquire audio and video data without the mobile network data, and improves the convenience of data transmission.
In one possible example, in connection with the selecting at least one target device from the plurality of second devices for providing the target data, the instructions in the program are specifically for performing the following: determining the number of the at least one target device according to the data volume of the target data; and for selecting the at least one target device from the plurality of second devices for providing the target data in accordance with the number of the at least one target device;
in respect of the receiving the target data from the at least one target device over the negotiated transmission channel, the instructions in the program are specifically configured to: dividing the target data into a plurality of data segment tasks according to the number of the at least one target device, and distributing the data segment tasks to the at least one target device through the negotiated transmission channel; and the data segment receiving unit is used for simultaneously receiving the data segment in the target data corresponding to each target device in the at least one target device through the negotiated transmission channel.
In this possible example, in the aspect that the at least one target device for providing the target data is selected from the plurality of second devices according to the number of the at least one target device, the instructions in the program are specifically configured to perform the following operations: determining response speeds of the plurality of second devices according to the receiving time of the response message; and a step for selecting the at least one target device for providing the target data from the plurality of second devices according to the order of the response speed and the number of the at least one target device.
In one possible example, in the aspect that the at least one target device for providing the target data is selected from the plurality of second devices according to the number of the at least one target device, the instructions in the program are specifically configured to perform the following operations: determining received signal strengths, RSSIs, of the plurality of second devices according to the response messages; and selecting the at least one target device for providing the target data from the plurality of second devices according to the signal strength sequence of the RSSIs and the number of the at least one target device.
In this possible example, the number of the at least one target device is 1, and in the aspect that the at least one target device for providing the target data is selected from the plurality of second devices according to the RSSI signal strength order and the number of the at least one target device, the instructions in the program are specifically configured to perform the following operations: selecting the second device with the strongest RSSI from the plurality of second devices as a first target device for providing the target data; and the first target device is used for judging whether all data of the target data are contained in the first target device; and when the first target device is judged to only contain partial data of the target data, selecting second devices containing data except the partial data of the target data from the plurality of second devices as second target devices.
In one possible example, the response message includes device capability information, and in the aspect that the at least one target device for providing the target data is selected from the plurality of second devices according to the number of the at least one target device, the instructions in the program are specifically configured to perform the following operations: determining a selection sequence of the plurality of second devices according to the device capability information; and the target device is used for selecting the at least one target device for providing the target data from the plurality of second devices according to the selection sequence and the number of the at least one target device, wherein all the at least one target device comprises all data of the target data.
In one possible example, the program further includes instructions for performing the steps of: enabling a NAN function prior to the broadcasting of the first message; the NAN function is used for detecting the distance between the first equipment and each equipment in a preset area according to a preset ranging strategy; and the device is used for screening the plurality of devices of which the distances are smaller than a preset distance threshold; and means for forming the NAN network with the plurality of devices and completing synchronization of each device in the NAN network.
The above description has introduced the solution of the embodiment of the present application mainly from the perspective of the method-side implementation process. It will be appreciated that the first device, in order to carry out the above-described functions, comprises corresponding hardware structures and/or software modules for performing the respective functions. Those of skill in the art will readily appreciate that the present application is capable of hardware or a combination of hardware and computer software implementing the various illustrative elements and algorithm steps described in connection with the embodiments provided herein. Whether a function is performed as hardware or computer software drives hardware depends upon the particular application and design constraints imposed on the solution. 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 application.
In the embodiment of the present application, the first device may be divided into the functional units according to the above method example, for example, each functional unit may be divided corresponding to each function, or two or more functions may be integrated into one processing unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit. It should be noted that the division of the unit in the embodiment of the present application is schematic, and is only a logic function division, and there may be another division manner in actual implementation.
Fig. 6 is a block diagram of functional units of a data transmission device 600 according to an embodiment of the present application. The data transmission apparatus 600 is applied to a first device, which is a neighbor aware network NAN device, the data transmission apparatus 600 includes a broadcasting unit 601, a receiving unit 602, a selecting unit 603, and a communication unit 604, wherein,
the broadcasting unit 601 is configured to broadcast a first message when it is detected that a target data playing request is made and a data transmission speed of a mobile network is lower than a preset speed threshold, where the first message is used for the first device to request the target data from a plurality of devices in the NAN network, where the plurality of devices are devices other than the first device, and the target data is audio data and/or video data;
the receiving unit 602 is configured to receive response messages from a plurality of second devices, where the response messages are used to indicate that the plurality of second devices contain the target data;
the selecting unit 603 is configured to select at least one target device for providing the target data from the plurality of second devices;
the communication unit 604 is configured to negotiate a transmission channel of the target data with the at least one target device;
the receiving unit 602 is further configured to receive the target data from the at least one target device through the negotiated transmission channel.
It can be seen that, in the embodiment of the present application, the first device first detects a request for playing the target data, and when the data transmission speed of the mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data, then, receiving response messages from a plurality of second devices, the response messages being used to indicate that the plurality of second devices contain the target data, then, selecting at least one target device for providing the target data from the plurality of second devices, then, negotiating a transmission channel for the target data with the at least one target device, and finally, receiving the target data from the at least one target device through the negotiated transmission channel. It can be seen that when the first device needs target data but the data transmission speed of the mobile network is lower than the preset speed threshold, the target data is acquired from the target device including the target data through the NAN network by broadcasting the first message to other devices in the NAN network without the need of the mobile network or wasting data traffic, which is beneficial to the electronic device to acquire audio and video data without the mobile network data, and improves the convenience of data transmission.
In a possible example, in terms of the selecting at least one target device for providing the target data from the plurality of second devices, the selecting unit 603 is specifically configured to: determining the number of the at least one target device according to the data volume of the target data; and for selecting the at least one target device from the plurality of second devices for providing the target data in accordance with the number of the at least one target device;
in respect that the negotiated transmission channel receives the target data from the at least one target device, the communication unit 604 is specifically configured to: dividing the target data into a plurality of data segment tasks according to the number of the at least one target device, and distributing the data segment tasks to the at least one target device through the negotiated transmission channel; and the data segment receiving unit is used for simultaneously receiving the data segment in the target data corresponding to each target device in the at least one target device through the negotiated transmission channel.
In this possible example, in the aspect that the at least one target device for providing the target data is selected from the plurality of second devices according to the number of the at least one target device, the selecting unit 603 is specifically configured to: determining response speeds of the plurality of second devices according to the receiving time of the response message; and a step for selecting the at least one target device for providing the target data from the plurality of second devices according to the order of the response speed and the number of the at least one target device.
In a possible example, in the aspect that the at least one target device for providing the target data is selected from the plurality of second devices according to the number of the at least one target device, the selecting unit 603 is specifically configured to: determining received signal strengths, RSSIs, of the plurality of second devices according to the response messages; and selecting the at least one target device for providing the target data from the plurality of second devices according to the signal strength sequence of the RSSIs and the number of the at least one target device.
In this possible example, the number of the at least one target device is 1, and in terms of selecting the at least one target device for providing the target data from the plurality of second devices according to the RSSI signal strength sequence and the number of the at least one target device, the selecting unit 603 is specifically configured to: selecting the second device with the strongest RSSI from the plurality of second devices as a first target device for providing the target data; and the first target device is used for judging whether all data of the target data are contained in the first target device; and when the first target device is judged to only contain partial data of the target data, selecting second devices containing data except the partial data of the target data from the plurality of second devices as second target devices.
In a possible example, the response message includes device capability information, and in the aspect that the at least one target device for providing the target data is selected from the plurality of second devices according to the number of the at least one target device, the selecting unit 603 is specifically configured to: determining a selection sequence of the plurality of second devices according to the device capability information; and the target device is used for selecting the at least one target device for providing the target data from the plurality of second devices according to the selection sequence and the number of the at least one target device, wherein all the at least one target device comprises all data of the target data.
In one possible example, the data transmission apparatus 600 further comprises a setup unit, before the broadcasting of the first message, for: enabling a NAN function; the NAN function is used for detecting the distance between the first equipment and each equipment in a preset area according to a preset ranging strategy; and the device is used for screening the plurality of devices of which the distances are smaller than a preset distance threshold; and means for forming the NAN network with the plurality of devices and completing synchronization of each device in the NAN network.
The broadcasting unit 601, the receiving unit 602, and the communication unit 604 may be transceivers or communication interfaces, the selecting unit 603 may be a processor, and the establishing unit may be a processor or a transceiver.
Embodiments of the present application also provide a computer storage medium, where the computer storage medium stores a computer program for electronic data exchange, and the computer program enables a computer to execute part or all of the steps of any one of the data transmission methods as described in the above method embodiments, and the computer includes a first device.
Embodiments of the present application also provide a computer program product comprising a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform some or all of the steps of any of the data transmission methods as described in the above method embodiments, the computer comprising a first device.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present application is not limited by the order of acts described, as some steps may occur in other orders or concurrently depending on the application. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required in this application.
In the foregoing embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus may be implemented in other manners. For example, the above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one type of division of logical functions, and there may be other divisions when actually implementing, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not implemented. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of some interfaces, devices or units, and may be an electric 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 application 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 integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable memory. Based on such understanding, the technical solution of the present application may be substantially implemented or a part of or all or part of the technical solution contributing to the prior art may be embodied in the form of a software product stored in a memory, and including several 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 described in the embodiments of the present application. And the aforementioned memory comprises: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic or optical disk, and other various media capable of storing program codes.
Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments may be performed by associated hardware as instructed by a program, which may be stored in a computer-readable memory, which may include: flash Memory disks, Read-Only memories (ROMs), Random Access Memories (RAMs), magnetic or optical disks, and the like.
The foregoing detailed description of the embodiments of the present application has been presented to illustrate the principles and implementations of the present application, and the above description of the embodiments is only provided to help understand the method and the core concept of the present application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (9)

1. A data transmission method is applied to a first device, wherein the first device is a Neighbor Awareness Network (NAN) device in a NAN network, and the method comprises the following steps:
when a target data playing request is detected and the data transmission speed of a mobile network is lower than a preset speed threshold, broadcasting a first message, wherein the first message is used for the first device to request the target data from a plurality of devices except the first device in the NAN network, and the target data is audio data and/or video data;
receiving response messages from a plurality of second devices, the response messages indicating that the plurality of second devices contain the target data;
selecting at least one target device from the plurality of second devices for providing the target data, comprising: determining the number of the at least one target device according to the data volume of the target data, and selecting the at least one target device for providing the target data from the plurality of second devices according to the number of the at least one target device;
negotiating a transmission channel of the target data with the at least one target device;
receiving the target data from the at least one target device over the negotiated transmission channel, comprising: dividing the target data into a plurality of data segment tasks according to the number of the at least one target device, distributing the data segment tasks to the at least one target device through the transmission channel negotiated, and simultaneously receiving the data segments in the target data corresponding to each target device from the at least one target device through the transmission channel negotiated.
2. The method of claim 1, wherein selecting the at least one target device from the plurality of second devices for providing the target data according to the number of the at least one target device comprises:
determining response speeds of the plurality of second devices according to the receiving time of the response message;
selecting the at least one target device for providing the target data from the plurality of second devices according to the order of the response speed and the number of the at least one target device.
3. The method of claim 1, wherein selecting the at least one target device from the plurality of second devices for providing the target data according to the number of the at least one target device comprises:
determining received signal strengths, RSSIs, of the plurality of second devices according to the response messages;
selecting the at least one target device for providing the target data from the plurality of second devices according to the RSSI signal strength sequence and the number of the at least one target device.
4. The method of claim 3, wherein the number of the at least one target device is 1, and wherein selecting the at least one target device from the plurality of second devices for providing the target data according to the RSSI signal strength sequence and the number of the at least one target device comprises:
selecting the second device with the strongest RSSI from the plurality of second devices as a first target device for providing the target data;
judging whether the first target equipment contains all data of the target data;
and when the first target device is judged to only contain partial data of the target data, selecting second devices containing data except the partial data in the target data from the plurality of second devices as second target devices.
5. The method of claim 1, wherein the response message includes device capability information, and wherein selecting the at least one target device from the plurality of second devices for providing the target data according to the number of the at least one target device comprises:
determining a selection sequence of the plurality of second devices according to the device capability information;
and selecting the at least one target device for providing the target data from the plurality of second devices according to the selection sequence and the number of the at least one target device, wherein all the at least one target device comprises all data of the target data.
6. The method of any of claims 1-5, wherein prior to broadcasting the first message, the method further comprises:
enabling a NAN function;
detecting the distance between the first equipment and each equipment in a preset area through the NAN function according to a preset ranging strategy;
screening the plurality of devices with the distances smaller than a preset distance threshold;
forming the NAN network with the plurality of devices and completing synchronization of each device in the NAN network.
7. The data transmission device is applied to a first device, the first device is a Neighbor Awareness Network (NAN) device in a NAN network, the data transmission device comprises a broadcasting unit, a receiving unit, a selecting unit and a communication unit, wherein:
the broadcast unit is configured to broadcast a first message when a target data play request is detected and a data transmission speed of a mobile network is lower than a preset speed threshold, where the first message is used for the first device to request the target data from a plurality of devices in the NAN network except the first device, and the target data is audio data and/or video data;
the receiving unit is configured to receive response messages from a plurality of second devices, where the response messages are used to indicate that the plurality of second devices contain the target data;
the selecting unit is configured to select at least one target device for providing the target data from the plurality of second devices, and includes: determining the number of the at least one target device according to the data volume of the target data, and selecting the at least one target device for providing the target data from the plurality of second devices according to the number of the at least one target device;
the communication unit is used for negotiating a transmission channel of the target data with the at least one target device;
the receiving unit is further configured to receive the target data from the at least one target device through the negotiated transmission channel, and includes: dividing the target data into a plurality of data segment tasks according to the number of the at least one target device, distributing the data segment tasks to the at least one target device through the transmission channel negotiated, and simultaneously receiving the data segments in the target data corresponding to each target device from the at least one target device through the transmission channel negotiated.
8. A first device, comprising: a processor, memory, and one or more programs; the one or more programs stored in the memory and configured to be executed by the processor, the programs comprising instructions for performing the steps in the method as described in any of claims 1-6.
9. A computer-readable storage medium, characterized in that a computer program for electronic data exchange is stored, wherein the computer program causes a computer to perform the method according to any of claims 1-6, the computer comprising a first device.
CN201810913287.5A 2018-08-09 2018-08-09 Data transmission method and related product Active CN109089246B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810913287.5A CN109089246B (en) 2018-08-09 2018-08-09 Data transmission method and related product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810913287.5A CN109089246B (en) 2018-08-09 2018-08-09 Data transmission method and related product

Publications (2)

Publication Number Publication Date
CN109089246A CN109089246A (en) 2018-12-25
CN109089246B true CN109089246B (en) 2021-04-06

Family

ID=64834300

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810913287.5A Active CN109089246B (en) 2018-08-09 2018-08-09 Data transmission method and related product

Country Status (1)

Country Link
CN (1) CN109089246B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110392423B (en) * 2019-06-28 2022-02-11 西安万像电子科技有限公司 Data transmission method, system and equipment
CN112055175B (en) * 2020-08-28 2023-03-24 浙江大华技术股份有限公司 Video partition-based negotiation transmission method, electronic device and recording medium
CN113596879A (en) * 2021-07-30 2021-11-02 浙江大华技术股份有限公司 Data transmission method and device of wireless equipment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101621793A (en) * 2008-06-30 2010-01-06 华为技术有限公司 Quick switching method and device based on decentralization mobility management business architecture
CN105637951A (en) * 2013-10-18 2016-06-01 高通股份有限公司 Systems and methods for establishing synchronization across multiple networks and participating stas via operations on a known common channel
CN108174420A (en) * 2018-02-02 2018-06-15 广东欧珀移动通信有限公司 Method for switching network, device, terminal and storage medium

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9949168B2 (en) * 2015-09-24 2018-04-17 Qualcomm Incorporated Reliable data channel over periodic discovery messages

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101621793A (en) * 2008-06-30 2010-01-06 华为技术有限公司 Quick switching method and device based on decentralization mobility management business architecture
CN105637951A (en) * 2013-10-18 2016-06-01 高通股份有限公司 Systems and methods for establishing synchronization across multiple networks and participating stas via operations on a known common channel
CN108174420A (en) * 2018-02-02 2018-06-15 广东欧珀移动通信有限公司 Method for switching network, device, terminal and storage medium

Also Published As

Publication number Publication date
CN109089246A (en) 2018-12-25

Similar Documents

Publication Publication Date Title
CN115087059B (en) Cell reselection method and device and communication equipment
CN108541044B (en) Method and device for joining proximity-aware network device group
US20170006117A1 (en) Service discovery and topology management
US11071092B2 (en) Response message transmission method and apparatus
KR102059461B1 (en) Communication apparatus, control method, and computer-readable storage medium
CN109089246B (en) Data transmission method and related product
EP2938144B1 (en) Service announcement message transmission method and device
KR102035171B1 (en) Communication apparatus, control method, and computer-readable storage medium
EP2031810A1 (en) System and method of zigbee communication for selecting and gaining access to zigbee network
US9565709B2 (en) Wireless communication device and method capable of peer-to-peer interconnection
EP3400736B1 (en) Sharing network feedback information using a device-to-device link
CN113079555B (en) Network resource sharing method and related device
US20170374690A1 (en) Indication of Attributes of Backhaul Connections of Access Points
CN109005044B (en) Data transmission control method and related device
US9686712B2 (en) Method and device for solving congestion in device to device communication
CN106465251B (en) System and method for utilizing stored high-level information
US9820117B1 (en) Methods and apparatus for advertising a service in a wireless network
CN103814591A (en) Communication method, access network equipment and UE (user equipment) of different-format networks
CN113455026A (en) Access method and communication device
US8000281B2 (en) System and method for providing multicast/broadcast services in a wireless network
CN109173267B (en) Game pairing method and related product
CN113163510B (en) Communication networking method, device and storage medium
CN113179509A (en) Self-networking method and device based on WiFi, storage medium and wireless node
CN109067882B (en) Data sharing method and related product
US20220400366A1 (en) Method and device for providing uwb service

Legal Events

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