CN110191443A - Bluetooth communication connection method, communication equipment and storage medium - Google Patents
Bluetooth communication connection method, communication equipment and storage medium Download PDFInfo
- Publication number
- CN110191443A CN110191443A CN201910364480.2A CN201910364480A CN110191443A CN 110191443 A CN110191443 A CN 110191443A CN 201910364480 A CN201910364480 A CN 201910364480A CN 110191443 A CN110191443 A CN 110191443A
- Authority
- CN
- China
- Prior art keywords
- communication equipment
- role
- communication
- bluetooth
- connection
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/80—Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W76/00—Connection management
- H04W76/10—Connection setup
- H04W76/14—Direct-mode setup
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W76/00—Connection management
- H04W76/10—Connection setup
- H04W76/19—Connection re-establishment
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W8/00—Network data management
- H04W8/005—Discovery of network devices, e.g. terminals
Abstract
This application discloses a kind of Bluetooth communication connection method, communication equipment and storage medium, the first communication equipment opens Bluetooth function;First communication equipment carries out AG role and the HF role's registration of first communication equipment by the way that a default UUID value in Session Description Protocol SDP, is written simultaneously;Determine connection to be established the first communication equipment and each self-supporting of the second communication equipment AG and HF the case where;With matched role, connection is established with the second communication equipment;It can be seen that the application can be when communication equipment opens Bluetooth function, AG role and HF role are registered, to expand the scope of application of communication equipment, improve user experience.
Description
Technical field
This application involves field of terminal technology, and in particular to a kind of Bluetooth communication connection method, communication equipment and computer
Readable storage medium storing program for executing.
Background technique
Bluetooth technology is widely used in the equipment such as mobile phone, wireless headset, Intelligent bracelet/wrist-watch, and bluetooth can
It realizes the connection between corresponding equipment, and the real-time Transmission of the contents such as audio, video, file can be further realized.Bluetooth skill
In the application of art, general bluetooth equipment only supports HF (Hands Free, hands-free) role or AG (Audio Gate, audio
Gateway) role, for example, mobile phone is supported only to be used as AG (i.e. bluetooth conversation function main side), bluetooth headset or mobile unit are only propped up
Hold as HF (i.e. bluetooth conversation function from end), in this way for general wearable bluetooth equipment can only be selected as HF or
AG compares and limits the usage scenario of the equipment, influences user experience.
Summary of the invention
The application technical problems to be solved are:, poor user experience limited for the usage scenario of current bluetooth equipment
The problem of, a kind of Bluetooth communication connection method, communication equipment and computer readable storage medium are provided.
In order to solve the above technical problems, the application provides a kind of Bluetooth communication connection method, the Bluetooth communication connection side
Method includes:
In a Session Description Protocol SDP registration, at least one UUID is written, to the angle of first communication equipment
Color is registered, the value of at least one UUID correspond to first communication equipment support simultaneously audio frequency net gate way AG role and
Hands-free HF role;
Bluetooth discovery is initiated, determines the role that the second communication equipment is supported;Or, receiving the indigo plant that the second communication equipment is initiated
Tooth search, the role for making the second communication equipment determine that the first communication equipment is supported;
According to bluetooth discovery as a result, being matched to the role between the first communication equipment and the second communication equipment;
With matched role, connection is established with the second communication equipment.
Optionally, the initiation bluetooth discovery, the role for determining that the second communication equipment is supported include:
Initiate the request message of SDP search;
It receives the SDP search response message of the second communication device feeding back, in the SDP search response message, carries table
Levy the characteristic value for the role that second communication equipment is supported.
Optionally, the bluetooth discovery for receiving the second communication equipment and initiating, makes the second communication equipment determine the first communication
The role that equipment is supported includes:
Receive the request message that the second communication equipment initiates SDP search;
To the second communication device feeding back SDP search response message, in the SDP search response message, table is carried
Levy the characteristic value for the role that first communication equipment is supported.
Optionally, after the role to first communication equipment registers, further includes:
Start the port RFcomm, waits subsequent connection.
Optionally, described with matched role, establishing connection with the second communication equipment includes:
By the port RFcomm having been turned on, to establish connection with the matched role of the second communication equipment.
Optionally, the value of at least one UUID correspond to first communication equipment support audio frequency net gate way AG role and
Hands-free HF role includes:
When the UUID is two, the value of one of UUID corresponds to first communication equipment and supports AG role,
The value of another UUID corresponds to first communication equipment and supports HF role;
When the UUID is one, the value of the UUID corresponds to first communication equipment and supports audio frequency net gate way simultaneously
AG role and hands-free HF role;
Optionally, it is established after connection with matched role with the second communication equipment described, further includes:
When the UUID is one, the value of the UUID is modified, the value of modified UUID is made to correspond only to described the
One communication equipment only supports the role that connection is currently established with the second communication equipment.
Optionally, described with matched role, establishing connection with the second communication equipment includes:
When second communication equipment only supports AG role, first communication equipment passes through HF role and described second
Communication equipment establishes connection;
When second communication equipment only supports HF role, first communication equipment passes through AG role and described second
Communication equipment establishes connection;
When second communication equipment supports AG role and HF role simultaneously, first communication equipment passes through the angle AG
Color establishes connection by HF role with the second communication equipment;Or, first communication equipment is communicated by HF role with second
Equipment establishes connection by AG role.
The application also provides a kind of communication equipment, and the communication equipment includes memory, transmitter, receiver, processor
And communication bus;
The communication bus is for realizing the connection communication between memory and processor;
The processor control transmitter, receiver, and the computer program stored in memory is called, on realizing
The step of Bluetooth communication connection method stated.
The application also provides a kind of computer readable storage medium, and the computer-readable recording medium storage has computer
The step of program, the computer program can be executed by processor to realize above-mentioned Bluetooth communication connection method.
Beneficial effect
The application provides a kind of Bluetooth communication connection method, communication equipment and storage medium, in a Session Description Protocol
In SDP registration, at least one UUID is written, to be registered to the role of the first communication equipment, the value pair of at least one UUID
Audio frequency net gate way AG role and hands-free HF role should be supported simultaneously in the first communication equipment;Bluetooth discovery is initiated, determines the second communication
The role that equipment is supported;Or, receiving the bluetooth discovery that the second communication equipment is initiated, the second communication equipment is made to determine the first communication
The role that equipment is supported;According to bluetooth discovery as a result, being carried out to the role between the first communication equipment and the second communication equipment
Matching;With matched role, connection is established with the second communication equipment;It can be seen that the application can open Bluetooth function in communication equipment
When, AG role and HF role register, to expand the scope of application of communication equipment, improve user experience.
Detailed description of the invention
The drawings herein are incorporated into the specification and forms part of this specification, and shows the implementation for meeting the application
Example, and together with specification it is used to explain the principle of the application.
In order to illustrate the technical solutions in the embodiments of the present application or in the prior art more clearly, to embodiment or will show below
There is attached drawing needed in technical description to be briefly described, it should be apparent that, for those of ordinary skill in the art
Speech, without any creative labor, is also possible to obtain other drawings based on these drawings.
Fig. 1 is a kind of hardware structural diagram of embodiment of wearable device provided by the embodiments of the present application;
Stereoscopic schematic diagram when Fig. 2 is a kind of screen expansion of embodiment of wearable device provided by the embodiments of the present application
One;
Stereoscopic schematic diagram when Fig. 3 is a kind of screen expansion of embodiment of wearable device provided by the embodiments of the present application
Two;
Stereoscopic schematic diagram when Fig. 4 is a kind of screen-bending of embodiment of wearable device provided by the embodiments of the present application;
Fig. 5 is the flow diagram for the Bluetooth communication connection method that the application first embodiment provides;
Fig. 6 is a kind of default frame structure schematic diagram that the application first embodiment provides;
Fig. 7 is the flow diagram for the Bluetooth communication connection method that the application second embodiment provides;
Fig. 8 is the Bluetooth communication attachment device composition schematic diagram that the application 3rd embodiment provides;
Fig. 9 is the Bluetooth communication attachment device composition schematic diagram that the application fourth embodiment provides;
Figure 10 is the Bluetooth communication connection method refined flow chart that the 5th embodiment of the application provides;
Figure 11 is the communication equipment composition schematic diagram that the application sixth embodiment provides.
Specific embodiment
It should be appreciated that specific embodiment described herein is only used to explain the application, it is not used to limit the application.
In subsequent description, it is only using the suffix for indicating such as " module ", " component " or " unit " of element
The explanation for being conducive to the application, itself does not have a specific meaning.Therefore, " module ", " component " or " unit " can mix
Ground uses.
The terminal provided in the embodiment of the present application includes the mobile terminals such as Intelligent bracelet, smartwatch and smart phone.
With the continuous development of Screen Technology, the appearance of the screens form such as flexible screen, Folding screen, the mobile terminals such as smart phone can also be with
As wearable device.The terminal provided in the embodiment of the present application may include: RF (Radio Frequency, radio frequency) unit,
WiFi module, A/V (audio/video) input unit, sensor, display unit, user input unit, connects audio output unit
The components such as mouth unit, memory, processor and power supply.
It will be illustrated by taking terminal as an example in subsequent descriptions, referring to Fig. 1, it is realize each embodiment of the application one
The hardware structural diagram of kind terminal, which may include: RF (Radio Frequency, radio frequency) unit 101, WiFi
Module 102, audio output unit 103, A/V (audio/video) input unit 104, sensor 105, display unit 106, user
The components such as input unit 107, interface unit 108, memory 109, processor 110 and power supply 111.Those skilled in the art
It is appreciated that the restriction of terminal structure not structure paired terminal shown in Fig. 1, terminal may include more more or less than illustrating
Component, perhaps combine certain components or different component layouts.
It is specifically introduced below with reference to all parts of the Fig. 1 to terminal:
Radio frequency unit 101 can be used for receiving and sending messages or communication process in, signal sends and receivees, specifically, radio frequency list
Uplink information can be sent to base station by member 101, after the downlink information that in addition can also be sent base station receives, be sent to terminal
Processor 110 handle, base station to the downlink information that radio frequency unit 101 is sent can be according to radio frequency unit 101 transmission it is upper
What row information generated, it is also possible to after the information update for detecting terminal actively to the push of radio frequency unit 101, for example,
After detecting that geographical location locating for terminal changes, base station can send geographical location to the radio frequency unit 101 of terminal and become
The message informing can be sent to the processing of terminal after receiving the message informing by the message informing of change, radio frequency unit 101
The processing of device 110, the processor 110 of terminal can control the message informing and be shown on the display panel 1061 of terminal;In general, penetrating
Frequency unit 101 includes but is not limited to antenna, at least one amplifier, transceiver, coupler, low-noise amplifier, duplexer
Deng.In addition, radio frequency unit 101 can also be communicated with network and other equipment by wireless communication, it specifically may include: to pass through
Wireless communication and the server communication in network system, for example, terminal can download file from server by wireless communication
Resource, for example application program can be downloaded from server, after terminal completes the downloading of a certain application program, if server
In the corresponding file resource of the application program update, then the server can be by wireless communication to terminal push resource updates
Message informing, to remind user to be updated the application program.Any communication standard or association can be used in above-mentioned wireless communication
View, including but not limited to GSM (Global System of Mobile communication, global system for mobile communications),
GPRS (General Packet Radio Service, general packet radio service), CDMA2000 (Code Division
Multiple Access 2000, CDMA 2000), WCDMA (Wideband Code Division Multiple
Access, wideband code division multiple access), TD-SCDMA (Time Division-Synchronous Code Division
Multiple Access, TD SDMA), FDD-LTE (Frequency Division Duplexing-Long
Term Evolution, frequency division duplex long term evolution) and TDD-LTE (Time Division Duplexing-Long Term
Evolution, time division duplex long term evolution) etc..
In one embodiment, terminal 100 can access existing communication network by insertion SIM card.
In another embodiment, terminal 100 can be by being arranged esim card (Embedded-SIM), to realize access
Existing communication network can save the inner space of terminal by the way of esim card, reduce thickness.
It is understood that although Fig. 1 shows radio frequency unit 101, but it is understood that, radio frequency unit 101 its
And it is not belonging to must be configured into for terminal, it can according to need within the scope of not changing the essence of the invention and omit completely.Terminal
100 can realize the communication connection with other equipment or communication network separately through WiFi module 102, and the embodiment of the present application is simultaneously
It is not limited.
WiFi belongs to short range wireless transmission technology, and terminal can help user's transceiver electronics postal by WiFi module 102
Part, browsing webpage and access streaming video etc., it provides wireless broadband internet access for user.Although Fig. 1 is shown
WiFi module 102, but it is understood that, and it is not belonging to must be configured into for terminal, it can according to need do not changing completely
Become in the range of the essence of invention and omits.
Audio output unit 103 can be in call signal reception pattern, call mode, logging mode, language in terminal 100
It is radio frequency unit 101 or WiFi module 102 is received or depositing when under the isotypes such as sound recognition mode, broadcast reception mode
The audio data stored in reservoir 109 is converted into audio signal and exports to be sound.Moreover, audio output unit 103 may be used also
To provide audio output relevant to the specific function that terminal 100 executes (for example, call signal receives sound, message sink sound
Sound etc.).Audio output unit 103 may include loudspeaker, buzzer etc..
A/V input unit 104 is for receiving audio or video signal.A/V input unit 104 may include graphics processor
(Graphics Processing Unit, GPU) 1041 and microphone 1042, graphics processor 1041 is in video acquisition mode
Or the image data of the static images or video obtained in image capture mode by image capture apparatus (such as camera) carries out
Reason.Treated, and picture frame may be displayed on display unit 106.Through graphics processor 1041, treated that picture frame can be deposited
Storage is sent in memory 109 (or other storage mediums) or via radio frequency unit 101 or WiFi module 102.Mike
Wind 1042 can connect in telephone calling model, logging mode, speech recognition mode etc. operational mode via microphone 1042
Quiet down sound (audio data), and can be audio data by such acoustic processing.Audio that treated (voice) data can
To be converted to the format output that can be sent to mobile communication base station via radio frequency unit 101 in the case where telephone calling model.
Microphone 1042 can be implemented various types of noises elimination (or inhibition) algorithms and send and receive sound to eliminate (or inhibition)
The noise generated during frequency signal or interference.
In one embodiment, terminal 100 includes one or more cameras, by opening camera, Neng Goushi
Now to the capture of image, the functions such as realization takes pictures, records a video, the position of camera, which can according to need, to be configured.
Terminal 100 further includes at least one sensor 105, such as optical sensor, motion sensor and other sensors.
Specifically, optical sensor includes ambient light sensor and proximity sensor, wherein ambient light sensor can be according to ambient light
Light and shade adjusts the brightness of display panel 1061, and proximity sensor can close display panel when terminal 100 is moved in one's ear
1061 and/or backlight.As a kind of motion sensor, accelerometer sensor can detect in all directions (generally three axis) and add
The size of speed can detect that size and the direction of gravity when static, can be used to identify application (such as the horizontal/vertical screen of mobile phone posture
Switching, dependent game, magnetometer pose calibrating), Vibration identification correlation function (such as pedometer, tap) etc..
In one embodiment, terminal 100 further includes proximity sensor, and by using proximity sensor, terminal can
It realizes non-contact manipulation, more modes of operation is provided.
In one embodiment, terminal 100 further includes heart rate sensor,, can by close to user when wearing
Realize the detecting of heart rate.
In one embodiment, terminal 100 can also can be realized peace by reading fingerprint including fingerprint sensor
The functions such as full verifying.
Display unit 106 is for showing information input by user or being supplied to the information of user.Display unit 106 can wrap
Display panel 1061 is included, liquid crystal display (Liquid Crystal Display, LCD), Organic Light Emitting Diode can be used
Forms such as (Organic Light-Emitting Diode, OLED) configure display panel 1061.
In one embodiment, display panel 1061 uses flexible display screen, and the terminal using flexible display screen is being worn
Dai Shi, screen is able to carry out bending, to more be bonded.Optionally, the flexible display screen can using OLED screen body and
Graphene screen body, in other embodiments, the flexible display screen are also possible to other display materials, the present embodiment not with
This is limited.
In one embodiment, the display panel 1061 of terminal can take rectangle, surround when convenient for wearing.At it
In his embodiment, other modes can also be taken.
User input unit 107 can be used for receiving the number or character information of input, and generates and set with the user of terminal
It sets and the related key signals of function control inputs.Specifically, user input unit 107 may include touch panel 1071 and its
His input equipment 1072.Touch panel 1071, also referred to as touch screen collect the touch operation (ratio of user on it or nearby
Such as user is using finger, stylus any suitable object or attachment on touch panel 1071 or near touch panel 1071
Operation), and corresponding attachment device is driven according to preset formula.Touch panel 1071 may include touch detecting apparatus
With two parts of touch controller.Wherein, the touch orientation of touch detecting apparatus detection user, and detect touch operation bring
Signal transmits a signal to touch controller;Touch controller receives touch information from touch detecting apparatus, and it is converted
At contact coordinate, then processor 110 is given, and order that processor 110 is sent can be received and executed.Furthermore, it is possible to adopt
Touch panel 1071 is realized with multiple types such as resistance-type, condenser type, infrared ray and surface acoustic waves.In addition to touch panel
1071, user input unit 107 can also include other input equipments 1072.Specifically, other input equipments 1072 can wrap
It includes but is not limited in physical keyboard, function key (such as volume control button, switch key etc.), trace ball, mouse, operating stick etc.
It is one or more, specifically herein without limitation.
In one embodiment, one or more buttons have can be set in the side of terminal 100.Button may be implemented short
It presses, long-pressing, the various ways such as rotation, to realize a variety of operating effects.The quantity of button can be multiple, different buttons it
Between can be applied in combination, realize a variety of operating functions.
Further, touch panel 1071 can cover display panel 1061, when touch panel 1071 detect on it or
After neighbouring touch operation, processor 110 is sent to determine the type of touch event, is followed by subsequent processing device 110 according to touch thing
The type of part provides corresponding visual output on display panel 1061.Although in Fig. 1, touch panel 1071 and display panel
1061 be the function that outputs and inputs of realizing terminal as two independent components, but in some embodiments it is possible to will
Touch panel 1071 and display panel 1061 integrate and realize the function that outputs and inputs of terminal, specifically herein without limitation.Than
Such as, when receiving the message informing of a certain application program by radio frequency unit 101, processor 110 be can control the message
Notice is shown in a certain predeterminable area of display panel 1061, a certain region pair of the predeterminable area and touch panel 1071
It answers, it, can be to being shown in corresponding region on display panel 1061 by carrying out touch control operation to a certain region of touch panel 1071
Message informing controlled.
Interface unit 108 be used as at least one external device (ED) connect with terminal 100 can by interface.For example, external
Device may include wired or wireless headphone port, external power supply (or battery charger) port, wired or wireless number
According to port, memory card port, port, the port audio input/output (I/O), view for connecting the device with identification module
The port frequency I/O, ear port etc..Interface unit 108 can be used for receiving the input from external device (ED) (for example, data are believed
Breath, electric power etc.) and by one or more elements that the input received is transferred in terminal 100 or can be used at end
Data are transmitted between end 100 and external device (ED).
In one embodiment, terminal 100 interface unit 108 using contact structure, by contact with it is corresponding
The functions such as charging, connection are realized in other equipment connection.Use contact can be with waterproof.
Memory 109 can be used for storing software program and various data.Memory 109 can mainly include storing program area
The storage data area and, wherein storing program area can (such as the sound of application program needed for storage program area, at least one function
Sound playing function, image player function etc.) etc.;Storage data area can store according to mobile phone use created data (such as
Audio data, phone directory etc.) etc..In addition, memory 109 may include high-speed random access memory, it can also include non-easy
The property lost memory, a for example, at least disk memory, flush memory device or other volatile solid-state parts.
Processor 110 is the control centre of terminal, using the various pieces of various interfaces and the entire terminal of connection, is led to
It crosses operation or executes the software program and/or module being stored in memory 109, and call and be stored in memory 109
Data execute the various functions and processing data of terminal, to carry out integral monitoring to terminal.Processor 110 may include one
Or multiple processing units;Preferably, processor 110 can integrate application processor and modem processor, wherein application processing
The main processing operation system of device, user interface and application program etc., modem processor mainly handles wireless communication.It can manage
Solution, above-mentioned modem processor can not also be integrated into processor 110.
Terminal 100 can also include the power supply 111 (such as battery) powered to all parts, it is preferred that power supply 111 can be with
It is logically contiguous by power-supply management system and processor 110, thus by power-supply management system realize management charging, electric discharge, with
And the functions such as power managed.
Although Fig. 1 is not shown, terminal 100 can also be including bluetooth module etc., and details are not described herein.Terminal 100 passes through indigo plant
Tooth can be connect with other terminal devices, realize communication and the interaction of information.
Fig. 2-Fig. 4 is please referred to, is a kind of knot of wearable device provided by the embodiments of the present application in one embodiment
Structure schematic diagram.Wearable device in the embodiment of the present application, including flexible screen.In wearable device expansion, flexible screen
It is elongated;When wearable device is in wearing state, flexible screen bending is annular in shape.Fig. 2 and Fig. 3 shows wearable set
Structural schematic diagram when standby screen expansion, Fig. 4 show structural schematic diagram when wearable device screen-bending;Certainly it should manage
The display screen of wearable device in the embodiment of the present application of solution can not also be flexible screen.
Based on above-mentioned mobile terminal hardware configuration and communications network system, each embodiment of the application method is proposed.
First embodiment
It is single for the Bluetooth communication connection type on current communication equipment, the problem of availability and flexibility difference, this reality
It applies example and provides a kind of new Bluetooth communication connection method, referring to FIG. 5, the Bluetooth communication connection method includes:
S501, in Session Description Protocol SDP registration, at least one UUID is written, to the first communication equipment
Role registers, the value of at least one UUID corresponds to the first communication equipment and supports audio frequency net gate way AG role and hands-free HF simultaneously
Role;
S502, bluetooth discovery is initiated, determines the role that the second communication equipment is supported;Or, receiving the second communication equipment hair
The bluetooth discovery risen, the role for making the second communication equipment determine that the first communication equipment is supported;
S503, according to bluetooth discovery as a result, being matched to the role between the first communication equipment and the second communication equipment;
S504, with matched role, establish connection with the second communication equipment.
The first communication equipment and the second communication equipment in the present embodiment, the communication that can belong to mobile terminal class are set
It is standby, such as mobile phone, wearable device, PC PC, it can also be terminal class equipment with one of them, another one is outside bluetooth
If such as bluetooth headset, bluetooth mouse, bluetooth keyboard;Difference between the two is, the communication equipment, if having with
The function that other modes are communicated with other equipment, such as, the call function on mobile phone, data connection function, wifi function
Energy etc. belongs to function not available for bluetooth peripheral hardware, that is to say, that bluetooth peripheral hardware is communicated as auxiliary mobile terminal
's.And bluetooth peripheral hardware, it is however generally that only have the function of HF role, mobile terminal can then have the function of AG role and HF role
Energy.In addition, the first communication equipment and the second communication equipment in the present embodiment, the angle only played the part of in process between the two
Color is distinguished, and the two can have same hardware configuration, and the first communication equipment and the second communication equipment are corresponding
Role can be interchanged in scene, the present embodiment is simultaneously not limited thereof.
When first communication equipment includes mobile terminal, the call function of the mobile terminal can pass through carrier network reality
Existing, wherein terminal can realize the call function by esim card or entity sim card;Alternatively, can also by data connection,
The functions such as wifi realize call function, such as wechat voice, qq voice by carrier of the various softwares for having call function.
In this case, the bluetooths peripheral hardware such as bluetooth headset can be used as audio initiation/receiving end in communication process, realize auxiliary
Call;And if the second communication equipment includes other mobile terminals, other mobile terminals, can also serve as conversing at this time
Audio initiation/receiving end or other terminals in journey are also used as synchronous audiomonitor and realize and the first communication equipment
Synchronous call.
The Bluetooth communication connection established between first communication equipment and the second communication equipment, can allow according to the actual situation
Any one of them may search for as recipient, searcher when initiating the search to recipient as searcher, another one
The character types that recipient supports, such as only AG role, only HF role and support AG role and HF role simultaneously.
In some embodiments, the value of at least one UUID correspond to the first communication equipment support audio frequency net gate way AG role and
Hands-free HF role may include:
When UUID is two, the value of one of UUID corresponds to the first communication equipment and supports AG role, another UUID
Value correspond to the first communication equipment support HF role;
When UUID is one, the value of UUID corresponds to the first communication equipment and supports audio frequency net gate way AG role and hands-free simultaneously
HF role.
In the present embodiment, to the registration process of the first communication equipment, be by least one UUID, while to AG role and
HF role registers;Specifically, the AG role of the first communication equipment and HF role's registration may include:
In sdp, the data element Data Element value of default frame structure is written, as default in first communication equipment
UUID.In the present embodiment, when being registered by a UUID, a kind of new frame structure value, the frame structure value are provided
It corresponds directly to the communication equipment while there are two kinds of roles of AG and HF, only embody a kind of frame knot without once registering
Structure, and the problem of lead to not completely to characterize the communication equipment practical role's situation supported.Specifically, in the present embodiment,
The default frame structure of communication equipment is made of the type field and Size field that are linked in sequence, and the type field indicates frame structure
Type, Size field indicate the size and content of frame structure.Referring to FIG. 6, Fig. 6 shows the default frame structure in the present embodiment
Schematic diagram, it is defined good value that wherein there has been 0-8 in the part Type in the related technology, and 9-31 is retention, therefore can be with
Using any one value used in 9=31, as customized Type;In Size field, shown in Size index with
How many expressions size, subsequent size afterwards indicate the length of the character string in authentic data domain, to guarantee correctly to be read
It takes;Subsequent HF&AG is then real data content, indicates while supporting AG role and HF role.In the present embodiment, together
One period only take up the port of a RFcomm wait connection, wait opposite end come initiate the connection or local terminal search connection pair
End.When being registered by two UUID, then two UUID are written together in same SDP registration process, between two UUID
It is spaced apart with identifier or two UUID is directly connected to.
In some embodiments, by SDP, the first communication equipment and the second communication equipment for determining connection to be established are respectively
The case where AG and HF of support may include:
First communication equipment initiates bluetooth discovery, the role for making the first communication equipment determine that the second communication equipment is supported.
Bluetooth discovery side can be carried out by the first communication equipment or the second communication equipment, that is to say, that the first communication equipment can be with
As search initiator, the second communication equipment can also be used as search initiator;When the first communication equipment is as search initiator
When, the second communication equipment is just as search recipient.The first communication equipment and second of connection to be established is determined in the present embodiment
The case where AG and HF of each self-supporting of communication equipment, and the case where searcher knows the support AG and HF of itself, it is only necessary to pass through
Search, knows the support situation of other side.In the present embodiment, that is, by initiating bluetooth discovery, so that the first bluetooth
Equipment determines the role that the second bluetooth equipment is supported.
Specifically, the first communication equipment initiates bluetooth discovery, the first communication equipment is made to determine that the second communication equipment is supported
Role may include:
First communication equipment initiates the request message of SDP search;
It receives the SDP search response message of the second communication device feeding back, in SDP search response message, carries characterization second
The characteristic value for the role that communication equipment is supported.Wherein, in SDP search response message, the second communication equipment of characterization institute of carrying
The characteristic value of the role of support, that is, the UUID that second communication equipment is written in registration.
In some embodiments, the first communication equipment of connection to be established and the AG of each self-supporting of the second communication equipment are determined
And the case where HF, can also include:
The bluetooth discovery for receiving the initiation of the second communication equipment, makes the second communication equipment determine what the first communication equipment was supported
Role.The example shows that searcher has become the second communication equipment, and when scanning for, the first communication is set the second communication equipment
Standby then be used as searched side, the role for accordingly being supported itself feeds back to the second communication equipment, process and above-mentioned the
One communication equipment is as the similar of searcher, and only the two exchanges role.
In some embodiments, the bluetooth discovery that the second communication equipment is initiated is received, the second communication equipment is made to determine first
The role that communication equipment is supported may include:
It receives the second communication equipment and initiates SDP search request message;
SDP search response message is sent to the second communication equipment, in SDP search response message, carries the first communication of characterization
The characteristic value for the role that equipment is supported.
Between first communication equipment and the second communication equipment when being attached, the mode connected can be to be connected automatically
Connect, be attached by the control of user etc., wherein automatic connection indicates the two after the search is completed, is automatically performed bluetooth
Connection can borrow the connection to realize Bluetooth communication between the two after connection;Automatically the type connected, can be according to the first communication
The difference for the character types supported between equipment and the second communication equipment and be arranged, such as, the first communication equipment is supported simultaneously
When AG and HF role, if the second communication equipment, only support one of role, then the first communication equipment by corresponding role with
Connection;If the second communication equipment also supports two kinds of roles, can be random between the first communication equipment and the second communication equipment
It selects corresponding role to connect, or according to preset priority, corresponding role is selected to be attached.Pass through the control of user
The case where connecting, then supporting two kinds of roles mainly for the first communication equipment and the second communication equipment is used in this case
Family can voluntarily select how to connect between the first communication equipment and the second communication equipment.Here connection refers in the first communication
The access of bluetooth is established between equipment and the second communication equipment, is not related to the transmission process of data.
In some embodiments, after the role to the first communication equipment registers, can also include:
Start the port RFcomm, waits subsequent connection.The linear simulation protocol of serial ports (RFcomm), suitable for being based on
The serial ports of L2CAP is simulated.The realization of HFP is based on the linear simulation protocol of serial ports.The linear simulation protocol of serial ports is established serially linearly to imitate
True agreement connection, needs distal end (Remote) to be registered in the service channel in service discovery protocol when sending SABM packet
(server channel) is used as parameter, to distinguish the different linear simulation protocol connections of serial ports.
In some embodiments, with matched role, establishing connection with the second communication equipment may include:
By the port RFcomm having been turned on, to establish connection with the matched role of the second communication equipment.
In some embodiments, with matched role, after establishing connection with the second communication equipment, can also include:
When UUID is one, the value of UUID is modified, the value of modified UUID is made to correspond only to the first communication equipment only
Support the role that connection is currently established with the second communication equipment.First communication equipment and the second communication equipment in connected state,
It is available only for that role of connection, and another role can not go access, in other words, two since device hardware limits again
Kind role is conflict in actual application, and when one is in use state, another one is not available then;In this feelings
Under condition, the role of another one can be nullified, to save Internet resources, be avoided in other equipment to be accessed, then carrying out need not
The search process wanted.Correspondingly, the role being canceled can be re-registered once again if current bluetooth connection disconnects.
For example, if opposite end initiate be AG connection, the service for starting upper layer AG connected using the established port RFcomm, even
After the completion of connecing foundation, modifying subsequent data field in Data Element is HF, to modify the ability of its support;When before
The data field that the connection of AG then restores in Data Element again after disconnecting is HF&AG.
In some embodiments, with matched role, establishing connection with the second communication equipment may include:
When the second communication equipment only supports AG role, the first communication equipment is established by HF role and the second communication equipment
Connection;
When the second communication equipment only supports HF role, the first communication equipment is established by AG role and the second communication equipment
Connection;
When the second communication equipment supports AG role and HF role simultaneously, between the first communication equipment and the second communication equipment
Connection is established by any AG role and HF role combinations.Specific namely the first communication equipment is by AG role, with second
Communication equipment establishes connection by HF role;Or, the first communication equipment passes through AG role by HF role, with the second communication equipment
Establish connection.In other words, connection between the two is the combination of AG and HF.
The present embodiment provides a kind of Bluetooth communication connection method, the first communication equipment opens Bluetooth function;First communication is set
For by the way that the AG role that a default UUID value carries out first communication equipment simultaneously in Session Description Protocol SDP, is written
It is registered with HF role;Determine the feelings of the first communication equipment of connection to be established and the AG and HF of each self-supporting of the second communication equipment
Condition;With matched role, connection is established with the second communication equipment;It can be seen that the application can communication equipment open Bluetooth function when,
AG role and HF role register, to expand the scope of application of communication equipment, improve user experience.
Second embodiment
A kind of new Bluetooth communication connection method is present embodiments provided, referring to FIG. 7, the Bluetooth communication connection method packet
It includes:
The feelings of the AG and HF of S601, the first communication equipment for determining connection to be established and each self-supporting of the second communication equipment
Condition;Wherein, the first communication equipment is by being written at least one UUID, to first in a Session Description Protocol SDP registration
The role of communication equipment registers, the value of at least one UUID corresponds to the first communication equipment and supports the angle audio frequency net gate way AG simultaneously
Color and hands-free HF role;
S602, the second communication equipment establish connection with matched role, with the first communication equipment.
The first communication equipment and the second communication equipment in the present embodiment, the communication that can belong to mobile terminal class are set
It is standby, such as mobile phone, wearable device, PC PC, it can also be terminal class equipment with one of them, another one is outside bluetooth
If such as bluetooth headset, bluetooth mouse, bluetooth keyboard;Difference between the two is, the communication equipment, if having with
The function that other modes are communicated with other equipment, such as, the call function on mobile phone, data connection function, wifi function
Energy etc. belongs to function not available for bluetooth peripheral hardware, that is to say, that bluetooth peripheral hardware is communicated as auxiliary mobile terminal
's.And bluetooth peripheral hardware, it is however generally that only have the function of HF role, mobile terminal can then have the function of AG role and HF role
Energy.In addition, the first communication equipment and the second communication equipment in the present embodiment, the angle only played the part of in process between the two
Color is distinguished, and the two can have same hardware configuration, and the first communication equipment and the second communication equipment are corresponding
Role can be interchanged in scene, the present embodiment is simultaneously not limited thereof.
When first communication equipment includes mobile terminal, the call function of the mobile terminal can pass through carrier network reality
Existing, wherein terminal can realize the call function by esim card or entity sim card;Alternatively, can also by data connection,
The functions such as wifi realize call function, such as wechat voice, qq voice by carrier of the various softwares for having call function.
In this case, the bluetooths peripheral hardware such as bluetooth headset can be used as audio initiation/receiving end in communication process, realize auxiliary
Call;And if the second communication equipment includes other mobile terminals, other mobile terminals, can also serve as conversing at this time
Audio initiation/receiving end or other terminals in journey are also used as synchronous audiomonitor and realize and the first communication equipment
Synchronous call.
The Bluetooth communication connection established between first communication equipment and the second communication equipment, can allow according to the actual situation
Any one of them may search for as recipient, searcher when initiating the search to recipient as searcher, another one
The character types that recipient supports, such as only AG role, only HF role and support AG role and HF role simultaneously.
In the present embodiment, to the registration process of the first communication equipment, be by least one UUID, while to AG role and
HF role registers;Specifically, the first communication equipment is by being written a default UUID in Session Description Protocol SDP
Value carries out the AG role of the first communication equipment simultaneously and HF role's registration may include:
In sdp, the data element Data Element value of default frame structure is written, as default in first communication equipment
UUID.Specifically, in the present embodiment, the default frame structure of communication equipment, by the type field and Size field group being linked in sequence
At the type field indicates the type of frame structure, and Size field indicates the size and content of frame structure.
In some embodiments, by SDP, the first communication equipment and the second communication equipment for determining connection to be established are respectively
The case where AG and HF of support may include:
First communication equipment initiates bluetooth discovery, the role for making the first communication equipment determine that the second communication equipment is supported.
Specifically, the first communication equipment initiates bluetooth discovery, the first communication equipment is made to determine that the second communication equipment is supported
Role may include:
First communication equipment initiates SDP search request message;
The SDP search response message for receiving the transmission of the second communication equipment in SDP search response message, carries characterization second
The characteristic value for the role that communication equipment is supported.
In some embodiments, the first communication equipment of connection to be established and the AG of each self-supporting of the second communication equipment are determined
And the case where HF, can also include:
The bluetooth discovery for receiving the initiation of the second communication equipment, makes the second communication equipment determine what the first communication equipment was supported
Role.
In some embodiments, the bluetooth discovery that the second communication equipment is initiated is received, the second communication equipment is made to determine first
The role that communication equipment is supported may include:
It receives the second communication equipment and initiates SDP search request message;
SDP search response message is sent to the second communication equipment, in SDP search response message, carries the first communication of characterization
The characteristic value for the role that equipment is supported.
Specifically, establishing connection with the second communication equipment may include: with matched role
When the second communication equipment only supports AG role, the first communication equipment is established by HF role and the second communication equipment
Connection;
When the second communication equipment only supports HF role, the first communication equipment is established by AG role and the second communication equipment
Connection;
When the second communication equipment supports AG role and HF role simultaneously, between the first communication equipment and the second communication equipment
Connection is established by any AG role and HF role combinations.
3rd embodiment
A kind of Bluetooth communication attachment device is present embodiments provided, referring to FIG. 7, the Bluetooth communication attachment device is applied to
First Bluetooth communication terminal, specifically includes:
Registration module 701, at least one UUID being written, to first in a Session Description Protocol SDP registration
The role of communication equipment registers, the value of at least one UUID corresponds to the first communication equipment and supports the angle audio frequency net gate way AG simultaneously
Color and hands-free HF role;
First role determining module 702, the role supported for determining the first communication equipment and the second communication equipment;
Matching module 703, for according to bluetooth discovery as a result, to the angle between the first communication equipment and the second communication equipment
Color is matched;
First link block 704, for establishing connection with the second communication equipment with matched role.
The first communication equipment and the second communication equipment in the present embodiment, the communication that can belong to mobile terminal class are set
It is standby, such as mobile phone, wearable device, PC PC, it can also be terminal class equipment with one of them, another one is outside bluetooth
If such as bluetooth headset, bluetooth mouse, bluetooth keyboard;Difference between the two is, the communication equipment, if having with
The function that other modes are communicated with other equipment, such as, the call function on mobile phone, data connection function, wifi function
Energy etc. belongs to function not available for bluetooth peripheral hardware, that is to say, that bluetooth peripheral hardware is communicated as auxiliary mobile terminal
's.And bluetooth peripheral hardware, it is however generally that only have the function of HF role, mobile terminal can then have the function of AG role and HF role
Energy.In addition, the first communication equipment and the second communication equipment in the present embodiment, the angle only played the part of in process between the two
Color is distinguished, and the two can have same hardware configuration, and the first communication equipment and the second communication equipment are corresponding
Role can be interchanged in scene, the present embodiment is simultaneously not limited thereof.
When first communication equipment includes mobile terminal, the call function of the mobile terminal can pass through carrier network reality
Existing, wherein terminal can realize the call function by esim card or entity sim card;Alternatively, can also by data connection,
The functions such as wifi realize call function, such as wechat voice, qq voice by carrier of the various softwares for having call function.
In this case, the bluetooths peripheral hardware such as bluetooth headset can be used as audio initiation/receiving end in communication process, realize auxiliary
Call;And if the second communication equipment includes other mobile terminals, other mobile terminals, can also serve as conversing at this time
Audio initiation/receiving end or other terminals in journey are also used as synchronous audiomonitor and realize and the first communication equipment
Synchronous call.
The Bluetooth communication connection established between first communication equipment and the second communication equipment, can allow according to the actual situation
Any one of them may search for as recipient, searcher when initiating the search to recipient as searcher, another one
The character types that recipient supports, such as only AG role, only HF role and support AG role and HF role simultaneously.
In the present embodiment, to the registration process of the first communication equipment, be by least one UUID, while to AG role and
HF role registers;Specifically, the first communication equipment is by being written a default UUID in Session Description Protocol SDP
Value carries out the AG role of the first communication equipment simultaneously and HF role's registration may include:
In sdp, the data element Data Element value of default frame structure is written, as default in first communication equipment
UUID。
In some embodiments, by SDP, the first communication equipment and the second communication equipment for determining connection to be established are respectively
The case where AG and HF of support may include:
First communication equipment initiates bluetooth discovery, the role for making the first communication equipment determine that the second communication equipment is supported.
Bluetooth discovery side can be carried out by the first communication equipment or the second communication equipment, that is to say, that the first communication equipment can be with
As search initiator, the second communication equipment can also be used as search initiator;When the first communication equipment is as search initiator
When, the second communication equipment is just as search recipient.The first communication equipment and second of connection to be established is determined in the present embodiment
The case where AG and HF of each self-supporting of communication equipment, and the case where searcher knows the support AG and HF of itself, it is only necessary to pass through
Search, knows the support situation of other side.In the present embodiment, that is, by initiating bluetooth discovery, so that the first bluetooth
Equipment determines the role that the second bluetooth equipment is supported.
Specifically, the first communication equipment initiates bluetooth discovery, the first communication equipment is made to determine that the second communication equipment is supported
Role may include:
First communication equipment initiates SDP search request message;
The SDP search response message for receiving the transmission of the second communication equipment in SDP search response message, carries characterization second
The characteristic value for the role that communication equipment is supported.Wherein, in SDP search response message, the second communication equipment of characterization institute of carrying
The characteristic value of the role of support, that is, the UUID that second communication equipment is written in registration, including but not limited to one
UUID shows that the bluetooth equipment supports one of AG role or HF role;Either two UUID, show the bluetooth equipment
AG role and HF role are supported simultaneously.
In some embodiments, the first communication equipment of connection to be established and the AG of each self-supporting of the second communication equipment are determined
And the case where HF, can also include:
The bluetooth discovery for receiving the initiation of the second communication equipment, makes the second communication equipment determine what the first communication equipment was supported
Role.The example shows that searcher has become the second communication equipment, and when scanning for, the first communication is set the second communication equipment
Standby then be used as searched side, the role for accordingly being supported itself feeds back to the second communication equipment, process and above-mentioned the
One communication equipment is as the similar of searcher, and only the two exchanges role.
In some embodiments, the bluetooth discovery that the second communication equipment is initiated is received, the second communication equipment is made to determine first
The role that communication equipment is supported may include:
It receives the second communication equipment and initiates SDP search request message;
SDP search response message is sent to the second communication equipment, in SDP search response message, carries the first communication of characterization
The characteristic value for the role that equipment is supported.
Between first communication equipment and the second communication equipment when being attached, the mode connected can be to be connected automatically
Connect, be attached by the control of user etc., wherein automatic connection indicates the two after the search is completed, is automatically performed bluetooth
Connection can borrow the connection to realize Bluetooth communication between the two after connection;Automatically the type connected, can be according to the first communication
The difference for the character types supported between equipment and the second communication equipment and be arranged, such as, the first communication equipment is supported simultaneously
When AG and HF role, if the second communication equipment, only support one of role, then the first communication equipment by corresponding role with
Connection;If the second communication equipment also supports two kinds of roles, can be random between the first communication equipment and the second communication equipment
It selects corresponding role to connect, or according to preset priority, corresponding role is selected to be attached.Pass through the control of user
The case where connecting, then supporting two kinds of roles mainly for the first communication equipment and the second communication equipment is used in this case
Family can voluntarily select how to connect between the first communication equipment and the second communication equipment.
Specifically, establishing connection with the second communication equipment may include: with matched role
When the second communication equipment only supports AG role, the first communication equipment is established by HF role and the second communication equipment
Connection;
When the second communication equipment only supports HF role, the first communication equipment is established by AG role and the second communication equipment
Connection;
When the second communication equipment supports AG role and HF role simultaneously, between the first communication equipment and the second communication equipment
Connection is established by any AG role and HF role combinations.
Fourth embodiment
A kind of Bluetooth communication attachment device is present embodiments provided, referring to FIG. 8, the Bluetooth communication attachment device is applied to
Second Bluetooth communication terminal, specifically includes:
Second role determining module 801, the first communication equipment and the second communication equipment for determining connection to be established are each
The case where AG and HF of self-supporting;Wherein, the first communication equipment is by being written at least one in Session Description Protocol SDP
UUID value carries out AG role and the HF role's registration of the first communication equipment;
Second link block 802, for establishing connection with matched role and the first communication equipment.
The first communication equipment and the second communication equipment in the present embodiment, the communication that can belong to mobile terminal class are set
It is standby, such as mobile phone, wearable device, PC PC, it can also be terminal class equipment with one of them, another one is outside bluetooth
If such as bluetooth headset, bluetooth mouse, bluetooth keyboard;Difference between the two is, the communication equipment, if having with
The function that other modes are communicated with other equipment, such as, the call function on mobile phone, data connection function, wifi function
Energy etc. belongs to function not available for bluetooth peripheral hardware, that is to say, that bluetooth peripheral hardware is communicated as auxiliary mobile terminal
's.And bluetooth peripheral hardware, it is however generally that only have the function of HF role, mobile terminal can then have the function of AG role and HF role
Energy.In addition, the first communication equipment and the second communication equipment in the present embodiment, the angle only played the part of in process between the two
Color is distinguished, and the two can have same hardware configuration, and the first communication equipment and the second communication equipment are corresponding
Role can be interchanged in scene, the present embodiment is simultaneously not limited thereof.
When first communication equipment includes mobile terminal, the call function of the mobile terminal can pass through carrier network reality
Existing, wherein terminal can realize the call function by esim card or entity sim card;Alternatively, can also by data connection,
The functions such as wifi realize call function, such as wechat voice, qq voice by carrier of the various softwares for having call function.
In this case, the bluetooths peripheral hardware such as bluetooth headset can be used as audio initiation/receiving end in communication process, realize auxiliary
Call;And if the second communication equipment includes other mobile terminals, other mobile terminals, can also serve as conversing at this time
Audio initiation/receiving end or other terminals in journey are also used as synchronous audiomonitor and realize and the first communication equipment
Synchronous call.
The Bluetooth communication connection established between first communication equipment and the second communication equipment, can allow according to the actual situation
Any one of them may search for as recipient, searcher when initiating the search to recipient as searcher, another one
The character types that recipient supports, such as only AG role, only HF role and support AG role and HF role simultaneously.
It is by a UUID, while to AG role and the angle HF to the registration process of the first communication equipment in the present embodiment
Color is registered;Specifically, the first communication equipment is by the way that in Session Description Protocol SDP, one default UUID value of write-in is same
The AG role of the first communication equipment of Shi Jinhang and HF role's registration may include:
In sdp, the data element Data Element value of default frame structure is written, as default in first communication equipment
UUID。
In some embodiments, by SDP, the first communication equipment and the second communication equipment for determining connection to be established are respectively
The case where AG and HF of support may include:
First communication equipment initiates bluetooth discovery, the role for making the first communication equipment determine that the second communication equipment is supported.
Specifically, the first communication equipment initiates bluetooth discovery, the first communication equipment is made to determine that the second communication equipment is supported
Role may include:
First communication equipment initiates SDP search request message;
The SDP search response message for receiving the transmission of the second communication equipment in SDP search response message, carries characterization second
The characteristic value for the role that communication equipment is supported.
In some embodiments, the first communication equipment of connection to be established and the AG of each self-supporting of the second communication equipment are determined
And the case where HF, can also include:
The bluetooth discovery for receiving the initiation of the second communication equipment, makes the second communication equipment determine what the first communication equipment was supported
Role.
In some embodiments, the bluetooth discovery that the second communication equipment is initiated is received, the second communication equipment is made to determine first
The role that communication equipment is supported may include:
It receives the second communication equipment and initiates SDP search request message;
SDP search response message is sent to the second communication equipment, in SDP search response message, carries the first communication of characterization
The characteristic value for the role that equipment is supported.
Specifically, establishing connection with the second communication equipment may include: with matched role
When the second communication equipment only supports AG role, the first communication equipment is established by HF role and the second communication equipment
Connection;
When the second communication equipment only supports HF role, the first communication equipment is established by AG role and the second communication equipment
Connection;
When the second communication equipment supports AG role and HF role simultaneously, between the first communication equipment and the second communication equipment
Connection is established by any AG role and HF role combinations.
In some embodiments, with matched role, after establishing connection with the second communication equipment, can also include:
When the first communication equipment keeps connection status with a role and the second communication equipment, another role is nullified.
5th embodiment
A kind of Bluetooth communication connection method is present embodiments provided, referring to FIG. 10, the Bluetooth communication connection method includes:
S901, the first communication device initiated bluetooth;
S902, the first communication equipment are completed at the same time by the way that a new UUID is written in sdp to AG role and HF role
Registration;
S903, the corresponding ports for starting a RFcomm;
S904, the second communication equipment initiate bluetooth discovery, and the first communication equipment of discovery supports two roles of AG and HF;
Do S905, the second communication equipment initiate AG connection? if so, S906 is gone to, if it is not, going to S908;
S906, starting AG, which are serviced and bound the port RFcomm, completes connection;
S907, it completes after connecting, modification UUID is HF;
Do S908, the second communication equipment initiate HF connection? if so, going to S909;
S909, starting HF, which are serviced and bound the port RFcomm, completes connection;
S910, it completes after connecting, modification UUID is AG.
Sixth embodiment
A kind of communication equipment is present embodiments provided, Figure 11 is please referred to, which includes memory 1002, transmitter
1004, receiver 1005, processor 1001 and communication bus 1003;
Communication bus 1003 is for realizing the connection communication between memory 1002 and processor 1001;
1001 control transmitter 1004 of processor, receiver 1005, and call the computer stored in memory 1002
Program, the step of to realize the Bluetooth communication connection method in the various embodiments described above, which is not described herein again.
The present embodiment additionally provides a kind of computer readable storage medium, which can be applied to respectively
In kind intelligent wearable device, it is stored with one or more computer program, which can quilt
One or more processor executes, the step of to realize as above Bluetooth communication connection method shown in each embodiment.
It should be noted that, in this document, term " includes ", " comprising " or its any other variant are intended to non-row
His property includes, so that the process, method, article or the device that include a series of elements not only include those elements, and
And further include other elements that are not explicitly listed, or further include for this process, method, article or device institute it is intrinsic
Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including being somebody's turn to do
There is also other identical elements in the process, method of element, article or device.
Above-mentioned the embodiment of the present application serial number is for illustration only, does not represent the advantages or disadvantages of the embodiments.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side
Method can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases
The former is more preferably embodiment.Based on this understanding, the technical solution of the application substantially in other words does the prior art
The part contributed out can be embodied in the form of software products, which is stored in a storage medium
In (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that a terminal (can be mobile phone, computer, service
Device, air conditioner or network equipment etc.) execute method described in each embodiment of the application.
Embodiments herein is described above in conjunction with attached drawing, but the application be not limited to it is above-mentioned specific
Embodiment, the above mentioned embodiment is only schematical, rather than restrictive, those skilled in the art
Under the enlightenment of the application, when not departing from the application objective and scope of the claimed protection, can also it make very much
Form, these are belonged within the protection of the application.
Claims (10)
1. a kind of Bluetooth communication connection method, which is characterized in that the Bluetooth communication connection method includes:
In Session Description Protocol SDP registration, at least one UUID is written, to the role of first communication equipment into
Row registration, the value of at least one UUID correspond to first communication equipment and support audio frequency net gate way AG role and hands-free simultaneously
HF role;
Bluetooth discovery is initiated, determines the role that the second communication equipment is supported;It is searched or, receiving the bluetooth that the second communication equipment is initiated
Rope, the role for making the second communication equipment determine that the first communication equipment is supported;
According to bluetooth discovery as a result, being matched to the role between the first communication equipment and the second communication equipment;
With matched role, connection is established with the second communication equipment.
2. Bluetooth communication connection method as described in claim 1, which is characterized in that the initiation bluetooth discovery determines second
The role that communication equipment is supported includes:
Initiate the request message of SDP search;
It receives the SDP search response message of the second communication device feeding back, in the SDP search response message, carries characterization institute
State the characteristic value for the role that the second communication equipment is supported.
3. Bluetooth communication connection method as described in claim 1, which is characterized in that described to receive what the second communication equipment was initiated
Bluetooth discovery, the role for making the second communication equipment determine that the first communication equipment is supported include:
Receive the request message that the second communication equipment initiates SDP search;
To the second communication device feeding back SDP search response message, in the SDP search response message, characterization institute is carried
State the characteristic value for the role that the first communication equipment is supported.
4. Bluetooth communication connection method as described in claim 1, which is characterized in that described to first communication equipment
After role registers, further includes:
Start the port RFcomm, waits subsequent connection.
5. Bluetooth communication connection method as claimed in claim 4, which is characterized in that it is described with matched role, it is logical with second
Letter equipment establishes connection and includes:
By the port RFcomm having been turned on, to establish connection with the matched role of the second communication equipment.
6. Bluetooth communication connection method as described in any one in claim 1-5, which is characterized in that at least one UUID's
Value corresponds to first communication equipment support audio frequency net gate way AG role and hands-free HF role includes:
When the UUID is two, the value of one of UUID corresponds to first communication equipment and supports AG role, another
The value of UUID corresponds to first communication equipment and supports HF role;
When the UUID is one, the value of the UUID corresponds to first communication equipment and supports the angle audio frequency net gate way AG simultaneously
Color and hands-free HF role.
7. Bluetooth communication connection method as claimed in claim 6, which is characterized in that described with matched role, with second
Communication equipment is established after connection, further includes:
When the UUID is one, the value of the UUID is modified, so that the value of modified UUID is corresponded only to described first logical
Letter equipment only supports the role that connection is currently established with the second communication equipment.
8. Bluetooth communication connection method as described in any one in claim 1-5, which is characterized in that it is described with matched role,
Establishing connection with the second communication equipment includes:
When second communication equipment only supports AG role, first communication equipment is communicated by HF role with described second
Equipment establishes connection;
When second communication equipment only supports HF role, first communication equipment is communicated by AG role with described second
Equipment establishes connection;
When second communication equipment supports AG role and HF role simultaneously, first communication equipment passes through AG role, with
Second communication equipment establishes connection by HF role;Or, first communication equipment is by HF role, it is logical with the second communication equipment
It crosses AG role and establishes connection.
9. a kind of communication equipment, which is characterized in that the communication equipment includes memory, transmitter, receiver, processor and leads to
Believe bus;
The communication bus is for realizing the connection communication between memory and processor;
The processor control transmitter, receiver, and the computer program stored in memory is called, to realize such as right
It is required that described in any one of 1-8 the step of Bluetooth communication connection method.
10. a kind of computer readable storage medium, which is characterized in that the computer-readable recording medium storage has computer journey
Sequence, the computer program can be executed by processor to realize such as the described in any item Bluetooth communication connection sides of claim 1-8
The step of method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910364480.2A CN110191443A (en) | 2019-04-30 | 2019-04-30 | Bluetooth communication connection method, communication equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910364480.2A CN110191443A (en) | 2019-04-30 | 2019-04-30 | Bluetooth communication connection method, communication equipment and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110191443A true CN110191443A (en) | 2019-08-30 |
Family
ID=67715550
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910364480.2A Pending CN110191443A (en) | 2019-04-30 | 2019-04-30 | Bluetooth communication connection method, communication equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110191443A (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103745720A (en) * | 2013-12-25 | 2014-04-23 | 安徽科大讯飞信息科技股份有限公司 | Bluetooth system with voice recognition |
CN106507501A (en) * | 2016-10-14 | 2017-03-15 | 广东欧珀移动通信有限公司 | A kind of Bluetooth connecting method and device |
CN106658359A (en) * | 2016-10-12 | 2017-05-10 | 青岛海信移动通信技术股份有限公司 | Bluetooth connection method and device and communication system |
US20170171734A1 (en) * | 2015-12-09 | 2017-06-15 | Hyundai Motor Company | Method of operating avn, avn, and vehicle including the same |
CN106900079A (en) * | 2015-12-18 | 2017-06-27 | 展讯通信(上海)有限公司 | Bluetooth connecting method and device |
-
2019
- 2019-04-30 CN CN201910364480.2A patent/CN110191443A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103745720A (en) * | 2013-12-25 | 2014-04-23 | 安徽科大讯飞信息科技股份有限公司 | Bluetooth system with voice recognition |
US20170171734A1 (en) * | 2015-12-09 | 2017-06-15 | Hyundai Motor Company | Method of operating avn, avn, and vehicle including the same |
CN106900079A (en) * | 2015-12-18 | 2017-06-27 | 展讯通信(上海)有限公司 | Bluetooth connecting method and device |
CN106658359A (en) * | 2016-10-12 | 2017-05-10 | 青岛海信移动通信技术股份有限公司 | Bluetooth connection method and device and communication system |
CN106507501A (en) * | 2016-10-14 | 2017-03-15 | 广东欧珀移动通信有限公司 | A kind of Bluetooth connecting method and device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107948430A (en) | A kind of display control method, mobile terminal and computer-readable recording medium | |
CN109462700A (en) | A kind of call method, mobile terminal and computer readable storage medium | |
CN110098845B (en) | Message processing method, wearable device, mobile terminal and readable storage medium | |
CN110267244A (en) | Communication handover method, equipment, system and readable storage medium storing program for executing | |
CN109995938A (en) | A kind of notice display methods, mobile phone, wearable device and calculate readable storage medium storing program for executing | |
CN110069193B (en) | Interface switching method of wearable device, wearable device and storage medium | |
CN110087223A (en) | Communication connecting method, communication equipment and storage medium | |
CN110213749A (en) | Communication processing method, communication equipment and storage medium | |
CN110198534A (en) | Communicate transparent transmission control method, communication equipment, system and storage medium | |
CN110213442A (en) | Speech playing method, terminal and computer readable storage medium | |
CN110139258A (en) | Communication connecting method, communication equipment and storage medium | |
CN110234099A (en) | Communication connecting method, communication equipment and storage medium | |
CN109151163A (en) | A kind of method for controlling mobile terminal, mobile terminal and computer readable storage medium | |
CN110191443A (en) | Bluetooth communication connection method, communication equipment and storage medium | |
CN110139257A (en) | Communication connecting method, communication equipment and storage medium | |
CN110121163A (en) | Registration handling method, communication equipment and storage medium | |
CN110267361A (en) | Communication control method, equipment, system and readable storage medium storing program for executing | |
CN110267243A (en) | Communication control method, communication equipment and storage medium | |
CN110248345A (en) | Communication control method, equipment, system and readable storage medium storing program for executing | |
CN110213750A (en) | Communication control method, equipment, system and readable storage medium storing program for executing | |
CN110234137A (en) | Communication control method, equipment, system and readable storage medium storing program for executing | |
CN110213836A (en) | Communication connecting method, communication equipment and storage medium | |
CN110191444A (en) | Communication connecting method, communication equipment and storage medium | |
CN110191445A (en) | Communication connecting method, communication equipment and storage medium | |
CN110087222A (en) | Role switching control method, communication equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20190830 |
|
RJ01 | Rejection of invention patent application after publication |