CN112449332B - Bluetooth connection method and electronic equipment - Google Patents

Bluetooth connection method and electronic equipment Download PDF

Info

Publication number
CN112449332B
CN112449332B CN201910844294.9A CN201910844294A CN112449332B CN 112449332 B CN112449332 B CN 112449332B CN 201910844294 A CN201910844294 A CN 201910844294A CN 112449332 B CN112449332 B CN 112449332B
Authority
CN
China
Prior art keywords
bluetooth
electronic device
accessory
authentication information
user
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910844294.9A
Other languages
Chinese (zh)
Other versions
CN112449332A (en
Inventor
朱宇洪
倪观军
林健新
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to PCT/CN2020/112126 priority Critical patent/WO2021037208A1/en
Publication of CN112449332A publication Critical patent/CN112449332A/en
Application granted granted Critical
Publication of CN112449332B publication Critical patent/CN112449332B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/06Authentication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W48/00Access restriction; Network selection; Access point selection
    • H04W48/08Access restriction or access information delivery, e.g. discovery data delivery
    • H04W48/10Access restriction or access information delivery, e.g. discovery data delivery using broadcasted information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W48/00Access restriction; Network selection; Access point selection
    • H04W48/16Discovering, processing access restriction or access information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/005Discovery of network devices, e.g. terminals
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Databases & Information Systems (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Telephone Function (AREA)

Abstract

The application provides a Bluetooth connection method and electronic equipment, wherein the Bluetooth connection method comprises the following steps: the Bluetooth headset is connected with the mobile phone A which is connected last time after being opened, and meanwhile, the Bluetooth headset can also send Bluetooth low energy BLE broadcast messages to other surrounding equipment; after receiving the BLE broadcast message, the mobile phone B prompts a user to input an encryption password; and after the mutual authentication between the mobile phone B and the Bluetooth headset is passed, the mobile phone B and the Bluetooth headset establish Bluetooth connection. The embodiment of the application is beneficial to improving the intelligent degree and the privacy of the electronic equipment and avoiding the complex operation of the user.

Description

Bluetooth connection method and electronic equipment
The present application claims priority of chinese patent application with chinese patent office, application number 201910816994.7, entitled "a bluetooth connection method and electronic device" filed on 30/8/2019 and chinese patent application with chinese patent office, application number 201910816105.7, entitled "a bluetooth pairing method and related device" filed on 30/8/2019, the entire contents of which are incorporated herein by reference.
Technical Field
The present application relates to the field of communications, and more particularly, to a method and an electronic device for bluetooth connection.
Background
In existing bluetooth connection procedures, accessory devices (e.g., bluetooth headsets, etc.) may connect to an electronic device through proximity discovery. However, when the accessory device needs to be connected to another electronic device, the accessory device needs to enter a pairable state to establish a bluetooth connection with the other electronic device.
For example, for an apple ipod, after a user needs to press a function key on an earphone box for 2-3 seconds, the ipod can be triggered to enter a pairable state, and then another electronic device can establish a bluetooth connection with the ipod. Such an operation is cumbersome for the user, and when the user wants the ipod to connect to a different electronic device, the user presses the function key before each connection. At the same time, this also increases the latency of the connection of the electronic device to the ipod.
Disclosure of Invention
The application provides a Bluetooth connection method and electronic equipment, which are beneficial to improving the intelligent degree and privacy of the electronic equipment and avoiding the complex operation of a user.
In a first aspect, a system is provided that includes a first electronic device and an accessory device to detect a first operation by a user; the accessory device is further configured to send first information to the first electronic device in response to the first operation, where the first information includes a Media Access Control (MAC) address of the accessory device and authentication information, and the authentication information is used to indicate that interactive authentication is required for connecting the accessory device; the first electronic equipment is used for prompting a user to input first authentication information when the MAC address is determined not to be stored; the first electronic equipment is also used for carrying out interactive authentication with the accessory equipment according to the first authentication information when the first authentication information input by a user is detected; the accessory equipment is also used for entering a pairable mode after the interactive authentication with the second electronic equipment is passed; the first electronic device is also used for establishing Bluetooth connection with the accessory device.
In the embodiment of the application, when the electronic device establishes the Bluetooth connection with the accessory device, the electronic device can prompt a user to input authentication information, and after the interactive authentication between the electronic device and the accessory device is passed, the accessory device can automatically enter a pairable mode. The pairing of the electronic equipment and the accessory equipment can be realized without the operation of a user on the accessory equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the accessory equipment by the user is reduced. Meanwhile, the privacy between the electronic equipment and accessory equipment can be improved.
In some possible implementation manners, the first electronic device performs mutual authentication with the accessory device, and may authenticate the first authentication information by the accessory device after the first electronic device sends the first authentication information input by the user to the accessory device. The accessory device can also authenticate the first authentication information, and the first electronic device also authenticates the authentication information sent by the accessory device; after the authentication information of the opposite party is successfully authenticated by both parties, the first electronic equipment and the accessory equipment are authenticated interactively.
With reference to the first aspect, in some possible implementations of the first aspect, the accessory device is further configured to send second information to the first electronic device before establishing a bluetooth connection with the first electronic device, where the second information is used to instruct the accessory device to enter a pairable mode; the first electronic device is specifically configured to: in response to receiving the second information, automatically sending a paging page message to the accessory device using the MAC address; and performing a standard Bluetooth pairing procedure with the accessory device.
In the embodiment of the application, after entering the pairable mode, the accessory device can indicate that the electronic device has entered the pairable mode, so that the electronic device can automatically send a paging message to the accessory device after receiving the indication, and a standard bluetooth pairing process is performed with the accessory device. The method and the device have the advantages that the electronic equipment can initiate paging to the accessory equipment without the operation of a user on the electronic equipment, so that the Bluetooth pairing process is simplified, and the difficulty of the user in operating the accessory equipment is reduced.
With reference to the first aspect, in some possible implementations of the first aspect, the system further includes a second electronic device, where the accessory device is configured to establish a bluetooth connection with the second electronic device before detecting the first operation; the second electronic device is used for prompting a user to add authentication information to the accessory device after the Bluetooth connection is established with the accessory device; the second electronic device is further used for sending the first authentication information to the accessory device after detecting that the user adds the first authentication information to the accessory device.
In the embodiment of the application, before the accessory device is connected with the first electronic device through the bluetooth, the accessory device can be connected with the second electronic device through the bluetooth, the second electronic device can prompt a user to add authentication information to the accessory device, and after the authentication information is added, the second electronic device sends the first authentication information to the accessory device after the first authentication information set by the user, so that when the accessory device is connected with the next electronic device, the accessory device can authenticate the next electronic device through the first authentication information.
In some possible implementations, the first authentication information may also be authentication information that is set inside the accessory device when the accessory device is shipped from a factory.
With reference to the first aspect, in some possible implementation manners of the first aspect, the first electronic device is further configured to prompt the user to modify the first authentication information or prompt the user to cancel the first authentication information after establishing a bluetooth connection with the accessory device; the first electronic device is further used for sending the second authentication information to the accessory device after detecting that the user modifies the first authentication information into the second authentication information.
In this embodiment of the application, after the first electronic device and the accessory device pass the interactive authentication and establish the bluetooth connection, the first electronic device may further prompt the user to modify the first authentication information, or prompt the user to cancel the first authentication information. When the first electronic device detects that the user modifies the first authentication information into the second authentication information, the first electronic device may send the second authentication information to the accessory device, so that the accessory device performs interactive authentication on the next electronic device to be connected by using the second authentication information. The first electronic device can modify the authentication information of the accessory device, which can further improve the privacy between the electronic device and the accessory device.
With reference to the first aspect, in some possible implementations of the first aspect, the system further includes a third electronic device, where the third electronic device is a device that is previously connected to the accessory device and is not last connected to the accessory device, and the accessory device is further configured to send the first information to the third electronic device; the third electronic device is used for prompting a user whether to establish Bluetooth connection with the accessory device after the third electronic device is determined to store the MAC address; the third electronic device is further configured to perform interactive authentication with the accessory device through third authentication information after detecting an operation of determining that the connection with the accessory device is established, where the third authentication information is authentication information added by the user to the accessory device on the third electronic device; the accessory equipment is also used for entering a pairing mode and disconnecting the Bluetooth connection with the first electronic equipment after the interactive authentication with the third electronic equipment is passed; the third electronic device is further configured to establish a bluetooth connection with the accessory device.
In this embodiment of the application, after receiving the first information, the electronic device that has been connected before but was not connected last time may prompt the user whether to connect the accessory device, and when the third electronic device determines that the accessory device needs to be connected, the accessory device also needs to perform interactive authentication with the third electronic device. Since it is possible that the other device modifies the authentication information for the accessory device after the third electronic device has been previously connected. This may improve privacy between the electronic device and the accessory device.
With reference to the first aspect, in some possible implementation manners of the first aspect, the accessory device is a bluetooth headset, and the first operation is an operation of opening a headset box by a user.
In a second aspect, a method for bluetooth connection is provided, where the method is applied to an electronic device, and the method includes: receiving first information sent by accessory equipment, wherein the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required to be carried out when the accessory equipment is connected; prompting a user to input first authentication information when the MAC address is determined not to be stored; when the fact that the user inputs the first authentication information is detected, performing interactive authentication with the accessory equipment according to the first authentication information; and after the interactive authentication with the accessory device is passed, establishing Bluetooth connection with the accessory device.
In the embodiment of the application, when the electronic device establishes the Bluetooth connection with the accessory device, the electronic device can prompt a user to input authentication information, and after the interactive authentication between the electronic device and the accessory device is passed, the accessory device can automatically enter a pairable mode. The pairing of the electronic equipment and the accessory equipment can be realized without the operation of a user on the accessory equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the accessory equipment by the user is reduced. Meanwhile, the privacy between the electronic equipment and accessory equipment can be improved.
With reference to the second aspect, in some possible implementations of the second aspect, before the establishing the bluetooth connection with the accessory device, the method further includes: receiving indication information sent by the accessory device, wherein the indication information is used for indicating the accessory device to enter a pairable mode; wherein, should establish bluetooth with this accessory device and be connected, include: in response to receiving the indication information, sending a paging message to the accessory device; and carrying out a standard Bluetooth pairing process with the Bluetooth headset.
In the embodiment of the application, after entering the pairable mode, the accessory device can indicate that the electronic device has entered the pairable mode, so that the electronic device can automatically send a paging message to the accessory device after receiving the indication, and a standard bluetooth pairing process is performed with the accessory device. The method and the device have the advantages that the electronic equipment can initiate paging to the accessory equipment without the operation of a user on the electronic equipment, so that the Bluetooth pairing process is simplified, and the difficulty of the user in operating the accessory equipment is reduced.
With reference to the second aspect, in some possible implementations of the second aspect, the method further includes: after the Bluetooth connection with the accessory equipment is established, prompting a user to modify the first authentication information, or prompting the user whether to cancel the first authentication information; and after detecting the operation that the user modifies the first authentication information into second authentication information, sending the second authentication information to the accessory equipment.
In the embodiment of the application, after the electronic device and the accessory device pass the interactive authentication and establish the bluetooth connection, the electronic device may further prompt the user to modify the first authentication information, or prompt the user to cancel the first authentication information. When the electronic device detects that the user modifies the first authentication information into the second authentication information, the electronic device may send the second authentication information to the accessory device, so that the accessory device performs interactive authentication on the next electronic device to be connected by using the second authentication information. The electronic device can modify the authentication information of the accessory device, which can further improve the privacy between the electronic device and the accessory device.
In a third aspect, a method for bluetooth connection is provided, where the method is applied to an accessory device, and the method includes: detecting a first operation of a user; responding to the first operation, sending first information to first electronic equipment, wherein the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required to be carried out when the accessory equipment is connected; performing interactive authentication with the first electronic device according to first authentication information, wherein the first authentication information is authentication information input by a user and detected on the first electronic device; entering a pairable mode after successful mutual authentication with the first electronic equipment; and establishing a Bluetooth connection with the first electronic device.
With reference to the third aspect, in some possible implementation manners of the third aspect, the method further includes: before establishing Bluetooth connection with the first electronic equipment, sending second information to the first electronic equipment, wherein the second information is used for indicating the accessory equipment to enter a pairable mode; wherein, should establish bluetooth with this first electronic equipment and connect, include: receiving a paging message sent by the first electronic equipment; and carrying out a standard Bluetooth pairing process with the first electronic equipment.
In the embodiment of the application, after the electronic device and the accessory device pass the interactive authentication, the accessory device can automatically enter the pairable mode. The pairing of the electronic equipment and the accessory equipment can be realized without the operation of a user on the accessory equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the accessory equipment by the user is reduced. Meanwhile, the privacy between the electronic equipment and accessory equipment can be improved.
With reference to the third aspect, in some possible implementation manners of the third aspect, the method further includes: before detecting the first operation, establishing a Bluetooth connection with the second electronic equipment; and receiving the first authentication information sent by the second electronic equipment.
With reference to the third aspect, in some possible implementation manners of the third aspect, the method further includes: after Bluetooth connection with the first electronic equipment is established, second authentication information sent by the first electronic equipment is received; and storing the second authentication information, wherein the second authentication information is used for mutual authentication between the accessory equipment and the electronic equipment to be connected next.
With reference to the third aspect, in some possible implementation manners of the third aspect, the accessory device is a bluetooth headset, and the first operation is an operation of opening a headset box by a user.
In a fourth aspect, a chip system is provided in an electronic device, the chip system including: the Bluetooth chip is used for receiving first information sent by accessory equipment, the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required when the accessory equipment is connected; the processor is used for controlling the display screen to prompt a user to input first authentication information when the MAC address is determined not to be stored; the processor is further configured to determine the first authentication information; the Bluetooth chip is also used for carrying out interactive authentication with the accessory equipment according to the first authentication information; the Bluetooth chip is also used for establishing Bluetooth connection with the accessory equipment after the interactive authentication with the accessory equipment is passed.
In some possible implementations, the bluetooth chip is further configured to receive indication information sent by the accessory device, where the indication information is used to indicate that the accessory device enters a pairable mode; the Bluetooth chip is also used for responding to the received indication information and sending a paging message to the accessory equipment; and carrying out a standard Bluetooth pairing process with the Bluetooth headset.
In some possible implementations, the processor is further configured to prompt a user to modify the first authentication information or prompt the user to cancel the first authentication information through a display screen; the processor is further used for receiving second authentication information detected by the touch sensor; the Bluetooth chip is further used for sending the second authentication information to the accessory device.
In a fifth aspect, a chip system is provided in an accessory device, the chip system comprising: the Bluetooth chip is used for sending first information to first electronic equipment, the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required when the accessory equipment is connected; the Bluetooth chip is also used for performing interactive authentication with the first electronic equipment according to first authentication information, wherein the first authentication information is authentication information input by a user and detected on the first electronic equipment; the Bluetooth chip is also used for entering a pairable mode after the Bluetooth chip successfully interacts with the first electronic equipment for authentication; the Bluetooth chip is also used for establishing Bluetooth connection with the first electronic equipment.
In some possible implementations, the bluetooth chip is further configured to send second information to the first electronic device before establishing a bluetooth connection with the first electronic device, where the second information is used to instruct the accessory device to enter a pairable mode; the Bluetooth chip is also used for receiving a paging message sent by the first electronic equipment; the Bluetooth chip is also used for carrying out a standard Bluetooth pairing process with the first electronic equipment.
In some possible implementations, the bluetooth chip is further configured to establish a bluetooth connection with the second electronic device before detecting the first operation; the bluetooth chip is further configured to receive the first authentication information sent by the second electronic device.
In some possible implementation manners, the bluetooth chip is further configured to receive second authentication information sent by the first electronic device after establishing a bluetooth connection with the first electronic device; the bluetooth chip is also used for storing the second authentication information.
A sixth aspect provides an apparatus, embodied in an electronic device, having functionality to implement the above aspects and possible implementations of the above aspects. The functions may be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above-described functions.
In a seventh aspect, there is provided an apparatus for inclusion in an accessory device, the apparatus having functionality to implement the above aspects and possible implementations of the above aspects. The functions may be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above-described functions.
In an eighth aspect, an electronic device is provided, including: a Bluetooth chip; a display screen; one or more processors; a memory; and one or more computer programs. Wherein, this bluetooth chip supports BR/EDR and BLE and connects. One or more computer programs are stored in the memory, the one or more computer programs including instructions. The instructions, when executed by the electronic device, cause the electronic device to perform the method of bluetooth connectivity in a possible implementation of the second aspect described above.
In a ninth aspect, there is provided an accessory device comprising: a Bluetooth chip; one or more processors; a memory; and one or more computer programs. Wherein, this bluetooth chip supports BR/EDR and BLE and connects. One or more computer programs are stored in the memory, the one or more computer programs including instructions. The instructions, when executed by the accessory device, cause the accessory device to perform the method of bluetooth connectivity in a possible implementation of the third aspect described above.
In a tenth aspect, the present disclosure provides a computer-readable storage medium including computer instructions, which, when executed on an electronic device, cause the electronic device to perform a method for bluetooth connection in any one of the possible implementations of any one of the above aspects.
In an eleventh aspect, the present disclosure provides a computer program product, which when run on an electronic device, causes the electronic device to perform the method for bluetooth connection in any one of the possible designs of the above aspects.
The application provides a Bluetooth pairing method and a related device, which can realize pairing of a terminal and Bluetooth equipment without operation of a user on the Bluetooth equipment, simplify a pairing process and reduce the difficulty of operating the Bluetooth equipment by the user.
In a twelfth aspect, the present application provides a bluetooth pairing method, applied to a bluetooth system, where the bluetooth system includes a terminal and a bluetooth device, and the method includes: first, the bluetooth device broadcasts a bluetooth low energy BLE broadcast packet. The BLE broadcast packet includes first pairing mode information and a bluetooth address of the bluetooth device. Then, the terminal receives the BLE broadcast packet broadcast by the bluetooth device. And then, when the terminal determines that the Bluetooth equipment does not enter the pairable mode currently according to the first pairing mode information, the terminal sends a pairing mode modification request to the Bluetooth equipment. Wherein the pairing mode request is for the bluetooth device to switch to a pairable mode. Then, the bluetooth device enters the pairable mode after receiving the pairing mode modification request. And finally, the terminal and the Bluetooth equipment are in Bluetooth pairing.
Through the application, the Bluetooth device can indicate whether the Bluetooth device enters the pairable mode through a specific field in a Bluetooth Low Energy (BLE) broadcast. Then, the terminal interacts with the Bluetooth equipment through the command on the BLE connection, the Bluetooth equipment enters a pairing mode, pairing of the terminal and the Bluetooth equipment can be achieved without operation of a user on the Bluetooth equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the Bluetooth equipment by the user is reduced.
In a possible implementation manner, the terminal may also be an electronic device, and the bluetooth device may also be an accessory device.
In one possible implementation, the method further includes: and when the terminal judges that the Bluetooth equipment enters the pairable mode currently according to the first pairing mode information, the terminal and the Bluetooth equipment are subjected to Bluetooth pairing. Therefore, when the Bluetooth equipment enters the pairing mode, the terminal can be directly paired with the Bluetooth equipment.
In one possible implementation, the method further includes: after the BLE broadcast packet broadcasted by the bluetooth device is received at the terminal, the method further includes: first, the terminal displays device options of the bluetooth device. Then, the terminal receives a pairing operation of the user for the Bluetooth device. Then, in response to the pairing operation, when the terminal determines that the bluetooth device does not currently enter a pairable mode according to the first pairing mode information, the terminal sends the pairing mode modification request to the bluetooth device. Therefore, the terminal can be paired with the Bluetooth equipment according to the needs of the user, and the user experience is improved.
In one possible implementation, before the terminal sends the pairing mode request to the bluetooth device, the method further includes: the terminal establishes BLE connection with the Bluetooth device. The terminal sends the pairing mode modification request to the Bluetooth device through response echo signaling of a logical link control and adaptation protocol L2 CAP.
In one possible implementation, after the bluetooth device enters the pairable mode, the method further includes: the bluetooth device transmits a pairing mode modification response to the terminal. And the pairing mode modification response comprises second pairing mode information of the Bluetooth device. And when the terminal determines that the Bluetooth equipment enters the pairable mode currently according to the second pairing mode information, the terminal is paired with the Bluetooth equipment. Therefore, after the Bluetooth device is switched to the pairing mode, the terminal can be informed that the terminal currently enters the pairing mode, so that pairing can be completed as soon as possible.
In a possible implementation manner, the bluetooth device sends the pairing mode modification response to the terminal through echo signaling of the L2 CAP.
In a possible implementation manner, when the bluetooth device enters the pairable mode, the bluetooth device enters an inquiry scan state.
In a possible implementation manner, after the bluetooth device receives the pairing mode modification request, the bluetooth device outputs a first prompt, where the first prompt is used to prompt a user that the terminal requests to pair with the bluetooth device.
In one possible implementation, the bluetooth device receives a confirmation pairing operation of the user. The bluetooth device enters a pairable mode in response to the confirm pairing operation.
In a thirteenth aspect, the present application provides a bluetooth system, comprising a terminal and a bluetooth device; the Bluetooth equipment is used for broadcasting a low-power consumption Bluetooth BLE broadcast packet. The BLE broadcast packet includes first pairing mode information and a bluetooth address of the bluetooth device. The terminal is configured to receive the BLE broadcast packet broadcasted by the bluetooth device. The terminal is further configured to send a pairing mode modification request to the bluetooth device when it is determined that the bluetooth device does not currently enter the pairable mode according to the first pairing mode information. The pairing mode request is for the bluetooth device to switch to a pairable mode. The bluetooth device is further configured to enter a pairable mode after receiving the pairing mode modification request. The terminal is also used for carrying out Bluetooth pairing with the Bluetooth equipment.
Through the method and the device, the Bluetooth device can indicate whether the Bluetooth device enters the pairable mode or not through a specific field in the low-power-consumption Bluetooth BLE broadcast. Then, the terminal interacts with the Bluetooth equipment through the command on the BLE connection, the Bluetooth equipment enters a pairing mode, pairing of the terminal and the Bluetooth equipment can be achieved without operation of a user on the Bluetooth equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the Bluetooth equipment by the user is reduced.
In a possible implementation manner, the terminal is further configured to: and when the Bluetooth device is judged to be currently in the pairable mode according to the first pairing mode information, carrying out Bluetooth pairing with the Bluetooth device. Therefore, when the Bluetooth equipment enters the pairing mode, the terminal can be directly paired with the Bluetooth equipment.
In a possible implementation manner, the terminal is further configured to: and when the BLE broadcast packet broadcasted by the Bluetooth device is received, displaying the device options of the Bluetooth device. The terminal is also used for receiving the pairing operation of the user aiming at the Bluetooth equipment. The terminal is further configured to respond to the pairing operation, and when the terminal determines that the bluetooth device does not currently enter a pairable mode according to the first pairing mode information, the terminal sends the pairing mode modification request to the bluetooth device. Therefore, the terminal can be paired with the Bluetooth equipment according to the needs of the user, and the user experience is improved.
In a possible implementation manner, the terminal is further configured to: and establishing BLE connection with the Bluetooth device. The terminal is specifically configured to: and sending the pairing mode modification request to the Bluetooth device through response echo signaling of a logical link control and adaptation protocol L2 CAP.
In one possible implementation, the bluetooth device is further configured to: and after the Bluetooth equipment enters the pairable mode, sending a pairing mode modification response to the terminal. And the pairing mode modification response comprises second pairing mode information of the Bluetooth device. The terminal is specifically configured to: and when the Bluetooth equipment is determined to enter the pairable mode currently according to the second pairing mode information, pairing with the Bluetooth equipment. Therefore, after the Bluetooth device is switched to the pairing mode, the terminal can be informed that the terminal currently enters the pairing mode, so that pairing can be completed as soon as possible.
In a possible implementation manner, the bluetooth device is specifically configured to: and sending the pairing mode modification response to the terminal through echo signaling of the L2 CAP.
In a possible implementation manner, when the bluetooth device enters the pairable mode, the bluetooth device enters an inquiry scan state.
In a fourteenth aspect, the present application provides a terminal, comprising: the device comprises a Bluetooth chip, a memory, a touch screen and a processor; the memory is coupled to the processor. Wherein, this bluetooth chip supports classic bluetooth BR EDR function and bluetooth low energy BLE function. The Bluetooth chip is used for receiving a low-power consumption Bluetooth BLE broadcast packet broadcasted by Bluetooth equipment. The BLE broadcast packet includes first pairing mode information and a bluetooth address of the bluetooth device. The processor is configured to instruct the bluetooth chip to send a pairing mode modification request to the bluetooth device when it is determined that the bluetooth device does not currently enter a pairable mode according to the first pairing mode information. Wherein the pairing mode request is for the bluetooth device to switch to a pairable mode. The Bluetooth chip is also used for carrying out Bluetooth pairing with the Bluetooth equipment after the Bluetooth equipment enters a pairing mode.
Through the method and the device, the Bluetooth device can indicate whether the Bluetooth device enters the pairable mode or not through a specific field in the low-power-consumption Bluetooth BLE broadcast. Then, the terminal interacts with the Bluetooth equipment through the command on the BLE connection, the Bluetooth equipment enters a pairing mode, pairing of the terminal and the Bluetooth equipment can be achieved without operation of a user on the Bluetooth equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the Bluetooth equipment by the user is reduced.
In a possible implementation manner, the processor is further configured to instruct the bluetooth chip to perform bluetooth pairing with the bluetooth device when it is determined that the bluetooth device currently enters the pairable mode according to the first pairing mode information. Therefore, when the Bluetooth equipment enters the pairing mode, the terminal can be directly paired with the Bluetooth equipment.
In a possible implementation manner, the touch screen is configured to display device options of the bluetooth device after receiving the BLE broadcast packet broadcasted by the bluetooth device. The touch screen is also used for receiving the pairing operation of the user for the Bluetooth equipment. The processor is specifically configured to: and responding to the pairing operation, and when determining that the Bluetooth device does not enter a pairable mode currently according to the first pairing mode information, indicating the Bluetooth chip to send the pairing mode modification request to the Bluetooth device. Therefore, the terminal can be paired with the Bluetooth equipment according to the needs of the user, and the user experience is improved.
In one possible implementation, the bluetooth chip is further configured to: and establishing BLE connection with the Bluetooth device. This bluetooth chip specifically is used for: and sending the pairing mode modification request to the Bluetooth device through response echo signaling of a logical link control and adaptation protocol L2 CAP.
In one possible implementation, the bluetooth chip is further configured to: and receiving a pairing mode modification response sent by the Bluetooth device after entering the pairable mode. And the pairing mode modification response comprises second pairing mode information of the Bluetooth device. The processor is specifically configured to: and when the Bluetooth device is determined to be currently in the pairable mode according to the second pairing mode information, indicating the Bluetooth chip to be paired with the Bluetooth device. Therefore, after the Bluetooth device is switched to the pairing mode, the terminal can be informed that the terminal currently enters the pairing mode, so that pairing can be completed as soon as possible.
In a possible implementation manner, the bluetooth chip is specifically configured to: and sending the pairing mode modification response to the terminal through echo signaling of the L2 CAP.
In a possible implementation manner, when the bluetooth device enters the pairable mode, the bluetooth device enters an inquiry scan state.
In a fifteenth aspect, the present application provides a bluetooth device, characterized by a bluetooth chip, a memory, and a processor; the memory is coupled with the processor; wherein, this bluetooth chip supports classic bluetooth BR EDR function and bluetooth low energy BLE function. This bluetooth chip for broadcasting low energy consumption bluetooth BLE broadcasts the package. The BLE broadcast packet includes first pairing mode information and a bluetooth address of the bluetooth device. The Bluetooth chip is also used for receiving a pairing mode modification request sent by the terminal. Wherein, the pairing mode request is used for the Bluetooth chip to switch to a pairable mode. This bluetooth chip still is used for carrying out the bluetooth with this bluetooth chip and pairs.
Through the method and the device, the Bluetooth device can indicate whether the Bluetooth device enters the pairable mode or not through a specific field in the low-power-consumption Bluetooth BLE broadcast. Then, the terminal interacts with the Bluetooth equipment through the command on the BLE connection, the Bluetooth equipment enters a pairing mode, pairing of the terminal and the Bluetooth equipment can be achieved without operation of a user on the Bluetooth equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the Bluetooth equipment by the user is reduced.
In a possible implementation manner, the bluetooth chip is further configured to perform bluetooth pairing with the terminal when the terminal determines that the bluetooth device currently enters the pairable mode according to the first pairing mode information.
In one possible implementation, the bluetooth chip is further configured to: a BLE connection is established with the terminal prior to receiving the pairing mode request. This bluetooth chip specifically is used for: and receiving the pairing mode modification request sent by the terminal through response echo signaling of the L2 CAP.
In one possible implementation, the bluetooth chip is further configured to: and sending a pairing mode modification response to the terminal. And the pairing mode modification response comprises second pairing mode information of the Bluetooth device. This bluetooth chip specifically is used for: and when the terminal determines that the Bluetooth equipment enters the pairable mode currently according to the second pairing mode information, carrying out Bluetooth pairing with the terminal.
In a possible implementation manner, the bluetooth chip is specifically configured to: and sending the pairing mode modification response to the terminal through echo signaling of the L2 CAP.
In one possible implementation, when the bluetooth chip enters the pairable mode, the bluetooth chip enters an inquiry scan state.
In a sixteenth aspect, the present application provides a chip system disposed on a terminal, the chip system including: bluetooth chip and treater. The Bluetooth chip is used for receiving a low-power consumption Bluetooth BLE broadcast packet broadcasted by the Bluetooth equipment. The BLE broadcast packet includes first pairing mode information and a bluetooth address of the bluetooth device. The processor is configured to instruct the bluetooth chip to send a pairing mode modification request to the bluetooth device when it is determined that the bluetooth device does not currently enter a pairable mode according to the first pairing mode information. Wherein the pairing mode request is for the bluetooth device to switch to a pairable mode. The Bluetooth chip is also used for carrying out Bluetooth pairing with the Bluetooth equipment after the Bluetooth equipment enters a pairing mode.
Through the method and the device, the Bluetooth device can indicate whether the Bluetooth device enters the pairable mode or not through a specific field in the low-power-consumption Bluetooth BLE broadcast. Then, the terminal interacts with the Bluetooth equipment through the command on the BLE connection, the Bluetooth equipment enters a pairing mode, pairing of the terminal and the Bluetooth equipment can be achieved without operation of a user on the Bluetooth equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the Bluetooth equipment by the user is reduced.
In a possible implementation manner, the processor is further configured to instruct the bluetooth chip to perform bluetooth pairing with the bluetooth device when it is determined that the bluetooth device currently enters the pairable mode according to the first pairing mode information.
In one possible implementation, the bluetooth chip is further configured to: and establishing BLE connection with the Bluetooth device. This bluetooth chip specifically is used for: and sending the pairing mode modification request to the Bluetooth device through response echo signaling of a logical link control and adaptation protocol L2 CAP.
In one possible implementation, the bluetooth chip is further configured to: and receiving a pairing mode modification response sent by the Bluetooth device after entering the pairable mode. And the pairing mode modification response comprises second pairing mode information of the Bluetooth device. The processor is specifically configured to: and when the Bluetooth device is determined to be currently in the pairable mode according to the second pairing mode information, indicating the Bluetooth chip to be paired with the Bluetooth device.
In a possible implementation manner, the bluetooth chip is specifically configured to: and sending the pairing mode modification response to the terminal through echo signaling of the L2 CAP.
In a seventeenth aspect, the present application provides a chip system disposed on a bluetooth device, the chip system including: bluetooth chip and treater. Wherein, this bluetooth chip supports classic bluetooth BR EDR function and bluetooth low energy BLE function. This bluetooth chip for broadcasting low energy consumption bluetooth BLE broadcasts the package. The BLE broadcast packet includes first pairing mode information and a bluetooth address of the bluetooth device. The Bluetooth chip is also used for receiving a pairing mode modification request sent by the terminal. Wherein, the pairing mode request is used for the Bluetooth chip to switch to a pairable mode. This bluetooth chip still is used for carrying out the bluetooth with this bluetooth chip and pairs.
Through the method and the device, the Bluetooth device can indicate whether the Bluetooth device enters the pairable mode or not through a specific field in the low-power-consumption Bluetooth BLE broadcast. Then, the terminal interacts with the Bluetooth equipment through the command on the BLE connection, the Bluetooth equipment enters a pairing mode, pairing of the terminal and the Bluetooth equipment can be achieved without operation of a user on the Bluetooth equipment, the Bluetooth pairing process is simplified, and the difficulty of operating the Bluetooth equipment by the user is reduced.
In a possible implementation manner, the bluetooth chip is further configured to perform bluetooth pairing with the terminal when the terminal determines that the bluetooth device currently enters the pairable mode according to the first pairing mode information.
In one possible implementation, the bluetooth chip is further configured to: a BLE connection is established with the terminal prior to receiving the pairing mode request. This bluetooth chip specifically is used for: and receiving the pairing mode modification request sent by the terminal through response echo signaling of the L2 CAP.
In one possible implementation, the bluetooth chip is further configured to: and sending a pairing mode modification response to the terminal. And the pairing mode modification response comprises second pairing mode information of the Bluetooth device. This bluetooth chip specifically is used for: and when the terminal determines that the Bluetooth equipment enters the pairable mode currently according to the second pairing mode information, carrying out Bluetooth pairing with the terminal.
In a possible implementation manner, the bluetooth chip is specifically configured to: and sending the pairing mode modification response to the terminal through echo signaling of the L2 CAP.
In one possible implementation, when the bluetooth chip enters the pairable mode, the bluetooth chip enters an inquiry scan state.
Drawings
Fig. 1 is a schematic structural diagram of an electronic device provided in an embodiment of the present application.
Fig. 2 is a schematic diagram of a bluetooth protocol framework according to an embodiment of the present application.
Fig. 3 is a schematic structural diagram of an accessory device provided in an embodiment of the present application.
Fig. 4 is a set of GUIs provided in embodiments of the present application.
FIG. 5 is another set of GUIs provided by an embodiment of the present application.
FIG. 6 is another set of GUIs provided by embodiments of the present application.
FIG. 7 is another set of GUIs provided by embodiments of the present application.
Fig. 8 is a schematic flowchart of a bluetooth headset connected to a mobile phone a for the first time through proximity discovery according to an embodiment of the present application.
Fig. 9 is a schematic flowchart of a method for bluetooth pairing connection between a mobile phone a and a bluetooth headset according to an embodiment of the present application.
Fig. 10 is a schematic flowchart of a process for establishing a bluetooth connection between a bluetooth headset and a mobile phone B according to an embodiment of the present application.
Fig. 11 is a schematic flowchart of mutual authentication between a bluetooth headset and a mobile phone B according to an embodiment of the present application.
Fig. 12 is another schematic flowchart of mutual authentication between a bluetooth headset and a mobile phone B according to an embodiment of the present application.
Fig. 13 is another schematic flowchart of mutual authentication between a bluetooth headset and a mobile phone B according to an embodiment of the present application.
Fig. 14 is a schematic flowchart of a process for establishing a bluetooth connection between a bluetooth headset and a mobile phone C according to an embodiment of the present application.
FIG. 15 is another set of GUIs provided by embodiments of the present application.
Fig. 16A-16J are a set of schematic interfaces provided by embodiments of the present application.
Fig. 17A-17I are schematic views of another set of interfaces provided by embodiments of the present application.
Fig. 18 is a flowchart illustrating a bluetooth pairing method according to an embodiment of the present application.
Fig. 19 is a schematic diagram of a BLE broadcast packet format according to an embodiment of the present application.
Fig. 20A is a schematic diagram of an L2CAP signaling format according to an embodiment of the present application.
Fig. 20B is a schematic diagram of another L2CAP signaling format according to an embodiment of the present application.
Fig. 21 is a schematic diagram of a system architecture according to an embodiment of the present application.
Detailed Description
The terminology used in the following examples is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in the specification of this application and the appended claims, the singular forms "a", "an", "the" and "the" are intended to include the plural forms as well, such as "one or more", unless the context clearly indicates otherwise. It should also be understood that in the following embodiments of the present application, "at least one", "one or more" means one, two or more. The term "and/or" is used to describe an association relationship that associates objects, meaning that three relationships may exist; for example, a and/or B, may represent: a alone, both A and B, and B alone, where A, B may be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship.
Reference throughout this specification to "one embodiment" or "some embodiments," or the like, means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," or the like, in various places throughout this specification are not necessarily all referring to the same embodiment, but rather "one or more but not all embodiments" unless specifically stated otherwise. The terms "comprising," "including," "having," and variations thereof mean "including, but not limited to," unless expressly specified otherwise.
Embodiments of an electronic device, a user interface for such an electronic device, and for using such an electronic device are described below. In some embodiments, the electronic device may be a portable electronic device, such as a cell phone, a tablet, a wearable electronic device with wireless communication capabilities (e.g., a smart watch), and the like, that also includes other functionality, such as personal digital assistant and/or music player functionality. Exemplary embodiments of the portable electronic device include, but are not limited to, a mount
Figure BDA0002194675560000111
Figure BDA0002194675560000112
Or other operating system. The portable electronic device may also be other portable electronic devices such as a Laptop computer (Laptop) or the like. It should also be understood that in other embodiments, the electronic device may not be a portable electronic device, but may be a desktop computer.
Fig. 1 shows a schematic structural diagram of an electronic device 100. The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a Universal Serial Bus (USB) interface 130, a charge management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a compass 190, a motor 191, a pointer 192, a camera 193, a display screen 194, a Subscriber Identification Module (SIM) card interface 195, and the like.
It is to be understood that the illustrated structure of the embodiment of the present application does not specifically limit the electronic device 100. In other embodiments of the present application, electronic device 100 may include more or fewer components than shown, or some components may be combined, some components may be split, or a different arrangement of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
Processor 110 may include one or more processing units, such as: the processor 110 may include an Application Processor (AP), a modem processor, a Graphics Processing Unit (GPU), an Image Signal Processor (ISP), a controller, a video codec, a Digital Signal Processor (DSP), a baseband processor, and/or a neural-Network Processing Unit (NPU), etc. Wherein the different processing units may be separate components or may be integrated in one or more processors. In some embodiments, the electronic device 101 may also include one or more processors 110. The controller can generate an operation control signal according to the instruction operation code and the time sequence signal to complete the control of instruction fetching and instruction execution. In other embodiments, a memory may also be provided in processor 110 for storing instructions and data. Illustratively, the memory in the processor 110 may be a cache memory. The memory may hold instructions or data that have just been used or recycled by the processor 110. If the processor 110 needs to reuse the instruction or data, it can be called directly from the memory. This avoids repeated accesses and reduces the latency of the processor 110, thereby increasing the efficiency with which the electronic device 101 processes data or executes instructions.
In some embodiments, processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit audio (I2S) interface, a Pulse Code Modulation (PCM) interface, a universal asynchronous receiver/transmitter (UART) interface, a Mobile Industry Processor Interface (MIPI), a general-purpose input/output (GPIO) interface, a SIM card interface, a USB interface, and/or the like. The USB interface 130 is an interface conforming to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, or the like. The USB interface 130 may be used to connect a charger to charge the electronic device 101, and may also be used to transmit data between the electronic device 101 and peripheral devices. The USB interface 130 may also be used to connect to a headset to play audio through the headset.
It should be understood that the interface connection relationship between the modules illustrated in the embodiments of the present application is only an illustration, and does not limit the structure of the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection manners or a combination of multiple interface connection manners in the above embodiments.
The charging management module 140 is configured to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive a wireless charging input through a wireless charging coil of the electronic device 100. The charging management module 140 may also supply power to the electronic device through the power management module 141 while charging the battery 142.
The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and/or the charge management module 140, and supplies power to the processor 110, the internal memory 121, the external memory, the display 194, the camera 193, the wireless communication module 160, and the like. The power management module 141 may also be used to monitor parameters such as battery capacity, battery cycle count, battery state of health (leakage, impedance), etc. In some other embodiments, the power management module 141 may also be disposed in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be disposed in the same device.
The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, a modem processor, a baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals. Each antenna in the electronic device 100 may be used to cover a single or multiple communication bands. Different antennas can also be multiplexed to improve the utilization of the antennas. For example: the antenna 1 may be multiplexed as a diversity antenna of a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The mobile communication module 150 may provide a solution including 2G/3G/4G/5G wireless communication applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a Low Noise Amplifier (LNA), and the like. The mobile communication module 150 may receive the electromagnetic wave from the antenna 1, filter, amplify, etc. the received electromagnetic wave, and transmit the electromagnetic wave to the modem processor for demodulation. The mobile communication module 150 may also amplify the signal modulated by the modem processor, and convert the signal into electromagnetic wave through the antenna 1 to radiate the electromagnetic wave. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the same device as at least some of the modules of the processor 110.
The wireless communication module 160 may provide a solution for wireless communication applied to the electronic device 100, including Wireless Local Area Networks (WLANs) (such as wireless fidelity (Wi-Fi) networks), bluetooth (bluetooth), Global Navigation Satellite System (GNSS), Frequency Modulation (FM), Near Field Communication (NFC), Infrared (IR), and the like. The wireless communication module 160 may be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, performs frequency modulation and filtering processing on electromagnetic wave signals, and transmits the processed signals to the processor 110. The wireless communication module 160 may also receive a signal to be transmitted from the processor 110, perform frequency modulation and amplification on the signal, and convert the signal into electromagnetic waves through the antenna 2 to radiate the electromagnetic waves.
The electronic device 100 implements display functions via the GPU, the display screen 194, and the application processor. The GPU is a microprocessor for image processing, and is connected to the display screen 194 and an application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
The display screen 194 is used to display images, videos, and the like. The display screen 194 includes a display panel. The display panel may be a Liquid Crystal Display (LCD), an organic light-emitting diode (OLED), an active matrix organic light-emitting diode (active-matrix organic light-emitting diode, AMOLED), a flexible light-emitting diode (FLED), a mini light-emitting diode (mini-light-emitting diode, mini), a Micro-o led, a quantum dot light-emitting diode (QLED), or the like. In some embodiments, the electronic device 100 may include 1 or more display screens 194.
In some embodiments of the present application, the display screen 194 in fig. 1 may be bent when the display panel is made of OLED, AMOLED, FLED, or the like. Here, the display 194 may be bent in such a manner that the display may be bent at any position to any angle and may be held at the angle, for example, the display 194 may be folded right and left from the middle. Or can be folded from the middle part up and down.
The display screen 194 of the electronic device 100 may be a flexible screen, which is currently attracting attention due to its unique characteristics and great potential. Compared with the traditional screen, the flexible screen has the characteristics of strong flexibility and flexibility, can provide a new interaction mode based on the bendable characteristic for a user, and can meet more requirements of the user on electronic equipment. For the electronic equipment provided with the foldable display screen, the foldable display screen on the electronic equipment can be switched between a small screen in a folded state and a large screen in an unfolded state at any time. Therefore, the use of the split screen function by the user on the electronic device equipped with the foldable display screen is more and more frequent.
The electronic device 100 may implement a photographing function through the ISP, the camera 193, the video codec, the GPU, the display screen 194, the application processor, and the like.
The ISP is used to process the data fed back by the camera 193. For example, when a photo is taken, the shutter is opened, light is transmitted to the camera photosensitive element through the lens, the optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing and converting into an image visible to naked eyes. The ISP can also carry out algorithm optimization on the noise, brightness and skin color of the image. The ISP can also optimize parameters such as exposure, color temperature and the like of a shooting scene. In some embodiments, the ISP may be provided in camera 193.
The camera 193 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image to the photosensitive element. The photosensitive element may be a Charge Coupled Device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The light sensing element converts the optical signal into an electrical signal, which is then passed to the ISP where it is converted into a digital image signal. And the ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into image signal in standard RGB, YUV and other formats. In some embodiments, the electronic device 100 may include 1 or more cameras 193.
The digital signal processor is used for processing digital signals, and can process digital image signals and other digital signals. For example, when the electronic device 100 selects a frequency bin, the digital signal processor is used to perform fourier transform or the like on the frequency bin energy.
Video codecs are used to compress or decompress digital video. The electronic device 100 may support one or more video codecs. In this way, the electronic device 100 may play or record video in a variety of encoding formats, such as: moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, and the like.
The NPU is a neural-network (NN) computing processor that processes input information quickly by using a biological neural network structure, for example, by using a transfer mode between neurons of a human brain, and can also learn by itself continuously. Applications such as intelligent recognition of the electronic device 100 can be realized through the NPU, for example: image recognition, face recognition, speech recognition, text understanding, and the like.
The external memory interface 120 may be used to connect an external memory card, such as a Micro SD card, to extend the memory capability of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as music, video, etc. are saved in an external memory card.
Internal memory 121 may be used to store one or more computer programs, including instructions. The processor 110 may execute the above-mentioned instructions stored in the internal memory 121, so as to enable the electronic device 101 to execute the method of bluetooth pairing connection provided in some embodiments of the present application, and various applications and data processing. The internal memory 121 may include a program storage area and a data storage area. Wherein, the storage program area can store an operating system; the storage program area may also store one or more applications (e.g., gallery, contacts, etc.), and the like. The storage data area may store data (such as photos, contacts, etc.) created during use of the electronic device 101, and the like. Further, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic disk storage components, flash memory components, Universal Flash Storage (UFS), and the like. In some embodiments, the processor 110 may cause the electronic device 101 to execute the method for bluetooth pairing connection provided in the embodiments of the present application and other applications and data processing by executing instructions stored in the internal memory 121 and/or instructions stored in a memory provided in the processor 110. The electronic device 100 may implement audio functions through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the earphone interface 170D, and the application processor, etc. Such as music playing, recording, etc.
The sensor module 180 may include a pressure sensor 180A, a gyro sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, and the like.
The pressure sensor 180A is used for sensing a pressure signal, and converting the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A may be disposed on the display screen 194. The pressure sensor 180A can be of a wide variety, such as a resistive pressure sensor, an inductive pressure sensor, a capacitive pressure sensor, and the like. The capacitive pressure sensor may be a sensor comprising at least two parallel plates having an electrically conductive material. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the strength of the pressure from the change in capacitance. When a touch operation is applied to the display screen 194, the electronic apparatus 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic apparatus 100 may also calculate the touched position from the detection signal of the pressure sensor 180A. In some embodiments, the touch operations that are applied to the same touch position but different touch operation intensities may correspond to different operation instructions. For example: and when the touch operation with the touch operation intensity smaller than the first pressure threshold value acts on the short message application icon, executing an instruction for viewing the short message. And when the touch operation with the touch operation intensity larger than or equal to the first pressure threshold value acts on the short message application icon, executing an instruction of newly building the short message.
The gyro sensor 180B may be used to determine the motion attitude of the electronic device 100. In some embodiments, the angular velocity of electronic device 100 about three axes (i.e., X, Y and the Z axis) may be determined by gyroscope sensor 180B. The gyro sensor 180B may be used for photographing anti-shake. For example, when the shutter is pressed, the gyro sensor 180B detects a shake angle of the electronic device 100, calculates a distance to be compensated for by the lens module according to the shake angle, and allows the lens to counteract the shake of the electronic device 100 through a reverse movement, thereby achieving anti-shake. The gyroscope sensor 180B may also be used for navigation, somatosensory gaming scenes.
The acceleration sensor 180E may detect the magnitude of acceleration of the electronic device 100 in various directions (typically three axes). The magnitude and direction of gravity can be detected when the electronic device 100 is stationary. The method can also be used for recognizing the posture of the electronic equipment, and is applied to horizontal and vertical screen switching, pedometers and other applications.
The ambient light sensor 180L is used to sense the ambient light level. Electronic device 100 may adaptively adjust the brightness of display screen 194 based on the perceived ambient light level. The ambient light sensor 180L may also be used to automatically adjust the white balance when taking a picture. The ambient light sensor 180L may also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.
The fingerprint sensor 180H is used to collect a fingerprint. The electronic device 100 can utilize the collected fingerprint characteristics to unlock the fingerprint, access the application lock, photograph the fingerprint, answer an incoming call with the fingerprint, and so on.
The temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 implements a temperature processing strategy using the temperature detected by temperature sensor 180J. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 performs a reduction in performance of a processor located near the temperature sensor 180J, so as to reduce power consumption and implement thermal protection. In other embodiments, the electronic device 100 heats the battery 142 when the temperature is below another threshold to avoid the low temperature causing the electronic device 100 to shut down abnormally. In other embodiments, when the temperature is lower than a further threshold, the electronic device 100 performs boosting on the output voltage of the battery 142 to avoid abnormal shutdown due to low temperature.
The touch sensor 180K is also referred to as a "touch panel". The touch sensor 180K may be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, which is also called a "touch screen". The touch sensor 180K is used to detect a touch operation applied thereto or nearby. The touch sensor can communicate the detected touch operation to the application processor to determine the touch event type. Visual output associated with the touch operation may be provided through the display screen 194. In other embodiments, the touch sensor 180K may be disposed on a surface of the electronic device 100, different from the position of the display screen 194.
As shown in fig. 2, the present application provides a bluetooth protocol framework, including but not limited to a host (host) protocol stack, a Host Controller Interface (HCI), and a controller (controller).
The Host protocol stack defines a plurality of applications (profiles) and a core protocol (protocol) in a bluetooth framework, each profile defines a respective corresponding message format and application rule, and the profile is a bluetooth service (application). In order to achieve interconnection and interworking of different devices under different platforms, bluetooth protocols are defined in various possible and generally meaningful application scenarios, such as bluetooth audio transmission model agreement (A2 DP), bluetooth hands-free protocol (HFP), and the like.
The core protocol includes, but is not limited to, a bluetooth basic Service Discovery Protocol (SDP), a logical link control and adaptation protocol (L2 CAP), and the like. The core protocol is essential in the bluetooth protocol stack.
The HCI provides a unified interface entering a link manager and a unified mode entering a baseband for an upper layer protocol, a plurality of transmission layers exist between a host core protocol stack and a controller, the transmission layers are transparent and complete a data transmission task, and a Bluetooth technical alliance (SIG) specifies four physical bus modes connected with hardware, namely four HCI transmission layers, namely USB, RS232, UART and PC cards.
The controller defines a bottom hardware part, including a Radio Frequency (RF), a baseband (BB) and a Link Management (LM), and the RF layer implements filtering and transmission of a data bit stream through microwaves in an ISM band that does not require authorization at 2.4GHz, and mainly defines conditions that a bluetooth transceiver needs to meet in the frequency band for normal operation. The baseband is responsible for frequency hopping and transmission of bluetooth data and information frames. The link management is responsible for connecting, establishing and removing links and performing security control. The Link Manager (LM) layer is a link management layer protocol of the bluetooth protocol stack, and is responsible for translating an upper layer HCI command into an operation that can be accepted by a baseband, establishing an asynchronous link (ACL) and a synchronous link (SCO), and entering an accessory device into an operating mode in an energy-saving state. The Link Control (LC) layer is responsible for responding to upper layer LM commands (e.g., LM commands that perform the functions of establishing a transport link for packets, maintaining a link, etc.) during the transmission of a batch of packets.
The method according to the embodiment of the present application is implemented by the wireless communication module 160 of the electronic device 100 shown in fig. 1, and may be specifically executed by a bluetooth module or a bluetooth chip.
Fig. 3 schematically shows a structural diagram of an accessory device 200 provided in an embodiment of the present application.
The following describes an embodiment of the accessory device 200. It should be understood that the accessory device 200 shown in FIG. 3 is merely an example, and that the accessory device 200 can have more or fewer components than shown in FIG. 3, can combine two or more components, or can have a different configuration of components. The various components shown in the figures may be implemented in hardware, software, or a combination of hardware and software including one or more signal processing and/or application specific integrated circuits,
as shown in fig. 3, the accessory device 200 can include: the device comprises a processor 201, a memory 202, a Bluetooth communication module 203, an antenna 204, a power switch 205, a USB communication processing module 206 and an audio module 207. Wherein:
the processor 201 is operable to read and execute computer readable instructions. In particular implementations, the processor 201 may mainly include a controller, an operator, and a register. The controller is mainly responsible for instruction decoding and sending out control signals for operations corresponding to the instructions. The arithmetic unit is mainly responsible for storing register operands, intermediate operation results and the like temporarily stored in the instruction execution process. In a specific implementation, the hardware architecture of the processor 201 may be an Application Specific Integrated Circuit (ASIC) architecture, a MIPS architecture, an ARM architecture, or an NP architecture, etc.
In some embodiments, the processor 201 may be configured to parse a signal received by the bluetooth communication processing module 203, such as a pairing mode modification request sent by the electronic device 100, and so on. The processor 201 may be configured to perform corresponding processing operations according to the parsing result, such as generating a pairing mode modification response, and the like.
A memory 202 is coupled to the processor 201 for storing various software programs and/or sets of instructions. In particular implementations, memory 202 may include high-speed random access memory and may also include non-volatile memory, such as one or more magnetic disk storage devices, flash memory devices, or other non-volatile solid-state storage devices. The memory 202 may store an operating system, such as an embedded operating system like uCOS, VxWorks, RTLinux, etc. Memory 202 may also store communication programs that may be used to communicate with electronic device 100, one or more servers, or other devices.
The Bluetooth communication module 203 may include a classic Bluetooth (BT) module and a Bluetooth Low Energy (BLE) module,
in some embodiments, the bluetooth communication module 203 can listen to signals, such as probe requests, scan signals, etc., transmitted by other devices (e.g., the electronic device 100) and can send response signals, scan responses, etc., so that the other devices (e.g., the electronic device 100) can discover the accessory device 200 and establish wireless communication connections with the other devices (e.g., the electronic device 100) to communicate with the other devices (e.g., the electronic device 100) via bluetooth.
In other embodiments, bluetooth communication module 203 may also transmit a signal, such as a broadcast BLE signal, so that other devices (e.g., electronic device 100) may discover accessory device 200 and establish a wireless communication connection with other devices (e.g., electronic device 100) to communicate with other devices (e.g., electronic device 100) via bluetooth.
The wireless communication function of the accessory device 200 can be realized by the antenna 204, the bluetooth communication module 203, the modem processor, and the like.
Antenna 204 may be used to transmit and receive electromagnetic wave signals. Each antenna in accessory device 200 can be used to cover a single or multiple communication bands.
There may be one or more antennas of the bluetooth communication module 203 in some embodiments.
The power switch 205 can be used to control the power of the power source to the accessory device 200.
The USB communication processing module 206 may be used to communicate with other devices through a USB interface (not shown).
Audio module 26 can be configured to output audio signals via an audio output interface, which can enable accessory device 200 to support audio playback. The audio module may also be configured to receive audio data via the audio input interface. The accessory device 200 can be a media player device such as a bluetooth headset.
In some embodiments, accessory device 200 can also include a display screen (not shown), wherein the display screen can be used to display images, prompts, and the like. The display screen can adopt an LCD display screen, an OLED display screen, an AMOLED display screen, a FLED display screen, a QLED display screen and the like.
In some embodiments, accessory device 200 can also include a serial interface such as an RS-232 interface. The serial interface may be connected to other devices, such as audio playback devices like speakers, so that the accessory device 200 and the audio playback device cooperate to play audio and video.
It is to be understood that the configuration illustrated in FIG. 3 does not constitute a specific limitation on the aftermarket apparatus 200. In other embodiments of the present application, the accessory device 200 can include more or fewer components than shown, or combine certain components, or split certain components, or a different arrangement of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
In the method according to the embodiment of the present application, the bluetooth protocol framework used by the accessory device may refer to fig. 2, which is not described herein again.
For convenience of understanding, the following embodiments of the present application will specifically describe a method for bluetooth pairing connection provided by the embodiments of the present application by taking a mobile phone having a structure shown in fig. 1 and fig. 2 and an accessory device shown in fig. 3 as a bluetooth headset as examples, and referring to the accompanying drawings.
Fig. 4 shows a set of Graphical User Interfaces (GUIs) provided by embodiments of the present application. Fig. 4 shows a process in which a bluetooth headset is connected to a cell phone through proximity discovery.
Referring to fig. 4 (a), the mobile phone a is in a bright screen state and displays a mobile phone desktop. The mobile phone desktop comprises application programs (APP) such as a pay bank application, a task card store, a microblog, an album, a WeChat, a card package, a setting and a theme. The bluetooth headset is now in the headset box.
Referring to fig. 4 (b), for the first pairing device, when the bluetooth headset detects that the user opens the headset box, the bluetooth headset may send a broadcast message to the peripheral devices, and the mobile phone a may pop up the reminder frame 401 automatically after receiving the broadcast message, where the reminder frame 401 may display the device name of the bluetooth headset, and when the mobile phone a detects that the user clicks the control 402, the mobile phone a may establish a bluetooth connection with the bluetooth headset and display the GUI shown in fig. 4 (c).
Referring to (c) in fig. 4, after detecting that the user clicks the control 402, the mobile phone a may automatically pop up a reminder box 403, where the reminder box 403 may prompt the user that "the connection with the bluetooth headset is successful" and display the power information of the bluetooth headset and the headset box. When the mobile phone a detects that the user clicks the control 404, the mobile phone a may know that the user wishes to set a password for the bluetooth headset, and the mobile phone a may display a GUI as shown in (d) of fig. 4.
Referring to (d) in fig. 4, after detecting that the user clicks the control 404, the mobile phone a may automatically pop up a reminder box 405, where the reminder box 405 may remind the user "please enter a 4-digit encryption password". When the mobile phone a detects that the user clicks the control 406, the mobile phone a may store a 4-bit encryption password "1234" set by the user for the bluetooth headset, and the mobile phone a may send the password to the bluetooth headset.
It should be understood that the above encryption password may be a 4-digit number, and may also be a combination of a number and a letter.
In one embodiment, the mobile phone a may further prompt the user to input a 6-digit encryption password, and similarly, the 6-digit encryption password may be a pure number or a combination of a number and a letter.
It should also be understood that, in the embodiment of the present application, the authentication information added by the mobile phone a in the accessory device is not limited to the password, and may also be other authentication information. For example, the mobile phone a may add fingerprint authentication information, face recognition authentication information, and the like to the accessory device, which is not limited in this embodiment of the present application.
Referring to fig. 4 (e), for the earphones with the pairing information, when the user opens the earphone box again, the mobile phone B may automatically pop up the reminder box 407. The reminder box 407 may prompt the user to "detect an encrypted device (bluetooth headset), please enter an encryption password if a connection needs to be established" and prompt the bluetooth headset for the device type and device name. The user can conveniently identify the Bluetooth equipment by prompting the type and the name of the user equipment.
Referring to (f) in fig. 4, after the mobile phone B detects that the user inputs the encryption password and detects that the user clicks the control 408, the mobile phone B may perform authentication interaction with the bluetooth headset according to the encryption password input by the user. After the authentication interaction, the mobile phone B can establish a Bluetooth connection with the Bluetooth headset.
In the embodiment of the application, cell-phone A can encrypt this bluetooth headset, when new cell-phone B needs to establish the bluetooth with bluetooth headset and connect, the user can directly input encryption password on cell-phone B and connect, avoided the user still need press the function key on the earphone box to make bluetooth headset get into can the pairing state after, could establish the bluetooth with cell-phone B and be connected, help avoiding the user to use the loaded down with trivial details operation of bluetooth headset and new equipment pairing, promote user experience. Meanwhile, after the equipment is encrypted, the illegal user can be prevented from being used maliciously.
It should be understood that the new device in the embodiment of the present application may refer to a device that has not previously established a bluetooth connection with a bluetooth headset.
In one embodiment, after (b) in fig. 4, the mobile phone may not remind the user to set the encryption password for the bluetooth headset, and after the user wishes to set the encryption password for the bluetooth headset, the user may set the password for the bluetooth headset in the setting interface of the bluetooth headset as shown in (b) in fig. 7. Unlike (c) in fig. 7, if the handset sets the password for the bluetooth headset for the first time, functional options such as "add password" and "close password" may be displayed in (c) in fig. 7. After the user clicks 'add password', the mobile phone can provide an interface for setting the encryption password for the user, so that the user can encrypt the Bluetooth headset.
FIG. 5 illustrates another set of diagram GUIs provided by an embodiment of the present application.
Referring to fig. 5 (a), when the mobile phone detects that the user clicks the control 408, the mobile phone B may also automatically pop up a reminder box 501. Where the reminder block 501 may prompt the user to "if the encryption password needs to be modified. When the mobile phone B detects that the user clicks the control 502, the mobile phone B determines that the user wishes to modify the encryption password of the mobile phone a, and displays a GUI as shown in (B) of fig. 5.
Referring to the GUI shown in (B) in fig. 5, when the mobile phone B detects that the user clicks the control 501, a reminder box 503 may pop up automatically. Where the reminder box 503 may prompt the user to "please enter a 4-digit encryption password". When the mobile phone B detects that the user inputs a new encryption password of "4321" and detects that the user clicks the control 504, the new encryption password may be sent to the bluetooth headset.
Thereafter, if the bluetooth headset is once again brought close to the unconnected electronic device, the electronic device may connect to the bluetooth headset after detecting that the user has entered a new encryption password of "4321". Further, the electronic device may also prompt the user if the encryption password needs to be modified.
In the embodiment of the application, when the bluetooth headset is connected with the new device, if the new device is successfully paired with the bluetooth headset, the new device can further continuously remind the user whether to modify the encryption password, so that the privacy between the bluetooth headset and the new device is ensured.
The process of encrypting the bluetooth headset by the handset is described above with reference to fig. 4 and 5 through the proximity discovery process. The following describes a process of connecting a bluetooth headset and encrypting the bluetooth headset by searching the bluetooth headset.
FIG. 6 illustrates another set of diagram GUIs provided by an embodiment of the present application.
Referring to fig. 6 (a), the GUI is a desktop of a mobile phone. The desktop of the mobile phone comprises a plurality of application icons, wherein the application icons comprise set icons 601. When the mobile phone detects that the user clicks the icon 601 on the desktop, the mobile phone may start to set the related functions of the mobile phone, and display the GUI as shown in (b) of fig. 6.
Referring to the GUI shown in (b) of fig. 6, the GUI is a setting interface of a mobile phone. The GUI comprises a plurality of function options, wherein the function options comprise wireless and network, equipment connection, desktop and wallpaper, sound and the like, and a user can set functions such as Bluetooth, NFC and mobile phone screen projection through the equipment connection function. When the mobile phone detects an operation of clicking the device connection function 602 with the user, the mobile phone may enter the device connection setting interface and display a GUI as shown in (c) of fig. 6.
Referring to the GUI shown in (c) of fig. 6, the GUI sets up an interface for device connection of a cellular phone. The GUI comprises a plurality of function options under the condition of connecting the equipment, wherein the function options comprise equipment connection options such as Bluetooth, NFC, Huawei beam, Huawei share, screen projection of a mobile phone and the like. When the mobile phone detects an operation of opening the control 603 by the user, the mobile phone may open the device interface of the bluetooth function, and display the GUI as shown in (d) in fig. 6.
Referring to the GUI shown in (d) of fig. 6, the GUI is a setting interface of the bluetooth function. The setting interface includes functions such as a bluetooth function start control 604, a device name "Huawei P30", and the like. When the mobile phone detects that the user clicks the control 604, the mobile phone may start the bluetooth function, and may display a diagram (e) in fig. 6.
Referring to the GUI shown in (e) of fig. 6, the GUI is another setting interface of the bluetooth function. The setting interface can display paired devices and available devices, wherein the paired devices can be Bluetooth devices connected with the mobile phone before, and the available devices can be Bluetooth devices searched by the mobile phone.
Referring to the GUI shown in (f) of fig. 6, the GUI is another setting interface of the bluetooth function. The bluetooth devices searched by the mobile phone can be displayed in the available devices in the setting interface, wherein the bluetooth devices comprise a bluetooth headset 605. When the handset detects an operation of the user clicking on the "bluetooth headset" 605, the handset may establish a bluetooth connection with the bluetooth headset, displaying a GUI as shown in (g) of fig. 6.
Referring to the GUI shown in (g) of fig. 6, the GUI is another setting interface of the bluetooth function. In the setting interface, it can be displayed that a bluetooth device named "bluetooth headset" is connected to a mobile phone among paired devices, and a GUI as shown in (h) of fig. 6 is automatically displayed.
Referring to the GUI shown in (h) of fig. 6, the GUI is another setting interface of the bluetooth function. After the bluetooth device with the device name of bluetooth headset is connected to the mobile phone, which can be displayed in the paired devices, the mobile phone can automatically pop up a reminder 606. The reminding box 606 can prompt the user whether the password needs to be set for the bluetooth headset, and when the mobile phone detects that the user clicks the control 607, the mobile phone can know that the user wants to set the password for the bluetooth headset, and the password can be displayed as shown in the figure
GUI shown in (i) in fig. 6.
It should be understood that when the bluetooth headset is first connected to the mobile phone, the user may be prompted to set the password for the bluetooth headset through the prompt box 606. Or setting a password on a setting interface of the bluetooth headset, as shown in (b) of fig. 7, the mobile phone may prompt the user to input the encryption password of the bluetooth headset and prompt the user to confirm the encryption password again.
Referring to the GUI shown in (i) of fig. 6, the GUI is a password setting interface of the bluetooth device. The password setup interface includes a reminder window 608. Wherein the reminder window 608 may prompt the user to "please enter a 4-digit encryption password". When the mobile phone detects that the user inputs the 4-bit encryption password and the mobile phone detects that the user clicks the control 609, the mobile phone completes the password setting of the bluetooth headset. The mobile phone can send the set password to the Bluetooth headset.
It will be appreciated that when the bluetooth headset is thereafter connected to a new device, mutual authentication between the new device and the bluetooth headset takes place. For example, the new device may prompt the user to enter an encryption password. After the authentication is passed, the new device may establish a bluetooth connection with the bluetooth headset.
It should also be understood that the user may also change the password of the bluetooth headset in the bluetooth function setup interface.
FIG. 7 illustrates another set of diagram GUIs provided by an embodiment of the present application.
Referring to the GUI shown in (a) of fig. 7, the GUI is another setting interface of the bluetooth function. When the mobile phone detects that the user clicks the control 701, the mobile phone may enter a setting interface of the bluetooth headset, and may display a GUI as shown in (b) of fig. 7.
Referring to the GUI shown in (b) of fig. 7, the GUI is a setting interface of the bluetooth headset. The setting interface comprises the functional options of call audio, media audio, contact person sharing, password setting and the like. When the mobile phone detects that the user clicks the control 702 corresponding to the set password, the mobile phone may set the password for the bluetooth headset, and may display a GUI as shown in (c) of fig. 7.
Referring to the GUI shown in (c) of fig. 7, the GUI is an interface for setting a password. The interface comprises two function options of changing the password and closing the password. When the mobile phone detects that the user clicks the control 703 corresponding to the password change, the mobile phone may enter the interface for changing the password, and may display a GUI as shown in (d) of fig. 7.
In one embodiment, the handset may cancel the encryption of the bluetooth headset when the handset detects that the user clicked the close password. At this point, the handset may inform the bluetooth headset that the encryption password has been cancelled. Then there may be no need to enter an encryption password when a new device is later connected to the bluetooth headset.
Referring to the GUI shown in (d) of fig. 7, the GUI is an interface for inputting an old device password. The user may enter a previously set encryption password (e.g., "1234") on the interface. When the handset detects that the user has input an old encrypted password and detects that the user has clicked on the control 704, the handset may determine that the user has input the old password, and if the old password is successfully input, the handset may display a GUI as shown in (e) of fig. 7.
Referring to the GUI shown in (e) of fig. 7, the GUI is an interface for setting a new password of the bluetooth device. The user may enter a new encryption password (e.g., "4321") on the interface. After the mobile phone detects that the user inputs a new encryption password and detects that the user clicks the control 705, the mobile phone determines that the user inputs the updated encryption password for the first time, the mobile phone may continue to prompt the user to confirm the updated encryption password, and the mobile phone may display a GUI as shown in (f) of fig. 7.
In one embodiment, when the user clicks on "other password type", the handset may prompt the user to select the type of password to be set, such as a 4-digit password, a 6-digit password, and so on.
Referring to the GUI shown in (f) of fig. 7, the GUI is another interface for setting a new bluetooth device password. The user may confirm the new password on the interface (e.g., enter "4321" again). After the mobile phone detects that the user successfully inputs a new encryption password again and detects that the user clicks the control 706, the mobile phone successfully sets the new password of the bluetooth device, and the mobile phone can send the set new password of the bluetooth device to the bluetooth headset.
In one embodiment, when the bluetooth headset is connected to a new device, a reminder box may be displayed on the new device to remind the user to enter an encryption password (e.g., "4321"), and when the new device detects that the user has entered the encryption password and detects a confirmation operation from the user, the new device may establish a bluetooth connection with the bluetooth headset.
It should be understood that the encryption password of the bluetooth headset may also be modified in the new device, and the modification manner may refer to the GUI in fig. 5 or fig. 7, which is not described herein again for brevity.
Fig. 8 shows a schematic flowchart of the first connection of the bluetooth headset to the mobile phone a through proximity discovery according to the embodiment of the present application. As shown in fig. 8, the process includes:
and S801, after the Bluetooth headset is opened, sending BLE broadcast information to peripheral equipment, wherein the BLE broadcast information carries the MAC address and the identity of the Bluetooth headset.
Illustratively, the identification may include a device type and a device name of the bluetooth headset.
S802, the mobile phone A can display the device name of the Bluetooth headset after receiving the device name.
Illustratively, as the GUI shown in (b) of fig. 4, the device name of the bluetooth headset may be displayed in the reminder box 401.
S803, the handset a detects an operation of connecting to the bluetooth headset.
S804, in response to the operation, the handset a initiates a page (page) for the MAC address of the bluetooth headset, and the bluetooth headset is performing page scan (page scan) at this time.
In response to this operation, the handset a and the bluetooth headset establish a standard bluetooth pairing procedure S805.
S806, after the connection is established, the mobile phone a may prompt the user to set the password of the bluetooth headset.
For example, referring to (c) in fig. 4, the mobile phone a may display a reminder box 403, wherein the reminder box 403 may prompt the user to "whether a password needs to be set for the bluetooth headset".
In one embodiment, the bluetooth headset may further send the power information of the bluetooth headset and the power information of the headset case to the mobile phone a.
For example, referring to (c) in fig. 4, the mobile phone a may further display the power information of the bluetooth headset and the headset case.
It should be understood that a specific byte may be included in the BLE broadcast message in S801, 1bit indicating whether the headset is already encrypted, and 1bit indicating whether the headset is encrypted.
For example, 01 represents that the headset is not encrypted but can be encrypted, and then the handset can display a reminder box as shown in (c) of fig. 4 at this time.
For example, 00 represents that the earphone is not encrypted, and cannot be encrypted, and the handset may not display the reminder box as shown in (c) of fig. 4 at this time. There is no flow of S806 to S808.
For the case where the headset is first connected to the device, there are only the above two cases 01, 00, and if S806-S808 occur, then the next time the headset connects to another device, a specific byte 11 may be carried.
S807, detecting that the user inputs the password, the mobile phone a may save the password.
And S808, the mobile phone A sends the password to the earphone.
Since the bluetooth connection between the handset a and the headset is already established at this time, all data can be encrypted, and it is safe to transmit the password over the air interface.
It should be understood that when the bluetooth headset is paired for the first time, the bluetooth headset may be in a pairable state after detecting an operation of opening the headset box by a user, or in an inquiry scan (inquiry scan) state, and other devices may discover the bluetooth headset.
Fig. 9 shows a schematic flowchart of a method 900 for bluetooth pairing connection between a mobile phone a and a bluetooth headset according to an embodiment of the present application, where as shown in fig. 9, the method 900 includes:
and S901, the Bluetooth headset detects the operation of opening the headset box by the user.
And S902, responding to the operation of opening the earphone box by the user, and establishing a first link between the left ear and the right ear.
Illustratively, the first link is a BR/EDR link.
And S903, the Bluetooth headset responds to the operation and enters inquiry scan (inquiry scan).
S904, the mobile phone a detects that the user turns on the bluetooth function.
Illustratively, as shown in fig. 6 (c), when the mobile phone detects that the user clicks the operation of opening the bluetooth function 603, the mobile phone opens the bluetooth function.
S905, the mobile phone a sends an inquiry message to surrounding devices.
S906, after receiving the inquiry message sent by the mobile phone A, the Bluetooth headset sends an FHS packet to the mobile phone, wherein the FHS packet comprises the MAC address of the Bluetooth headset.
S907, the handset a sends request information to the bluetooth headset for the MAC address in the FHS packet, where the request information is used to request the device name of the bluetooth headset.
S908, in response to the request message, the main ear sends the device name of the bluetooth headset to the handset a.
S909, the handset a displays the device name of the bluetooth headset in the available devices in the bluetooth device search interface.
Illustratively, as shown in (f) of fig. 6, the device name of the bluetooth headset may be "bluetooth headset".
S910, the mobile phone a detects an operation of clicking the "bluetooth headset" by the user.
S911, in response to the operation that the user clicks the 'Bluetooth headset', the mobile phone A initiates a paging (page) message aiming at the MAC address of the Bluetooth headset.
S912, the main ear is in a page scan state, and after receiving a page message sent by the mobile phone, the mobile phone and the Bluetooth headset perform a standard Bluetooth pairing process.
And S913, data transmission is carried out between the mobile phone and the Bluetooth headset.
Illustratively, the HFP connection between the handset and the primary ear may be made when the handset is answering a call through a bluetooth headset.
Illustratively, when the handset listens to music and watches videos through the bluetooth headset, an A2DP connection may be made between the handset and the main ear.
S914, after the connection is established, the mobile phone a may prompt the user to set the password of the bluetooth headset.
It should be understood that, in the embodiment of the present application, an example is described in which the mobile phone a prompts the user to set the password of the bluetooth headset, and the mobile phone a may also add other authentication information to the bluetooth headset, for example, the mobile phone a adds authentication information such as fingerprint and face recognition to the bluetooth headset. The type of the authentication information is not limited in the embodiment of the present application.
For example, referring to (c) in fig. 4, the mobile phone a may display a reminder box 403, wherein the reminder box 403 may prompt the user to "whether a password needs to be set for the bluetooth headset".
In an embodiment, after the first pairing, the bluetooth headset may send indication information to the mobile phone after establishing a bluetooth connection with the mobile phone a, where the indication information may carry specific bytes, for example, 1bit indicates that the bluetooth headset may be encrypted, and 1bit indicates that the bluetooth headset is not encrypted. After receiving the indication information, the mobile phone can prompt the user to set the password of the Bluetooth headset. After receiving the indication information, the mobile phone may prompt the user to perform encryption setting in a pop-up prompt box 403; a setting item may also be added to the bluetooth function setting interface, and for example, the setting password may be clicked on the setting interface of the bluetooth headset as shown in (b) in fig. 7, so as to encrypt the bluetooth headset.
For example, 01 represents that the headset is not encrypted but can be encrypted, and then the handset can display a reminder box as shown in (c) of fig. 4 at this time.
For example, 00 represents that the earphone is not encrypted, and cannot be encrypted, and the handset may not display the reminder box as shown in (c) of fig. 4 at this time. There is no flow of S806 to S808.
For the case where the headset is first connected to the device, there are only the above two cases 01, 00, and if S806-S808 occur, then the next time the headset connects to another device, a specific byte 11 may be carried.
S915, detecting that the user inputs the password, the mobile phone a may store the password.
S916, the handset a sends the password to the headset.
The process that the mobile phone can encrypt the bluetooth headset and send the password to the bluetooth headset after the bluetooth headset is connected to the mobile phone a is described above with reference to fig. 8 and 9, and a schematic flow chart of the connection between the bluetooth headset and the new device is described below.
Fig. 10 is a schematic flowchart illustrating a procedure for establishing a bluetooth connection between a bluetooth headset and a mobile phone B according to an embodiment of the present application. As shown in fig. 10, the process includes:
and S1001, the Bluetooth headset detects the operation of opening the headset box by the user.
S1002, in response to the operation, the bluetooth headset connects back to the mobile phone a.
When the bluetooth headset is connected with the mobile phone a last time, after the bluetooth headset detects that the user opens the headset box, the bluetooth headset can initiate paging (page) to the mobile phone according to the MAC address of the mobile phone, and a standard bluetooth pairing process is performed between the bluetooth headset and the mobile phone a.
It should be understood that S1002 is an optional step, and the bluetooth headset may connect back to the last connected mobile phone a after detecting the operation of opening the headset case by the user. The result of the loopback connection can be a successful loopback connection or a failed loopback connection (for example, if the distance between the mobile phone A and the Bluetooth headset is too far away, the loopback connection can be lost). In the process of connecting the bluetooth headset with the mobile phone a, the mobile phone a actively disconnects from the bluetooth headset after detecting the operation of the user, and then the bluetooth headset does not need to be connected with the mobile phone a next time after the bluetooth headset detects the operation of opening the headset box by the user.
S1003, broadcasting a BLE broadcast data packet to peripheral equipment by the Bluetooth headset, wherein the BLE broadcast data packet carries an authentication identifier which is used for indicating that the Bluetooth headset needs to perform an authentication process to establish Bluetooth connection.
It should be understood that the mobile phone a may also receive a BLE broadcast packet, and after receiving the BLE broadcast packet, the mobile phone a may confirm that the MAC address carried in the broadcast packet is the MAC address of the bluetooth headset currently connected to the mobile phone a, and the mobile phone a may ignore the BLE broadcast packet.
It should also be understood that, in the embodiment of the present application, there is no actual sequence between S1002 and S1003.
It should also be understood that the bluetooth headset reconnects the handset a but fails to connect back after detecting the user's operation of opening the headset case. For example, if the distance between the mobile phone a and the bluetooth headset is too far, the bluetooth headset fails to connect back to the mobile phone a.
In one embodiment, the BLE broadcast packet may also carry a MAC address of the bluetooth headset, which is used by the peripheral device to determine whether a bluetooth connection has been previously established with the bluetooth headset.
In one embodiment, the BLE broadcast packet may also carry information about the device type and device name of the bluetooth headset.
In one embodiment, the BLE broadcast packet may also carry a specific byte to indicate whether the bluetooth headset is encrypted and is encryptable.
S1004, the mobile phone B determines that the Bluetooth connection with the Bluetooth headset is not established before, and prompts the user to input an encryption password.
In one embodiment, determining that a bluetooth connection has not been previously established with the bluetooth headset by handset B may comprise: handset B determines that the MAC address of the bluetooth headset is not stored. Wherein, the BLE broadcast packet in S1003 may include the MAC address of the bluetooth headset.
For example, the handset B may determine, through the authentication information in the BLE broadcast packet, that an authentication (or mutual authentication) procedure with the bluetooth headset is required to establish a bluetooth connection with the bluetooth headset.
Handset B can determine that the bluetooth headset is a device that has been encrypted by parsing a particular byte (e.g., "11").
Cell B may prompt the user in the reminder box 407 that the device name of the bluetooth device is "bluetooth headset" through the device type and device name of the bluetooth headset carried in the BLE broadcast packet, such as the GUI shown in fig. 4 (e).
The mobile phone B may determine whether a bluetooth connection has been established with the bluetooth headset before through the MAC address carried in the BLE broadcast packet, and if the MAC address of the bluetooth headset does not exist in the MAC address corresponding to the paired device stored in the mobile phone B, the mobile phone B may determine that a bluetooth connection has not been established with the bluetooth headset before. As shown in the GUI of fig. 4 (e), the cell phone B may prompt the user to enter an encryption password in the reminder box 407.
And S1005, carrying out an interactive authentication process between the mobile phone B and the Bluetooth headset.
S1006, after the mutual authentication between the mobile phone B and the Bluetooth headset is successful, the mobile phone B and the Bluetooth headset are connected.
The following describes the process of performing mutual authentication and connection establishment between the mobile phone B and the bluetooth headset with reference to fig. 11 to 13.
Fig. 11 is a schematic flowchart illustrating a process of mutual authentication between a mobile phone B and a bluetooth headset according to an embodiment of the present application, where as shown in fig. 11, the mutual authentication process includes:
s1101, the mobile phone B and the Bluetooth headset establish an ACL link.
For example, handset B may establish an ACL link with a bluetooth headset under a BR/EDR connection.
And S1102, performing interactive authentication on the ACL link by the mobile phone B and the Bluetooth headset.
For example, the handset B may send a hash of the encrypted password (which may also include other information, such as a MAC address, etc.) entered by the user to the bluetooth headset over the ACL link, and the bluetooth headset verifies the encrypted password.
For example, the mobile phone B may first send a hash value of a part of authentication information (e.g., a part of encrypted password information) to the bluetooth headset on the ACL link, and the bluetooth headset performs verification; after the verification is passed, the Bluetooth headset requests the residual authentication information from the mobile phone B; and after the mobile phone B sends the residual authentication information to the Bluetooth headset, the Bluetooth headset verifies the residual authentication information. If the bluetooth headset passes the verification of the remaining authentication information, the bluetooth headset can determine that the authentication of the mobile phone is successful.
In one embodiment, after the bluetooth headset successfully authenticates the mobile phone, the bluetooth headset may also send the hash value of the encryption password stored by the bluetooth headset to the mobile phone B, and the mobile phone B authenticates the encryption password. And when the mobile phone B successfully authenticates the encryption password, the Bluetooth headset and the mobile phone successfully perform interactive authentication.
It should be appreciated that since the ACL link is an unencrypted link, handset B may send the authentication information to the bluetooth headset in an encrypted manner, e.g., handset B sends the authentication information to the headset based on a hash of the encrypted password.
And S1103, if the mutual authentication between the Bluetooth headset and the mobile phone B is successful, the Bluetooth headset can enter a pairable mode.
S1104, the bluetooth headset indicates to the handset B that the bluetooth headset has entered the pairable mode.
For example, the bluetooth headset may send an indication on the ACL link that the handset has entered the pairable mode.
S1105, the mobile phone B and the Bluetooth headset carry out a standard Bluetooth pairing process.
In one embodiment, handset B may establish a BR/EDR connection with a Bluetooth headset.
In one embodiment, the establishing the BR/EDR connection between the mobile phone B and the Bluetooth headset comprises the following steps: the mobile phone B initiates paging to the Bluetooth headset, and the mobile phone B and the Bluetooth headset perform pairing/SDP/encryption processes.
Fig. 12 is a schematic flowchart illustrating a process of performing mutual authentication between a mobile phone B and a bluetooth headset according to an embodiment of the present application, where, as shown in fig. 12, the mutual authentication process includes:
s1201, the handset B sends a part of authentication information (e.g., part of information of an encryption password) to the bluetooth headset through the first BLE broadcast message.
S1202, after the bluetooth headset passes authentication of the part of authentication information, the bluetooth headset sends a second BLE broadcast message to the mobile phone B, where the second BLE broadcast message may instruct the mobile phone B to send the remaining authentication information to the bluetooth headset.
S1203, the mobile phone B sends a third BLE broadcast message to the bluetooth headset, where the third BLE broadcast message carries the remaining authentication information.
Due to the fact that the amount of information carried in the broadcast channel is limited, under the condition that the amount of information of the authentication information is large, the mobile phone B can send the authentication information to the Bluetooth headset for multiple times through BLE broadcast messages.
S1204, if the mutual authentication between the Bluetooth headset and the mobile phone B is successful, the Bluetooth headset can enter a pairable mode.
It should be understood that successful mutual authentication between the bluetooth headset and the mobile phone B may refer to that the bluetooth headset passes authentication of the authentication information sent by the mobile phone, or that the bluetooth headset passes authentication of the authentication information sent by the mobile phone and that the mobile phone B passes authentication of the authentication information sent by the bluetooth headset. When the mobile phone B needs to authenticate the Bluetooth headset, the Bluetooth headset is also needed to send the stored authentication information to the mobile phone B for authentication.
S1205, the bluetooth headset sends a fourth BLE broadcast message to the handset B, where the fourth BLE broadcast message is used to instruct the bluetooth headset to enter a pairable mode.
And S1206, carrying out a standard Bluetooth pairing process on the mobile phone B and the Bluetooth headset.
In one embodiment, handset B may establish a BR/EDR connection with a Bluetooth headset.
In one embodiment, the establishing the BR/EDR connection between the mobile phone B and the Bluetooth headset comprises the following steps: the mobile phone B initiates paging to the Bluetooth headset, and the mobile phone B and the Bluetooth headset perform pairing/SDP/encryption processes.
Fig. 13 is a schematic flowchart illustrating another process of mutual authentication between a mobile phone B and a bluetooth headset according to an embodiment of the present application, where as shown in fig. 13, the mutual authentication process includes:
and S1301, establishing an ACL link under BLE connection by the mobile phone B and the Bluetooth headset.
S1302, the mobile phone B performs interactive authentication with the Bluetooth headset on the ACL link.
It should be understood that, for the process of performing the mutual authentication between the mobile phone B and the bluetooth headset on the ACL link, reference may be made to the process of S1102 described above, and details are not described herein for brevity.
And S1303, after the mutual authentication between the mobile phone B and the Bluetooth headset is passed, the Bluetooth headset enters a pairing mode.
S1304, the bluetooth headset sends an indication message to the mobile phone B, where the indication message is used to indicate the bluetooth headset to enter a pairable mode.
S1305, the handset B disconnects the ACL link with the bluetooth headset.
S1306, the mobile phone B and the Bluetooth headset perform a standard Bluetooth pairing process.
In one embodiment, handset B may establish a standard bluetooth pairing procedure with a bluetooth headset under BR/EDR connectivity.
In one embodiment, the standard bluetooth pairing procedure for establishing BR/EDR connection between the mobile B and the bluetooth headset includes: the mobile phone B initiates paging to the Bluetooth headset, and the mobile phone B and the Bluetooth headset perform (BR/EDR) pairing/SDP/encryption process.
In one embodiment, in S1305, the handset B may also continue to have an ACL link with the bluetooth headset, and the handset B may continue to establish a BLE connection with the bluetooth headset. Illustratively, handset B may perform a BLE pairing/SDP/encryption procedure with the bluetooth headset under BLE connection.
It should be appreciated that the bluetooth headset enters the pairable mode after it is determined that the mutual authentication is passed. For example, after the bluetooth headset determines that the interactive authentication passes, the bluetooth IO capability flag may be set to be in a bindable mode, and the bluetooth headset enters a pairable mode.
And S1007, transmitting data between the mobile phone B and the Bluetooth headset.
In one embodiment, the handset B can transmit data with the Bluetooth headset in a BR/EDR connection.
In another embodiment, the handset B may also perform data transmission with the bluetooth headset under a BLE connection.
Illustratively, HFP connection between the handset and the primary ear is possible when handset B answers the phone via a bluetooth headset.
Illustratively, when the mobile phone B listens to music and watches videos through the Bluetooth headset, an A2DP connection can be made between the mobile phone and the main ear.
In one embodiment, the process further comprises:
s1008, the mobile phone B reminds the user whether to modify the password of the Bluetooth headset.
Illustratively, as shown in fig. 5 (a), the handset may prompt the user to modify the password.
S1009, the handset B detects that the user sets a new encryption password.
Illustratively, as shown in fig. 5 (b), the handset detects that the user has entered a new encryption password and clicks on the determination.
And S1010, the mobile phone B sends the new encryption password to the Bluetooth headset.
Fig. 14 is a schematic flowchart illustrating a procedure for establishing a bluetooth connection between a bluetooth headset and a mobile phone C according to an embodiment of the present application. As shown in fig. 14, the process includes:
s1401, the bluetooth headset detects an operation of opening the headset case by the user.
S1402, in response to the operation, the bluetooth headset connects back to the handset a.
When the last connection of the bluetooth headset is the mobile phone a, after the bluetooth headset detects that the user opens the headset box, the bluetooth headset can initiate paging (page) to the mobile phone according to the MAC address of the mobile phone, and a standard bluetooth connection process is performed between the bluetooth headset and the mobile phone a.
And S1403, the Bluetooth headset broadcasts a BLE broadcast data packet to peripheral equipment, wherein the BLE broadcast data packet carries an authentication identifier which is used for indicating that the Bluetooth headset needs to perform an authentication process to establish Bluetooth connection.
S1404, the mobile phone C determines that a bluetooth connection has been established with the bluetooth headset before, and prompts the user whether to establish a connection with the bluetooth headset.
For example, the handset C may determine, through the authentication information in the BLE broadcast packet, that an authentication (or mutual authentication) procedure with the bluetooth headset is required to establish a bluetooth connection with the bluetooth headset.
Handset C may determine that the bluetooth headset is a device that has been encrypted by parsing a particular byte (e.g., "11").
The mobile phone C may determine whether a bluetooth connection has been established with the bluetooth headset before through the MAC address carried in the BLE broadcast packet, and if the MAC address of the bluetooth headset exists in the MAC address corresponding to the paired device stored in the mobile phone C, the mobile phone C may determine that a bluetooth connection has not been established with the bluetooth headset before. The handset C may prompt the user whether to establish a connection with the bluetooth headset.
S1405, the mobile phone C detects the operation of the user to click and establish connection with the Bluetooth headset.
And S1406, carrying out an interactive authentication process between the mobile phone C and the Bluetooth headset.
It should be understood that reference may be made to the description of the method 1100-1300 above for S1406, and for brevity, the description is not repeated herein.
It should also be appreciated that although the bluetooth connection was previously established with the bluetooth headset, the handset C and the bluetooth headset were authenticated with each other and passed authentication. However, the bluetooth headset may then be password modified by other devices establishing a bluetooth connection, so here again an interactive authentication procedure is required.
Illustratively, the bluetooth headset is a bluetooth device of the user a, and the user a can set a password for the bluetooth headset when establishing a bluetooth connection with the bluetooth headset by using the own mobile phone a. The user B borrows the Bluetooth headset from the user A, the user A can inform the user B of the encrypted password, and when the user B uses the own mobile phone B to connect the Bluetooth headset with the Bluetooth headset for the first time, the user B can input the password informed by the user A so that the mobile phone B and the Bluetooth headset can establish Bluetooth connection.
After the user B returns the Bluetooth headset to the user A, the user A can use the mobile phone A to modify the encryption password, and then under the condition that the user B does not know that the encryption password of the Bluetooth headset is modified, when the user B uses the mobile phone B to try to establish Bluetooth connection with the Bluetooth headset again, the interaction authentication of the mobile phone B and the Bluetooth headset cannot be passed, so that the mobile phone B cannot establish Bluetooth connection with the Bluetooth headset. When the user B inputs the previous password on the mobile phone B, the interactive authentication between the mobile phone B and the Bluetooth headset cannot pass, at the moment, the mobile phone B can prompt the user to input the password again, and when the user B successfully inputs a new password, the subsequent process can be carried out.
S1407, the Bluetooth headset enters into a pairable mode after the interactive authentication is determined to pass.
S1408, after determining that the interactive authentication is passed, the mobile phone B starts a standard bluetooth pairing procedure.
It should be understood that if the bluetooth headset is establishing bluetooth connection with the mobile phone a at this time, after the mobile phone B and the bluetooth headset are authenticated interactively, the bluetooth headset may disconnect the bluetooth connection with the mobile phone a when entering a mateable state; or, when the bluetooth headset and the mobile phone perform a standard bluetooth pairing process, the bluetooth headset may disconnect the bluetooth connection with the mobile phone a.
It should also be appreciated that reference may be made to the method 1100 and 1300 for the above manner of determining that the mutual authentication passes through by the bluetooth headset, and details thereof are not described herein for brevity.
And S1409, carrying out a standard Bluetooth pairing process on the mobile phone B and the Bluetooth headset.
And S1410, the mobile phone B and the Bluetooth headset perform data transmission.
In an embodiment, after the bluetooth connection between the mobile phone C and the bluetooth headset is established, the mobile phone C may also prompt the user whether to modify the password, and the process may refer to the above S1008-S1010, which is not described herein again for brevity.
FIG. 15 shows another set of GUIs of an embodiment of the present application.
Referring to the GUI shown in (a) of fig. 15, when the user opens the earphone box of the bluetooth earphone, the bluetooth earphone may first be connected back to the mobile phone a which was connected last time. The mobile phone a can prompt the user of the electric quantity of the bluetooth headset and the electric quantity of the headset box through the reminding frame 1501.
Referring to the GUI shown in fig. 15 (B), when the mobile phone B approaches the bluetooth headset, the mobile phone B may automatically pop up a reminder box 1502, wherein the reminder box 1502 may prompt the user to "detect an encryption device (bluetooth headset), and if a connection needs to be established, please enter an encryption password".
Referring to the GUI shown in (C) of fig. 15, when the mobile phone C approaches the bluetooth headset, the mobile phone C may automatically pop up a reminder box 1503, where the reminder box 1503 may display the power of the bluetooth headset, the power of the headset box, and a prompt for the user to "detect an encryption device (bluetooth headset), establish connection" or not.
It should be understood that in the embodiment of the present application, the bluetooth headset may not send its power information to the peripheral devices before the bluetooth headset is connected for the first time.
When the bluetooth headset is already paired (or connected) with other devices and the headset case of the bluetooth headset is in a closed state, the bluetooth headset may transmit power information to the paired (or connected) devices. For example, paired devices may view power information for a bluetooth headset in a pull-down menu, minus one screen.
After the Bluetooth headset is connected with a certain device, the Bluetooth headset can broadcast the electric quantity information of the Bluetooth headset to surrounding devices through BLE broadcast data packets; alternatively, the bluetooth headset may transmit its power information to the connected device point-to-point.
A schematic user interface diagram relating to a pairing method in the embodiment of the present application is described below.
As shown in fig. 16A, the electronic device 100 may display an interface 1610 having a home screen, the interface 1610 displaying a page in which application icons are placed, the page including a plurality of application icons (e.g., a weather application icon, a stock application icon, a calculator application icon, a settings application icon 1616, a mail application icon, a pay treasure application icon, a facebook application icon, a browser application icon, a gallery application icon, a music application icon, a video application icon, an application store icon). And page indicators are also displayed below the application icons to indicate the position relationship of the currently displayed page and other pages. A plurality of tray icons (such as a dialing application icon, an information application icon, a contact application icon and a camera application icon) are arranged below the page indicator, the tray icons are kept displayed when the page is switched, and the page can also comprise a plurality of application icons and page indicators; the page indicator may not be a part of the page, and may exist separately, and the tray icon is also optional, which is not limited in this embodiment of the present application. Above the interface 1610, a status bar 1611 is displayed, and the status bar 1611 may include: one or more signal strength indicators for mobile communication signals (which may also be referred to as cellular signals), one or more signal strength indicators for wireless fidelity (Wi-Fi) signals, a battery status indicator, a time indicator, and so forth. Displayed beneath the tray icon is a navigation bar 1612, which navigation bar 1612 may include: a return key 1613, a Home screen key 1614, a call out task history key 1615, and system navigation keys. When it is detected that the user clicks the return key 1613, the electronic device 100 may display a page previous to the current page. When the user is detected to click the home interface button 1614, the electronic device 100 may display the home interface. When detecting that the user clicks the outgoing task history key 1615, the electronic device 100 may display the task that was recently opened by the user. The names of the navigation keys can be other keys, and the application does not limit the names. Not limited to virtual keys, each navigation key in navigation bar 1612 may also be implemented as a physical key.
The electronic device 100 may receive an input operation (e.g., a single click) by the user for the setting icon 1616, and in response to the input operation for the setting icon 1616, the electronic device 100 may display a setting interface 1620 as shown in fig. 16B.
As shown in fig. 16B, the settings interface 1620 displays settings including wireless and network settings entries, device connection settings entries 1621, application and notification settings entries, battery settings entries, display settings entries, sound settings entries, storage settings entries, security and privacy settings entries, user and account settings entries, and the like.
The electronic device 100 may receive an input operation (e.g., a single click) by the user with respect to the device connection entry 1621, and in response to the input operation with respect to the device connection entry 1621, the electronic device 100 may display a device connection interface 1630 as shown in fig. 16C.
As shown in fig. 16C, the device connection interface 1630 display includes bluetooth setup items 1631, NFC setup items, Huawei Beam setup items, Huawei Share setup items, cell phone screen projection setup items, USB setup items, print setup items, and the like.
The electronic device 100 may receive an input operation of a user for the bluetooth setting entry 1631 in the device connection interface 1630, and in response to the input operation for the bluetooth setting entry 1631, the electronic device 100 may display a bluetooth setting interface 1640 as shown in fig. 16D.
As shown in fig. 16D, the bluetooth setting interface 1640 includes a bluetooth switch entry 1641, a device name setting entry 1642, a received file setting entry 1643, a scan control 1644, and a help control 1645. A bluetooth switch 1651 is shown in the bluetooth switch entry 1641. The bluetooth switch 1651 may be configured to receive an operation of a user and trigger the electronic device 100 to turn on/off a bluetooth function.
For example, when the bluetooth switch 1651 is currently in the off state, the electronic device 100 may receive an input operation (e.g., a click) of the bluetooth switch 1651 by a user, and in response to the input operation of the bluetooth switch 1651, the electronic device 100 may turn on the bluetooth function.
As shown in fig. 16E, after the bluetooth function is turned on, the electronic device 100 may further display a paired device list 1646 on the bluetooth setup interface 1640. The paired device list includes one or more paired device options (e.g., "hua wei AM 08" device option, "hua wei Mate 20" device option, etc.), and a scan prompt 1647. Wherein when the bluetooth function is triggered on, the electronic device 100 may scan for bluetooth (including BLE and classic bluetooth) broadcasts by other devices. While the electronic device 100 is scanning for bluetooth broadcasts of other devices, the electronic device 100 may display the scan prompt 1647 for prompting the user that the electronic device 100 is currently scanning for available devices.
Wherein each scanning of the electronic device 100 may be limited to a period of time (e.g., 5 seconds), when the electronic device 100 does not scan an available device required by the user while the bluetooth function is turned on, the electronic device 100 may receive an input operation (e.g., a click) from the user for the scanning control 1644, and in response to the input operation (e.g., a click) for the scanning control 1644, the electronic device 100 may scan the bluetooth broadcast of another device again.
In the present embodiment, the accessory device 200 may be referred to by the device name "HUAWEI Free BUDS". After being powered on and when not entering pairing mode, accessory device 200 may send out a BLE broadcast packet, where the BLE broadcast packet includes a broadcast device address, pairing mode information, and a device name of accessory device 200, and so on. The pairing mode information is used to indicate whether the accessory device 200 has not entered a pairing mode.
When electronic device 100 scans the BLE broadcast of accessory device 200, electronic device 100 may determine whether accessory device 200 has been paired with electronic device 100 according to the broadcast device address in the BLE broadcast, and if so, electronic device 100 may display the device option of accessory device 200 in paired device list 1646. If not paired with electronic device 100, electronic device 100 can display device options for accessory device 200 in available device list 1648.
Illustratively, as shown in fig. 16F, when electronic device 100 determines that accessory device 200 is not paired with electronic device 100 according to the broadcast device address in the BLE broadcast of accessory device 200, electronic device 100 may display device option 1649 of accessory device 200 in available device list 1648. Among other things, the device name of the accessory device 200 (e.g., "HUAWEI Free BUds") is displayed in the device option 1649 of the accessory device 200.
Electronic device 100 can receive an input operation (e.g., a single click) by a user for device option 1649 of available device list 1648, and in response to the input operation for device option 1649, electronic device 100 can establish a BLE connection with accessory device 200. Electronic device 100, upon establishing a BLE connection with accessory device 200, can send a pairing mode modification request to accessory device 200 requesting accessory device 200 to enter a pairable mode. After receiving the pairing mode modification request sent by the electronic device 100, the accessory device 200 may determine whether the accessory device 200 does not establish a classic bluetooth connection with another device, and if so, the accessory device 200 may enter the pairable mode and return a pairing mode modification response to the electronic device 100, so as to notify the electronic device 100 that the accessory device 200 has currently entered the pairable mode. The electronic device 100 can perform a classic bluetooth pairing procedure with the accessory device 200 after receiving the pairing mode modification response sent by the accessory device 200.
As shown in fig. 16G, the electronic device 100 may output a prompt that pairing is in progress (for example, a word "pairing in progress …" or the like is displayed in the device option 1649) after receiving an input operation of the user for the device option 1649.
As shown in fig. 16H, after electronic device 100 is successfully paired with accessory device 200, electronic device 100 can display device option 1652 for accessory device 200 in paired device list 1646.
After the electronic device 100 is successfully paired with the accessory device 200, the electronic device 100 can establish a classic bluetooth connection with the accessory device 200. The classic bluetooth connection established between the electronic device 100 and the accessory device 200 may be triggered after successful pairing, or may be triggered by a user, for example, after the electronic device 100 and the bluetooth are successfully paired, the electronic device 100 may receive an input operation (e.g., a click) from the user on the device option 1652 in the paired device list 1646, and in response to the input operation, the electronic device 100 may establish the classic bluetooth connection with the accessory device 200. After the electronic device 100 establishes a Bluetooth connection with the accessory device 200, the electronic device 100 can display a connected prompt on the device option 1652 to prompt the user that the electronic device 100 has established a classic Bluetooth connection with the accessory device 200.
For example, as shown in FIG. 16I, the connected reminder displayed on device option 1652 by electronic device 100 may be a text message of "connected for voice and audio of media", or the like.
In one possible implementation, electronic device 100 may display the device options of accessory device 200 in a pop-up window manner after scanning BLE broadcast packets of accessory device 200.
For example, as shown in figure 16J, electronic device 100 may display a pairable device window 1653 after scanning BLE broadcast packets for accessory device 200. The mateable device window 1653 includes a device option 1654 for the accessory device 200 therein, the device option 1654 displaying a device name (e.g., "HUAWEI Free Buds") for the accessory device 200. Electronic device 100 can receive the input operation (e.g., a single click) for device option 1654 of accessory device 200, and in response to the input operation for device option 1654, electronic device 100 can establish a BLE connection with accessory device 200. Electronic device 100, upon establishing a BLE connection with accessory device 200, can send a pairing mode modification request to accessory device 200 requesting accessory device 200 to enter a pairable mode. After receiving the pairing mode modification request sent by the electronic device 100, the accessory device 200 may determine whether the accessory device 200 does not establish a classic bluetooth connection with another device, and if so, the accessory device 200 may enter the pairable mode and return a pairing mode modification response to the electronic device 100, so as to notify the electronic device 100 that the accessory device 200 has currently entered the pairable mode. The electronic device 100 can perform a classic bluetooth pairing procedure with the accessory device 200 after receiving the pairing mode modification response sent by the accessory device 200.
Wherein electronic device 100, upon successful pairing with accessory device 200, can display device option 1652 for accessory device 200 as described above in FIG. 16H in paired device list 1646.
A schematic user interface diagram relating to a pairing method in the embodiment of the present application is described below.
As shown in fig. 17A, the electronic device 100 displays an interface 1710 with a home screen, the interface 1710 displaying a page with application icons placed therein, the page including a plurality of application icons (e.g., a weather application icon, a stock application icon, a calculator application icon, a settings application icon, the page including a plurality of application icons, a pay treasure application icon, a facebook application icon, a browser application icon, a gallery application icon, a music application icon, a video application icon, an application store icon). And page indicators are also displayed below the application icons to indicate the position relationship of the currently displayed page and other pages. Below the page indicator are a plurality of tray icons (e.g., a dialing application icon, an information application icon, a contacts application icon, a camera application icon), which remain displayed upon page switching, a page may include a plurality of application icons and page indicators; the page indicator may not be a part of the page, and may exist separately, and the tray icon is also optional, which is not limited in this embodiment of the present application. A status bar 1711 is displayed above the interface 1710, wherein for the description of the status bar 1711, reference may be made to the status bar 1611 in the embodiment in fig. 16A, which is not described herein again. A navigation bar 1712 is displayed below the tray icon, wherein for the description of the navigation bar 1712, reference may be made to the navigation bar 1612 in the embodiment in fig. 16A, which is not described herein again.
The electronic device 100 may receive a user's slide operation with respect to the status bar 1711 (e.g., slide down from the status bar 1711 position), and in response to the slide operation with respect to the status bar 1711, the electronic device 100 may display a window menu 1720 as shown in fig. 17B.
As shown in fig. 17B, the window menu 1720 may display switch controls with some functions (e.g., a WLAN switch control, a bluetooth switch control 1721, a flashlight switch control, a reminder switching control, an automatic rotation switch control, a huacheng sharing switch control, a flight mode switch control, a mobile data switch control, a positioning switch control, a screen capture switch control, an eye protection mode switch control, a hot spot switch control, a screen recording switch control, a large screen projection control, an NFC switch control, etc.).
The electronic device 100 may receive an input operation (e.g., a single click) from a user with respect to the bluetooth switch control 1721, and in response to the input operation with respect to the bluetooth switch control 1721, the electronic device 100 may turn on the bluetooth function.
As shown in fig. 17C, after the electronic device 100 starts the bluetooth function, the bluetooth switch control 1721 can be switched to an on state for prompting the user that the current bluetooth function is started. After the bluetooth function is turned on, the electronic device 100 may background scan for bluetooth broadcasts (including BLE broadcasts and classic bluetooth broadcasts) of other devices.
As shown in fig. 17D, after the electronic device 100 scans the BLE broadcast of the accessory device 200, the electronic device 100 may determine whether the accessory device 200 is not paired with the electronic device 100 according to the broadcast device address in the BLE broadcast, and if not, the electronic device 100 may display a notification bar 1730 below the window menu 1720. The notification bar 1730 displays the device name (e.g., "HUAWEI Free Buds") of the accessory device 200. If the accessory device 200 is not paired with the electronic device 100, the electronic device 100 can establish a classic Bluetooth connection with the accessory device 200.
The electronic device 100 may receive an input operation (e.g., a single click) by the user with respect to the notification bar 1730, and in response to the input operation with respect to the notification bar 1730, the electronic device 100 may set up a bluetooth setting interface 1740 as shown in fig. 17E.
As shown in fig. 17E, the bluetooth setup interface 1740 includes a bluetooth switch entry 1741, a device name entry 1742, a received file entry 1743, a scan control 1744, a help control 1745, a paired device list 1746, and an available device list 1748. A bluetooth switch 1751 is displayed in this bluetooth switch entry 1741. The bluetooth switch 1751 may be configured to receive an operation of a user and trigger the electronic device 100 to turn on/off a bluetooth function. Since the electronic device 100 is currently enabled with bluetooth functionality, the bluetooth switch 1751 may be displayed in an on state. Since electronic device 100 has scanned the BLE broadcast of accessory device 200 and determined that electronic device 100 is not currently paired with accessory device 200, electronic device 100 can display device options 1749 of accessory device 200 in this list of available devices 1748. The device option 1749 can display the device name of the accessory device 200 (e.g., "HUAWEI Free Buds").
Electronic device 100 can receive an input operation (e.g., a single click) by a user for device option 1749 in available device list 1748, and in response to the input operation for that device option 1749, electronic device 100 can establish a BLE connection with accessory device 200. Electronic device 100, upon establishing a BLE connection with accessory device 200, can send a pairing mode modification request to accessory device 200 requesting accessory device 200 to enter a pairable mode. After receiving the pairing mode modification request sent by the electronic device 100, the accessory device 200 may determine whether the accessory device 200 does not establish a classic bluetooth connection with another device, and if so, the accessory device 200 may enter the pairable mode and return a pairing mode modification response to the electronic device 100, so as to notify the electronic device 100 that the accessory device 200 has currently entered the pairable mode. The electronic device 100 can perform a classic bluetooth pairing procedure with the accessory device 200 after receiving the pairing mode modification response sent by the accessory device 200.
As shown in fig. 17F, the electronic device 100 may output a prompt that the user is pairing after receiving an input operation for the device option 1749 (for example, display a word "pairing …" or the like in the device option 1749).
As shown in fig. 17G, after the electronic device 100 is successfully paired with the accessory device 200, the electronic device 100 can display a device option 1752 of the accessory device 200 in a paired device list 1746.
After the electronic device 100 is successfully paired with the accessory device 200, the electronic device 100 can establish a classic bluetooth connection with the accessory device 200. The classic bluetooth connection established between the electronic device 100 and the accessory device 200 may be triggered by the user, for example, after the electronic device 100 is successfully paired with bluetooth, the electronic device 100 may receive an input operation (e.g., a click) from the user on the device option 1752 in the paired device list 1746, and in response to the input operation, the electronic device 100 may establish the classic bluetooth connection with the accessory device 200. After the electronic device 100 establishes a bluetooth connection with the accessory device 200, the electronic device 100 can display a connected prompt message on the device option 1752 for prompting the user that the electronic device 100 has established a classic bluetooth connection with the accessory device 200.
For example, as shown in FIG. 17H, the connected reminder displayed on device option 1752 by electronic device 100 may be a text message of "connected for voice and media", or the like.
In one possible case, the electronic device 100 may directly establish a BLE connection with the accessory device 200 in response to an input operation on the notification bar 1730 after receiving the input operation (e.g., clicking) on the notification bar 1730 in fig. 17D by the user. Electronic device 100, upon establishing a BLE connection with accessory device 200, can send a pairing mode modification request to accessory device 200 requesting accessory device 200 to enter a pairable mode. After receiving the pairing mode modification request sent by the electronic device 100, the accessory device 200 may determine whether the accessory device 200 does not establish a classic bluetooth connection with another device, and if so, the accessory device 200 may enter the pairable mode and return a pairing mode modification response to the electronic device 100, so as to notify the electronic device 100 that the accessory device 200 has currently entered the pairable mode. The electronic device 100 can perform a classic bluetooth pairing procedure with the accessory device 200 after receiving the pairing mode modification response sent by the accessory device 200.
Electronic device 100 can establish a classic bluetooth connection with accessory device 200 after pairing with accessory device 200 is complete. Wherein, as shown in fig. 17I, the electronic device 100 can display the device name of the accessory device 200 (e.g., "huaweii Free days") under the bluetooth switch control 1721 in the window menu 1720 after establishing the classic bluetooth connection with the accessory device 200.
A bluetooth pairing method provided in the present application is specifically described below with reference to fig. 18. The method comprises the following steps:
s1801, the electronic device 100 scans for BLE broadcasts.
Electronic device 100 may scan for BLE broadcasts when a user triggers turning on of BLE broadcasts.
For example, the operation of turning on BLE broadcast triggered by the user may refer to the input operation (e.g., clicking) on the bluetooth switch 1651 in the bluetooth setting interface 1640 in fig. 16D described above, and may also refer to the input operation (e.g., clicking) on the bluetooth switch control 1721 in the window menu 1720 described above in fig. 17B. For details, reference may be made to the foregoing embodiments shown in fig. 16D or fig. 17B, which are not described herein again.
In this embodiment of the application, the process of the electronic device 100 scanning BLE broadcast may be that the electronic device 100 scans BLE broadcast packets on a plurality of broadcast channels (e.g., BLE broadcast channel 37(2402MHz), BLE broadcast channel 38(2426MHz), and BLE broadcast channel 39(2480MHz)) in sequence. The duration of scanning by electronic device 100 on one BLE broadcast channel may be referred to as a scanning window, and the scanning window is fixed in size (for example, the scanning window may take 10ms to 10.24s), and the interval between the start times of two consecutive scanning windows may be referred to as a scanning interval, and the scanning interval is fixed (for example, the scanning interval may take 10ms to 10.24 s).
S1802, accessory device 200 does not enter a pairable mode.
When the accessory device 200 does not enter the pairable mode, the accessory device cannot be paired with the electronic device 100. When accessory device 200 does not enter the pairable mode, several conditions may be included:
1. accessory device 200 is currently unpaired, and disconnects bluetooth from other devices, but does not enter the pairable mode. For example, accessory device 200 successfully pairs with other devices before unpairing with the other devices.
2. Accessory device 200 has already been paired with other devices, has not established a bluetooth connection with other devices, but has not entered a pairable mode. For example, accessory device 200 has already been paired with other devices, currently retaining pairing information for pairing with other devices, but has been disconnected from other devices.
3. Accessory device 200 has paired with other devices and established a bluetooth connection, but has not entered pairable mode. For example, the accessory device 200 has been paired with another device and has established a bluetooth connection, in a connection state.
When accessory device 200 does not enter the pairable mode, that is, accessory device 200 does not enter the inquiry scan state, and when accessory device 200 enters the pairable mode, that is, accessory device 200 enters the inquiry scan state is indicated.
When accessory device 200 enters the inquiry scan state, the Bluetooth protocol stack on accessory device 200 may send a write scan enable command (write scan enable command) to a controller (controller) of classic Bluetooth (BR/EDR). The write scan enable command includes a scan enable parameter, which may control a controller of the BR/EDR to periodically scan for a transmitted page (page) or a scan request (inquiry request) to other devices.
S1803, the accessory device 200 transmits a BLE broadcast packet. The BLE broadcast packet includes a pairable mode field, and the pairable mode field includes first pairing mode information for indicating whether the accessory device 200 enters a pairable mode.
Accessory device 200 may periodically transmit BLE broadcast packets with a broadcast interval (e.g., 100ms) between every two adjacent broadcasts. Each time the accessory device 200 makes a BLE broadcast, BLE broadcast messages may be sent on one or more BLE broadcast channels (e.g., BLE broadcast channel 37(2402MHz), BLE broadcast channel 38(2426MHz), BLE broadcast channel 39(2480 MHz)).
The format of BLE broadcast packet may refer to fig. 19.
As shown in fig. 19, the BLE broadcast packet may include a broadcast Header (Header) field and an information content (Payload) field. The Header field contains information for link control, for example, the information for link control may include one or more of the following: broadcast packet type, sender address type, receive address type, etc. The Least Significant Bit (LSB) of the BLE broadcast packet is on the left side of the Header field in fig. 19, and the Most Significant Bit (MSB) of the BLE broadcast packet is on the right side of the Payload field in fig. 19.
The Payload field may include an address (AdvA) field and a data (AdvData) field. The broadcast device address field takes 6 bytes and the broadcast data field takes 31 bytes. The broadcast data field may include a valid data portion and an invalid data portion. Wherein, the valid data part comprises N broadcasting data structures (AD structures), and N is a positive integer. Each AD structure includes a Length field, a broadcast Data Type field, and a broadcast Data structure Data (AD Data) field. The invalid data portion is filled with 0.
The Length field occupies 1 byte, and is used for indicating the lengths of the AD Type field and the AD Data in the AD structure. The AD Type field is used to indicate the meaning of AD Data. For example, when the value of the AD Type field is 0xFF, it may indicate that the AD Data field in the AD structure is vendor-defined Data, and the vendor may fill the AD Data field at will.
In the embodiment of the present application, the pairable mode field may be set in the AD Data field. Illustratively, the pairable mode field may occupy 1bit, which may indicate that accessory device 200 is not currently entering a pairable mode when the pairable mode field value is 0, and may indicate that accessory device 200 is currently entering a pairable mode when the pairable mode field value is 1. The examples are merely illustrative of the present application and should not be construed as limiting.
S1804, the electronic device 100 displays pairing options of the accessory device 200.
Illustratively, the pairing options for the accessory device 200 can be as described above for device option 1649 shown in available devices list 1648 in FIG. 16F, as described above for device option 1654 shown in pairable devices window 1653 in FIG. 16J, as described above for notification bar 1730 in FIG. 17D, and so forth. For content, reference may be made to the embodiments shown in fig. 16F or fig. 17D, which are not described herein again.
S1805, the electronic device 100 receives a pairing operation for the accessory device 200.
The pairing operation may refer to an input operation (e.g., a single click) for the device option 1649 in the available device list 1648 in fig. 16F, an input operation (e.g., a single click) for the device option 1654 in the pairable device window 1653 in fig. 16J, an input operation (e.g., a single click) for the notification bar 1730 in fig. 17D, and the like. For details, reference may be made to the foregoing embodiments, which are not described herein again.
S1806, in response to the pairing operation for the accessory device 200, the electronic device 100 determines whether the accessory device 200 does not currently enter the pairable mode according to the pairable mode field in the BLE broadcast packet. If yes, step S1807 is executed, and the electronic device 100 establishes a BLE connection with the accessory device 200. If not, step S1812 is executed to perform classic bluetooth pairing between the electronic device 100 and the accessory device 200.
After receiving the BLE broadcast packet sent by accessory device 200, electronic device 100 may parse the value of the pairable mode field from the BLE broadcast packet, and determine whether accessory device 200 does not currently enter the pairable mode according to the value of the pairable mode field. For example, if the pairable mode field occupies 1bit, when the electronic device 100 analyzes that the value of the pairing mode field is 0, the electronic device 100 may determine that the accessory device 200 does not currently enter the pairable mode, and when the electronic device 100 analyzes that the value of the pairing mode field is 1, the electronic device 100 may determine that the accessory device 200 currently enters the pairable mode.
The following describes a procedure of the electronic device 100 establishing a BLE connection with a bluetooth device in the embodiment of the present application.
When electronic device 100 determines that accessory device 200 is not currently entering the pairable mode, electronic device 100 may send a connection request to accessory device 200, where the connection request includes time window information for electronic device 100 to send a data packet. After receiving the connection request sent by the electronic device 100, the accessory device 200 opens the radio frequency receiving window according to the time window information, and receives the synchronization packet sent by the electronic device 100. After transmitting the connection request to the accessory device 200, the electronic device 100 may transmit a synchronization packet to the accessory device 200. After receiving the synchronization packet sent by the electronic device 100, the accessory device 200 may return an acknowledgement packet to the electronic device 100 after a time inter frame space (T _ IFS), and when the electronic device 100 receives the packet returned by the accessory device 200, the electronic device 100 and the accessory device 200 establish a BLE connection successfully.
S1808, the electronic device 100 sends a pairing mode modification request to the accessory device 200. The pairing mode modification request is for requesting accessory device 200 to enter a pairable mode.
After the electronic device 100 establishes the BLE connection with the accessory device 200, the pairing mode modification request may be sent to the accessory device 200 by a command in a Logical link control and adaptation protocol (L2 CAP).
In the embodiment of the present application, a format of L2CAP signaling is defined for the electronic device 100 to request the accessory device 200 to enter the pairable mode. The format of the L2CAP signaling of the pairing mode modification request may be referred to as fig. 16A.
As shown in fig. 20A, L2CAP signaling includes a L2CAP packet header, one or more commands. Wherein:
the header part of the L2CAP packet includes a protocol data unit length field (PDU length) and a channel number (CID). The protocol unit length field takes 2 bytes and the channel number takes 2 bytes.
Each instruction includes an instruction Code (Code), an Identifier (Identifier), an instruction length (command length), and a data field. The L2CAP signaling command code occupies 1 byte, the identifier occupies 1 byte, and the command length occupies 2 bytes.
In the embodiment of the present application, the pairing signaling type field and the pairing mode field are defined in a data field in an instruction having an instruction code of "0 x 08" (i.e., an Echo Request instruction). Wherein the location of the pairing signaling type field in the data field is not limited.
The pairing signaling type field takes 1 byte and the pairing mode value takes 1 bit. The pairing signaling type field is used for indicating whether the L2CAP signaling is a pairing mode modification request. When the pairing signaling type field is "0 x 01", it may indicate that the L2CAP signaling is a pairing mode modification request. The pairing mode field is used to indicate whether the request is to enter pairing mode. When the value of the pairing mode field is "1", it may indicate that the pairing mode is requested to be entered; when the value of the pairing mode field is "0", it may indicate that the non-pairing mode is requested to be entered.
When the instruction code in the L2CAP signaling sent by the electronic device 100 to the accessory device 200 is "0 x08," the value of the pairing signaling type field is "0 x01," and the pairing mode value is "1," it indicates that the L2CAP signaling sent by the electronic device 100 to the accessory device 200 is a pairing mode modification request for requesting the accessory device 200 to enter the pairing mode.
In the embodiment of the present application, the L2CAP signaling format of the pairing mode modification request shown in fig. 16A is only used for explaining the present application, and should not be limited thereto. The electronic device 100 may also send the pairing mode modification request through other protocol commands, for example, the pairing mode modification request may also be sent through a generic attribute protocol (GATT) command.
S1809, after receiving the pairing mode modification request, the accessory device 200 may output a first prompt prompting the user that the electronic device 100 requests to pair with the accessory device 200, and enter a pairable mode.
Wherein the first prompt may be a display prompt, for example, if accessory device 200 is configured with a display screen, accessory device 200 may display the prompt information "HUAWEI P30 requests pairing" ("HUAWEI P30" is the device name of electronic device 100). The first prompt can also be an audio prompt, for example, if accessory device 200 is configured with an audio output device, accessory device 200 can output an audio prompt via the audio output device prompting the user that electronic device 100 requests pairing with accessory device 200. The first cue may also be a mechanical vibration cue. In the embodiment of the present application, the first prompt may be a combined prompt of two or more of a display prompt, an audio prompt, a mechanical vibration prompt, and the like.
In one possible implementation, after receiving the pairing mode modification request and before entering the pairable mode, the accessory device 200 may further determine whether the accessory device 200 is currently disconnected from other devices by classical bluetooth, and if so, the accessory device 200 may enter the pairable mode and notify the electronic device 100 that the accessory device 200 has currently entered the pairable mode. If not, accessory device 200 does not enter the pairable mode and notifies electronic device 100 that accessory device 200 is not currently entering the pairable mode. Thus, accessory device 200 can refuse the pairing mode modification of electronic device 100 when performing classic bluetooth connection with other devices to ensure that accessory device 200 does not suddenly disconnect classic bluetooth connection with other devices, improving user experience.
In one possible implementation, accessory device 200, upon receiving the pairing mode modification request, outputting the first prompt, can receive a confirmation pairing operation by the user, in response to which accessory device 200 can enter the pairing mode, and notify electronic device 100 that accessory device 200 has currently entered the pairing mode. In this way, accessory device 200 can allow the user to confirm whether the pairing with electronic device 100 is approved, ensuring that accessory device 200 is not used by others without consent.
S1810, accessory device 200 can send a pairing mode modification response to electronic device 100.
The pairing mode modification response includes second pairing mode information of the accessory device 200, and the second pairing mode information is used for indicating whether the accessory device 200 enters the pairable mode after receiving the pairing mode modification request.
In an embodiment of the present application, the pairing mode modification response characterizing entry of accessory device 200 into the pairable mode may be referred to as a first modification response. The pairing mode modification response, which characterizes the accessory device 200 not entering the pairable mode, can be referred to as a second modification response. That is, a first modified response to indicate that accessory device 200 has entered the pairable mode, and a second modified response to indicate that accessory device 200 has not entered the pairable mode.
In some embodiments, when accessory device 200 does not enter pairing mode before receiving a pairing mode modification request, there may be the following:
1. accessory device 200 is not currently paired, but does not enter a mateable state. For example, accessory device 200 successfully pairs with other devices before unpairing with the other devices.
2. Accessory device 200 has already been paired with other devices, has not established a bluetooth connection with other devices, but has not entered a pairable mode.
3. Accessory device 200 has paired with other devices and established a bluetooth connection, but has not entered pairable mode.
For case 1 above: accessory device 200 is not currently paired, but does not enter a mateable state. After receiving the pairing mode modification request sent by electronic device 100, accessory device 200 may enter the pairing mode and return a first modification response to electronic device 100 for notifying electronic device 100 that accessory device 200 has entered the pairable mode.
For case 2 above: accessory device 200 has already been paired with other devices, has not established a bluetooth connection with other devices, but has not entered a pairable mode. After receiving the pairing mode modification request sent by electronic device 100, accessory device 200 may enter the pairing mode and return a first modification response to electronic device 100 for notifying electronic device 100 that accessory device 200 has entered the pairable mode.
For case 3 above: after receiving the pairing mode modification request sent by electronic device 100, accessory device 200 remains in a state of not entering the pairing mode, and returns a second modification response to electronic device 100 for notifying electronic device 100 that accessory device 200 does not enter the pairable mode.
In an embodiment of the application, the accessory device 200 can send the pairing mode modification response through L2CAP signaling. The format of the L2CAP signaling of the pairing mode modification response may refer to fig. 16B.
As shown in fig. 20B, L2CAP signaling includes a L2CAP packet header, one or more commands. Wherein:
the header part of the L2CAP packet includes a protocol data unit length field (PDU length) and a channel number (CID). The protocol unit length field takes 2 bytes and the channel number takes 2 bytes.
Each instruction includes an instruction Code (Code), an Identifier (Identifier), an instruction length (command length), and a data field. The L2CAP signaling command code occupies 1 byte, the identifier occupies 1 byte, and the command length occupies 2 bytes, and is used for indicating the data length of the data field.
In the embodiment of the present application, the pairing signaling type field and the pairing mode value field are defined in a data field in an instruction whose instruction code is "0 x 09" (i.e., an Echo Response (Echo Response) instruction). Wherein the location of the pairing signaling type field in the data field is not limited.
The pairing signaling type field takes 1 byte and the pairing mode value takes 1 bit. The pairing signaling type field is used for indicating whether the L2CAP signaling is a pairing mode modification request. When the pairing signaling type field is "0 x 01", it may indicate that the L2CAP signaling is a pairing mode modification response. The pairing mode field is used to indicate whether the accessory device 200 has currently entered pairing mode. When the value of the pairing mode field is "1", it may indicate that the accessory device 200 has currently entered the pairing mode; when the value of the pairing mode field is "0", it may indicate that the accessory device 200 does not currently enter the pairing mode.
When the instruction code in the L2CAP signaling sent by the electronic device 100 to the accessory device 200 is "0 x09," the value of the pairing signaling type field is "0 x01," and the pairing mode value is "1," it indicates that the L2CAP signaling sent by the electronic device 100 to the accessory device 200 is a first modification response for notifying the electronic device 100 that the accessory device 200 has entered the pairing mode.
When the instruction code in the L2CAP signaling sent by the electronic device 100 to the accessory device 200 is "0 x09," the value of the pairing signaling type field is "0 x01," and the pairing mode value is "0," it indicates that the L2CAP signaling sent by the electronic device 100 to the accessory device 200 is a second modification response for notifying the electronic device 100 that the accessory device 200 does not enter the pairing mode.
The above L2CAP signaling format of the pairing mode modification request shown in fig. 20B is only for explaining the present application and should not be limited thereto.
S1811, after receiving the pairing mode modification response, the electronic device 100 may determine whether the accessory device 200 has entered the pairing mode according to the pairing mode modification response. If yes, step S1412 is executed to perform classic bluetooth pairing between the electronic device 100 and the accessory device 200. If not, the electronic device 100 and the accessory device 200 are disconnected from BLE, and a pairing failure prompt is output for prompting that the user and the accessory device 200 fail to pair.
Wherein electronic device 100 can establish an Asynchronous Connection (ACL) connection with accessory device 200 before electronic device 100 and accessory device 200 are classic bluetooth paired.
The following describes a classic bluetooth pairing procedure in an embodiment of the present application.
In the embodiment of the present application, a device that first initiates pairing is referred to as a Master device (Master), and a device that passively performs pairing is referred to as a Slave device (Slave). For example, electronic device 100 actively initiates pairing with accessory device 200, electronic device 100 can be referred to as a master device, and accessory device 200 can be referred to as a slave device.
The classical bluetooth pairing procedure may be as follows:
1. an initial key (key) is generated.
Wherein the initial key length is 128 bits (bit) and is generated by the E22 algorithm.
Wherein, the input (plaintext) of the E22 algorithm consists of the following three parts: the physical address BD _ ADDR of the opposite device, the PIN code and its length, a 128-bit random number IN _ RAND.
Physical address of the slave device before generating the initial key, the master device obtains the address (BD _ ADDRB) of the slave device by means of an inquiry. Wherein the address of the master device is BD _ ADDRA.
The PIN code is preset by both devices (master and slave), for example, "0000" or "1234" or the like.
The random number IN _ RAND is generated by the master device and transmitted to the slave device IN clear.
Since the master and slave devices use the same E22 algorithm, if the values of the above three parts of the two devices are equal, the initial keys calculated by the two devices should be the same.
2. A link key (Kab) is generated.
After generating the initial key, the master device may generate a 128-bit random number Link _ RandA and the slave device may also generate a 128-bit random number Link _ RandB. In the master device, the master device performs bit-bit logical exclusive-or operation on the initial key and the Link _ RandA, and an exclusive-or result is sent to the slave device. Similarly, in the slave device, the slave device performs bit-bit logical xor operation on the initial key and Link _ RandB, and sends an xor result to the master device.
The master device may obtain Link _ RandB through calculation according to the xor result sent by the slave device and the locally stored initial key. The slave device may obtain Link _ RandA through calculation according to the xor result sent by the master device and the locally stored initial key. Thus, both the master and slave devices have the same initial key, Link _ RandA.
The master device may encrypt Link _ RandA and BD _ ADDRA using an algorithm (e.g., the E21 algorithm) to obtain Link _ KA and encrypt Link _ RandB and BD _ ADDRB to obtain Link _ KB. Then, the master device may perform xor according to Link _ KA and Link _ KB to obtain Kab.
Likewise, the slave device may encrypt Link _ RandA and BD _ ADDRA using an algorithm (e.g., E21 algorithm) to obtain Link _ KA, and encrypt Link _ RandB and BD _ ADDRB to obtain Link _ KB. Then, the slave device may perform xor according to Link _ KA and Link _ KB to obtain Kab.
3. And performing bidirectional authentication on the master device and the slave device.
Among them, a challenge-response (challenge-response) manner is authenticated in two ways. The master device may be a responder and the slave device may be a requester. The responder may generate a 128-bit random number AU _ RANDA and send it in clear to the requester. The responder and the requester use the E1 algorithm to generate 32-bit SRESA and SRESB, respectively, from the respective AU _ RANDA, Kab, and BD _ RANDB encryption operations. Wherein, SRESA is generated by the main device as the responder, and SRESB is generated by the auxiliary device as the requester. The requesting party sends SRESB to the responding party, the responding party compares SRESA with SRESB, if the SRESA and the SRESB are equal, the authentication is passed, otherwise, the authentication is not passed. After the authentication is executed, the roles of the master device and the slave device are exchanged, the master device serves as a requester, and the slave device serves as a responder to perform authentication in the same way.
After the electronic device 100 and the accessory device 200 are authenticated, the electronic device 100 and the accessory device 200 establish a bluetooth connection for transmitting data, and the electronic device 100 and the accessory device 200 may encrypt the respective transmitted data by using the link key Kab.
In one possible implementation, after electronic device 100 establishes a BLE connection with accessory device 200, electronic device 100 may also send a pairing mode modification request to accessory device 200 in other ways. Accessory device 200 can also pair the mode modification response to electronic device 100 in other ways. For example, electronic device 100 can also send a pairing mode modification request to accessory device 200 via a GATT command. After entering the pairable mode (inquiry scan state), accessory device 200 can modify the response to electronic device 100 via the pairing mode. When accessory device 200 supports Near Field Communication (NFC) or Wi-Fi, electronic device 100 may also send a pairing mode modification request to accessory device 200 through NFC or Wi-Fi. Accessory device 200 can also send a pairing mode modification response to electronic device 100 through NFC or Wi-Fi.
Fig. 21 is a schematic diagram of a system architecture 2100 provided by an embodiment of the present application. As shown in fig. 21, the system 2100 may include: an electronic device 2101 and an accessory device 2102.
Here, the electronic device 2101 may be an electronic device in the above-described embodiment, and the accessory device 2102 may be an accessory device in the above-described embodiment.
Illustratively, the electronic device 2101 may be a smartphone, a tablet, a personal computer, or the like. The accessory device 2102 may be a bluetooth enabled device such as a bluetooth headset, a bluetooth speaker, a smart watch, and the like.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (26)

1. A system comprising a first electronic device and an accessory device,
the accessory device is used for detecting a first operation of a user;
the accessory device is further configured to respond to the first operation and send first information to the first electronic device, where the first information includes a Media Access Control (MAC) address of the accessory device and authentication information, and the authentication information is used to indicate that interactive authentication is required for connecting the accessory device;
the first electronic equipment is used for prompting a user to input first authentication information when the MAC address is determined not to be stored;
the first electronic equipment is further used for performing interactive authentication with the accessory equipment according to the first authentication information when the first authentication information input by a user is detected;
the accessory equipment is further used for entering a pairable mode after the interactive authentication with the first electronic equipment is passed;
the first electronic device is further used for establishing Bluetooth connection with the accessory device.
2. The system of claim 1,
the accessory device is further configured to send second information to the first electronic device before establishing a bluetooth connection with the first electronic device, where the second information is used to instruct the accessory device to enter a pairable mode;
the first electronic device is specifically configured to:
in response to receiving the second information, automatically sending a paging page message to the accessory device using the MAC address;
and carrying out a standard Bluetooth pairing process with the accessory equipment.
3. The system according to claim 1 or 2, further comprising a second electronic device, wherein,
the accessory device is used for establishing Bluetooth connection with the second electronic device before the first operation is detected;
the second electronic device is used for prompting a user to add authentication information to the accessory device after the Bluetooth connection is established with the accessory device;
the second electronic device is further configured to send the first authentication information to the accessory device after detecting that the user adds the first authentication information to the accessory device.
4. The system according to claim 1 or 2,
the first electronic device is further used for prompting a user to modify the first authentication information or prompting the user to cancel the first authentication information after the Bluetooth connection with the accessory device is established;
the first electronic device is further used for sending the second authentication information to the accessory device after detecting that the user modifies the first authentication information into the second authentication information.
5. The system of claim 1 or 2, further comprising a third electronic device that is a previously connected and not last connected device of the accessory device,
the accessory device is further configured to send the first information to the third electronic device;
the third electronic device is used for prompting a user whether to establish Bluetooth connection with the accessory device after the third electronic device is determined to store the MAC address;
the third electronic device is further configured to perform interactive authentication with the accessory device through third authentication information after detecting an operation of determining that connection with the accessory device is established, where the third authentication information is authentication information added by a user to the accessory device on the third electronic device;
the accessory equipment is also used for entering a pairable mode and disconnecting the Bluetooth connection with the first electronic equipment after the interactive authentication with the third electronic equipment is passed;
the third electronic device is further configured to establish a bluetooth connection with the accessory device.
6. The system according to claim 1 or 2, wherein the accessory device is a bluetooth headset, and the first operation is an operation of opening a headset case by a user.
7. A method of Bluetooth connection, the method being applied to an electronic device, the method comprising:
receiving first information sent by accessory equipment, wherein the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required to be carried out when the accessory equipment is connected;
prompting a user to input first authentication information when the MAC address is determined not to be stored;
when the fact that the user inputs the first authentication information is detected, performing interactive authentication with the accessory equipment according to the first authentication information;
and after the interactive authentication with the accessory equipment is passed, establishing Bluetooth connection with the accessory equipment.
8. The method of claim 7, wherein prior to establishing the Bluetooth connection with the accessory device, the method further comprises:
receiving indication information sent by the accessory device, wherein the indication information is used for indicating the accessory device to enter a pairable mode;
wherein, with the accessory device establishes bluetooth connection, include:
in response to receiving the indication information, sending a paging message to the accessory device;
and carrying out a standard Bluetooth pairing process with the Bluetooth headset.
9. The method according to claim 7 or 8, characterized in that the method further comprises:
after the Bluetooth connection with the accessory equipment is established, prompting a user to modify the first authentication information, or prompting the user to cancel the first authentication information;
and after the operation that the user modifies the first authentication information into second authentication information is detected, the second authentication information is sent to the accessory equipment.
10. A method of Bluetooth connection, the method being applied to an accessory device, the method comprising:
detecting a first operation of a user;
responding to the first operation, sending first information to first electronic equipment, wherein the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required to be carried out when the accessory equipment is connected;
performing interactive authentication with the first electronic device according to first authentication information, wherein the first authentication information is authentication information input by a user and detected on the first electronic device;
entering a pairable mode after successful mutual authentication with the first electronic equipment;
and establishing Bluetooth connection with the first electronic equipment.
11. The method of claim 10, further comprising:
before establishing a Bluetooth connection with the first electronic device, sending second information to the first electronic device, wherein the second information is used for indicating the accessory device to enter a pairable mode;
wherein, establish bluetooth with the first electronic equipment and connect, include:
receiving a paging message sent by the first electronic equipment;
and carrying out a standard Bluetooth pairing process with the first electronic equipment.
12. The method according to claim 10 or 11, characterized in that the method further comprises:
before the first operation is detected, establishing a Bluetooth connection with a second electronic device;
and receiving the first authentication information sent by the second electronic equipment.
13. The method according to claim 10 or 11, characterized in that the method further comprises:
after Bluetooth connection with the first electronic equipment is established, second authentication information sent by the first electronic equipment is received;
and storing the second authentication information, wherein the second authentication information is used for performing interactive authentication on the accessory equipment and the electronic equipment to be connected next.
14. The method according to claim 10 or 11, wherein the accessory device is a bluetooth headset, and the first operation is an operation of opening a headset case by a user.
15. An electronic device, comprising:
a Bluetooth chip;
a display screen;
one or more processors;
one or more memories;
the one or more memories store one or more computer programs, the one or more computer programs comprising instructions, which when executed by the one or more processors, cause the electronic device to perform the steps of:
receiving first information sent by accessory equipment, wherein the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required to be carried out when the accessory equipment is connected;
when the MAC address is determined not to be stored, prompting a user to input first authentication information through the display screen;
when the fact that the user inputs the first authentication information is detected, performing interactive authentication with the accessory equipment according to the first authentication information;
and after the interactive authentication with the accessory equipment is passed, establishing Bluetooth connection with the accessory equipment.
16. The electronic device of claim 15, wherein the instructions, when executed by the one or more processors, cause the electronic device to perform the steps of:
before establishing Bluetooth connection with the accessory device, receiving indication information sent by the accessory device, wherein the indication information is used for indicating the accessory device to enter a pairable mode;
in response to receiving the indication information, sending a paging message to the accessory device;
and carrying out a standard Bluetooth pairing process with the Bluetooth headset.
17. The electronic device of claim 15 or 16, wherein the instructions, when executed by the one or more processors, cause the electronic device to perform the steps of:
after the Bluetooth connection with the accessory equipment is established, prompting a user to modify the first authentication information through a display screen, or prompting the user to cancel the first authentication information;
and after the operation that the user modifies the first authentication information into second authentication information is detected, the second authentication information is sent to the accessory equipment.
18. An accessory apparatus, comprising:
a Bluetooth chip;
one or more processors;
one or more memories;
the one or more memories store one or more computer programs, the one or more computer programs comprising instructions, which when executed by the one or more processors, cause the electronic device to perform the steps of:
detecting a first operation of a user;
responding to the first operation, sending first information to first electronic equipment, wherein the first information comprises a Media Access Control (MAC) address and authentication information of the accessory equipment, and the authentication information is used for indicating that interactive authentication is required to be carried out when the accessory equipment is connected;
performing interactive authentication with the first electronic device according to first authentication information, wherein the first authentication information is authentication information input by a user and detected on the first electronic device;
entering a pairable mode after successful mutual authentication with the first electronic equipment;
and establishing Bluetooth connection with the first electronic equipment.
19. The accessory device of claim 18, wherein the instructions, when executed by the one or more processors, cause the electronic device to perform the steps of:
before establishing a Bluetooth connection with the first electronic device, sending second information to the first electronic device, wherein the second information is used for indicating the accessory device to enter a pairable mode;
receiving a paging message sent by the first electronic equipment;
and carrying out a standard Bluetooth pairing process with the first electronic equipment.
20. The accessory device of claim 18 or 19, wherein the instructions, when executed by the one or more processors, cause the electronic device to perform the steps of:
before the first operation is detected, establishing a Bluetooth connection with a second electronic device;
and receiving the first authentication information sent by the second electronic equipment.
21. The accessory device of claim 18 or 19, wherein the instructions, when executed by the one or more processors, cause the electronic device to perform the steps of:
after Bluetooth connection with the first electronic equipment is established, second authentication information sent by the first electronic equipment is received;
and storing the second authentication information, wherein the second authentication information is used for performing interactive authentication on the accessory equipment and the electronic equipment to be connected next.
22. The accessory device of claim 18 or 19, wherein the accessory device is a bluetooth headset and the first operation is an operation of a user opening a headset case.
23. A chip system, characterized in that the chip system comprises at least one processor, which when executed in the at least one processor causes the functionality of the method according to any of claims 7-9 on the electronic device to be implemented.
24. A chip system, characterized in that the chip system comprises at least one processor, which when executed in the at least one processor causes the functionality of the method according to any of claims 10-14 on the electronic device to be implemented.
25. A computer readable storage medium comprising computer instructions which, when run on an electronic device, cause the electronic device to perform the method of bluetooth connection of any of claims 7-9.
26. A computer readable storage medium comprising computer instructions that, when executed on an electronic device, cause the accessory device to perform the method of bluetooth connection of any of claims 10-14.
CN201910844294.9A 2019-08-30 2019-09-06 Bluetooth connection method and electronic equipment Active CN112449332B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2020/112126 WO2021037208A1 (en) 2019-08-30 2020-08-28 Bluetooth connection method and electronic apparatus

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN2019108161057 2019-08-30
CN201910816105 2019-08-30
CN201910816994 2019-08-30
CN2019108169947 2019-08-30

Publications (2)

Publication Number Publication Date
CN112449332A CN112449332A (en) 2021-03-05
CN112449332B true CN112449332B (en) 2022-04-12

Family

ID=74733535

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910844294.9A Active CN112449332B (en) 2019-08-30 2019-09-06 Bluetooth connection method and electronic equipment

Country Status (1)

Country Link
CN (1) CN112449332B (en)

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114363868A (en) * 2020-09-30 2022-04-15 华为技术有限公司 Bluetooth system, Bluetooth headset and password verification method
CN113329381B (en) * 2021-04-28 2022-03-11 荣耀终端有限公司 Method for establishing Bluetooth connection and electronic equipment
CN115776661A (en) * 2021-09-08 2023-03-10 Oppo广东移动通信有限公司 Bluetooth-based control method and device, electronic equipment and storage medium
WO2023093328A1 (en) * 2021-11-23 2023-06-01 Oppo广东移动通信有限公司 Bluetooth back-connection method and apparatus, information storage method and apparatus, and terminal device
CN114245362B (en) * 2022-02-25 2022-11-15 荣耀终端有限公司 Device reconnection method and Bluetooth peripheral
CN114500730B (en) * 2022-02-28 2023-08-29 歌尔股份有限公司 Popup function control method, popup function control device and computer readable storage medium
CN116056051B (en) * 2022-06-06 2023-10-27 荣耀终端有限公司 Bluetooth connection control method, system and equipment
CN115022452B (en) * 2022-06-13 2024-04-02 浙江地芯引力科技有限公司 Communication method, device, equipment and storage medium of audio equipment
CN115087134B (en) * 2022-07-20 2023-01-13 荣耀终端有限公司 Bluetooth connection method and electronic equipment
CN116132565A (en) * 2022-10-24 2023-05-16 维沃移动通信有限公司 Display method, display device, electronic equipment and readable storage medium
CN116679855B (en) * 2022-10-25 2024-07-23 荣耀终端有限公司 Data processing method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101399567A (en) * 2007-09-26 2009-04-01 艾威梯软件技术(北京)有限公司 Method for automatically initiating Bluetooth connection authentication and authentication initiating device
CN104320412A (en) * 2014-11-11 2015-01-28 福建联迪商用设备有限公司 Bluetooth POS and safe Bluetooth POS connecting method and device
CN106233637A (en) * 2014-04-21 2016-12-14 Arm 有限公司 System and method for short distance wireless data transmission

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9563766B2 (en) * 2014-04-30 2017-02-07 Infineon Technologies Austria Ag Device and accessory pairing
US9961484B2 (en) * 2016-01-22 2018-05-01 Lg Electronics Inc. Method and apparatus for controlling a device using bluetooth technology

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101399567A (en) * 2007-09-26 2009-04-01 艾威梯软件技术(北京)有限公司 Method for automatically initiating Bluetooth connection authentication and authentication initiating device
CN106233637A (en) * 2014-04-21 2016-12-14 Arm 有限公司 System and method for short distance wireless data transmission
CN104320412A (en) * 2014-11-11 2015-01-28 福建联迪商用设备有限公司 Bluetooth POS and safe Bluetooth POS connecting method and device

Also Published As

Publication number Publication date
CN112449332A (en) 2021-03-05

Similar Documents

Publication Publication Date Title
CN112449332B (en) Bluetooth connection method and electronic equipment
JP7317242B2 (en) Bluetooth connection methods, systems and electronic devices
WO2021036835A1 (en) Bluetooth search method and system, and related apparatus
CN112469015B (en) Bluetooth connection method and electronic equipment
CN112469013B (en) Bluetooth connection method and related device
WO2020062344A1 (en) Data transmission method and electronic device
WO2021175268A1 (en) Method and apparatus for sharing mobile network hotspot, and hotspot sharing device
CN114710768B (en) Bluetooth connection method and related device
US11844119B2 (en) Bluetooth pairing method and related apparatus
CN111491297A (en) Method and device for controlling intelligent household equipment to be connected with network
CN112860428A (en) High-energy-efficiency display processing method and equipment
CN114895991B (en) Content sharing method and electronic equipment
CN113676879A (en) Method, electronic device and system for sharing information
EP4283931A1 (en) Nfc method and system, and electronic device
WO2021218544A1 (en) Wireless connection providing system, method, and electronic apparatus
CN111492678A (en) File transmission method and electronic equipment
WO2021037208A1 (en) Bluetooth connection method and electronic apparatus
EP4138462A1 (en) Information sharing method, electronic devices and system
CN113923528B (en) Screen sharing method, terminal and storage medium
CN114489876A (en) Text input method, electronic equipment and system
CN115525366A (en) Screen projection method and related device
WO2024002137A1 (en) Communication method, communication system, and electronic device
WO2023025059A1 (en) Communication system and communication method
CN115802326A (en) Bluetooth connection method and electronic equipment
CN115515112A (en) Bluetooth communication 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
GR01 Patent grant
GR01 Patent grant