CN107343325A - A kind of data transmission method, device and terminal - Google Patents

A kind of data transmission method, device and terminal Download PDF

Info

Publication number
CN107343325A
CN107343325A CN201710495347.1A CN201710495347A CN107343325A CN 107343325 A CN107343325 A CN 107343325A CN 201710495347 A CN201710495347 A CN 201710495347A CN 107343325 A CN107343325 A CN 107343325A
Authority
CN
China
Prior art keywords
direct
terminal
communication connection
data
user data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201710495347.1A
Other languages
Chinese (zh)
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 CN201710495347.1A priority Critical patent/CN107343325A/en
Publication of CN107343325A publication Critical patent/CN107343325A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup

Abstract

The embodiment of the invention discloses a kind of data transmission method, device and terminal, wherein, method includes:Establish the first direct-connected communication connection with second terminal, using described first it is direct-connected communicate to connect to second terminal transmit user data when, obtain the link information on the second direct-connected communication connection, and the attribute information of the user data;Judged whether to meet the default set up the condition for establishing the second direct-connected communication connection according to the link information and the attribute information;When meeting the set up the condition, the described second direct-connected communication connection for establishing between the first terminal and the second terminal;It is switched in the described second direct-connected communication connection to the second terminal and transmits the user data.The embodiment of the present invention can be adaptive selected direct-connected communication connection and carry out data transmission, and meet the diversified demand of data transfer.

Description

A kind of data transmission method, device and terminal
Technical field
The present invention relates to communication technical field, and in particular to a kind of data transmission method, device and terminal.
Background technology
A kind of direct-connected communication service of communication of terminal, (such as Bluetooth communication, shares due to establishing direct-connected communication connection between terminal Wi-Fi hotspot communicates) direct transmission of the data in terminal room can be realized, without being forwarded by third party (such as base station), because This, direct-connected communication can improve transmission rate, shortens transmission time and reduce energy expenditure.
The content of the invention
The embodiments of the invention provide a kind of data transmission method, device and terminal, can be adaptive selected direct-connected communication Connection carries out data transmission, and meets the diversified demand of data transfer.
In a first aspect, the embodiment of the present invention provides a kind of data transmission method, including:
Establish the first direct-connected communication connection with second terminal;
Using described first it is direct-connected communicate to connect transmit user data to second terminal when, obtain direct-connected logical on second Believe the link information of connection, and the attribute information of the user data;
Judge whether to meet according to the link information and the attribute information default to establish the second direct-connected communication connection Set up the condition;
When meeting the set up the condition, described second established between the first terminal and the second terminal is direct-connected Communication connection;
It is switched in the described second direct-connected communication connection to the second terminal and transmits the user data.
Second aspect, the embodiments of the invention provide a kind of data processing equipment, described device includes:
Module is established, for establishing the first direct-connected communication connection with second terminal;
Acquisition module, for using described first it is direct-connected communicate to connect to second terminal transmit user data when, obtain close In the link information of the second direct-connected communication connection, and the attribute information of the user data;
Judge module, for judging whether to meet according to the link information and the attribute information default to establish second The set up the condition of direct-connected communication connection;
It is described to establish module, it is additionally operable to when meeting the set up the condition, establishes the first terminal and described second eventually The described second direct-connected communication connection between end;
Handover module, the user data is transmitted in the described second direct-connected communication connection for being switched to.
The third aspect, the embodiments of the invention provide a kind of terminal, the terminal includes:Processor and memory, it is described Processor is connected with the memory by bus, and the memory storage has executable program code, and the processor is used for The executable program code is called, performs the data transmission method that first aspect of the embodiment of the present invention provides.
Fourth aspect, the embodiments of the invention provide a kind of computer-readable recording medium, wherein, it is described computer-readable Storage medium stores the computer program for electronic data interchange, wherein, the computer program causes computer to perform such as Perform the data transmission method that first aspect of the embodiment of the present invention provides.
As can be seen that in the embodiment of the present invention, the efficiency of transmission of data can be more efficiently improved, and in certain journey Terminal energy consumption can be saved on degree.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing There is the required accompanying drawing used in technology description to be briefly described, it should be apparent that, drawings in the following description are only this Some embodiments of invention, for those of ordinary skill in the art, on the premise of not paying creative work, can be with Other accompanying drawings are obtained according to these accompanying drawings.
Fig. 1 is a kind of network diagram of data transfer provided in an embodiment of the present invention;
Fig. 2 is a kind of schematic flow sheet of data transmission method provided in an embodiment of the present invention;
Fig. 3 is the schematic flow sheet of another data transmission method provided in an embodiment of the present invention;
Fig. 4 is a kind of structural representation of data transmission device provided in an embodiment of the present invention;
Fig. 5 is a kind of structural representation of terminal provided in an embodiment of the present invention.
Embodiment
In order that those skilled in the art more fully understand the present invention program, below in conjunction with the embodiment of the present invention Accompanying drawing, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment is only Part of the embodiment of the present invention, rather than whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art The every other embodiment obtained under the premise of creative work is not made, belongs to the scope of protection of the invention.
Term " first ", " second " in description and claims of this specification and above-mentioned accompanying drawing etc. are to be used to distinguish Different objects, rather than for describing particular order.In addition, term " comprising " and " having " and their any deformations, it is intended that It is to cover non-exclusive include.Such as process, method, system, product or the equipment for containing series of steps or unit do not have The step of being defined in the step of having listed or unit, but alternatively also including not listing or unit, or alternatively also wrap Include for other intrinsic steps of these processes, method, product or equipment or unit.
Referenced herein " embodiment " is it is meant that the special characteristic, structure or the characteristic that describe can wrap in conjunction with the embodiments In at least one embodiment of the present invention.Each position in the description occur the phrase might not each mean it is identical Embodiment, nor the independent or alternative embodiment with other embodiments mutual exclusion.Those skilled in the art explicitly and Implicitly understand, embodiment described herein can be combined with other embodiments.
Mobile terminal involved by the embodiment of the present invention can include the various handheld devices with radio communication function, Mobile unit, wearable device, computing device or other processing equipments for being connected to radio modem, and various forms User equipment (User Equipment, UE), mobile station (Mobile Station, MS), terminal device (terminal Device) etc..For convenience of description, apparatus mentioned above is referred to as mobile terminal.The embodiment of the present invention is carried out below detailed It is thin to introduce.
With the development of the mobile communication communication technology, the direct-connected communication connection of various terminals also transport and give birth to by fortune, is such as based on WiFi Hotspot pattern, the direct-connected communication connection based on bluetooth mode, based near field communication mode or based on infrared mode, it is different direct-connected logical Letter connection has the characteristics of different, for example, direct-connected logical based on bluetooth mode, based near field communication mode and based on infrared mode Believe that the power consumption of connection is relatively low, the message transmission rate of the direct-connected communication connection based on Wi-Fi hotspot pattern is higher, based on infrared mould The security of the direct-connected communication connection of formula than relatively low, and send user data attribute information (data type of user data, Privacy of user data etc.) it is different, it is different to the demand of the user data transmission.
In one embodiment, if the data higher for privacy of the user data (carry password or user identity The data of information), first terminal can select the higher direct-connected communication link of data transmission security to fetch and transmit the number of users According to the security of data transfer can be improved;If the data type of the user data be multi-medium data (e.g., video data, Speech data, image data), first terminal can select data transmission quality or the higher direct-connected communication connection of transmission rate To transmit the user data, to improve the efficiency of the user data transmission;If the data type of the user data is short message Data, the direct-connected communication link that first terminal can select the power consumption of data transfer relatively low, which fetches, transmits the user data, Ke Yiwei The terminal amount of saving energy, to extend the cruising time of terminal.A kind of data transmission method, first terminal are provided based on this present invention The adaptively selected direct-connected communication connection of link information of attribute information and direct-connected communication connection that can be based on user data is carried out Data transfer, to meet the diversified demand of data transfer.
The embodiment of the invention discloses a kind of data transmission method, referring to Fig. 1, being provided in an embodiment of the present invention pass through It is direct-connected to communicate to connect the network diagram carried out data transmission.As shown in figure 1, the network includes first terminal 10 and its affiliated User and second terminal 20 and its affiliated user, also, established between first terminal 10 and second terminal 20 direct-connected Communication connection.By the direct-connected communication connection of foundation, user data can be transmitted between first terminal 10 and second terminal 20.
In embodiments of the present invention, it is direct-connected communication refer to directly be communicated between first terminal 10 and second terminal 20 and Without the help of base station (Base Station, abbreviation BS), server, WAP (Wireless Access Point, letter Claim WAP) etc. third party device, using first terminal 10 as send terminal, second terminal 20 conduct receiving terminal exemplified by, when first When terminal 10 sends user data to second terminal 20 by the direct-connected communication connection, the user data is direct from first terminal 10 Second terminal 20 is sent to, and without any third party device, that is, do not need the forwarding of any third party device.
In one embodiment, the direct-connected communication connection can include bluetooth, infrared, Wireless Fidelity (Wireless Fidelity, abbreviation Wi-Fi), the connection such as near-field communication (Near Field Communication, abbreviation NFC).It should be understood that The direct-connected communication connection can initiate direct-connected communication connection request by any one party in first terminal 10 and second terminal 20 And establish.
In one embodiment, direct-connected communication connection being established between first terminal 10 and second terminal 20 can specifically wrap Include:First direct-connected communication connection is established based on the first transmission means between first terminal 10 and second terminal 20;This is first direct-connected Communicate to connect such as can be based on bluetooth, infrared, NFC communication connection;In one embodiment, first terminal 10 and Any one party in two terminals 20 can initiate Bluetooth pairing request, in order to establish between first terminal 10 and second terminal 20 The first direct-connected communication connection;Second direct-connected communication is established based on the second transmission means between first terminal 10 and second terminal 20 Connection, the second direct-connected communication connection for example can be that Wi-Fi Hotspot connects, any in first terminal 10 and second terminal 20 One side can open Wi-Fi Hotspot, in order to establish the second direct-connected communication connection between first terminal 10 and second terminal 20.
In one embodiment, when establishing the second direct-connected communication connection, first terminal 10 and second terminal 20 can be The connection data of the second transmission means of interaction in the first direct-connected communication connection established, the connection data for example can be Wi-Fi The user name and access pin of focus;And establish the second direct-connected communication link based on the second transmission means based on the connection data Connect.
When establishing the second direct-connected communication connection, terminal power can be first considered, if electricity is higher than default electricity threshold Value, then the mode of Wi-Fi hotspot is directly based upon, the Wi-Fi hotspot connection established between first terminal 10 and second terminal 20, established Second direct-connected communication connection.If electricity is less than default power threshold, it is direct-connected logical can first to establish bluetooth etc. first Letter is connected, then the connection data of the second transmission means are interacted in the first direct-connected communication connection, and base is established based on the connection data In the second direct-connected communication connection of the second transmission means.
In one embodiment, when establishing the second direct-connected communication connection, first terminal 10 and second terminal 20 can lead to Over-scan the connection data that Quick Response Code interacts the second transmission means;And established based on the connection data based on the second transmission means Second direct-connected communication connection.
Wherein, the power consumption values of the first direct-connected communication connection when carrying out data interaction are less than the second direct-connected communication connection Carry out power consumption values during data interaction.Also, power consumption values when the first direct-connected communication connection carries out data interaction are less than first Power consumption values between terminal 10 and second terminal 20 during the connection data of the second transmission means of interaction.
In one embodiment, a direct-connected communications buttons can be set, opened when user clicks on the direct-connected communications buttons During direct-connected communication function, first terminal 10 and second terminal 20 can automatically turn on bluetooth or NFC in terminal etc. and be used to build The functional module of vertical first direct-connected communication connection, and start the Wi-Fi hotspot function in terminal or WiFi scan functions, in order to Establish the second direct-connected communication connection based on Wi-Fi hotspot.
In one embodiment, first terminal 10 can establish the first direct-connected communication connection with second terminal 20, and first eventually End 10 using first based on bluetooth mode it is direct-connected communicate to connect to second terminal 20 transmit user data when, can obtain on The link information of second direct-connected communication connection, and the attribute information of the user data, determine that second is direct-connected according to the link information The mode type of communication connection is based on Wi-Fi hotspot pattern, and determines according to the attribute information data type of the user data For image data (size of image data is 1G), due to when user data type is image data, using based on WiFi heat The transmission duration of the direct-connected communication connection of dot pattern is less than the transmission duration using the direct-connected communication connection based on bluetooth mode, because This meets the default set up the condition on establishing the second direct-connected communication connection according to the link information and attribute information determination, The direct-connected communication connection of second based on Wi-Fi hotspot pattern established between the first terminal and the second terminal, first terminal 10 It can be switched in the second direct-connected communication connection and transmit the user data to second terminal 20, wherein, it is direct-connected by second Communication connection transmits transmission duration required during the user data and transmits the user data less than by the first direct-connected communication connection When transmission duration.
In one embodiment, the use of first terminal 10 second based on Wi-Fi hotspot pattern is direct-connected communicates to connect to second When terminal 20 transmits user data, the attribute information of next user data can be obtained, according to and according to the attribute information it is true The data type of the fixed user data is short message data, due to when user data type is short message data, using based on The direct-connected communication connection of Wi-Fi hotspot pattern is much the same with using the transmission duration of the direct-connected communication connection based on bluetooth mode, And the power dissipation ratio of the direct-connected communication connection based on bluetooth mode is relatively low, first terminal can be switched to first based on bluetooth mode Direct-connected communicate to connect to second terminal transmits next user data.
The step of data transmission method in one embodiment of the present of invention is described in detail below.
Referring to Fig. 2, Fig. 2 is the embodiments of the invention provide a kind of schematic flow sheet of data transmission method, it is applied to Terminal including direct-connected communication connection can be established applied to smart mobile phone, tablet personal computer, Intelligent bracelet etc., as illustrated, this number Include according to transmission method:
S201, first terminal and second terminal establish the first direct-connected communication connection.
In one embodiment, first terminal and second terminal can establish the first direct-connected communication connection, and this is first direct-connected Communication connection can be the communication connection based on Wi-Fi hotspot pattern, the communication connection based on bluetooth mode, based on near-field communication One kind in the communication connection of pattern, communication connection based on infrared mode etc..
In one embodiment, if the first direct-connected communication connection is the communication connection based on bluetooth mode, first terminal Or any one party in second terminal initiates Bluetooth pairing request, other side responds Bluetooth pairing request, so as to set up at this The communication connection based on bluetooth mode between first terminal and the second terminal.
S202, using this first it is direct-connected communicate to connect to second terminal transmit user data when, first terminal obtain close In the link information of the second direct-connected communication connection, and the attribute information of the user data.
In one embodiment, first terminal using first it is direct-connected communicate to connect to second terminal transmit user data when, The link information on the second direct-connected communication access is obtained by way of checking communication configuration information or app scannings, and can Analyzed with the content to the user data to obtain the attribute information of the user data.
Wherein, link information can include the mode type of the second direct-connected communication connection, and the mode type can include base In Wi-Fi hotspot pattern etc., the information such as maximum transmission data amount threshold value or peak transfer rate can also be included, the present invention is to this It is not construed as limiting.
Wherein, the attribute information of user data can include data type, size of data (the i.e. data of the user data Amount) and data privacy etc..
Wherein, the second direct-connected communication connection can be the first direct-connected communication connection of direct-connected communication connection difference.
S203, first terminal judge whether to meet that default to establish this second straight according to the link information and the attribute information Connection letter establishment of connection condition, if satisfied, then first terminal can perform step S204, otherwise, terminates this flow.
In one embodiment, first terminal can judge whether to meet to preset according to the link information and the attribute information The set up the condition on establishing the second direct-connected communication connection, when meeting condition, step S204 can be performed, so as to Based on the adaptively selected direct-connected communication connection of the link information and the attribute information and the user data is transmitted, to meet that data pass Defeated variation needs, otherwise terminate this flow, i.e., transmit the user data using the first direct-connected communication connection.
Wherein, the default set up the condition on establishing the second direct-connected communication connection can be corresponding according to the mode type Performance parameter (such as the performance parameter include power consumption, data transmission quality, message transmission rate, the security of data transfer) And the attribute information considers setting, it can also be what is set according to individual subscriber hobby, when can also be that terminal is dispatched from the factory What manufacturer was set, this is not limited by the present invention.
If it should be noted that the data higher for privacy of the user data (carry password or user identity letter The data of breath), first terminal can select direct-connected communication link corresponding to the higher mode type of data transmission security to fetch The user data is transmitted, the security of data transfer can be improved;If the data type of the user data is multi-medium data (e.g., video data, speech data, image data), first terminal can select data transmission quality or transmission rate higher Mode type corresponding to direct-connected communication link fetch transmit the user data, to improve the efficiency of the user data transmission;If The data type of the user data is short message data, and first terminal can select the relatively low mode type of the power consumption of data transfer The user data is transmitted in corresponding direct-connected communication connection, can be the terminal amount of saving energy, to extend the cruising time of terminal.
For example, if the user data is carries the data of subscriber identity information, first terminal can be according to the use The attribute information of user data determines the user data as the higher data of privacy, if first terminal is according to the second direct-connected communication The link information of connection determines that the mode type of the second direct-connected communication connection is the pattern based on WiFi, due to based on WiFi's The security of second direct-connected communication connection of pattern is higher, thus first terminal can determine to meet it is default on establish this The set up the condition of two direct-connected communication connections.
In one embodiment, the data type of the user data is included in the attribute information, the link information includes should During the mode type of the second direct-connected communication connection, first terminal can realize step S203 by performing following steps:Inquiry Database, the mode type matched with each data type is have recorded in the database;According to the inquiry to the database As a result, when determining that the data type of the user data matches with the mode type that the link information includes, it is determined that meeting default The set up the condition for establishing the second direct-connected communication connection.
In one embodiment, first terminal can inquire about database, be determined and the user data according to the database The mode type of data type matching, however, it is determined that when the mode type gone out matches with the mode type that the link information includes, then It is determined that meet the default set up the condition for establishing the second direct-connected communication connection.
It should be noted that first terminal can establish database, the database is used to record and each data type The mode type of matching, for example, it is based on bluetooth mode that the database, which can record the mode type matched with short message data, Or based near field communication mode, it is based on Wi-Fi hotspot pattern to record the mode type matched with multi-medium data.
For example, if the user data type is short message data, first terminal inquires about the database, it is determined that short with this The mode type of match messages is based on bluetooth mode or based near field communication mode, if the pattern class that the link information includes Type is based on Wi-Fi hotspot pattern, it is determined that the mode type that the data type of the user data and the link information include is not Match somebody with somebody, further determine that and be unsatisfactory for the default set up the condition for establishing the second direct-connected communication connection;Otherwise, it determines the user data The mode type that data type includes with the link information matches, and determines to be unsatisfactory for default establishing the second direct-connected communication connection Set up the condition.
In further example, if the data type of user data is video data, first terminal inquires about the database, really The fixed mode type matched with the video data is based on Wi-Fi hotspot pattern, if the mode type that includes of the link information for based on Wi-Fi hotspot pattern, it is determined that the mode type that the data type of the user data includes with the link information matches, further It is determined that meet the default set up the condition for establishing the second direct-connected communication connection;Otherwise, it determines the data type of the user data with Mode type that the link information includes mismatches, and determine to be unsatisfactory for it is default establish the second direct-connected communication connection establish bar Part.
In one embodiment, the attribute information includes the data volume of the user data, and first terminal judges the number of users According to data volume whether the data-quantity threshold of the second direct-connected communication connection included with the link information matches;In matching, really Surely the default set up the condition for establishing the second direct-connected communication connection is met.
First terminal may determine that the second direct-connected the communication whether data volume of the user data includes with the link information The data-quantity threshold matching of connection, the i.e. data volume of the user data are second direct-connected less than or equal to including with the link information During the data-quantity threshold of communication connection, the second direct-connected communication link that the data volume of the user data and the link information include is determined The data-quantity threshold matching connect, and can determine to meet the default set up the condition for establishing the second direct-connected communication connection.
It should be noted that the data-quantity threshold of the second direct-connected communication connection can refer to that the second direct-connected communication connection is permitted Perhaps the maximum amount of data transmitted.
For example, if the second direct-connected communication connection is the communication connection based on Wi-Fi hotspot pattern, the attribute information Data volume (data volume 100M) including the user data, the data-quantity threshold of the second direct-connected communication connection is 1G, and first eventually End determines that the data-quantity threshold for the second direct-connected communication connection that the data volume of the user data includes with the link information matches;And It is determined that meet the default set up the condition for establishing the second direct-connected communication connection.
The second direct-connected communication connection that S203, first terminal are established between the first terminal and the second terminal.
In one embodiment, when meeting the set up the condition, first terminal can send the second direct-connected communication connection Data are accessed to the second terminal, or receive the access data for the second direct-connected communication connection that second terminal is sent, and root The second direct-connected communication connection established according to access data between the first terminal and the second terminal.
Wherein, the access data can include title, password or access interface etc. of access point, and the access data can be with Including trigger command, the second direct-connected communication connection is established for triggering terminal.
In one embodiment, should if the second direct-connected communication connection is the communication connection based on Wi-Fi hotspot pattern First terminal establishes Wi-Fi hotspot, and the access number of the Wi-Fi hotspot is sent to the second terminal using first direct-connected communicate to connect According to the access data are used to indicate the second terminal according to the access data access to the Wi-Fi hotspot, to establish first end The second direct-connected communication connection between end and the second terminal.
First terminal can open Wi-Fi hotspot function or open Wi-Fi hotspot access app, to establish Wi-Fi hotspot.And Can use this first it is direct-connected communicate to connect the access data that the Wi-Fi hotspot is sent to the second terminal, the access data are used for The second terminal is indicated according to the access data access to the Wi-Fi hotspot, to establish between the first terminal and the second terminal The second direct-connected communication connection.
It should be noted that the access data can include the title of Wi-Fi hotspot, the close of Wi-Fi hotspot can also be included Code, or the Quick Response Code generated according to title and password, can also include trigger command, should for triggering second terminal foundation Second direct-connected communication connection, the access data can also include other information, and the embodiment of the present invention is not construed as limiting.
For example, if the access data only have the title and trigger command of Wi-Fi hotspot, first terminal can this connect Enter data and be sent to second terminal, the trigger command that the access data include is used to indicate the second terminal according to Wi-Fi hotspot Title is linked into the Wi-Fi hotspot;If the access data include title, password and the trigger command of Wi-Fi hotspot, first terminal The access data can be sent to second terminal, the trigger command that the access data include be used for indicate the second terminal according to The title and password of Wi-Fi hotspot are linked into the Wi-Fi hotspot;If the access data include the title according to Wi-Fi hotspot, password The Quick Response Code and trigger command of generation, then first terminal can give the access data to second terminal, the access data include Trigger command be used for indicate that the second terminal is linked into the Wi-Fi hotspot according to the Quick Response Code;To establish the first terminal and be somebody's turn to do The second direct-connected communication connection between second terminal.
In one embodiment, if the second direct-connected communication connection is the communication connection based on Wi-Fi hotspot pattern, first Terminal can use the first direct-connected communication connection to receive the Wi-Fi hotspot access data that the second terminal is sent, according to the access Data establish the Wi-Fi hotspot, to establish the second direct-connected communication connection between the first terminal and the second terminal.
In one embodiment, established if the Wi-Fi hotspot is second terminal, first terminal can use this first straight Even communication connection receives the Wi-Fi hotspot access data that the second terminal is sent, to establish WiFi heat according to the access data Point, to establish the second direct-connected communication connection between the first terminal and the second terminal.
S204, first terminal are switched in the second direct-connected communication connection and transmit the user data to second terminal.
In one embodiment, the second direct-connected communication connection is established between the first terminal and the second terminal Afterwards, first terminal can be switched in the second direct-connected communication connection and transmit the user data, to meet the various of data transfer Change demand.
For example, first terminal establishes the first direct-connected communication connection with second terminal, and the first direct-connected communication connection is Communication connection based on bluetooth mode, first terminal transmit user data using the first direct-connected communicate to connect to second terminal, and The link information on the second direct-connected communication connection, and the attribute information of the user data are obtained, is determined according to the link information Second direct-connected communication connection is the communication connection based on Wi-Fi hotspot pattern, and the user data type is determined according to the attribute information For video data, first terminal can determine to meet the default set up the condition for establishing the second direct-connected communication connection, establish this The second direct-connected communication connection based on Wi-Fi hotspot pattern is established between one terminal and the second terminal, first terminal can use Second direct-connected communicate to connect to second terminal transmits the user data, wherein, the use is transmitted by the second direct-connected communication connection Required transmission duration is less than the transmission duration when user data is transmitted by the first direct-connected communication connection during user data.
In one embodiment, using first it is direct-connected communicate to connect to second terminal transmit user data when, judgement is No to possess the condition for establishing the second direct-connected communication connection, the communication quality of the second direct-connected communication connection is first direct-connected higher than this The communication quality of communication connection;When possessing the condition for establishing the second direct-connected communication connection, then establish the first terminal and be somebody's turn to do The second direct-connected communication connection between second terminal, and the use is transmitted by second direct-connected communicate to connect to the second terminal User data.
It should be noted that judge whether that first terminal can be referred to by possessing the condition for establishing the second direct-connected communication connection Whether detection first terminal or second terminal, which possess, is established the hardware condition of the second direct-connected communication connection (such as, if possess WiFi Module), it can also refer to whether first terminal detection second terminal opens direct-connected communication connection button, can also refer to detection the Whether one terminal searches the second direct-connected communication connection signal, or refers to whether first terminal receives second terminal transmission The access data of second direct-connected communication connection.
For example, it is direct-connected if detecting that first terminal receives second based on Wi-Fi hotspot pattern that second terminal is sent The access data of communication connection, it may be determined that possess the condition for establishing the second direct-connected communication connection, and establish the first terminal The second direct-connected communication connection between the second terminal, and transmitted by second direct-connected communicate to connect to the second terminal The user data.
In the embodiment of the present invention, first terminal using first it is direct-connected communicate to connect to second terminal transmit user data when, The link information on the second direct-connected communication connection, and the attribute information of the user data are obtained, according to the link information and is somebody's turn to do Attribute information judges whether to meet the default set up the condition for establishing the second direct-connected communication connection, when meeting the set up the condition, The second direct-connected communication connection established between the first terminal and the second terminal, is switched in the second direct-connected communication connection The user data is transmitted to second terminal, direct-connected communication connection can be adaptive selected and carried out data transmission, meet data transfer Diversified demand.
Referring to Fig. 3, Fig. 3 is that the embodiments of the invention provide the schematic flow sheet of another data transmission method, application In the terminal including direct-connected communication connection can be established applied to smart mobile phone, tablet personal computer, Intelligent bracelet etc., as illustrated, this Data transmission method includes:
S301, first terminal and second terminal establish the first direct-connected communication connection.
S302, using this first it is direct-connected communicate to connect to second terminal transmit user data when, first terminal obtain should The communication quality information of first direct-connected communication connection.
In one embodiment, using first it is direct-connected communicate to connect to second terminal transmit user data when, first eventually End can obtain the communication quality information of the first direct-connected communication connection, and the communication quality information can include signal to noise ratio, transmission The information such as speed, the bit error rate or bit error rate.
For example, first terminal can send test data by the first direct-connected communicate to connect to second terminal, and connect The feedback information on test data that second terminal is sent is received, first terminal can determine that this is first direct-connected according to feedback information The communication quality information of communication connection.
S303, first terminal judge whether the communication quality meets default switching condition, if then, execution step S304~ S305, if it is not, then performing step S306.
In one embodiment, first terminal may determine that whether the communication quality meets default switching condition, that is, Say, when the communication quality of the first direct-connected communication connection is poor, e.g., transmission rate is less than scheduled rate threshold value, and the bit error rate is higher than Predetermined threshold value, it may be determined that meet default switching condition, first terminal can perform step S304~S305;If first is direct-connected logical Believe that the communication quality of connection is preferable, it may be determined that be unsatisfactory for default switching condition, first terminal can perform step S306.
S304, the described second direct-connected communication connection established between the first terminal and the second terminal.
S305, by this second it is direct-connected communication connection transmit the user data.
In one embodiment, if the communication quality information meets default switching condition, or according to the link information and The attribute information determine meet it is default establish the second direct-connected communication connection set up the condition when, then can establish the first terminal The second direct-connected communication connection between the second terminal, and should to second terminal transmission by second direct-connected communicate to connect User data.
The link information of S306, acquisition on the second direct-connected communication connection, and the attribute information of the user data.
In one embodiment, if the communication quality information is unsatisfactory for default switching condition, first terminal can obtain On the link information of the second direct-connected communication connection, and the attribute information of the user data.
S307, according to the link information and the attribute information judge whether to meet default to establish the second direct-connected communication connection Set up the condition, if satisfied, then perform step S304~S305, otherwise, terminate this flow.
In one embodiment, first terminal determines to meet default to establish the according to the link information and the attribute information The set up the condition of two direct-connected communication connections, first terminal can perform step S304~S305, establish the second direct-connected communication connection, And the user data is transmitted using the second direct-connected communication connection, otherwise terminate this flow.
For example, first terminal establishes the first direct-connected communication connection with second terminal, and the first direct-connected communication connection is Based on the communication connection of Wi-Fi hotspot pattern, first terminal transmits number of users using the first direct-connected communicate to connect to second terminal According to first terminal obtains the communication quality information of the first direct-connected communication connection, determines that this is first direct-connected according to the communication quality The signal intensity of communication is less than preset strength threshold value, the base that first terminal can be established between the first terminal and the second terminal The user data is transmitted in the second direct-connected communication connection of bluetooth mode, and by the second direct-connected communication connection.If according to this Communication quality determines that the signal intensity of the first direct-connected communication is higher than preset strength threshold value, and first terminal can be obtained on second The link information of direct-connected communication connection, and the attribute information of the user data, the second direct-connected communication is determined according to the link information The communication connection based on bluetooth mode is connected as, determines that the user data type is short message data according to the attribute information, the One terminal can determine to meet the default set up the condition for establishing the second direct-connected communication connection, establish the first terminal with this second The second direct-connected communication connection based on bluetooth mode is established between terminal, first terminal can use the second direct-connected communication connection The user data is transmitted to second terminal, wherein, required energy consumption when transmitting the user data by the second direct-connected communication connection Value is less than the power consumption values when user data is transmitted by the first direct-connected communication connection.
In one embodiment, after first terminal performs step S305, following steps be can also carry out:Detect this second Whether direct-connected communication connection is abnormal;When the second direct-connected communication connection is abnormal, obtain in the user data data volume be less than it is pre- If the packet of data-quantity threshold, the user data includes multiple packets, in the first direct-connected communication connection to this second Terminal sends acquired packet.
In one embodiment, whether abnormal first terminal detects the second direct-connected communication connection;It is second direct-connected logical at this When letter connection is abnormal, the packet that data volume in the user data is less than preset data amount threshold value is obtained, the user data includes Multiple packets, acquired packet is sent to the second terminal in the first direct-connected communication connection.That is, at this Second it is direct-connected communication connection it is abnormal when, can by less packet in the user data using first it is direct-connected communication connection pass It is defeated, the validity of data transfer can be improved.
It should be noted that the second direct-connected abnormal transmission rate that can refer to the second direct-connected communication connection of communication connection Less than Preset Transfer rate-valve value or refer in preset time period (such as 10min), the user data has had not been transmitted.
For example, detect this second it is direct-connected communication connection occur data transmission bauds less than pre-set velocity threshold value, Or during the second direct-connected communication connection abnormal conditions such as signal intensity is poor, it is small that first terminal obtains data volume in the user data In the packet of preset data amount threshold value (such as 20M), the user data includes multiple packets, in the first direct-connected communication connection On acquired packet is sent to the second terminal.
In the embodiment of the present invention, using first it is direct-connected communicate to connect to second terminal transmit user data when, first eventually End can obtain the communication quality of the first direct-connected communication connection, and when communication quality meets switching condition, first terminal can be built Vertical second direct-connected communication connection, and the user data is sent using the second direct-connected communicate to connect to second terminal, in communication quality When being unsatisfactory for switching condition, the link information on the second direct-connected communication connection, and the attribute letter of the user data can be obtained Breath, according to the link information and the attribute information judge whether to meet it is default establish the second direct-connected communication connection establish bar Part, when meeting the set up the condition, the second direct-connected communication connection established between the first terminal and the second terminal, switching The user data is transmitted to second terminal on to the second direct-connected communication connection, direct-connected communication connection can be adaptive selected and carried out Data transfer, meet the diversified demand of data transfer.
Referring to Fig. 4, Fig. 4 is that the embodiments of the invention provide a kind of structural representation of data transmission device, the dress Put including:Establish module 401, acquisition module 402, judge module 403, handover module 404, detection module 405, wherein:
Module 401 is established, for establishing the first direct-connected communication connection with second terminal.
Acquisition module 402, for using described first it is direct-connected communicate to connect to second terminal transmit user data when, obtain Take the link information on the second direct-connected communication connection, and the attribute information of the user data.
Judge module 403, for judging whether to meet default foundation according to the link information and the attribute information The set up the condition of second direct-connected communication connection.
It is described to establish module 401, it is additionally operable to, when meeting the set up the condition, establish the first terminal and described second The described second direct-connected communication connection between terminal.
Handover module 404, the user data is transmitted in the described second direct-connected communication connection for being switched to.
It should be noted that the foundation of module 401 and the first direct-connected communication connection of second terminal are established, and it is straight using first Even communications user data, acquisition module 301 can be that the company on the second direct-connected communication connection is obtained based on communication module Information is connect, the attribute information of user data can also be obtained based on processor.Judge module 302, establish module 303, switching mould Block 304 can be based on computing device following steps:Judge whether to meet according to the link information and the attribute information The default set up the condition on establishing the second direct-connected communication connection;When meeting the set up the condition, described first is established eventually The described second direct-connected communication connection between end and the second terminal;It is switched in the described second direct-connected communication connection to second User data described in terminal transmission.
When the attribute information includes the data type of the user data, the judge module 403, specifically for looking into Database is ask, the mode type matched with each data type is have recorded in the database;According to the database Query Result, determine the described second direct-connected communication link that the data type of the user data and the link information include During the mode type matching connect, it is determined that meeting the default set up the condition for establishing the described second direct-connected communication connection.
When the attribute information includes the data volume of the user data, the judge module 403, specifically for judging Whether the data-quantity threshold of the second direct-connected communication connection included with the link information matches the data volume of the user data; In matching, it is determined that meeting the default set up the condition for establishing the described second direct-connected communication connection.
The acquisition module 402, be additionally operable to using first it is direct-connected communicate to connect to second terminal transmit user data when, Obtain the communication quality information of the described first direct-connected communication connection.
It is described to establish module 401, if being additionally operable to the communication quality information meets default switching condition, establish described the The described second direct-connected communication connection between one terminal and the second terminal, and transmitted by the described second direct-connected communication connection The user data;
The acquisition module 401, if being additionally operable to the communication quality information is unsatisfactory for default switching condition, perform described in Obtain the link information on the second direct-connected communication connection, and the step of attribute information of the user data.
Detection module 405, for using first it is direct-connected communicate to connect to second terminal transmit user data when, detection is No possess the condition for establishing the described second direct-connected communication connection, and the communication quality of the second direct-connected communication connection is higher than described the Connect the communication quality of communication connection always;
The handover module 404, it is additionally operable to when possessing the condition for establishing the described second direct-connected communication connection, then establish institute The described second direct-connected communication connection between first terminal and the second terminal is stated, and passes through the described second direct-connected communication connection The user data is transmitted to the second terminal.
The detection module 405, it is additionally operable to whether extremely to detect the described second direct-connected communication connection.
The acquisition module 401, be additionally operable to described second it is direct-connected communication connection it is abnormal when, obtain in the user data Data volume is less than the packet of preset data amount threshold value, and the user data includes multiple packets;
The handover module 404, it is additionally operable in the described first direct-connected communication connection send to the second terminal and is obtained The packet taken.
In one embodiment, the described second direct-connected communication connection is the communication connection based on Wi-Fi hotspot pattern, described Module 403 is established, specifically for establishing Wi-Fi hotspot;Institute is sent using the described first direct-connected communicate to connect to the second terminal The access data of Wi-Fi hotspot are stated, the access data are used to indicate the second terminal according to the access data access to institute Wi-Fi hotspot is stated, to establish the described second direct-connected communication connection between the first terminal and the second terminal.
It should be noted that the module 403 of establishing can be based on computing device following steps:Establish Wi-Fi hotspot; Using the described first direct-connected access data communicated to connect to the second terminal transmission Wi-Fi hotspot, the access data For indicate the second terminal according to it is described access data access to the Wi-Fi hotspot, to establish the first terminal and institute State the described second direct-connected communication connection between second terminal.
In one embodiment, the described second direct-connected communication connection is the communication connection based on Wi-Fi hotspot pattern, described Module 403 is established, specifically for the Wi-Fi hotspot using the described first direct-connected communication connection reception second terminal transmission Access data;Wi-Fi hotspot is established according to the access data, to establish between the first terminal and the second terminal The second direct-connected communication connection.
The module 403 of establishing can be based on computing device following steps:Using the described first direct-connected communication connection Receive the access data for the Wi-Fi hotspot that the second terminal is sent;Wi-Fi hotspot is established according to the access data, to establish The described second direct-connected communication connection between the first terminal and the second terminal.
During the present invention is implemented, attribute information and the connection letter of direct-connected communication connection that first terminal can be based on user data Cease adaptively selected direct-connected communication connection to carry out data transmission, to meet the diversified demand of data transfer.
Referring to Fig. 5, Fig. 5 is the structural representation the embodiments of the invention provide another terminal, the terminal can be with Including:At least one processor 501, such as CPU;At least one memory 502, communicator 503, above-mentioned processor 501, deposit Reservoir 502, communicator 503 are connected by bus 504.
Wherein, communicator 503, for messaging and direct-connected communication connection is established, communicator 503 can include logical Believe interface, transceiver etc..
Memory 502 is used for store instruction, and processor 501 calls the program code stored in memory 502.
In one embodiment, processor 501 calls the program code stored in memory 502, performs following operate:
The first direct-connected communication connection is established with second terminal;
Using described first it is direct-connected communicate to connect transmit user data to second terminal when, obtain direct-connected logical on second Believe the link information of connection, and the attribute information of the user data;
Judge whether to meet according to the link information and the attribute information default to establish the second direct-connected communication connection Set up the condition;
When meeting the set up the condition, described second established between the first terminal and the second terminal is direct-connected Communication connection;
It is switched in the described second direct-connected communication connection to the second terminal and transmits the user data.
It should be noted that using first it is direct-connected communicate to connect transmit user data to second terminal when, and first is straight When even communication connection is based on bluetooth mode communication connection, communicator 503 can be based on processor 501 by checking that communication is matched somebody with somebody The mode that confidence is ceased or app is scanned obtains the link information on the second direct-connected communication access, and processor 501 can be according to this Link information determines that the second direct-connected communication is the communication connection based on Wi-Fi hotspot pattern, and can be in the user data Appearance is analyzed to obtain the attribute information of the user data, and the data type for determining the user data according to the attribute information is Video data.Processor 501 can be determined to meet according to the link information and the attribute information it is default on establish this second The set up the condition of direct-connected communication connection, and being somebody's turn to do based on Wi-Fi hotspot pattern established between the first terminal and the second terminal Second direct-connected communication connection, the user data is transmitted in the second direct-connected communication connection to be switched to.
In one embodiment, processor 501 calls the program code stored in memory 502, the attribute information bag The data volume of the user data is included, can also carry out following operation:
Judge the number for the second direct-connected the communication connection whether data volume of the user data includes with the link information According to amount threshold value matching;
In matching, it is determined that meeting the default set up the condition for establishing the described second direct-connected communication connection.
In one embodiment, processor 501 calls the program code stored in memory 502, in the attribute information Include the data type of the user data, when the link information includes the mode type of the described second direct-connected communication connection, It can also carry out following operation:
Database is inquired about, the mode type matched with each data type is have recorded in the database;
According to the Query Result to the database, the data type and the connection for determining the user data are believed When ceasing the mode type matching of the described second direct-connected communication connection included, it is determined that meeting that default to establish described second direct-connected logical Believe establishment of connection condition.
In one embodiment, processor 501 calls the program code stored in memory 502, can also carry out following Operation:
Using first it is direct-connected communicate to connect transmit user data to second terminal when, obtain the first direct-connected communication link The communication quality information connect;
If the communication quality information meets default switching condition, establish the first terminal and the second terminal it Between the described second direct-connected communication connection, and pass through the described second direct-connected communication connection and transmit the user data;
If the communication quality information is unsatisfactory for default switching condition, the acquisition is performed on the second direct-connected communication link The link information connect, and the step of attribute information of the user data.
In one embodiment, processor 501 calls the program code stored in memory 502, can also carry out following Operation:
Using first it is direct-connected communicate to connect transmit user data to second terminal when, detect whether to possess and establish described the The condition of two direct-connected communication connections, the communication quality of the second direct-connected communication connection is higher than the described first direct-connected communication connection Communication quality;
When possessing the condition for establishing the described second direct-connected communication connection, then the first terminal and described second is established eventually The described second direct-connected communication connection between end, and by described second it is direct-connected communicate to connect to the second terminal transmission described in User data.
It should be noted that processor 501 can inquire about database, the number with the user data is determined according to the database According to the mode type of type matching, however, it is determined that when the mode type gone out matches with the mode type that the link information includes, then really Surely the default set up the condition for establishing the second direct-connected communication connection is met.
In one embodiment, processor 501 calls the program code stored in memory 502, direct-connected described second Communicate to connect for communication connection based on Wi-Fi hotspot pattern when, can also carry out following operation:
Establish Wi-Fi hotspot;
It is described using the described first direct-connected access data communicated to connect to the second terminal transmission Wi-Fi hotspot Access data be used for indicate the second terminal according to it is described access data access to the Wi-Fi hotspot, to establish described first The described second direct-connected communication connection between terminal and the second terminal.
It should be noted that communicator 503 can establish Wi-Fi hotspot based on processor 501, and by the Wi-Fi hotspot Access data be sent to second terminal, with indicate second terminal according to access data access arrive the Wi-Fi hotspot, complete foundation The described second direct-connected communication connection between the first terminal and the second terminal.
Wherein, the access data can include the title of Wi-Fi hotspot, can also include the password of Wi-Fi hotspot, Huo Zhegen The Quick Response Code generated according to title and password, can also include trigger command, and for triggering the second terminal, to establish this second direct-connected Communication connection, the access data can also include other information, and the embodiment of the present invention is not construed as limiting to this.
In one embodiment, processor 501 calls the program code stored in memory 502, direct-connected described second Communicate to connect for communication connection based on Wi-Fi hotspot pattern when, can also carry out following operation:
The access data for the Wi-Fi hotspot that the second terminal is sent are received using the described first direct-connected communication connection;
Wi-Fi hotspot is established according to the access data, to establish the institute between the first terminal and the second terminal State the second direct-connected communication connection.
It should be noted that communicator can receive the Wi-Fi hotspot that the second terminal is sent based on processor 501 Data are accessed, Wi-Fi hotspot can be established according to the access data, to establish being somebody's turn to do between the first terminal and the second terminal Second direct-connected communication connection.
In one embodiment, processor 501 calls the program code stored in memory 502, can also carry out following Operation:
Whether abnormal detect the described second direct-connected communication connection;
Described second it is direct-connected communication connection it is abnormal when, obtain data volume in the user data and be less than preset data amount threshold The packet of value, the user data include multiple packets;
Acquired packet is sent to the second terminal in the described first direct-connected communication connection.
It should be noted that processor 501 is detecting that the second direct-connected communication connection data transmission bauds occurs and be less than During the abnormal conditions such as pre-set velocity threshold value or the second direct-connected broken communication connection, it is switched in the first direct-connected communication connection Continue to transmit the user data, to improve the validity of data transfer.
During the present invention is implemented, attribute information and the connection letter of direct-connected communication connection that first terminal can be based on user data Cease adaptively selected direct-connected communication connection to carry out data transmission, to meet the diversified demand of data transfer.
The embodiment of the present invention also provides a kind of computer-readable storage medium, wherein, the computer-readable storage medium is stored for electricity The computer program that subdata exchanges, it is any as described in above-mentioned embodiment of the method that the computer program make it that computer performs A kind of part or all of step of data transmission method.
The embodiment of the present invention also provides a kind of computer program product, and the computer program product includes storing calculating The non-transient computer-readable recording medium of machine program, the computer program are operable to make computer perform side as described above The part or all of step of any data transmission method described in method embodiment.The computer program product can be one Individual software installation bag.
It should be noted that for foregoing each method embodiment, in order to be briefly described, therefore it is all expressed as a series of Combination of actions, but those skilled in the art should know, the present invention is not limited by described sequence of movement because According to the present invention, some steps can use other orders or carry out simultaneously.Secondly, those skilled in the art should also know Know, embodiment described in this description belongs to preferred embodiment, and involved action and module are not necessarily of the invention It is necessary.
In the above-described embodiments, the description to each embodiment all emphasizes particularly on different fields, and does not have the portion being described in detail in some embodiment Point, it may refer to the associated description of other embodiment.
In several embodiments provided herein, it should be understood that disclosed device, can be by another way Realize.For example, device embodiment described above is only schematical, such as the division of the unit, it is only one kind Division of logic function, can there is an other dividing mode when actually realizing, such as multiple units or component can combine or can To be integrated into another system, or some features can be ignored, or not perform.Another, shown or discussed is mutual Coupling direct-coupling or communication connection can be by some interfaces, the INDIRECT COUPLING or communication connection of device or unit, Can be electrical or other forms.
The unit illustrated as separating component can be or may not be physically separate, show as unit The part shown can be or may not be physical location, you can with positioned at a place, or can also be distributed to multiple On NE.Some or all of unit therein can be selected to realize the mesh of this embodiment scheme according to the actual needs 's.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, can also That unit is individually physically present, can also two or more units it is integrated in a unit.Above-mentioned integrated list Member can both be realized in the form of hardware, can also be realized in the form of software program module.
If the integrated unit is realized in the form of software program module and is used as independent production marketing or use When, it can be stored in a computer-readable access to memory.Based on such understanding, technical scheme substantially or Person say the part to be contributed to prior art or the technical scheme all or part can in the form of software product body Reveal and, the computer software product is stored in a memory, including some instructions are causing a computer equipment (can be personal computer, server or network equipment etc.) performs all or part of each embodiment methods described of the present invention Step.And foregoing memory includes:USB flash disk, read-only storage (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disc or CD etc. are various can be with the medium of store program codes.
One of ordinary skill in the art will appreciate that all or part of step in the various methods of above-described embodiment is can To instruct the hardware of correlation to complete by program, the program can be stored in a computer-readable memory, memory It can include:Flash disk, read-only storage (English:Read-Only Memory, referred to as:ROM), random access device (English: Random Access Memory, referred to as:RAM), disk or CD etc..
The embodiment of the present invention is described in detail above, specific case used herein to the principle of the present invention and Embodiment is set forth, and the explanation of above example is only intended to help the method and its core concept for understanding the present invention; Meanwhile for those of ordinary skill in the art, according to the thought of the present invention, can in specific embodiments and applications There is change part, in summary, this specification content should not be construed as limiting the invention.

Claims (10)

1. a kind of data transmission method, it is characterised in that applied to first terminal, methods described includes:
The first direct-connected communication connection is established with second terminal;
Using described first it is direct-connected communicate to connect to second terminal transmit user data when, obtain on the second direct-connected communication link The link information connect, and the attribute information of the user data;
Judge whether to meet according to the link information and the attribute information default to establish building for the second direct-connected communication connection Vertical condition;
When meeting the set up the condition, the described second direct-connected communication for establishing between the first terminal and the second terminal Connection;
It is switched in the described second direct-connected communication connection to the second terminal and transmits the user data.
2. data transmission method according to claim 1, it is characterised in that the attribute information includes the user data Data type, it is described to judge whether to meet that default to establish second direct-connected logical according to the link information and the attribute information Believe establishment of connection condition, including:
Database is inquired about, the mode type matched with each data type is have recorded in the database;
According to the Query Result to the database, the data type of the user data and the link information bag are determined During the mode type matching of the described second direct-connected communication connection included, it is determined that meeting default to establish the described second direct-connected communication link The set up the condition connect.
3. data transmission method according to claim 1, it is characterised in that the attribute information includes the user data Data volume, it is described to judge whether to meet according to the link information and the attribute information default to establish the second direct-connected communication Establishment of connection condition, including:
Judge the data volume for the second direct-connected the communication connection whether data volume of the user data includes with the link information Threshold value matches;
In matching, it is determined that meeting the default set up the condition for establishing the described second direct-connected communication connection.
4. data transmission method according to claim 1, it is characterised in that methods described also includes:
Using described first it is direct-connected communicate to connect transmit user data to second terminal when, obtain the first direct-connected communication link The communication quality information connect;
If the communication quality information meets default switching condition, establish between the first terminal and the second terminal The second direct-connected communication connection, and the number of users is transmitted by the described second direct-connected communicate to connect to the second terminal According to;
If the communication quality information is unsatisfactory for default switching condition, the acquisition is performed on the second direct-connected communication connection Link information, and the step of attribute information of the user data.
5. data transmission method according to claim 1, it is characterised in that methods described also includes:
Using described first it is direct-connected communicate to connect transmit user data to second terminal when, detect whether to possess that to establish second straight The even condition of communication connection, the communication quality of the second direct-connected communication connection are higher than the communication of the described first direct-connected communication connection Quality;
When possessing the condition for establishing the described second direct-connected communication connection, then establish the first terminal and the second terminal it Between the described second direct-connected communication connection, and the user is transmitted by the described second direct-connected communicate to connect to the second terminal Data.
6. according to the data transmission method described in claim 1-5 any one, it is characterised in that methods described also includes:
Whether abnormal detect the described second direct-connected communication connection;
When the described second direct-connected communication connection is abnormal, obtains data volume in the user data and be less than preset data amount threshold value Packet, the user data include multiple packets;
Acquired packet is sent to the second terminal in the described first direct-connected communication connection.
A kind of 7. data transmission device, it is characterised in that it is arranged in first terminal, including:
Module is established, for establishing the first direct-connected communication connection with second terminal;
Acquisition module, for using described first it is direct-connected communicate to connect to second terminal transmit user data when, obtain on the The link information of two direct-connected communication connections, and the attribute information of the user data;
Judge module, for judging whether to meet that default to establish second direct-connected according to the link information and the attribute information The set up the condition of communication connection;
It is described to establish module, be additionally operable to when meeting the set up the condition, establish the first terminal and the second terminal it Between the described second direct-connected communication connection;
Handover module, the user data is transmitted in the described second direct-connected communication connection for being switched to.
8. data transmission device according to claim 7, it is characterised in that the attribute information includes the user data Data type,
The judge module, matched specifically for have recorded in inquiry database, the database with each data type Mode type;According to the Query Result to the database, the data type of the user data and the company are determined When connecing the mode type matching for the described second direct-connected communication connection that information includes, it is determined that meeting that default to establish described second straight Connection letter establishment of connection condition.
A kind of 9. terminal, it is characterised in that including:Processor and memory, the processor and the memory pass through bus Connection, the memory storage have executable program code, and the processor is used to call the executable program code, performed Data transmission method as claimed in any one of claims 1 to 6.
A kind of 10. computer-readable recording medium, it is characterised in that it stores the computer program for electronic data interchange, Wherein, the computer program causes computer to perform data transmission method as claimed in any one of claims 1 to 6.
CN201710495347.1A 2017-06-26 2017-06-26 A kind of data transmission method, device and terminal Pending CN107343325A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710495347.1A CN107343325A (en) 2017-06-26 2017-06-26 A kind of data transmission method, device and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710495347.1A CN107343325A (en) 2017-06-26 2017-06-26 A kind of data transmission method, device and terminal

Publications (1)

Publication Number Publication Date
CN107343325A true CN107343325A (en) 2017-11-10

Family

ID=60220952

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710495347.1A Pending CN107343325A (en) 2017-06-26 2017-06-26 A kind of data transmission method, device and terminal

Country Status (1)

Country Link
CN (1) CN107343325A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107968994A (en) * 2017-11-29 2018-04-27 北京小米移动软件有限公司 Method for building up, the apparatus and system of LAN
CN108040093A (en) * 2017-11-28 2018-05-15 深圳天珑无线科技有限公司 Audio file sharing method, mobile terminal and the storage device of mobile terminal
CN108712280A (en) * 2018-05-02 2018-10-26 Oppo广东移动通信有限公司 A kind of management method of network function, device, storage medium and intelligent terminal
CN109963173A (en) * 2017-12-26 2019-07-02 杭州萤石软件有限公司 Video flowing takes stream method, system, computer equipment, machine readable storage medium
WO2021175300A1 (en) * 2020-03-06 2021-09-10 华为技术有限公司 Data transmission method and apparatus, electronic device, and readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103368611A (en) * 2012-03-27 2013-10-23 腾讯科技(深圳)有限公司 Method and mobile terminal for file transfer
CN103607780A (en) * 2013-11-19 2014-02-26 惠州Tcl移动通信有限公司 Mobile device and network connection method thereof
WO2015165024A1 (en) * 2014-04-29 2015-11-05 华为终端有限公司 Data transmission method and terminal
CN105578099A (en) * 2016-01-29 2016-05-11 高翔 Method, apparatus and system for generating voice and video file
CN106658372A (en) * 2016-12-13 2017-05-10 上海斐讯数据通信技术有限公司 Low-power-consumption data transmission method and system, transmitting equipment, and receiving equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103368611A (en) * 2012-03-27 2013-10-23 腾讯科技(深圳)有限公司 Method and mobile terminal for file transfer
CN103607780A (en) * 2013-11-19 2014-02-26 惠州Tcl移动通信有限公司 Mobile device and network connection method thereof
WO2015165024A1 (en) * 2014-04-29 2015-11-05 华为终端有限公司 Data transmission method and terminal
CN105578099A (en) * 2016-01-29 2016-05-11 高翔 Method, apparatus and system for generating voice and video file
CN106658372A (en) * 2016-12-13 2017-05-10 上海斐讯数据通信技术有限公司 Low-power-consumption data transmission method and system, transmitting equipment, and receiving equipment

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108040093A (en) * 2017-11-28 2018-05-15 深圳天珑无线科技有限公司 Audio file sharing method, mobile terminal and the storage device of mobile terminal
CN107968994A (en) * 2017-11-29 2018-04-27 北京小米移动软件有限公司 Method for building up, the apparatus and system of LAN
CN109963173A (en) * 2017-12-26 2019-07-02 杭州萤石软件有限公司 Video flowing takes stream method, system, computer equipment, machine readable storage medium
CN109963173B (en) * 2017-12-26 2021-09-21 杭州萤石软件有限公司 Video stream fetching method, system, computer device and machine readable storage medium
CN108712280A (en) * 2018-05-02 2018-10-26 Oppo广东移动通信有限公司 A kind of management method of network function, device, storage medium and intelligent terminal
CN108712280B (en) * 2018-05-02 2020-12-04 Oppo广东移动通信有限公司 Network function management method and device, storage medium and intelligent terminal
WO2021175300A1 (en) * 2020-03-06 2021-09-10 华为技术有限公司 Data transmission method and apparatus, electronic device, and readable storage medium

Similar Documents

Publication Publication Date Title
CN107343325A (en) A kind of data transmission method, device and terminal
CN102545964B (en) Communication method and system for triggering information interaction by collision
CN100394734C (en) Method and system for establishing short-range service sessions
US7020486B2 (en) Portable communication terminal
CN106657521A (en) Smart device voice communication method, apparatus and system
WO2013086993A1 (en) Method for transmitting data between terminals and terminal
CN104301857A (en) Method and device for wireless communication between communication terminals
EP1865739A1 (en) Method and system for enabling reception of targeted services to a handheld communication device
CN107360635A (en) A kind of data transmission method, device, terminal and computer-readable recording medium
CN107360636A (en) A kind of data transmission method, device, terminal and computer-readable recording medium
CN106464303A (en) Data transmission method and terminal
CN105472038A (en) Control method, control apparatus and control system for file transmission
CN104584490A (en) Data transmitting method and device
CN107222937B (en) Data transmission method, device and terminal
CN107277756B (en) A kind of data transmission method, device, terminal and computer readable storage medium
CN109413627A (en) A kind of smart home device matches network method and distribution network systems
CN107317943B (en) Method and system for setting call forwarding
CN104125321B (en) A kind of contact details update method, device and system
CN107426806B (en) Method and device for transmitting data by Internet of things terminal
US20130157623A1 (en) Method and system for delivering messages to one or more handheld communication devices
CN107659999A (en) WIFI connection methods and equipment
US20070287421A1 (en) Method and system for providing continuity of service with an existing communication network
US20070286133A1 (en) Handheld communication device for communication of information
CN108513716A (en) The method and apparatus for establishing connection
CN105099836A (en) BLE intelligent node control method and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20171110