WO2023246056A1 - Device connection method and apparatus, and storage medium and chip - Google Patents

Device connection method and apparatus, and storage medium and chip Download PDF

Info

Publication number
WO2023246056A1
WO2023246056A1 PCT/CN2022/142139 CN2022142139W WO2023246056A1 WO 2023246056 A1 WO2023246056 A1 WO 2023246056A1 CN 2022142139 W CN2022142139 W CN 2022142139W WO 2023246056 A1 WO2023246056 A1 WO 2023246056A1
Authority
WO
WIPO (PCT)
Prior art keywords
bluetooth
bluetooth audio
connection
low
identification information
Prior art date
Application number
PCT/CN2022/142139
Other languages
French (fr)
Chinese (zh)
Inventor
包建全
Original Assignee
Oppo广东移动通信有限公司
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 Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2023246056A1 publication Critical patent/WO2023246056A1/en

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
    • H04W76/00Connection management
    • H04W76/10Connection setup

Definitions

  • the present application relates to the field of Bluetooth communication technology, and in particular, to a device connection method and device, a storage medium, and a chip.
  • Bluetooth audio devices when users use Bluetooth audio devices to connect to terminal devices (such as smartphones, tablets, smart wearable devices, etc.), in addition to using the classic Bluetooth connection method, they can also use BLE (Bluetooth Low Energy) based on the new generation of Bluetooth technology. Establish a connection through Bluetooth Low Energy), especially LE Audio (Low Energy Audio, Low Energy Audio) Bluetooth connection.
  • LE Audio Low Energy Audio, Low Energy Audio
  • Embodiments of the present application disclose a device connection method and device, storage medium, and chip, which can reduce the possibility of Bluetooth audio devices misconnecting to terminal devices and improve the accuracy and flexibility of communication connections by Bluetooth audio devices.
  • the first aspect of the embodiment of the present application discloses a device connection method, which is applied to a first Bluetooth audio device.
  • the method includes:
  • the low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
  • a Bluetooth low energy audio connection is established with the first target device.
  • the second aspect of the embodiment of the present application discloses a device connection method, which is applied to a second Bluetooth audio device.
  • the method includes:
  • the low-power Bluetooth broadcast message is used to indicate that the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
  • a Bluetooth low energy audio connection is established with the first target device.
  • the second aspect of the embodiment of the present application also discloses another device connection method, which is applied to a second Bluetooth audio device.
  • the method includes:
  • the low-power Bluetooth broadcast message is used to indicate that the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
  • a Bluetooth low energy audio connection is established with the first target device.
  • the third aspect of the embodiments of the present application discloses a device connection method, which is applied to terminal devices.
  • the method includes:
  • the first Bluetooth low energy broadcast message corresponds to the identification information of the terminal device
  • the fourth aspect of the embodiment of the present application discloses a device connection device, which is applied to the first Bluetooth audio device.
  • the device connection device includes:
  • An information acquisition unit configured to acquire identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device;
  • a first broadcast sending unit configured to send a low-power Bluetooth broadcast message corresponding to the identification information.
  • the low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the first target device’s initiation. Bluetooth low energy audio connection request;
  • a first request receiving unit configured to receive a low-power Bluetooth audio connection request sent by the first target device
  • a first connection unit configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
  • the fifth aspect of the embodiment of the present application discloses a device connection device applied to a second Bluetooth audio device.
  • the device connection device includes:
  • a monitoring unit configured to monitor the Bluetooth link between the first Bluetooth audio device and the first target device and obtain monitoring data, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device. gather;
  • a computing unit configured to calculate identification information of the first target device according to the monitoring data
  • a second broadcast sending unit configured to send a low-power Bluetooth broadcast message corresponding to the identification information, where the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to a call initiated by the first target device.
  • Bluetooth low energy audio connection request
  • a second request receiving unit configured to receive a low-power Bluetooth audio connection request sent by the first target device
  • the second connection unit is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
  • the fifth aspect of the embodiment of the present application discloses another device connection device, which is applied to a second Bluetooth audio device.
  • the device connection device includes:
  • An information receiving unit configured to receive the identification information of the first target device sent by the first Bluetooth audio device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
  • a third broadcast sending unit configured to send a low-power Bluetooth broadcast message corresponding to the identification information, where the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to a call initiated by the first target device.
  • Bluetooth low energy audio connection request
  • a third request receiving unit configured to receive a low-power Bluetooth audio connection request sent by the first target device
  • the third connection unit is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
  • the sixth aspect of the embodiment of the present application discloses an equipment connection device, which is applied to terminal equipment.
  • the equipment connection device includes:
  • An information sending unit configured to send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the terminal device;
  • a broadcast receiving unit configured to receive a low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the security management information
  • a request sending unit configured to respond to the Bluetooth low energy broadcast message and send a low-power Bluetooth audio device to the first Bluetooth audio device when it is determined that the low-power Bluetooth broadcast message corresponds to the identification information of the terminal device. and a power consumption Bluetooth audio connection request, so that the first Bluetooth audio device responds to the low power Bluetooth audio connection request and establishes a low power Bluetooth audio connection with the terminal device.
  • the seventh aspect of the embodiment of the present application discloses a Bluetooth audio device, which includes a memory and a processor.
  • a computer program is stored in the memory.
  • the processor implements the following All or part of the steps in any device connection method disclosed in the first aspect or the second aspect of the application embodiments.
  • the eighth aspect of the embodiment of the present application discloses a terminal device, which includes a memory and a processor.
  • a computer program is stored in the memory.
  • the processor implements the application as described in the present application. All or part of the steps in any device connection method disclosed in the third aspect of the embodiment.
  • the ninth aspect of the embodiment of the present application discloses a computer-readable storage medium that stores a computer program, wherein when the computer program is executed by a processor, the first aspect, the second aspect, or the third aspect of the embodiment of the present application is implemented. All or part of the steps in any of the disclosed device connection methods.
  • the tenth aspect of the embodiment of the present application discloses a chip, including a processor, the processor is configured to read and execute the computer program stored in the memory to execute the first aspect, the second aspect or the third aspect of the embodiment of the present application. All or part of the steps in any device connection method disclosed in the aspect.
  • Figure 1A is a schematic diagram of an application scenario of the device connection method disclosed in the embodiment of the present application.
  • Figure 1B is a schematic diagram of another application scenario of the device connection method disclosed in the embodiment of the present application.
  • FIG. 2 is a basic framework diagram of the Bluetooth protocol in related technologies
  • Figure 3 is a schematic flow chart of a device connection method applied to a first Bluetooth audio device disclosed in an embodiment of the present application
  • Figure 4 is a schematic flow chart of another device connection method applied to the first Bluetooth audio device disclosed in the embodiment of the present application.
  • Figure 5 is a schematic flow chart of yet another device connection method applied to the first Bluetooth audio device disclosed in the embodiment of the present application.
  • Figure 6 is a schematic flow chart of a device connection method applied to a second Bluetooth audio device disclosed in the embodiment of the present application;
  • Figure 7 is a schematic flowchart of a device connection method applied to a terminal device disclosed in an embodiment of the present application.
  • Figure 8 is a sequence diagram of a device connection method disclosed in the embodiment of the present application.
  • FIG. 9 is a sequence diagram of another device connection method disclosed in the embodiment of the present application.
  • Figure 10 is a modular schematic diagram of a device connection device disclosed in the embodiment of the present application.
  • Figure 11 is a modular schematic diagram of another device connection device disclosed in the embodiment of the present application.
  • Figure 12 is a modular schematic diagram of yet another device connection device disclosed in the embodiment of the present application.
  • Figure 13 is a modular schematic diagram of the fourth device connection device disclosed in the embodiment of the present application.
  • Figure 14 is a modular schematic diagram of a Bluetooth audio device disclosed in the embodiment of the present application.
  • Figure 15 is a modular schematic diagram of a terminal device disclosed in the embodiment of the present application.
  • Embodiments of the present application disclose a device connection method and device, storage medium, and chip, which can reduce the possibility of Bluetooth audio devices misconnecting to terminal devices and improve the accuracy and flexibility of communication connections by Bluetooth audio devices.
  • FIG. 1A is a schematic diagram of an application scenario of the device connection method disclosed in the embodiment of the present application.
  • FIG. 1B is a schematic diagram of another application scenario of the device connection method disclosed in the embodiment of the present application.
  • the application scenario may include a first Bluetooth audio device 10 and a terminal device 20.
  • the first Bluetooth audio device 10 may establish a Bluetooth connection with the terminal device 20, such as a classic Bluetooth connection, BLE (Bluetooth Low Energy, Low Energy). Power consumption Bluetooth) connection, etc.
  • the above-mentioned classic Bluetooth connection refers to the BR based on various versions of Bluetooth protocols (such as the protocols before Bluetooth 4.0 formulated by the Bluetooth SIG, which can also include Bluetooth 4.0 and subsequent versions of the protocol). /EDR (Basic Rate/Enhanced Data Rate), AMP (Alternate MAC/PHYs) and other technologies (or modes) to achieve Bluetooth connection solutions;
  • the above-mentioned BLE connection refers to a new generation Bluetooth protocol based on (such as developed by Bluetooth SIG Bluetooth 4.0 and subsequent versions of the protocol), a Bluetooth connection solution implemented using BLE technology (or mode).
  • the first Bluetooth audio device 10 can also establish LE Audio (Low Energy Audio, low power audio) with the terminal device 20 Bluetooth connection is based on the new generation of Bluetooth core specification CoreSpec5.2. Compared with the classic A2DP (Advanced Audio Distribution Profile, Advanced Audio Distribution Profile), it can have a higher compression rate and better sound quality, and can also perform at low data rates. Can achieve the effect of sound quality enhancement. It should be noted that, for the purpose of making the device more compatible, the first Bluetooth audio device 10 can adopt dual-mode Bluetooth technology, that is, it supports both classic Bluetooth connection and LE Audio Bluetooth connection.
  • the first Bluetooth audio device 10 At least one classic Bluetooth link and at least one LE Audio Bluetooth link can be established with the terminal device 20 at the same time.
  • the first Bluetooth audio device 10 needs to establish a LE Audio Bluetooth connection with the terminal device 20
  • the terminal After receiving the LE Audio broadcast message, the device 20 can automatically or manually send a low-power Bluetooth audio connection request to the first Bluetooth audio device 10, and then the first Bluetooth audio device 10 can respond to the above-mentioned Bluetooth low energy connection request. Audio connection request to establish a LE Audio Bluetooth connection with the terminal device 20.
  • Figure 2 shows the basic framework of a Bluetooth protocol, suitable for devices that support the establishment of classic Bluetooth connections and/or LE Audio Bluetooth connections.
  • the framework may include but is not limited to application layer (Profiles), host layer (Host) and control layer (Controller).
  • the application layer can include various application specifications (profiles) defined by Bluetooth SIG, such as the above-mentioned A2DP, HFP (Hands-Free Profile, phone hands-free profile), HDP (Health Device Profile, health device profile), etc., that is, for Each application can define its own corresponding message format and application rules to suit various application scenarios.
  • profiles defined by Bluetooth SIG, such as the above-mentioned A2DP, HFP (Hands-Free Profile, phone hands-free profile), HDP (Health Device Profile, health device profile), etc.
  • the host layer defines the core protocols in the framework, which can include but are not limited to Bluetooth's basic Service Discovery Protocol (Service Discover Protocol, SDP), Logical Link Control and Adaptation Protocol (Logical Link Control and Adaptation Protocol, L2CAP )wait.
  • the control layer defines the underlying hardware parts, such as Host Controller Interface (HCI), Radio Frequency (RF), Baseband (BB), and links based on Link Management Protocol (LMP). Road management, etc.
  • the first Bluetooth audio device 10 that supports LE Audio Bluetooth connection there can be a maximum number of connections based on their respective performance configurations.
  • its maximum number of connections is 1, that is, it is only allowed to maintain a LE Audio Bluetooth connection with one terminal device 20 at the same time, and when the first Bluetooth audio When the device 10 has established a LE Audio Bluetooth connection with a certain terminal device 20, it needs to disconnect the LE Audio Bluetooth connection with the terminal device 20 before it can establish a LE Audio Bluetooth connection with a new terminal device 20.
  • the maximum number of connections is greater than 1, that is, it is allowed to maintain LE Audio Bluetooth connections with multiple terminal devices 20 at the same time, and when communicating with the first Bluetooth
  • the number of terminal devices 20 that the audio device 10 establishes a LE Audio Bluetooth connection does not reach the maximum connectable number, it may be allowed to establish a LE Audio Bluetooth connection with a new terminal device 20;
  • the number of terminal devices 20 has reached the maximum connectable number, it is necessary to disconnect the LE Audio Bluetooth connections with some terminal devices 20 before establishing a LE Audio Bluetooth connection with a new terminal device 20 .
  • the identification information of the terminal device 20 can be obtained based on the security management protocol (Security Manager Protocol, SMP) between the first Bluetooth audio device 10 and the terminal device 20, and then the third A Bluetooth audio device 10 can send an LE Audio broadcast message carrying the identification information.
  • the above-mentioned LE Audio broadcast message can be used to instruct the terminal device 20 to initiate a LE Audio Bluetooth connection request to the first Bluetooth audio device 10, and the first Bluetooth audio device 10 can respond to the LE Audio Bluetooth connection request.
  • the first Bluetooth audio device 10 can receive the low-power Bluetooth audio connection request sent by the terminal device 20, and respond to the low-power Bluetooth audio connection request to establish a LE Audio Bluetooth connection with the terminal device 20.
  • the first Bluetooth audio device 10 can quickly and accurately obtain the identification information of the terminal device 20 by performing relevant interactive operations based on the security management protocol with the terminal device 20 on the classic Bluetooth link, and can further obtain the identification information of the terminal device 20 based on the classic Bluetooth link.
  • the obtained identification information sends a "directed connectable" LE Audio broadcast message to the terminal device 20, so that the terminal device 20 can communicate with the above-mentioned first Bluetooth audio under the trigger of this targeted LE Audio broadcast message.
  • Device 10 establishes a LE Audio Bluetooth connection.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the first Bluetooth audio device 10 can only be responded to by the terminal device 20 expected by the user, and other devices with different identification information receive the above-mentioned LE Audio broadcast message.
  • the first Bluetooth audio device 10 can be prioritized to establish a LE Audio Bluetooth connection with the terminal device 20, and the first Bluetooth audio device 10 can be prevented from being mistakenly connected to other devices not selected by the user, which is beneficial to reducing the risk of the first Bluetooth audio device 10
  • the possibility of mistakenly connecting the terminal device effectively improves the accuracy and flexibility of the communication connection of the first Bluetooth audio device 10 .
  • the above-mentioned first Bluetooth audio device 10 may include various types of Bluetooth headsets, Bluetooth speakers, etc., and may especially include TWS (True Wireless Stereo) headsets.
  • the above-mentioned terminal device 20 may include various devices or systems with Bluetooth communication functions, such as mobile phones, smart wearable devices, vehicle-mounted terminals, tablet computers, PC (Personal Computer, personal computer), PDA (Personal Digital Assistant, Personal digital assistant), etc., are not specifically limited in the embodiments of this application.
  • the first Bluetooth audio device 10 shown in FIG. 1A and FIG. 1B is a Bluetooth headset
  • the terminal device 20 is a mobile phone.
  • the first Bluetooth audio device 10 including an earphone device as an example, in some embodiments, as shown in FIG. 1A , the first Bluetooth audio device 10 may be a single earphone. In other embodiments, as shown in FIG. 1B , the application scenario may also include a second Bluetooth audio device 30 , and the second Bluetooth audio device 30 and the first Bluetooth audio device 10 may belong to the same Bluetooth device set.
  • one of the first Bluetooth audio device 10 and the second Bluetooth audio device 30 can establish a classic Bluetooth connection with the terminal device 20 (which can be understood as the current main headset or main device), so that the first Bluetooth audio
  • the device 10 and the second Bluetooth audio device 30 can be distinguished as master and slave to achieve classic Bluetooth connection with the terminal device 20; at the same time, the first Bluetooth audio device 10 and the second Bluetooth audio device 30 can also be established with the terminal device 20 respectively.
  • LE Audio Bluetooth connection the first Bluetooth audio device 10 and the second Bluetooth audio device 30 may not distinguish the master-slave relationship, so that the first Bluetooth audio device 10 and the second Bluetooth audio device 30 can achieve classic communication with the terminal device 20 at the same time.
  • Bluetooth connectivity and LE Audio Bluetooth connectivity may not distinguish the master-slave relationship, so that the first Bluetooth audio device 10 and the second Bluetooth audio device 30 can achieve classic communication with the terminal device 20 at the same time.
  • the above-mentioned Bluetooth audio device may also include two or more devices in the same group, that is, it may also include other Bluetooth devices except the first Bluetooth audio device 10 and the second Bluetooth audio device 30.
  • Each device in the same group and the terminal device The method of establishing a Bluetooth connection 20 may be similar to the method of establishing a Bluetooth connection between the first Bluetooth audio device 10 and the second Bluetooth audio device 30 and the terminal device 20 .
  • Figure 3 is a schematic flowchart of a device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned first Bluetooth audio device. As shown in Figure 3, the device connection method may include the following steps:
  • the first Bluetooth audio device in order to establish a Bluetooth connection between the first Bluetooth audio device and the terminal device that the user intends to connect to (i.e., the first target device designated by the user), especially including establishing a LE Audio Bluetooth connection, the first Bluetooth audio device
  • the identification information of the first target device can be obtained first, and then in subsequent steps, a "directed connectable" LE Audio broadcast message for the first target device can be sent based on the identification information to specify that the first target device can communicate with the first target device.
  • the first Bluetooth audio device establishes a LE Audio Bluetooth connection and avoids false responses from other devices in a connectable state, thereby improving the accuracy of the communication connection of the first Bluetooth audio device.
  • the identification information of the first target device may include the device address identification information of the first target device (such as the device Bluetooth address, including classic Bluetooth address and BLE address, etc.), device identity identification information, device name identification information, device Model identification information, etc.
  • the first Bluetooth audio device can confirm that the only corresponding terminal device is the above-mentioned first target device, and thus can establish a Bluetooth connection with the first target device in a targeted manner based on the identification information.
  • the above-mentioned first Bluetooth audio device can adopt dual-mode Bluetooth technology, that is, the first Bluetooth audio device can support classic Bluetooth connection and LE Audio Bluetooth connection at the same time.
  • the first Bluetooth audio device can first establish a classic Bluetooth connection with the first target device, and when the classic Bluetooth connection has been established, the first Bluetooth audio device can communicate with the first Bluetooth audio device by configuring the classic Bluetooth link.
  • security management protocol between target devices, and perform interactive operations (i.e., SMP operations) related to the security management protocol, obtain identification information of the first target device, and apply the identification information to establish the first Bluetooth audio device and the third LE Audio Bluetooth connection between a target device.
  • the above-mentioned security management protocol can be used to manage the pairing, authentication, encryption and other Bluetooth device interaction operations specified in the protocol between the first Bluetooth audio device and the first target device, including realizing the transfer of designated private information, etc., in order to Assist in realizing the directional connection between the first Bluetooth audio device and the first target device.
  • the first Bluetooth audio device may also only support LE Audio Bluetooth connection (ie, LE single-mode Bluetooth), and may also implement the device connection method disclosed in the embodiments of this application.
  • the first Bluetooth audio device can establish a LE Bluetooth connection with the first target device, configure a security management protocol between the first Bluetooth audio device and the first target device on the LE Bluetooth link, and execute the Interaction operations related to the security management protocol (ie, SMP operations) obtain the identification information of the first target device. On this basis, the first Bluetooth audio device can use the identification information to further establish a LE Audio Bluetooth connection with the first target device.
  • the above SMP operation may be performed on a Bluetooth link (including a classic Bluetooth link or a LE Bluetooth link) between the first Bluetooth audio device and the first target device.
  • a BR/EDR channel can be configured between the first Bluetooth audio device and the first target device, which means that the first Bluetooth audio device and the first target device
  • a target device can establish a Bluetooth physical link such as ACL (Asynchronous Connection Less, asynchronous linkless) or SCO (Synchronous Connection Oriented, synchronous directional link) based on BR/EDR technology, or it can also indicate that the two establish an upper-layer protocol connection, such as A2DP (Advanced Audio Distribution Profile, advanced audio transmission specification), HFP (Hands-Free-Profile, hands-free specification), etc., or intermediary protocol SPP (Serial Port Profile, serial port protocol), etc.
  • A2DP Advanced Audio Distribution Profile, advanced audio transmission specification
  • HFP Highands-Free-Profile, hands-free specification
  • intermediary protocol SPP Serial Port Profile, serial port
  • the above SMP operation can be implemented based on the ACL link between the first Bluetooth audio device and the first target device, and the relevant interactive information transfer is completed during the process of establishing a classic Bluetooth connection between the two.
  • the first Bluetooth audio device can receive the security management information sent by the first target device through the SMP operation, and then can determine the identification information of the first target device based on the security management information.
  • the above security management information may only include the IRK (Identity Resolving Key, Bluetooth device address resolution key) corresponding to the first target device, so that after receiving the IRK, the first Bluetooth audio device can directly The IRK is calculated to obtain the identification information of the first target device, which may especially include the BLE address of the first target device, etc.
  • the above-mentioned security management information may also include an encrypted data packet carrying the above-mentioned IRK, for example, through STK/LTK (Short Term Key/Long Term Key) generated in the SMP operation. After encrypting the IRK the resulting packet.
  • the first Bluetooth audio device can parse it to obtain the IRK of the corresponding first target device, and then calculate the IRK to obtain the identification information of the first target device, which may especially include the identification information for the first target device. A BLE address of the target device, etc.
  • the above-mentioned SMP operation may include four main steps: exchanging information (S1), generating encryption keys (S2), encrypting connections (S3), and distributing IRKs (S4).
  • the step of exchanging information (S1) is mainly used to exchange relevant pairing parameters or feature information (Pairing Feature) between the first Bluetooth audio device and the first target device, and then based on different pairing situations, different processes can be adopted.
  • S1 is mainly used to exchange relevant pairing parameters or feature information (Pairing Feature) between the first Bluetooth audio device and the first target device, and then based on different pairing situations, different processes can be adopted.
  • the first target device can encrypt and transmit its corresponding IRK to the first Bluetooth audio device, so that the first Bluetooth audio device can securely obtain the IRK of the first target device for use.
  • To calculate its identification information such as device Bluetooth address, etc.
  • the low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device.
  • the first Bluetooth audio device after acquiring the identification information of the first target device, can generate and send an LE Audio broadcast message corresponding to the identification information based on the identification information, so that the first target device After receiving the LE Audio broadcast message, the LE Audio Bluetooth connection can be established with the first Bluetooth audio device after confirming that the LE Audio broadcast message corresponds to its own identification information.
  • the first Bluetooth audio device can generate an orientation for the first target device based on the identification information.
  • Connectable broadcast message ADV_DIRECT_IND.
  • the broadcast message can be a "directed connectable" LE Audio broadcast message. It can be understood that for the identification information of different terminal devices, the LE Audio broadcast messages generated and sent by the first Bluetooth audio device may also be different to point to the corresponding terminal devices.
  • the first Bluetooth audio device can send the above-mentioned LE Audio broadcast message by broadcasting, thereby instructing the terminal device that receives the LE Audio broadcast message to judge itself. If it determines that it is the LE Audio broadcast message If the specified first target device is the first target device, the first target device can send a corresponding low-power Bluetooth audio connection request to the first Bluetooth audio device, so that the first Bluetooth audio device establishes a LE Audio Bluetooth connection with the first target device. .
  • the first target device can determine the LE Audio broadcast message after receiving the LE Audio broadcast message.
  • the identification information corresponding to the broadcast message matches the identification information of the first target device itself, and then in response to the LE Audio broadcast message, a low-power Bluetooth audio connection request can be sent to the first Bluetooth audio device (i.e., a low-power Bluetooth audio connection request is initiated). Audio connection, or initiating a low-power Bluetooth audio connection request).
  • the first Bluetooth audio device can receive the above-mentioned low-power Bluetooth audio connection request.
  • the low-power Bluetooth audio connection request can specifically refer to the request instruction data packet, and accordingly establish a targeted connection with the first target device. LE Audio Bluetooth connection.
  • the second target device with different identification information can determine that the identification information corresponding to the LE Audio broadcast message does not match the identification information of the second target device itself, so that it can Not responding to this LE Audio broadcast message (for example, directly discarding the broadcast data packet corresponding to the LE Audio broadcast message, etc.) effectively avoids misconnection between the first Bluetooth audio device and the second target device.
  • the first Bluetooth audio device may respond to the low-power Bluetooth audio connection request and communicate with the first target in a targeted manner.
  • the device establishes a LE Audio Bluetooth connection, which will not be described here.
  • the first Bluetooth audio device can quickly and accurately obtain the identification information of the first target device by performing SMP operations with the first target device on the classic Bluetooth link. Then, based on the identification information of the first target device, a "directed connectable" LE Audio broadcast message can be sent to the first target device, so that the first target device can communicate with the first target device under the trigger of the targeted LE Audio broadcast message.
  • the above-mentioned first Bluetooth audio device establishes a LE Audio Bluetooth connection.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the first Bluetooth audio device can only be responded to by the first target device expected by the user, and the second target device with different identification information receives the above-mentioned LE Audio broadcast message.
  • the first Bluetooth audio device can be prioritized to establish a LE Audio Bluetooth connection with the first target device, and the first Bluetooth audio device can be prevented from being mistakenly connected to the second target device, which is beneficial to reducing the risk of the first Bluetooth audio device being mistakenly connected to the terminal device. possibility, effectively improving the accuracy and flexibility of communication connections for the first Bluetooth audio device.
  • Figure 4 is a schematic flowchart of another device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned first Bluetooth audio device. As shown in Figure 4, the device connection method may include the following steps:
  • the first Bluetooth audio device obtains the identification information of the first target device based on the security management protocol between it and the first target device. Specifically, it may be through the security information sent to the first target device. Obtained by processing management information.
  • the above security management information may only include the Bluetooth device address resolution key IRK corresponding to the first target device, or may include an encrypted data packet carrying the above IRK, etc.
  • an SMP operation based on the security management protocol can be performed between the first Bluetooth audio device and the first target device, so that the first Bluetooth audio device can obtain the security management sent by the first target device through the SMP operation.
  • information For example, when a first Bluetooth audio device establishes a classic Bluetooth connection with a first target device, the connection between the first Bluetooth audio device and the first target device can be configured on the classic Bluetooth link between the two. Security Management Protocol, so that both can perform SMP operations based on this classic Bluetooth link and pass their respective IRKs to each other.
  • the first Bluetooth audio device can receive the security management information sent by the first target device based on the above security management protocol, and then can directly obtain it based on the security management information. Or parse it to obtain the IRK corresponding to the first target device, so that in subsequent steps, based on the relevant parsing and calculation rules for the IRK, the identification information for the first target device can be calculated from the IRK.
  • the identification information of the first target device may include the device Bluetooth address of the first target device.
  • the device Bluetooth address may include an RPA (Resolvable Private Address, resolvable private address) type BLE address
  • the first Bluetooth audio device may generate a "directed connectable" LE Audio broadcast message based on the BLE address to indicate The first target device that receives the LE Audio broadcast message establishes a corresponding LE Audio Bluetooth connection with the first Bluetooth audio device after confirming that it points to itself.
  • the above-mentioned Bluetooth device address may include two parts, one part of which may include a random number prand used for hash operation, and the other part may be obtained by hashing the random number prand with the above-mentioned IRK.
  • the Bluetooth device address can include 48 bits, of which the high 24 bits can include 22 bits of random number prand and 2 bits of designated bits (such as 10, 01, etc., which can be used for identification, verification, etc.), and the low 24 bits can include It is obtained by the first Bluetooth audio device performing a hash operation based on the above-mentioned 22-bit random number prand and the IRK corresponding to the first target device. On this basis, the first Bluetooth audio device can generate a LE Audio broadcast message containing the Bluetooth address of the device in subsequent steps, and send the LE Audio broadcast message by broadcasting.
  • the first Bluetooth audio device can further generate an LE Audio broadcast message carrying the Bluetooth address of the device based on the device Bluetooth address it generates for the first target device.
  • the LE Audio broadcast message may also include identification information of the first Bluetooth audio device itself, such as device address identification information, device identity identification information, device name identification information, device model identification information, etc., for receiving the After confirming that the terminal device of the LE Audio broadcast message is the first target device specified by the LE Audio broadcast message, the terminal device can initiate a low-power Bluetooth audio connection to the above-mentioned first Bluetooth audio device accordingly.
  • the first target device after receiving the above LE Audio broadcast message, can obtain the Bluetooth address of the device it carries, and further extract the random number prand therein. On this basis, the first target device can hash the random number prand with its own IRK. If the verification Bluetooth address obtained matches the device Bluetooth address carried in the above LE Audio broadcast message, then it can Confirm that the above LE Audio broadcast message points to the first target device.
  • the second target device after the second target device receives the above-mentioned LE Audio broadcast message, it can also extract the random number prand in the Bluetooth address of the device it carries, and perform a hash operation on the random number prand and its own IRK. , if the verification Bluetooth address obtained thereby does not match the device Bluetooth address carried in the above-mentioned LE Audio broadcast message, it can be confirmed that the above-mentioned LE Audio broadcast message is not directed to the second target device. On this basis, the above-mentioned matching first target device can initiate a low-power Bluetooth audio connection to the first Bluetooth audio device, while the unmatched second target device can ignore this LE Audio broadcast message, thereby achieving the first Directed connections for Bluetooth audio devices.
  • step 408 is similar to the above-mentioned step 304. It should be noted that, after receiving the LE Audio broadcast message carrying the Bluetooth address of the above-mentioned device, if the terminal device determines that it is the first target device specified by the LE Audio broadcast message, the first target device can send a message to the first target device. The Bluetooth audio device sends a corresponding low-power Bluetooth audio connection request, so that the first Bluetooth audio device establishes a LE Audio Bluetooth connection with the first target device.
  • step 410 and step 412 are similar to the above-mentioned step 306 and step 308, and will not be described again here.
  • the first Bluetooth audio device can send a "directional connectable" message to the first target device based on the identification information of the first target device that it quickly and accurately obtains through the SMP operation.
  • LE Audio broadcast message so that the first target device can establish a LE Audio Bluetooth connection with the above-mentioned first Bluetooth audio device under the trigger of the targeted LE Audio broadcast message.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the first Bluetooth audio device can only be responded to by the first target device expected by the user, thereby avoiding misconnection between the first Bluetooth audio device and the second target device.
  • the first Bluetooth audio device uses the IRK of the first target device to calculate the RPA type BLE address, which can ensure that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the first target device, thereby being able to give the above LE Audio
  • the "directionally connectable" feature of the broadcast message is conducive to improving the accuracy and reliability of the first Bluetooth audio device's directional connection to the terminal device.
  • Figure 5 is a schematic flow chart of yet another device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned first Bluetooth audio device.
  • the first Bluetooth audio device can be connected to a second Bluetooth audio device.
  • a communication connection is established, wherein the second Bluetooth audio device and the first Bluetooth audio device may belong to the same Bluetooth device set.
  • the device connection method may include the following steps:
  • step 502 is similar to the above-mentioned step 402.
  • the first Bluetooth audio device and the second Bluetooth audio device that have established a classic Bluetooth connection can respectively establish LE Audio Bluetooth connections with the first target device to improve the flexibility of communication connections between the Bluetooth audio devices.
  • the page packet may be issued by the first target device, the first Bluetooth audio device or the second Bluetooth audio device in different scenarios), or in response to the classic Bluetooth connection request
  • the page scan mode can be turned on by the first target device, the second Bluetooth audio device, or the second Bluetooth audio device to receive the page packet
  • the first Bluetooth audio device establishes a classic Bluetooth connection with the first target device
  • a device in the same group of the first Bluetooth audio device i.e., the second Bluetooth audio device
  • the first Bluetooth audio device and the second Bluetooth audio device establish a classic Bluetooth connection with the first target device at the same time.
  • the first Bluetooth audio device and/or the second Bluetooth audio device can be used in subsequent steps. Synchronize the security management information sent by the first target device, or directly synchronize the identification information of the first target device determined by the security management information, and turn on the respective LE Audio broadcast to send the above identification respectively.
  • the LE Audio broadcast message corresponding to the information can then establish a LE Audio Bluetooth connection with the first target device respectively.
  • the first Bluetooth audio device and the second Bluetooth audio device may have a master-slave relationship.
  • the first Bluetooth audio device may As the master earphone, the second Bluetooth audio device can be the slave earphone.
  • the first Bluetooth audio device as the master earphone can establish a classic Bluetooth connection with the first target device, and based on the first Bluetooth audio device and the first target device
  • the security management protocol between the two devices receives the security management information sent by the first target device.
  • the second Bluetooth audio device can synchronously obtain the above-mentioned security management information through the classic Bluetooth connection with the first Bluetooth audio device, or synchronously obtain the identity of the first target device determined by the security management information. information.
  • step 504 is similar to the above-mentioned step 404 and step 406.
  • the identification information of the first target device may include the device Bluetooth address of the first target device, that is, the first Bluetooth audio device may send an LE Audio broadcast carrying the device Bluetooth address. message, the LE Audio broadcast message can be used to instruct the first target device to initiate a low-power Bluetooth audio connection to the first Bluetooth audio device.
  • the first Bluetooth audio device may, after determining the identification information of the first target device based on the above security management information, actively send the identification information to the second Bluetooth audio device to implement the first Bluetooth audio device. Synchronize information with the second Bluetooth audio device.
  • the above-mentioned identification information may include the device Bluetooth address of the first target device, so that the second Bluetooth audio device may also send an LE Audio broadcast message carrying the Bluetooth address of the device. The LE Audio broadcast message may be used to instruct the first target device to The second Bluetooth audio device initiates a low-power Bluetooth audio connection.
  • the second Bluetooth audio device can also use monitoring data to obtain the identification information of the first target device through monitoring, so as to realize the information exchange between the first Bluetooth audio device and the second Bluetooth audio device. Synchronize. It should be noted that since the process of calculating the security management information sent by the first target device to obtain the identification information of the first target device is completed within the first Bluetooth audio device, the second Bluetooth audio device does not The monitoring directly obtains the above identification information, but obtains the above security management information (that is, the monitoring data may include the security management information), and the second Bluetooth audio device performs similar calculations on the security management information to obtain the first target device's Identification information. For example, the first Bluetooth audio device may receive the security management information sent by the first target device through the classic Bluetooth link between it and the first target device.
  • the security management information may include the IRK of the first target device. , so that the first Bluetooth audio device can use the specified random number prand_1 to calculate the IRK and obtain the BLE address for the first target device.
  • the second Bluetooth audio device can monitor the classic Bluetooth link between the first Bluetooth audio device and the first target device, and obtain the security management information sent by the first target device based on the monitoring data, and then can Using another specified random number prand_2 (which may or may not be the same as the above prand_1), the IRK contained in the security management information is calculated to obtain the BLE address of the first target device.
  • the possibility of audio equipment mistakenly connecting to terminal equipment effectively improves the accuracy and flexibility of communication connections for Bluetooth audio equipment.
  • the first Bluetooth audio device and the second Bluetooth audio device can establish LE Audio Bluetooth with the first target device respectively. connection to improve the flexibility of communication connections for Bluetooth audio devices, and also help improve the reliability of audio data transmission by each Bluetooth audio device based on BLE technology.
  • Figure 6 is a schematic flowchart of yet another device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned second Bluetooth audio device. As shown in Figure 6, the device connection method may include the following steps:
  • step 606, step 608 and step 610 are similar to the above-mentioned step 304, step 306 and step 308 respectively.
  • the second Bluetooth audio device can use the same method as the first Bluetooth audio device to send a "directed connectable" LE Audio broadcast message to the first target device to establish a LE Audio Bluetooth connection with the first target device in a targeted manner.
  • the above-mentioned first Bluetooth audio device can directly send the identification information to the second Bluetooth device after it successfully obtains the identification information of the first target device according to the security management information of the first target device. Audio equipment.
  • the second Bluetooth audio device can directly obtain the identification information of the first target device by receiving, that is, the second Bluetooth audio device can receive the identification information of the first target device sent by the first Bluetooth audio device, Then, the above steps 606, 608 and 610 can be executed to establish a low-power Bluetooth audio connection with the first target device.
  • FIG. 7 is a schematic flowchart of a device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned terminal device (ie, the first target device in the above-mentioned embodiment). As shown in Figure 7, the device connection method may include the following steps:
  • the terminal device can configure the connection between the first Bluetooth audio device and the terminal device through a Bluetooth link (including a classic Bluetooth link or an LE Bluetooth link) between the terminal device and the first Bluetooth audio device.
  • Security management protocol so that both the terminal device and the first Bluetooth audio device can perform SMP operations based on the security management protocol on the Bluetooth link between the two, so that the SMP operation can be used to transmit the above security management information.
  • the above-mentioned security management protocol can be used to manage the pairing, authentication, encryption and other Bluetooth device interaction operations specified in the protocol between Bluetooth audio devices and terminal devices, including the transfer of designated private information, etc., to assist in the implementation of Bluetooth audio The device's directed connection to this end device.
  • the terminal device can send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device through an SMP operation based on the above security management protocol.
  • the above identification information may include the device Bluetooth address of the terminal device, and the device Bluetooth address may be determined by the Bluetooth device address resolution key IRK corresponding to the terminal device, then the above security management information may only include the device corresponding to the terminal device.
  • the IRK may also include encrypted data packets containing the above IRK, etc.
  • the first Bluetooth audio device can extract the IRK corresponding to the terminal device, and further calculate the device Bluetooth address for the terminal device according to the calculation rules corresponding to the security management information, and then can generate and send the Bluetooth address of the terminal device. "Directed Connectable" LE Audio broadcast message of the device's Bluetooth address.
  • the first Bluetooth audio device can obtain the identification information of the terminal device (such as the device Bluetooth address of the terminal device) based on the security management information. etc.), and then the LE Audio broadcast message corresponding to the identification information can be sent. On this basis, the terminal device can receive the above-mentioned LE Audio broadcast message, and judge the LE Audio broadcast message in subsequent steps. If it is confirmed that it points to the terminal device itself, it can initiate a request to the first Bluetooth audio device accordingly. LE Audio Bluetooth connection.
  • the first Bluetooth Low Energy broadcast message corresponds to the identification information of the terminal device
  • in response to the first Bluetooth Low Energy broadcast message send a Bluetooth Low Energy audio connection request to the first Bluetooth audio device.
  • the first Bluetooth audio device responds to the low-power Bluetooth audio connection request and establishes a low-power Bluetooth audio connection with the terminal device.
  • the terminal device when the terminal device receives the first LE Audio broadcast message of "directional connectability" sent by the first Bluetooth audio device, it can determine whether the first LE Audio broadcast message is directed to the terminal device itself, To determine whether a LE Audio Bluetooth connection needs to be established with the first Bluetooth audio device.
  • the terminal device can calculate the security management information it sends and the target Bluetooth address according to the calculation rules corresponding to the security management information to obtain the verification Bluetooth address. .
  • the terminal device can perform a hash operation on the IRK of the terminal device contained in the above security management information and the random number prand extracted from the target Bluetooth address to obtain the corresponding verification Bluetooth address.
  • the terminal device can compare the above-mentioned target Bluetooth address and the verification Bluetooth address. If the target Bluetooth address matches the verification Bluetooth address, it can be determined that the above-mentioned first LE Audio broadcast message corresponds to the device Bluetooth address of the terminal device. That is, it can be confirmed that the above-mentioned first LE Audio broadcast message is directed to the terminal device. On this basis, the terminal device can respond to the above-mentioned first LE Audio broadcast message and send a low-power Bluetooth audio connection request to the first Bluetooth audio device to establish a LE Audio Bluetooth connection with the first Bluetooth audio device.
  • a second Bluetooth audio device that belongs to the same Bluetooth device set as the above-mentioned first Bluetooth audio device can also establish a LE Audio Bluetooth connection with the terminal device.
  • the first Bluetooth audio device may determine the identification information of the terminal device based on the security management information, Information synchronization is performed with the second Bluetooth audio device so that the second Bluetooth audio device can obtain the identification information of the above-mentioned terminal device.
  • the first Bluetooth audio device can actively send the identification information to the second Bluetooth audio device, so that the second Bluetooth audio device can also similarly send the identification information corresponding to the identification information.
  • the second LE Audio broadcast message after determining the above identification information, the first Bluetooth audio device can actively send the identification information to the second Bluetooth audio device, so that the second Bluetooth audio device can also similarly send the identification information corresponding to the identification information.
  • the second LE Audio broadcast message after determining the above identification information, the first Bluetooth audio device can actively send the identification information to the second Bluetooth audio device, so that the second Bluetooth audio device can also similarly send the identification information corresponding to the identification information.
  • the second Bluetooth audio device can monitor the Bluetooth link between the first Bluetooth audio device and the terminal device, and independently determine the identification information of the terminal device based on the security management information obtained by monitoring. , and then the second LE Audio broadcast message corresponding to the identification information can be sent.
  • the terminal device can respectively determine whether the LE Audio broadcast message sent by the first Bluetooth audio device and the second Bluetooth audio device corresponds to the identification information of the terminal device, and confirm the sending of the corresponding LE Audio broadcast message.
  • the terminal i.e., the above-mentioned first Bluetooth audio device and/or the second Bluetooth audio device
  • sends a corresponding low-power Bluetooth audio connection request so that the above-mentioned first Bluetooth audio device and/or the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request.
  • Power consumption Bluetooth audio connection request to establish a LE Audio Bluetooth connection with the terminal device.
  • the terminal device may also prioritize whether the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set. , and only when the two belong to the same Bluetooth device set, the LE Audio Bluetooth connection is allowed to be established with the second Bluetooth audio device to avoid mistakenly connecting other Bluetooth audio devices belonging to different sets.
  • the terminal device can determine whether the corresponding second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set based on the above-mentioned second LE Audio broadcast message and the first LE Audio broadcast message. For example, after receiving the first LE Audio broadcast message, the terminal device can obtain the device identification (such as IRK, device Bluetooth address, product identification code, etc.) of the corresponding first Bluetooth audio device, and add it to the candidate list. list or whitelist. Then, after receiving the second LE Audio broadcast message, the terminal device can obtain the same type of device identification for the second Bluetooth audio device and compare it with the device identification in the above candidate list or white list.
  • the device identification such as IRK, device Bluetooth address, product identification code, etc.
  • the terminal device can determine that the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set, and can then determine If the second LE Audio broadcast message also corresponds to the identification information of the terminal device, further send a low-power Bluetooth audio connection request to the second Bluetooth audio device, so that the second Bluetooth audio device responds to the low-power Bluetooth audio connection request. Power consumption Bluetooth audio connection request to establish a LE Audio Bluetooth connection with the terminal device.
  • the terminal device can perform SMP operations with the Bluetooth audio device, so that the Bluetooth audio device can quickly and accurately obtain the identification information of the terminal device and send it to the terminal device.
  • Send a "directed connectable" LE Audio broadcast message so that the terminal device can establish a LE Audio Bluetooth connection with the above-mentioned Bluetooth audio device when triggered by the targeted LE Audio broadcast message.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the terminal device expected by the user, thereby preventing the Bluetooth audio device from being mistakenly connected to other devices in a connectable state, and helping to reduce the risk of The possibility of Bluetooth audio devices mistakenly connecting to terminal devices effectively improves the accuracy and flexibility of communication connections for Bluetooth audio devices.
  • the Bluetooth audio device can calculate the corresponding RPA type BLE address, thereby ensuring that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the terminal device. It is beneficial to improve the accuracy and reliability of directional connection of Bluetooth audio devices to terminal devices.
  • the terminal device can establish LE Audio Bluetooth connections with the first Bluetooth audio device and the second Bluetooth audio device respectively to improve
  • the flexibility of communication and connection between terminal devices and Bluetooth audio devices also helps improve the reliability of audio data transmission by each headset based on BLE technology.
  • Figure 8 is a sequence diagram of a device connection method disclosed in an embodiment of the present application. This method can be applied to Bluetooth communication composed of the above-mentioned first Bluetooth audio device and terminal device (ie, the first target device). in the system. As shown in Figure 8, the device connection method may include the following steps:
  • the first target device When the first Bluetooth audio device establishes a classic Bluetooth connection with the first target device, the first target device sends a request to the first Bluetooth device based on the security management protocol between the first Bluetooth audio device and the first target device. The audio device sends security management information corresponding to the identification information of the first target device.
  • the above security management information may include the IRK of the first target device, that is, the first target device may transmit its IRK to the first Bluetooth audio device through an SMP operation based on the security management protocol.
  • the first Bluetooth audio device receives the security management information sent by the first target device based on the security management protocol between the first Bluetooth audio device and the first target device, and determines the first Bluetooth audio device based on the security management information. Identification information of the target device.
  • the first Bluetooth audio device sends the first low-power Bluetooth broadcast message corresponding to the above identification information.
  • the above-mentioned identification information may include the device Bluetooth address
  • the first Bluetooth audio device may calculate the security management information according to the calculation rules corresponding to the above-mentioned security management information (that is, calculate the IRK of the first target device), To generate the device Bluetooth address of the first target device, and then generate and send the LE Audio broadcast message carrying the device Bluetooth address according to the device Bluetooth address.
  • the first target device receives the first Bluetooth low energy broadcast message, and when it is determined that the first Bluetooth low energy broadcast message corresponds to the identification information of the first target device, responds to the first Bluetooth low energy broadcast message. Broadcast message to send low-power Bluetooth audio connection request to the first Bluetooth audio device.
  • the first Bluetooth audio device receives the low-power Bluetooth audio connection request sent by the first target device, and responds to the low-power Bluetooth audio connection request to establish a low-power Bluetooth audio connection with the first target device.
  • the first Bluetooth audio device may also establish a Bluetooth connection with another device (which may be recorded as the second target device).
  • the device connection method may also include the following steps:
  • the first Bluetooth audio device disconnects the Bluetooth connection from the second target device, and the identification information of the second target device is different from the identification information of the first target device.
  • the above-mentioned Bluetooth connection may include a classic Bluetooth connection and/or a LE Audio Bluetooth connection, which is not specifically limited in the embodiments of this application.
  • the first Bluetooth audio device enters the pairing state.
  • the above-mentioned pairing state means that the first Bluetooth audio device is in a discoverable and connectable state. In the pairing state, the first Bluetooth audio device can stop sending any LE Audio broadcast messages.
  • the first target device sends a classic Bluetooth connection request to the first Bluetooth audio device.
  • the first target device can discover the first Bluetooth audio device in the paired state by scanning, and automatically or manually confirm by the user to initiate a classic Bluetooth connection to the first Bluetooth audio device.
  • the first Bluetooth audio device can be added to the whitelist of the first target device to facilitate subsequent rapid connection back. , reconnect and other operations, and also help to assist in verification when establishing a LE Audio Bluetooth connection with the first Bluetooth audio device.
  • the first target device may only add the first Bluetooth audio device to the whitelist of the first target device when it initiates a LE Audio Bluetooth connection to the first Bluetooth audio device, so that it can be maintained through maintenance
  • the above whitelist speeds up the subsequent process of confirming whether the LE Audio broadcast message sent by the first Bluetooth audio device corresponds to the identification information of the first target device, and helps to improve the establishment of a Bluetooth connection between the first Bluetooth audio device and the terminal device. , especially the efficiency of establishing LE Audio Bluetooth connections.
  • the first Bluetooth audio device receives the classic Bluetooth connection request sent by the first target device, and responds to the classic Bluetooth connection request to establish a classic Bluetooth connection with the first target device.
  • the Bluetooth audio device can establish a LE Audio Bluetooth connection with the first target device expected by the user in a directional manner.
  • the second target device when the above-mentioned second target device receives the LE Audio broadcast message corresponding to the identification information of the first target device sent by the first Bluetooth audio device, it may not respond and discard the LE Audio broadcast message, thereby effectively Avoid misconnection between the first Bluetooth audio device and the second target device.
  • Figure 9 is a sequence diagram of another device connection method disclosed in an embodiment of the present application. This method can be applied to the first Bluetooth audio device, the second Bluetooth audio device and the terminal device (i.e., the first Bluetooth audio device).
  • the first Bluetooth audio device and the second Bluetooth audio device may belong to the same Bluetooth device set.
  • the first Bluetooth audio device may be the master Bluetooth audio device
  • the second Bluetooth audio device may be the slave Bluetooth audio device.
  • the device connection method may include the following steps:
  • the first target device sends security management information corresponding to the identification information of the first target device to the first Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the first target device.
  • the first Bluetooth audio device receives the security management information sent by the first target device based on the security management protocol between the first Bluetooth audio device and the first target device, and determines the first Bluetooth audio device based on the security management information. Identification information of the target device.
  • the above security management information may include the IRK of the first target device, that is, the first target device may transmit its IRK to the first Bluetooth audio device through an SMP operation based on the security management protocol.
  • the above-mentioned identification information may include the Bluetooth address of the device, and the first Bluetooth audio device may calculate the security management information (that is, calculate the IRK of the first target device) according to the calculation rules corresponding to the above-mentioned security management information. , to determine the device Bluetooth address of the first target device, and apply it to the subsequent steps of sending the "directed connectable" LE Audio broadcast message.
  • the first Bluetooth audio device sends the identification information of the first target device to the second Bluetooth audio device.
  • the first Bluetooth audio device after determining the identification information of the first target device (such as the device Bluetooth address of the first target device, etc.), the first Bluetooth audio device can actively send the identification information to the second Bluetooth audio device. , to achieve information synchronization between the first Bluetooth audio device and the second Bluetooth audio device.
  • the identification information of the first target device such as the device Bluetooth address of the first target device, etc.
  • the second Bluetooth audio device may also obtain the identification information of the first target device through monitoring to achieve information synchronization between the first Bluetooth audio device and the second Bluetooth audio device.
  • the second Bluetooth audio device can monitor the classic Bluetooth link between the first Bluetooth audio device and the first target device, obtain the security management information sent by the first target device, and then independently determine the second Bluetooth audio device. Identification information of a target device and apply it to subsequent steps of sending "directed connectable" LE Audio broadcast messages.
  • the first Bluetooth audio device sends the first low-power Bluetooth broadcast message corresponding to the above identification information.
  • the second Bluetooth audio device sends a second low-power Bluetooth broadcast message corresponding to the above identification information.
  • the first target device receives the low-power Bluetooth broadcast message sent by the first Bluetooth audio device and the second Bluetooth audio device respectively, and determines that the low-power Bluetooth broadcast message corresponds to the identification information of the first target device. Next, in response to the low-power Bluetooth audio broadcast message, send a low-power Bluetooth audio connection request to the corresponding first Bluetooth audio device and/or the second Bluetooth audio device.
  • the first Bluetooth audio device receives the low-power Bluetooth audio connection request sent by the first target device, and responds to the low-power Bluetooth audio connection request to establish a low-power Bluetooth audio connection with the first target device.
  • the second Bluetooth audio device receives the low-power Bluetooth audio connection request sent by the first target device, and responds to the low-power Bluetooth audio connection request to establish a low-power Bluetooth audio connection with the first target device.
  • the first Bluetooth audio device and the second Bluetooth audio device may also establish a Bluetooth connection with the second target device, which is not shown in FIG. 9 .
  • the second target device receives the LE Audio broadcast message corresponding to the identification information of the first target device sent by the first Bluetooth audio device and/or the second Bluetooth audio device, it may not respond and discard the LE Audio broadcast message, Thus, misconnection with the first Bluetooth audio device and/or the second Bluetooth audio device can be effectively avoided.
  • the Bluetooth audio device can quickly and accurately obtain the identification information of the first target device by performing SMP operations with the first target device on the classic Bluetooth link, and thus can Based on the identification information of the first target device, a "directed connectable" LE Audio broadcast message is sent to the first target device, so that the first target device can communicate with the above-mentioned Bluetooth under the trigger of the targeted LE Audio broadcast message.
  • the audio device establishes a LE Audio Bluetooth connection.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the first target device expected by the user, and the second target device with different identification information receives the above LE Audio broadcast message. No response is required.
  • the Bluetooth audio device can be prioritized to establish a LE Audio Bluetooth connection with the first target device, and the Bluetooth audio device can be prevented from being mistakenly connected to the second target device, which is beneficial to reducing the possibility of the Bluetooth audio device being mistakenly connected to the terminal device, and effectively improving the The accuracy and flexibility of communication connections for Bluetooth audio devices.
  • Figure 10 is a modular schematic diagram of a device connection device disclosed in an embodiment of the present application.
  • the device connection device can be applied to the above-mentioned first Bluetooth audio device.
  • the device connection device may include an information acquisition unit 1001, a first broadcast sending unit 1002, a first request receiving unit 1003 and a first connection unit 1004, where:
  • the information acquisition unit 1001 is configured to acquire the identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device;
  • the first broadcast sending unit 1002 is configured to send a low-power Bluetooth broadcast message corresponding to the above identification information.
  • the low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the first target device to initiate low-power Bluetooth audio. connection request;
  • the first request receiving unit 1003 is configured to receive a low-power Bluetooth audio connection request sent by the first target device
  • the first connection unit 1004 is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
  • the Bluetooth audio device can quickly and accurately obtain the identification information of the first target device by performing SMP operations with the first target device on the classic Bluetooth link, and thus can Based on the identification information of the first target device, a "directed connectable" LE Audio broadcast message is sent to the first target device, so that the first target device can communicate with the above-mentioned Bluetooth under the trigger of the targeted LE Audio broadcast message.
  • the audio device establishes a LE Audio Bluetooth connection.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the first target device expected by the user, and the second target device with different identification information receives the above LE Audio broadcast message. No response is required.
  • the Bluetooth audio device can be prioritized to establish a LE Audio Bluetooth connection with the first target device, and the Bluetooth audio device can be prevented from being mistakenly connected to the second target device, which is conducive to reducing the possibility of the Bluetooth audio device being mistakenly connected to the terminal device, and effectively improving the The accuracy and flexibility of communication connections for Bluetooth audio devices.
  • the device connection device may also include an information synchronization unit (not shown).
  • the information synchronization unit may be used to send identification information of the first target device to the second Bluetooth audio device, so that the second Bluetooth audio device The audio device sends a low-power Bluetooth broadcast message corresponding to the identification information.
  • the second Bluetooth audio device may also monitor the Bluetooth link between the first Bluetooth audio device and the first target device, and calculate the identification information of the first target device based on the monitoring data.
  • the above-mentioned second Bluetooth audio device may belong to the same Bluetooth device set as the first Bluetooth audio device.
  • the above-mentioned information acquisition unit 1001 may include a receiving subunit and a determining subunit (not shown), where:
  • a receiving subunit configured to receive security management information sent by the first target device based on the security management protocol between the first Bluetooth audio device and the first target device;
  • the determining subunit is used to determine the identification information of the first target device according to the security management information.
  • the above receiving subunit can be used for:
  • the above-mentioned Bluetooth link may be an asynchronous connectionless ACL type Bluetooth link.
  • the IRK is calculated to generate the device Bluetooth address of the first target device.
  • the above-mentioned first Bluetooth audio device may be a device that supports the simultaneous establishment of a classic Bluetooth connection and a low-power Bluetooth audio connection.
  • the device connection device acquires the first target device in the above-mentioned information acquisition unit 1001.
  • you can also enter the pairing state (which can be implemented by a pairing unit not shown).
  • the pairing state means that the Bluetooth audio device is discoverable and connectable;
  • the above-mentioned first request receiving unit 1003 can also be used to:
  • the above-mentioned first connection unit 1004 can also be used for:
  • the above-mentioned information acquisition unit 1001 can be specifically configured to obtain the first target based on the security management protocol between the first Bluetooth audio device and the first target device on the classic Bluetooth link with the first target device. Identification information of the device.
  • the second target device when the second target device receives the Bluetooth low energy broadcast message corresponding to the identification information of the first target device sent by the Bluetooth audio device, it may not respond and discard the Bluetooth low energy broadcast message.
  • the above-mentioned first Bluetooth audio device may also be a device that only supports establishing a low-power Bluetooth audio connection.
  • the above-mentioned first connection unit 1004 may also be used for:
  • the above-mentioned information acquisition unit 1001 can be specifically configured to obtain the third Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the first target device on the low-power Bluetooth link with the first target device. Identification information of a target device.
  • the Bluetooth audio device can send a "directed connectable" LE to the first target device based on the identification information of the first target device quickly and accurately obtained through the SMP operation. Audio broadcast message, so that the first target device can establish a LE Audio Bluetooth connection with the above-mentioned Bluetooth audio device under the trigger of the targeted LE Audio broadcast message.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the first target device expected by the user, thereby preventing the Bluetooth audio device from being mistakenly connected to the second target device, which is conducive to reducing the cost of Bluetooth audio.
  • the possibility of audio equipment mistakenly connecting to terminal equipment effectively improves the accuracy and flexibility of communication connections for Bluetooth audio equipment.
  • the Bluetooth audio device uses the IRK of the first target device to calculate the RPA type BLE address, which can ensure that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the first target device, so that the above LE Audio broadcast message can be given
  • the "directionally connectable" feature helps improve the accuracy and reliability of Bluetooth audio devices' directional connection to terminal devices.
  • the first Bluetooth audio device and the second Bluetooth audio device can establish LE Audio Bluetooth with the first target device respectively. connection to improve the flexibility of communication connections for Bluetooth audio devices, and also help improve the reliability of audio data transmission by each headset based on BLE technology.
  • FIG. 11 is a modular schematic diagram of another device connection device disclosed in an embodiment of the present application.
  • the device connection device can be applied to the above-mentioned second Bluetooth audio device.
  • the device connection device may include a listening unit 1101, a computing unit 1102, a second broadcast sending unit 1103, a second request receiving unit 1104 and a second connection unit 1105, where:
  • the monitoring unit 1101 is used to monitor the Bluetooth link between the first Bluetooth audio device and the first target device and obtain monitoring data, where the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
  • the calculation unit 1102 is configured to calculate the identification information of the first target device according to the monitoring data
  • the second broadcast sending unit 1103 is used to send a low-power Bluetooth broadcast message corresponding to the identification information.
  • the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
  • the second request receiving unit 1104 is configured to receive a low-power Bluetooth audio connection request sent by the first target device
  • the second connection unit 1105 is configured to respond to a low-power Bluetooth audio connection request and establish a low-power Bluetooth audio connection with the first target device.
  • the above-mentioned monitoring data may include security management information of the first target device.
  • the security management information may specifically include the Bluetooth device address resolution key IRK.
  • the above-mentioned identification information may include the device Bluetooth address, so that the above-mentioned computing unit 1102 can be specifically used for:
  • the IRK is calculated to generate the device Bluetooth address of the first target device.
  • FIG. 12 is a modular schematic diagram of yet another device connection device disclosed in an embodiment of the present application.
  • the device connection device can also be applied to the above-mentioned second Bluetooth audio device.
  • the device connection device may include an information receiving unit 1201, a third broadcast sending unit 1202, a third request receiving unit 1203 and a third connection unit 1204, where:
  • the information receiving unit 1201 is configured to receive the identification information of the first target device sent by the first Bluetooth audio device, where the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
  • the third broadcast sending unit 1202 is used to send a low-power Bluetooth broadcast message corresponding to the identification information.
  • the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
  • the third request receiving unit 1203 is configured to receive a low-power Bluetooth audio connection request sent by the first target device
  • the third connection unit 1204 is configured to respond to a low-power Bluetooth audio connection request and establish a low-power Bluetooth audio connection with the first target device.
  • Figure 13 is a modular schematic diagram of a fourth device connection device disclosed in an embodiment of the present application.
  • This device connection device can be applied to the above-mentioned terminal equipment.
  • the device connection device may include an information sending unit 1301, a broadcast receiving unit 1302 and a request sending unit 1303, where:
  • the information sending unit 1301 is configured to send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the terminal device;
  • the broadcast receiving unit 1302 is configured to receive the first low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the above security management information;
  • the request sending unit 1303 is configured to send a low-power Bluetooth audio device to the first Bluetooth audio device in response to the first low-power Bluetooth broadcast message when it is determined that the first low-power Bluetooth broadcast message corresponds to the identification information of the terminal device. and a Bluetooth low energy audio connection request, so that the first Bluetooth audio device responds to the Bluetooth low energy audio connection request and establishes a low power Bluetooth audio connection with the terminal device.
  • the above-mentioned information sending unit 1301 may include a protocol configuration subunit and an information sending subunit (not shown), wherein:
  • the protocol configuration subunit is used to configure the security management protocol between the first Bluetooth audio device and the terminal device through the Bluetooth link between the first Bluetooth audio device and the terminal device;
  • the information sending subunit is configured to send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device based on the above-mentioned security management protocol.
  • the security management information is used to cause the first Bluetooth audio device to, according to the above-mentioned security management information, Determine the identification information of the terminal device, and send the first low-power Bluetooth broadcast message corresponding to the identification information.
  • the above identification information may include the Bluetooth address of the device, then the above broadcast receiving unit 1302 may be used to:
  • the above request sending unit 1303 may include a calculation subunit, a comparison subunit and a sending subunit (not shown), where:
  • the calculation subunit is used to calculate the security management information and the target Bluetooth address according to the calculation rules corresponding to the above security management information to obtain the verification Bluetooth address;
  • Comparison subunit used to compare the target Bluetooth address and the verification Bluetooth address
  • the sending subunit is configured to determine that the first low-power Bluetooth broadcast message corresponds to the device Bluetooth address of the terminal device when the above-mentioned target Bluetooth address matches the verification Bluetooth address, and respond to the above-mentioned first low-power Bluetooth address.
  • the Bluetooth consumption broadcast message sends a low-power Bluetooth audio connection request to the first Bluetooth audio device.
  • the device connection device may also include a connection unit not shown, wherein:
  • the above request sending unit 1303 may also be used to determine that the first Bluetooth audio device is in a pairing state before the above information sending unit 1301 sends the security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device. Send a classic Bluetooth connection request to the first Bluetooth audio device.
  • the above pairing state means that the first Bluetooth audio device is in a discoverable and connectable state;
  • a connection unit configured to establish a classic Bluetooth connection with the first Bluetooth audio device that responds to the classic Bluetooth connection request.
  • the above security management information can be used to enable the first Bluetooth audio device to determine the identification information of the terminal device based on the security management information, and the first Bluetooth audio device sends the identification information to the second Bluetooth audio device.
  • the identification information of the terminal device wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set; or the second Bluetooth audio device performs the Bluetooth link between the first Bluetooth audio device and the terminal device.
  • Monitor and calculate the identification information of the terminal device based on the above-mentioned security management information obtained by monitoring;
  • the identification information of the terminal device is used for the first Bluetooth audio device and/or the second Bluetooth audio device to send a low-power Bluetooth broadcast message corresponding to the identification information.
  • the above broadcast receiving unit 1302 can also be used to:
  • the device connection device can also determine whether the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set based on the second Bluetooth low energy broadcast message and the first Bluetooth low energy broadcast message (can be determined by Judgment unit implementation not shown);
  • the above request sending unit 1303 can be specifically used to:
  • the second Bluetooth Low Energy broadcast message corresponds to the identification information of the terminal device
  • the second Bluetooth Low Energy Broadcast a message to send a low-power Bluetooth audio connection request to the second Bluetooth audio device, so that the second Bluetooth audio device responds to the low-power Bluetooth audio connection request and establishes a low-power Bluetooth audio connection with the terminal device.
  • the terminal device can perform SMP operation with the Bluetooth audio device, so that the Bluetooth audio device can quickly and accurately obtain the identification information of the terminal device and send it to the terminal device.
  • Send a "directed connectable" LE Audio broadcast message so that the terminal device can establish a LE Audio Bluetooth connection with the above-mentioned Bluetooth audio device when triggered by the targeted LE Audio broadcast message.
  • Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the terminal device expected by the user, thereby preventing the Bluetooth audio device from being mistakenly connected to other devices in a connectable state, and helping to reduce the risk of The possibility of Bluetooth audio devices mistakenly connecting to terminal devices effectively improves the accuracy and flexibility of communication connections for Bluetooth audio devices.
  • the Bluetooth audio device can calculate the corresponding RPA type BLE address, thereby ensuring that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the terminal device. It is beneficial to improve the accuracy and reliability of directional connection of Bluetooth audio devices to terminal devices.
  • the terminal device can establish LE Audio Bluetooth connections with the first Bluetooth audio device and the second Bluetooth audio device respectively to improve
  • the flexibility of communication and connection between terminal devices and Bluetooth audio devices also helps improve the reliability of audio data transmission by each headset based on BLE technology.
  • FIG 14 is a modular schematic diagram of a Bluetooth audio device disclosed in an embodiment of the present application.
  • the Bluetooth audio device may include:
  • Memory 1401 storing executable program code
  • processor 1402 coupled to memory 1401;
  • the processor 1402 calls the executable program code stored in the memory 1401 to execute all or part of the steps in any of the device connection methods described in the above embodiments that are applied to the first Bluetooth audio device or the second Bluetooth audio device. .
  • FIG. 15 is a modular schematic diagram of a terminal device disclosed in an embodiment of the present application.
  • the terminal device may include:
  • Memory 1501 storing executable program code
  • processor 1502 coupled to memory 1501;
  • the processor 1502 calls the executable program code stored in the memory 1501 to execute all or part of the steps in any device connection method applied to the terminal device described in the above embodiments.
  • embodiments of the present application further disclose a computer-readable storage medium that stores a computer program for electronic data exchange, wherein the computer program enables the computer to perform any of the device connection methods described in the above embodiments. all or part of the steps.
  • the embodiment of the present application further discloses a computer program product.
  • the computer program product When the computer program product is run on a computer, the computer can perform all or part of the steps in any of the device connection methods described in the above embodiments.
  • the program can be stored in a computer-readable storage medium, and the storage medium includes a read-only storage medium.
  • Memory Read-Only Memory, ROM), Random Access Memory (RAM), Programmable Read-only Memory (PROM), Erasable Programmable Read Only Memory, EPROM), One-time Programmable Read-Only Memory (OTPROM), Electronically Erasable Programmable Read-Only Memory (EEPROM), Compact Disc Read-Only Memory (CD-ROM) or other optical disk storage, magnetic disk storage, magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.
  • Memory Read-Only Memory, ROM
  • RAM Random Access Memory
  • PROM Programmable Read-only Memory
  • EPROM Erasable Programmable Read Only Memory
  • OTPROM One-time Programmable Read-Only Memory
  • EEPROM Electronically Erasable Programmable Read-Only Memory
  • CD-ROM Compact Disc Read-Only Memory

Abstract

A device connection method and apparatus, and a storage medium and a chip. The method is applied to a first Bluetooth audio device, and comprises: on the basis of a security management protocol between a first Bluetooth audio device and a first target device, acquiring identification information of the first target device; sending a Bluetooth-low-energy broadcast message corresponding to the identification information, wherein the Bluetooth-low-energy broadcast message is used for indicating that the first Bluetooth audio device can respond to a Bluetooth-low-energy audio connection request initiated by the first target device; receiving a Bluetooth-low-energy audio connection request sent by the first target device; and in response to the Bluetooth-low-energy audio connection request, establishing a Bluetooth-low-energy audio connection to the first target device. By means of the embodiments of the present application, the possibility of a Bluetooth audio device erroneously connecting to a terminal device can be reduced, thereby improving the accuracy and flexibility of the Bluetooth audio device performing a communication connection.

Description

设备连接方法及装置、存储介质、芯片Equipment connection methods and devices, storage media, chips
本申请要求于2022年6月21日提交、申请号为202210705490.X、发明名称为“设备连接方法及装置、存储介质、芯片”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims priority to the Chinese patent application submitted on June 21, 2022, with application number 202210705490. Applying.
技术领域Technical field
本申请涉及蓝牙通信技术领域,尤其涉及一种设备连接方法及装置、存储介质、芯片。The present application relates to the field of Bluetooth communication technology, and in particular, to a device connection method and device, a storage medium, and a chip.
背景技术Background technique
当前,用户在使用蓝牙音频设备与终端设备(例如智能手机、平板电脑、智能可穿戴设备等)连接时,除了采用经典蓝牙连接方式,还可以基于新一代蓝牙技术,采用BLE(Bluetooth Low Energy,低功耗蓝牙)的方式建立连接,尤其可以包括LE Audio(Low Energy Audio,低功耗音频)蓝牙连接。然而,在实践中发现,对于目前支持LE Audio的蓝牙音频设备及终端设备,在连接过程中往往容易出现误连的情况,即蓝牙音频设备容易与不同于用户预期的终端设备误连接,降低了蓝牙音频设备进行通信连接的准确性及灵活性。Currently, when users use Bluetooth audio devices to connect to terminal devices (such as smartphones, tablets, smart wearable devices, etc.), in addition to using the classic Bluetooth connection method, they can also use BLE (Bluetooth Low Energy) based on the new generation of Bluetooth technology. Establish a connection through Bluetooth Low Energy), especially LE Audio (Low Energy Audio, Low Energy Audio) Bluetooth connection. However, in practice, it has been found that for current Bluetooth audio devices and terminal devices that support LE Audio, misconnections are often prone to occur during the connection process. That is, Bluetooth audio devices are prone to misconnection with terminal devices that are different from what the user expected, which reduces the risk of misconnection. The accuracy and flexibility of communication connections for Bluetooth audio devices.
发明内容Contents of the invention
本申请实施例公开了一种设备连接方法及装置、存储介质、芯片,能够降低蓝牙音频设备误连终端设备的可能性,提升蓝牙音频设备进行通信连接的准确性及灵活性。Embodiments of the present application disclose a device connection method and device, storage medium, and chip, which can reduce the possibility of Bluetooth audio devices misconnecting to terminal devices and improve the accuracy and flexibility of communication connections by Bluetooth audio devices.
本申请实施例第一方面公开一种设备连接方法,应用于第一蓝牙音频设备,所述方法包括:The first aspect of the embodiment of the present application discloses a device connection method, which is applied to a first Bluetooth audio device. The method includes:
基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息;Based on the security management protocol between the first Bluetooth audio device and the first target device, obtain the identification information of the first target device;
发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第一蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;Send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
接收所述第一目标设备发送的低功耗蓝牙音频连接请求;Receive a low-power Bluetooth audio connection request sent by the first target device;
响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。In response to the Bluetooth low energy audio connection request, a Bluetooth low energy audio connection is established with the first target device.
本申请实施例第二方面公开一种设备连接方法,应用于第二蓝牙音频设备,所述方法包括:The second aspect of the embodiment of the present application discloses a device connection method, which is applied to a second Bluetooth audio device. The method includes:
对第一蓝牙音频设备与第一目标设备之间的蓝牙链路进行监听,获取监听数据,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;Monitor the Bluetooth link between the first Bluetooth audio device and the first target device to obtain monitoring data, where the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
根据所述监听数据,计算得到所述第一目标设备的标识信息;According to the monitoring data, calculate the identification information of the first target device;
发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;Send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
接收所述第一目标设备发送的低功耗蓝牙音频连接请求;Receive a low-power Bluetooth audio connection request sent by the first target device;
响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。In response to the Bluetooth low energy audio connection request, a Bluetooth low energy audio connection is established with the first target device.
本申请实施例第二方面还公开另一种设备连接方法,应用于第二蓝牙音频设备,所述方法包括:The second aspect of the embodiment of the present application also discloses another device connection method, which is applied to a second Bluetooth audio device. The method includes:
接收第一蓝牙音频设备发送的第一目标设备的标识信息,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;Receive the identification information of the first target device sent by the first Bluetooth audio device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;Send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
接收所述第一目标设备发送的低功耗蓝牙音频连接请求;Receive a low-power Bluetooth audio connection request sent by the first target device;
响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。In response to the Bluetooth low energy audio connection request, a Bluetooth low energy audio connection is established with the first target device.
本申请实施例第三方面公开一种设备连接方法,应用于终端设备,所述方法包括:The third aspect of the embodiments of the present application discloses a device connection method, which is applied to terminal devices. The method includes:
基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息;Based on the security management protocol between the first Bluetooth audio device and the terminal device, send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device;
接收所述第一蓝牙音频设备响应于所述安全管理信息发送的第一低功耗蓝牙广播消息;Receive a first low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the security management information;
在确定所述第一低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于所述第一低功耗蓝牙广播消息,向所述第一蓝牙音频设备发送低功耗蓝牙音频连接请求,以使所述第一蓝牙音频设备响应于所述低功耗蓝牙音频连接请求,与所述终端设备建立低功耗蓝牙音频连接。When it is determined that the first Bluetooth low energy broadcast message corresponds to the identification information of the terminal device, in response to the first Bluetooth low energy broadcast message, send a low-power Bluetooth audio device to the first Bluetooth audio device. and a Bluetooth audio connection request, so that the first Bluetooth audio device responds to the Bluetooth low energy audio connection request and establishes a low-power Bluetooth audio connection with the terminal device.
本申请实施例第四方面公开一种设备连接装置,应用于第一蓝牙音频设备,所述设备连接装置包括:The fourth aspect of the embodiment of the present application discloses a device connection device, which is applied to the first Bluetooth audio device. The device connection device includes:
信息获取单元,用于基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息;An information acquisition unit configured to acquire identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device;
第一广播发送单元,用于发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第一蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;A first broadcast sending unit configured to send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the first target device’s initiation. Bluetooth low energy audio connection request;
第一请求接收单元,用于接收所述第一目标设备发送的低功耗蓝牙音频连接请求;A first request receiving unit configured to receive a low-power Bluetooth audio connection request sent by the first target device;
第一连接单元,用于响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。A first connection unit configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
本申请实施例第五方面公开一种设备连接装置,应用于第二蓝牙音频设备,所述设备连接装置包括:The fifth aspect of the embodiment of the present application discloses a device connection device applied to a second Bluetooth audio device. The device connection device includes:
监听单元,用于对第一蓝牙音频设备与第一目标设备之间的蓝牙链路进行监听,获取监听数据,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;A monitoring unit configured to monitor the Bluetooth link between the first Bluetooth audio device and the first target device and obtain monitoring data, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device. gather;
计算单元,用于根据所述监听数据,计算得到所述第一目标设备的标识信息;A computing unit configured to calculate identification information of the first target device according to the monitoring data;
第二广播发送单元,用于发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备响应所述第一目标设备发起的低功耗蓝牙音频连接请求;A second broadcast sending unit, configured to send a low-power Bluetooth broadcast message corresponding to the identification information, where the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to a call initiated by the first target device. Bluetooth low energy audio connection request;
第二请求接收单元,用于接收所述第一目标设备发送的低功耗蓝牙音频连接请求;A second request receiving unit, configured to receive a low-power Bluetooth audio connection request sent by the first target device;
第二连接单元,用于响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。The second connection unit is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
本申请实施例第五方面公开另一种设备连接装置,应用于第二蓝牙音频设备,所述设备连接装置包括:The fifth aspect of the embodiment of the present application discloses another device connection device, which is applied to a second Bluetooth audio device. The device connection device includes:
信息接收单元,用于接收第一蓝牙音频设备发送的第一目标设备的标识信息,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;An information receiving unit configured to receive the identification information of the first target device sent by the first Bluetooth audio device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
第三广播发送单元,用于发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备响应所述第一目标设备发起的低功耗蓝牙音频连接请求;A third broadcast sending unit, configured to send a low-power Bluetooth broadcast message corresponding to the identification information, where the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to a call initiated by the first target device. Bluetooth low energy audio connection request;
第三请求接收单元,用于接收所述第一目标设备发送的低功耗蓝牙音频连接请求;A third request receiving unit configured to receive a low-power Bluetooth audio connection request sent by the first target device;
第三连接单元,用于响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。The third connection unit is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
本申请实施例第六方面公开一种设备连接装置,应用于终端设备,所述设备连接装置包括:The sixth aspect of the embodiment of the present application discloses an equipment connection device, which is applied to terminal equipment. The equipment connection device includes:
信息发送单元,用于基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息;An information sending unit configured to send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the terminal device;
广播接收单元,用于接收所述第一蓝牙音频设备响应于所述安全管理信息发送的低功耗蓝牙广播消息;A broadcast receiving unit configured to receive a low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the security management information;
请求发送单元,用于在确定所述低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于所述低功耗蓝牙广播消息,向所述第一蓝牙音频设备发送低功耗蓝牙音频连接请求,以使所述第一蓝牙音频设备响应于所述低功耗蓝牙音频连接请求,与所述终端设备建立低功耗蓝牙音频连接。A request sending unit, configured to respond to the Bluetooth low energy broadcast message and send a low-power Bluetooth audio device to the first Bluetooth audio device when it is determined that the low-power Bluetooth broadcast message corresponds to the identification information of the terminal device. and a power consumption Bluetooth audio connection request, so that the first Bluetooth audio device responds to the low power Bluetooth audio connection request and establishes a low power Bluetooth audio connection with the terminal device.
本申请实施例第七方面公开了一种蓝牙音频设备,包括存储器及处理器,所述存储器中存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器实现如本申请实施例第一方面或第二方面公开的任意一种设备连接方法中的全部或部分步骤。The seventh aspect of the embodiment of the present application discloses a Bluetooth audio device, which includes a memory and a processor. A computer program is stored in the memory. When the computer program is executed by the processor, the processor implements the following All or part of the steps in any device connection method disclosed in the first aspect or the second aspect of the application embodiments.
本申请实施例第八方面公开了一种终端设备,包括存储器及处理器,所述存储器中存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器实现如本申请实施例第三方面公开的任意一种设备连接方法中的全部或部分步骤。The eighth aspect of the embodiment of the present application discloses a terminal device, which includes a memory and a processor. A computer program is stored in the memory. When the computer program is executed by the processor, the processor implements the application as described in the present application. All or part of the steps in any device connection method disclosed in the third aspect of the embodiment.
本申请实施例第九方面公开了一种计算机可读存储介质,其存储计算机程序,其中,所述计算机程序被处理器执行时实现如本申请实施例第一方面、第二方面或第三方面公开的任意一种设备连接方法中的全部或部分步骤。The ninth aspect of the embodiment of the present application discloses a computer-readable storage medium that stores a computer program, wherein when the computer program is executed by a processor, the first aspect, the second aspect, or the third aspect of the embodiment of the present application is implemented. All or part of the steps in any of the disclosed device connection methods.
本申请实施例第十方面公开了一种芯片,包括处理器,所述处理器用于读取并执行存储器中存储的计算机程序,以执行如本申请实施例第一方面、第二方面或第三方面公开的任意一种设备连接方法中的全部或部分步骤。The tenth aspect of the embodiment of the present application discloses a chip, including a processor, the processor is configured to read and execute the computer program stored in the memory to execute the first aspect, the second aspect or the third aspect of the embodiment of the present application. All or part of the steps in any device connection method disclosed in the aspect.
本申请的一个或多个实施例的细节在下面的附图和描述中提出。本申请的其它特征和有益效果将从说明书、附图以及权利要求书中体现。The details of one or more embodiments of the application are set forth in the accompanying drawings and the description below. Other features and beneficial effects of the application will be apparent from the description, drawings and claims.
附图说明Description of the drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例中所需要使用的附图进行简单的介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其它的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required to be used in the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. Those of ordinary skill in the art can also obtain other drawings based on these drawings without exerting creative efforts.
图1A是本申请实施例公开的设备连接方法的一种应用场景示意图;Figure 1A is a schematic diagram of an application scenario of the device connection method disclosed in the embodiment of the present application;
图1B是本申请实施例公开的设备连接方法的另一种应用场景示意图;Figure 1B is a schematic diagram of another application scenario of the device connection method disclosed in the embodiment of the present application;
图2是是相关技术中蓝牙协议的基本框架图;Figure 2 is a basic framework diagram of the Bluetooth protocol in related technologies;
图3是本申请实施例公开的一种应用于第一蓝牙音频设备的设备连接方法的流程示意图;Figure 3 is a schematic flow chart of a device connection method applied to a first Bluetooth audio device disclosed in an embodiment of the present application;
图4是本申请实施例公开的另一种应用于第一蓝牙音频设备的设备连接方法的流程示意图;Figure 4 is a schematic flow chart of another device connection method applied to the first Bluetooth audio device disclosed in the embodiment of the present application;
图5是本申请实施例公开的又一种应用于第一蓝牙音频设备的设备连接方法的流程示意图;Figure 5 is a schematic flow chart of yet another device connection method applied to the first Bluetooth audio device disclosed in the embodiment of the present application;
图6是本申请实施例公开的一种应用于第二蓝牙音频设备的设备连接方法的流程示意图;Figure 6 is a schematic flow chart of a device connection method applied to a second Bluetooth audio device disclosed in the embodiment of the present application;
图7是本申请实施例公开的一种应用于终端设备的设备连接方法的流程示意图;Figure 7 is a schematic flowchart of a device connection method applied to a terminal device disclosed in an embodiment of the present application;
图8是本申请实施例公开的一种设备连接方法的时序图;Figure 8 is a sequence diagram of a device connection method disclosed in the embodiment of the present application;
图9是本申请实施例公开的另一种设备连接方法的时序图;Figure 9 is a sequence diagram of another device connection method disclosed in the embodiment of the present application;
图10是本申请实施例公开的一种设备连接装置的模块化示意图;Figure 10 is a modular schematic diagram of a device connection device disclosed in the embodiment of the present application;
图11是本申请实施例公开的另一种设备连接装置的模块化示意图;Figure 11 is a modular schematic diagram of another device connection device disclosed in the embodiment of the present application;
图12是本申请实施例公开的又一种设备连接装置的模块化示意图;Figure 12 is a modular schematic diagram of yet another device connection device disclosed in the embodiment of the present application;
图13是本申请实施例公开的第四种设备连接装置的模块化示意图;Figure 13 is a modular schematic diagram of the fourth device connection device disclosed in the embodiment of the present application;
图14是本申请实施例公开的一种蓝牙音频设备的模块化示意图;Figure 14 is a modular schematic diagram of a Bluetooth audio device disclosed in the embodiment of the present application;
图15是本申请实施例公开的一种终端设备的模块化示意图。Figure 15 is a modular schematic diagram of a terminal device disclosed in the embodiment of the present application.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整的描述,显然,所描述的实施例仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其它实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of this application.
需要说明的是,本申请实施例的术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。在不冲突的情况下,本申请中的实施例、实施方式及相关技术特征可以相互组合、替换,不同实施例、实施方式中的解释可以相互适用。本申请中的“多个”是指两个或两个以上。It should be noted that the terms "comprising" and "having" and any variations thereof in the embodiments of this application are intended to cover non-exclusive inclusion, for example, a process, method, system, product or product that includes a series of steps or units. Apparatus are not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such processes, methods, products or devices. If there is no conflict, the embodiments, implementation modes and related technical features in this application can be combined and replaced with each other, and the explanations in different embodiments and implementation modes can be applied to each other. "Plural" in this application means two or more.
本申请实施例公开了一种设备连接方法及装置、存储介质、芯片,能够降低蓝牙音频设备误连终端设备的可能性,提升蓝牙音频设备进行通信连接的准确性及灵活性。Embodiments of the present application disclose a device connection method and device, storage medium, and chip, which can reduce the possibility of Bluetooth audio devices misconnecting to terminal devices and improve the accuracy and flexibility of communication connections by Bluetooth audio devices.
以下将结合附图进行详细描述。A detailed description will be given below with reference to the accompanying drawings.
请一并参阅图1A和图1B,图1A是本申请实施例公开的设备连接方法的一种应用场景示意图,图1B则是本申请实施例公开的设备连接方法的另一种应用场景示意图。如图1A所示,该应用场景可以包括第一蓝牙音频设备10以及终端设备20,该第一蓝牙音频设备10可以与终端设备20建立蓝牙连接,例如经典蓝牙连接、BLE(Bluetooth Low Energy,低功耗蓝牙)连接等。其中,上述经典蓝牙连接,指的是基于各版本蓝牙协议(例如由蓝牙技术联盟Bluetooth SIG制定的蓝牙4.0之前的各版本协议,同时也可包 括蓝牙4.0及之后的各版本协议)中规定的BR/EDR(Basic Rate/Enhanced Data Rate)、AMP(Alternate MAC/PHYs)等技术(或模式)所实现的蓝牙连接方案;上述BLE连接,则是指基于新一代蓝牙协议(例如由Bluetooth SIG制定的蓝牙4.0及之后的各版本协议),采用BLE技术(或模式)所实现的蓝牙连接方案。Please refer to FIG. 1A and FIG. 1B together. FIG. 1A is a schematic diagram of an application scenario of the device connection method disclosed in the embodiment of the present application. FIG. 1B is a schematic diagram of another application scenario of the device connection method disclosed in the embodiment of the present application. As shown in Figure 1A, the application scenario may include a first Bluetooth audio device 10 and a terminal device 20. The first Bluetooth audio device 10 may establish a Bluetooth connection with the terminal device 20, such as a classic Bluetooth connection, BLE (Bluetooth Low Energy, Low Energy). Power consumption Bluetooth) connection, etc. Among them, the above-mentioned classic Bluetooth connection refers to the BR based on various versions of Bluetooth protocols (such as the protocols before Bluetooth 4.0 formulated by the Bluetooth SIG, which can also include Bluetooth 4.0 and subsequent versions of the protocol). /EDR (Basic Rate/Enhanced Data Rate), AMP (Alternate MAC/PHYs) and other technologies (or modes) to achieve Bluetooth connection solutions; the above-mentioned BLE connection refers to a new generation Bluetooth protocol based on (such as developed by Bluetooth SIG Bluetooth 4.0 and subsequent versions of the protocol), a Bluetooth connection solution implemented using BLE technology (or mode).
在相关技术中,为了在保持设备低功耗的基础上实现数据流量更大的音频数据传输,第一蓝牙音频设备10也可以与终端设备20建立LE Audio(Low Energy Audio,低功耗音频)蓝牙连接,其基于新一代蓝牙核心规范CoreSpec5.2,相较于经典的A2DP(Advanced Audio Distribution Profile,高级音频分配规范)可以具有更高的压缩率和更好的音质,在低数据速率下也能达到音质增强的效果。需要说明的是,出于使设备兼容性更高的目的,第一蓝牙音频设备10可以采用双模蓝牙技术,即,同时支持经典蓝牙连接和LE Audio蓝牙连接,此时第一蓝牙音频设备10可以与终端设备20同时建立至少一条经典蓝牙链路和至少一条LE Audio蓝牙链路。其中,在需要第一蓝牙音频设备10与终端设备20建立LE Audio蓝牙连接时,通常需要由第一蓝牙音频设备10以广播的方式发送低功耗蓝牙广播消息(即LE Audio广播消息),终端设备20在接收到LE Audio广播消息后,可以自动或由用户手动向该第一蓝牙音频设备10发送低功耗蓝牙音频连接请求,进而该第一蓝牙音频设备10可以响应于上述低功耗蓝牙音频连接请求,与终端设备20建立LE Audio蓝牙连接。In related technologies, in order to achieve audio data transmission with greater data traffic while maintaining low power consumption of the device, the first Bluetooth audio device 10 can also establish LE Audio (Low Energy Audio, low power audio) with the terminal device 20 Bluetooth connection is based on the new generation of Bluetooth core specification CoreSpec5.2. Compared with the classic A2DP (Advanced Audio Distribution Profile, Advanced Audio Distribution Profile), it can have a higher compression rate and better sound quality, and can also perform at low data rates. Can achieve the effect of sound quality enhancement. It should be noted that, for the purpose of making the device more compatible, the first Bluetooth audio device 10 can adopt dual-mode Bluetooth technology, that is, it supports both classic Bluetooth connection and LE Audio Bluetooth connection. At this time, the first Bluetooth audio device 10 At least one classic Bluetooth link and at least one LE Audio Bluetooth link can be established with the terminal device 20 at the same time. Among them, when the first Bluetooth audio device 10 needs to establish a LE Audio Bluetooth connection with the terminal device 20, it is usually necessary for the first Bluetooth audio device 10 to send a low-power Bluetooth broadcast message (ie, LE Audio broadcast message) in a broadcast manner, and the terminal After receiving the LE Audio broadcast message, the device 20 can automatically or manually send a low-power Bluetooth audio connection request to the first Bluetooth audio device 10, and then the first Bluetooth audio device 10 can respond to the above-mentioned Bluetooth low energy connection request. Audio connection request to establish a LE Audio Bluetooth connection with the terminal device 20.
示例性的,图2示出了一种蓝牙协议的基本框架,适用于支持建立经典蓝牙连接和/或LE Audio蓝牙连接的设备。该框架可以包括但不限于应用层(Profiles)、主机层(Host)和控制层(Controller)。其中,应用层可以包括Bluetooth SIG定义的各种应用规范(profile),例如上述的A2DP、HFP(Hands-Free Profile,电话免提规范)、HDP(Health Device Profile,健康设备规范)等,即针对每个应用可以定义各自相应的消息格式与应用规则,以适用于各种不同的应用场景。主机层定义了该框架中的核心协议(protocol),可以包括但不限于蓝牙基本的服务发现协议(Service Discover Protocol,SDP)、逻辑链路控制和适配协议(Logical Link Control and Adaptation Protocol,L2CAP)等。控制层定义了底层硬件部分,例如主机控制接口(Host Controller Interface,HCI)、无线射频(Radio Frequency,RF)、基带(Baseband,BB)以及基于链路管理协议(Link Management Protocol,LMP)的链路管理层等。Exemplarily, Figure 2 shows the basic framework of a Bluetooth protocol, suitable for devices that support the establishment of classic Bluetooth connections and/or LE Audio Bluetooth connections. The framework may include but is not limited to application layer (Profiles), host layer (Host) and control layer (Controller). Among them, the application layer can include various application specifications (profiles) defined by Bluetooth SIG, such as the above-mentioned A2DP, HFP (Hands-Free Profile, phone hands-free profile), HDP (Health Device Profile, health device profile), etc., that is, for Each application can define its own corresponding message format and application rules to suit various application scenarios. The host layer defines the core protocols in the framework, which can include but are not limited to Bluetooth's basic Service Discovery Protocol (Service Discover Protocol, SDP), Logical Link Control and Adaptation Protocol (Logical Link Control and Adaptation Protocol, L2CAP )wait. The control layer defines the underlying hardware parts, such as Host Controller Interface (HCI), Radio Frequency (RF), Baseband (BB), and links based on Link Management Protocol (LMP). Road management, etc.
在此基础上,对于支持LE Audio蓝牙连接的第一蓝牙音频设备10,依据各自的性能配置可以存在最大可连接数。在一些实施例中,对于支持一拖一的第一蓝牙音频设备10,其最大可连接数为1,即仅允许同时与一台终端设备20保持LE Audio蓝牙连接,且当该第一蓝牙音频设备10已经与某一终端设备20建立LE Audio蓝牙连接时,需要先断开与该终端设备20的LE Audio蓝牙连接,然后才能够与新的终端设备20建立LE Audio蓝牙连接。在另一些实施例中,对于支持一拖多的第一蓝牙音频设备10,其最大可连接数大于1,即允许同时与多台终端设备20保持LE Audio蓝牙连接,且在与该第一蓝牙音频设备10建立LE Audio蓝牙连接的终端设备20数量未达到最大可连接数时,可允许与新的终端设备20建立LE Audio蓝牙连接;在与该第一蓝牙音频设备10建立LE Audio蓝牙连接的终端设备20数量已达到最大可连接数时,则需要先断开与部分终端设备20的LE Audio蓝牙连接,然后才能够与新的终端设备20建立LE Audio蓝牙连接。On this basis, for the first Bluetooth audio device 10 that supports LE Audio Bluetooth connection, there can be a maximum number of connections based on their respective performance configurations. In some embodiments, for the first Bluetooth audio device 10 that supports one-to-one, its maximum number of connections is 1, that is, it is only allowed to maintain a LE Audio Bluetooth connection with one terminal device 20 at the same time, and when the first Bluetooth audio When the device 10 has established a LE Audio Bluetooth connection with a certain terminal device 20, it needs to disconnect the LE Audio Bluetooth connection with the terminal device 20 before it can establish a LE Audio Bluetooth connection with a new terminal device 20. In other embodiments, for the first Bluetooth audio device 10 that supports one to many, the maximum number of connections is greater than 1, that is, it is allowed to maintain LE Audio Bluetooth connections with multiple terminal devices 20 at the same time, and when communicating with the first Bluetooth When the number of terminal devices 20 that the audio device 10 establishes a LE Audio Bluetooth connection does not reach the maximum connectable number, it may be allowed to establish a LE Audio Bluetooth connection with a new terminal device 20; When the number of terminal devices 20 has reached the maximum connectable number, it is necessary to disconnect the LE Audio Bluetooth connections with some terminal devices 20 before establishing a LE Audio Bluetooth connection with a new terminal device 20 .
经发明人研究发现,上述相关技术中存在第一蓝牙音频设备10误连终端设备的问题:在第一蓝牙音频设备10处于LE Audio可连接的状态下,该第一蓝牙音频设备10可以向外广播LE Audio广播消息。若该第一蓝牙音频设备10的最大可连接数为N1,而此时有N2(N1、N2均为正整数,且N2>N1)台终端设备20接收到该LE Audio广播消息,并向第一蓝牙音频设备10发送了低功耗蓝牙音频连接请求,则可能会发生用户预期连接的终端设备20未能与第一蓝牙音频设备10建立LE Audio蓝牙连接的误连情况。The inventor found through research that there is a problem in the above related technologies that the first Bluetooth audio device 10 is mistakenly connected to the terminal device: when the first Bluetooth audio device 10 is in a state where LE Audio can be connected, the first Bluetooth audio device 10 can be connected to the external device. Broadcast LE Audio broadcast messages. If the maximum connectable number of the first Bluetooth audio device 10 is N1, and at this time there are N2 (N1, N2 are positive integers, and N2>N1) terminal devices 20 receive the LE Audio broadcast message and send it to the first Bluetooth audio device 10. If a Bluetooth audio device 10 sends a low-power Bluetooth audio connection request, a misconnection may occur in which the terminal device 20 that the user intends to connect fails to establish a LE Audio Bluetooth connection with the first Bluetooth audio device 10.
为解决这一问题,在本申请实施例中,可以基于第一蓝牙音频设备10与终端设备20之间的安全管理协议(Security Manager Protocol,SMP),获取该终端设备20的标识信息,进而第一蓝牙音频设备10可以发送携带该标识信息的LE Audio广播消息。其中,上述LE Audio广播消息可以用于指示终端设备20向该第一蓝牙音频设备10发起LE Audio蓝牙连接请求,且第一蓝牙音频设备10能够对该LE Audio蓝牙连接请求进行响应。在此基础上,第一蓝牙音频设备10可以接收终端设备20所发送的低功耗蓝牙音频连接 请求,并响应于该低功耗蓝牙音频连接请求,与终端设备20建立LE Audio蓝牙连接。In order to solve this problem, in the embodiment of the present application, the identification information of the terminal device 20 can be obtained based on the security management protocol (Security Manager Protocol, SMP) between the first Bluetooth audio device 10 and the terminal device 20, and then the third A Bluetooth audio device 10 can send an LE Audio broadcast message carrying the identification information. The above-mentioned LE Audio broadcast message can be used to instruct the terminal device 20 to initiate a LE Audio Bluetooth connection request to the first Bluetooth audio device 10, and the first Bluetooth audio device 10 can respond to the LE Audio Bluetooth connection request. On this basis, the first Bluetooth audio device 10 can receive the low-power Bluetooth audio connection request sent by the terminal device 20, and respond to the low-power Bluetooth audio connection request to establish a LE Audio Bluetooth connection with the terminal device 20.
通过实施上述方法,第一蓝牙音频设备10可以通过在经典蓝牙链路上与终端设备20进行基于安全管理协议的相关交互操作,以快速、准确地取该终端设备20的标识信息,进而可以基于其所获取的标识信息,向该终端设备20发送“定向可连接”的LE Audio广播消息,从而该终端设备20可以在这一针对性的LE Audio广播消息的触发下,与上述第一蓝牙音频设备10建立LE Audio蓝牙连接。这样的设备连接方式,可以确保第一蓝牙音频设备10所发出的LE Audio广播消息仅能够被用户预期的终端设备20所响应,而具有不同标识信息的其他设备在接收到上述LE Audio广播消息时可以不作任何响应。从而,能够使第一蓝牙音频设备10优先与该终端设备20建立LE Audio蓝牙连接,并避免该第一蓝牙音频设备10与非用户选择的其他设备误连接,有利于降低第一蓝牙音频设备10误连终端设备的可能性,有效提升了第一蓝牙音频设备10进行通信连接的准确性及灵活性。By implementing the above method, the first Bluetooth audio device 10 can quickly and accurately obtain the identification information of the terminal device 20 by performing relevant interactive operations based on the security management protocol with the terminal device 20 on the classic Bluetooth link, and can further obtain the identification information of the terminal device 20 based on the classic Bluetooth link. The obtained identification information sends a "directed connectable" LE Audio broadcast message to the terminal device 20, so that the terminal device 20 can communicate with the above-mentioned first Bluetooth audio under the trigger of this targeted LE Audio broadcast message. Device 10 establishes a LE Audio Bluetooth connection. Such a device connection method can ensure that the LE Audio broadcast message sent by the first Bluetooth audio device 10 can only be responded to by the terminal device 20 expected by the user, and other devices with different identification information receive the above-mentioned LE Audio broadcast message. No response is required. Therefore, the first Bluetooth audio device 10 can be prioritized to establish a LE Audio Bluetooth connection with the terminal device 20, and the first Bluetooth audio device 10 can be prevented from being mistakenly connected to other devices not selected by the user, which is beneficial to reducing the risk of the first Bluetooth audio device 10 The possibility of mistakenly connecting the terminal device effectively improves the accuracy and flexibility of the communication connection of the first Bluetooth audio device 10 .
示例性,上述第一蓝牙音频设备10可以包括各类蓝牙耳机、蓝牙音箱等,尤其可以包括TWS(True Wireless Stereo,真无线立体声)耳机。示例性地,上述终端设备20可以包括具备蓝牙通信功能的各类设备或系统,如手机、智能可穿戴设备、车载终端、平板电脑、PC(Personal Computer,个人电脑)、PDA(Personal Digital Assistant,个人数字助理)等,本申请实施例中不作具体限定。需要说明的是,图1A及图1B中所示的第一蓝牙音频设备10为蓝牙耳机,终端设备20为手机,这仅仅是一种示例,不构成本申请实施例中对蓝牙音频设备10以及终端设备20的设备类型的限定。以上述第一蓝牙音频设备10包括耳机设备为例,在一些实施例中,如图1A所示,该第一蓝牙音频设备10可以为单个耳机。而在另一些实施例中,如图1B所示,该应用场景还可以包括第二蓝牙音频设备30,该第二蓝牙音频设备30与第一蓝牙音频设备10可以属于同一蓝牙设备集合。可选地,上述第一蓝牙音频设备10和第二蓝牙音频设备30的其中一者可以与终端设备20建立经典蓝牙连接(可以理解为当前的主耳机或主设备),从而该第一蓝牙音频设备10和第二蓝牙音频设备30可以区分为主从耳,以与终端设备20实现经典蓝牙连接;同时,该第一蓝牙音频设备10和第二蓝牙音频设备30也可以分别与终端设备20建立LE Audio蓝牙连接。可选地,第一蓝牙音频设备10和第二蓝牙音频设备30也可以不区分主从关系,以使该第一蓝牙音频设备10和第二蓝牙音频设备30可以分别同时与终端设备20实现经典蓝牙连接和LE Audio蓝牙连接。For example, the above-mentioned first Bluetooth audio device 10 may include various types of Bluetooth headsets, Bluetooth speakers, etc., and may especially include TWS (True Wireless Stereo) headsets. For example, the above-mentioned terminal device 20 may include various devices or systems with Bluetooth communication functions, such as mobile phones, smart wearable devices, vehicle-mounted terminals, tablet computers, PC (Personal Computer, personal computer), PDA (Personal Digital Assistant, Personal digital assistant), etc., are not specifically limited in the embodiments of this application. It should be noted that the first Bluetooth audio device 10 shown in FIG. 1A and FIG. 1B is a Bluetooth headset, and the terminal device 20 is a mobile phone. This is only an example and does not constitute a reference to the Bluetooth audio device 10 and the Bluetooth audio device 10 in the embodiment of the present application. Limitation of the device type of the terminal device 20. Taking the above-mentioned first Bluetooth audio device 10 including an earphone device as an example, in some embodiments, as shown in FIG. 1A , the first Bluetooth audio device 10 may be a single earphone. In other embodiments, as shown in FIG. 1B , the application scenario may also include a second Bluetooth audio device 30 , and the second Bluetooth audio device 30 and the first Bluetooth audio device 10 may belong to the same Bluetooth device set. Optionally, one of the first Bluetooth audio device 10 and the second Bluetooth audio device 30 can establish a classic Bluetooth connection with the terminal device 20 (which can be understood as the current main headset or main device), so that the first Bluetooth audio The device 10 and the second Bluetooth audio device 30 can be distinguished as master and slave to achieve classic Bluetooth connection with the terminal device 20; at the same time, the first Bluetooth audio device 10 and the second Bluetooth audio device 30 can also be established with the terminal device 20 respectively. LE Audio Bluetooth connection. Optionally, the first Bluetooth audio device 10 and the second Bluetooth audio device 30 may not distinguish the master-slave relationship, so that the first Bluetooth audio device 10 and the second Bluetooth audio device 30 can achieve classic communication with the terminal device 20 at the same time. Bluetooth connectivity and LE Audio Bluetooth connectivity.
可以理解,上述蓝牙音频设备也可以包括两个以上的同组设备,即,还可以包括除第一蓝牙音频设备10以及第二蓝牙音频设备30以外的其他蓝牙设备,各个同组设备与终端设备20建立蓝牙连接的方式可以与上述第一蓝牙音频设备10以及第二蓝牙音频设备30与终端设备20建立蓝牙连接的方式类似。It can be understood that the above-mentioned Bluetooth audio device may also include two or more devices in the same group, that is, it may also include other Bluetooth devices except the first Bluetooth audio device 10 and the second Bluetooth audio device 30. Each device in the same group and the terminal device The method of establishing a Bluetooth connection 20 may be similar to the method of establishing a Bluetooth connection between the first Bluetooth audio device 10 and the second Bluetooth audio device 30 and the terminal device 20 .
请参阅图3,图3是本申请实施例公开的一种设备连接方法的流程示意图,该方法可以应用于上述的第一蓝牙音频设备。如图3所示,该设备连接方法可以包括以下步骤:Please refer to Figure 3. Figure 3 is a schematic flowchart of a device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned first Bluetooth audio device. As shown in Figure 3, the device connection method may include the following steps:
302、基于第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取该第一目标设备的标识信息。302. Based on the security management protocol between the first Bluetooth audio device and the first target device, obtain the identification information of the first target device.
在本申请实施例中,为了使第一蓝牙音频设备与用户预期连接的终端设备(即该用户指定的第一目标设备)建立蓝牙连接,尤其包括建立LE Audio蓝牙连接,该第一蓝牙音频设备可以先获取该第一目标设备的标识信息,继而可以在后续步骤中根据该标识信息,发出针对第一目标设备的“定向可连接”的LE Audio广播消息,以指定第一目标设备可以与该第一蓝牙音频设备建立LE Audio蓝牙连接,同时避免其他处于可连接状态的设备误响应,从而有利于提升第一蓝牙音频设备进行通信连接的准确性。In the embodiment of the present application, in order to establish a Bluetooth connection between the first Bluetooth audio device and the terminal device that the user intends to connect to (i.e., the first target device designated by the user), especially including establishing a LE Audio Bluetooth connection, the first Bluetooth audio device The identification information of the first target device can be obtained first, and then in subsequent steps, a "directed connectable" LE Audio broadcast message for the first target device can be sent based on the identification information to specify that the first target device can communicate with the first target device. The first Bluetooth audio device establishes a LE Audio Bluetooth connection and avoids false responses from other devices in a connectable state, thereby improving the accuracy of the communication connection of the first Bluetooth audio device.
其中,上述第一目标设备的标识信息,可以包括该第一目标设备的设备地址标识信息(例如设备蓝牙地址,包括经典蓝牙地址以及BLE地址等)、设备身份标识信息、设备名称标识信息、设备型号标识信息等。根据该标识信息,第一蓝牙音频设备可确认唯一与之对应的终端设备为上述第一目标设备,从而可以基于该标识信息,针对性地与第一目标设备建立蓝牙连接。The identification information of the first target device may include the device address identification information of the first target device (such as the device Bluetooth address, including classic Bluetooth address and BLE address, etc.), device identity identification information, device name identification information, device Model identification information, etc. According to the identification information, the first Bluetooth audio device can confirm that the only corresponding terminal device is the above-mentioned first target device, and thus can establish a Bluetooth connection with the first target device in a targeted manner based on the identification information.
在本申请实施例中,上述第一蓝牙音频设备可以采用双模蓝牙技术,即该第一蓝牙音频设备可以同时支持经典蓝牙连接和LE Audio蓝牙连接。在此基础上,第一蓝牙音频设备可以先与第一目标设备建立经典蓝牙连接,并在已建立经典蓝牙连接的情况下,通过在经典蓝牙链路上配置该第一蓝牙音频设备与第一目标设备之间的安全管理协议,以及执行该安全管理协议相关的交互操作(即SMP操作),获取第 一目标设备的标识信息,以将该标识信息应用于建立该第一蓝牙音频设备与第一目标设备之间的LE Audio蓝牙连接。其中,上述安全管理协议,可以用于管理第一蓝牙音频设备与第一目标设备之间的配对、身份验证以及加密等协议内规定的蓝牙设备交互操作,包括实现指定私有信息的传递等,以协助实现第一蓝牙音频设备与第一目标设备的定向连接。In this embodiment of the present application, the above-mentioned first Bluetooth audio device can adopt dual-mode Bluetooth technology, that is, the first Bluetooth audio device can support classic Bluetooth connection and LE Audio Bluetooth connection at the same time. On this basis, the first Bluetooth audio device can first establish a classic Bluetooth connection with the first target device, and when the classic Bluetooth connection has been established, the first Bluetooth audio device can communicate with the first Bluetooth audio device by configuring the classic Bluetooth link. security management protocol between target devices, and perform interactive operations (i.e., SMP operations) related to the security management protocol, obtain identification information of the first target device, and apply the identification information to establish the first Bluetooth audio device and the third LE Audio Bluetooth connection between a target device. Among them, the above-mentioned security management protocol can be used to manage the pairing, authentication, encryption and other Bluetooth device interaction operations specified in the protocol between the first Bluetooth audio device and the first target device, including realizing the transfer of designated private information, etc., in order to Assist in realizing the directional connection between the first Bluetooth audio device and the first target device.
在一些实施例中,第一蓝牙音频设备也可以仅支持LE Audio蓝牙连接(即LE单模蓝牙),同样可以实现本申请实施例所公开的设备连接方法。示例性地,该第一蓝牙音频设备可以与第一目标设备建立LE蓝牙连接,并在LE蓝牙链路上配置该第一蓝牙音频设备与第一目标设备之间的安全管理协议,以及执行该安全管理协议相关的交互操作(即SMP操作),获取第一目标设备的标识信息。在此基础上,第一蓝牙音频设备可以利用该标识信息,进一步建立其与第一目标设备之间的LE Audio蓝牙连接。In some embodiments, the first Bluetooth audio device may also only support LE Audio Bluetooth connection (ie, LE single-mode Bluetooth), and may also implement the device connection method disclosed in the embodiments of this application. Exemplarily, the first Bluetooth audio device can establish a LE Bluetooth connection with the first target device, configure a security management protocol between the first Bluetooth audio device and the first target device on the LE Bluetooth link, and execute the Interaction operations related to the security management protocol (ie, SMP operations) obtain the identification information of the first target device. On this basis, the first Bluetooth audio device can use the identification information to further establish a LE Audio Bluetooth connection with the first target device.
示例性地,上述SMP操作可以在第一蓝牙音频设备与第一目标设备之间的蓝牙链路(包括经典蓝牙链路或LE蓝牙链路)上进行。以第一蓝牙音频设备与第一目标设备建立经典蓝牙连接的过程为例,该第一蓝牙音频设备与第一目标设备之间可以配置BR/EDR通道,即表示该第一蓝牙音频设备与第一目标设备可以基于BR/EDR技术建立ACL(Asynchronous Connection Less,异步无链接)或SCO(Synchronous Connection Oriented,同步定向链接)等类型的蓝牙物理链路,也可以表示两者建立上层协议连接,例如A2DP(Advanced Audio Distribution Profile,高级音频传送规格)、HFP(Hands-Free-Profile,免提规格)等,或者中介协议SPP(Serial Port Profile,串口协议)等,具体可参考相关版本蓝牙协议的规定。优选地,上述SMP操作可以基于第一蓝牙音频设备与第一目标设备之间的ACL链路实现,在两者建立经典蓝牙连接的过程中完成相关的交互信息传递。Exemplarily, the above SMP operation may be performed on a Bluetooth link (including a classic Bluetooth link or a LE Bluetooth link) between the first Bluetooth audio device and the first target device. Taking the process of establishing a classic Bluetooth connection between the first Bluetooth audio device and the first target device as an example, a BR/EDR channel can be configured between the first Bluetooth audio device and the first target device, which means that the first Bluetooth audio device and the first target device A target device can establish a Bluetooth physical link such as ACL (Asynchronous Connection Less, asynchronous linkless) or SCO (Synchronous Connection Oriented, synchronous directional link) based on BR/EDR technology, or it can also indicate that the two establish an upper-layer protocol connection, such as A2DP (Advanced Audio Distribution Profile, advanced audio transmission specification), HFP (Hands-Free-Profile, hands-free specification), etc., or intermediary protocol SPP (Serial Port Profile, serial port protocol), etc. For details, please refer to the regulations of the relevant version of the Bluetooth protocol . Preferably, the above SMP operation can be implemented based on the ACL link between the first Bluetooth audio device and the first target device, and the relevant interactive information transfer is completed during the process of establishing a classic Bluetooth connection between the two.
基于上述蓝牙链路(例如ACL链路等),第一蓝牙音频设备可以接收第一目标设备通过SMP操作所发送的安全管理信息,进而可以根据该安全管理信息确定出第一目标设备的标识信息。在一些实施例中,上述安全管理信息可以仅包括该第一目标设备对应的IRK(Identity Resolving Key,蓝牙设备地址解析密钥),从而第一蓝牙音频设备在接收到该IRK之后,可以直接对该IRK进行计算,得到第一目标设备的标识信息,尤其可以包括针对该第一目标设备的BLE地址等。Based on the above Bluetooth link (such as ACL link, etc.), the first Bluetooth audio device can receive the security management information sent by the first target device through the SMP operation, and then can determine the identification information of the first target device based on the security management information. . In some embodiments, the above security management information may only include the IRK (Identity Resolving Key, Bluetooth device address resolution key) corresponding to the first target device, so that after receiving the IRK, the first Bluetooth audio device can directly The IRK is calculated to obtain the identification information of the first target device, which may especially include the BLE address of the first target device, etc.
在另一些实施例中,上述安全管理信息也可以包括载有上述IRK的加密数据包,例如通过SMP操作中所产生的STK/LTK(Short Term Key/Long Term Key),对该IRK进行加密后所得到的数据包。第一蓝牙音频设备在接收到该安全管理信息之后,可以从中解析得到相应的第一目标设备的IRK,进而可以对该IRK进行计算,得到第一目标设备的标识信息,尤其可包括针对该第一目标设备的BLE地址等。In other embodiments, the above-mentioned security management information may also include an encrypted data packet carrying the above-mentioned IRK, for example, through STK/LTK (Short Term Key/Long Term Key) generated in the SMP operation. After encrypting the IRK the resulting packet. After receiving the security management information, the first Bluetooth audio device can parse it to obtain the IRK of the corresponding first target device, and then calculate the IRK to obtain the identification information of the first target device, which may especially include the identification information for the first target device. A BLE address of the target device, etc.
具体举例来说,上述SMP操作可以包括交换信息(S1)、产生加密密钥(S2)、加密连接(S3)以及分发IRK(S4)四个主要步骤。其中,交换信息(S1)步骤主要用于在第一蓝牙音频设备以及第一目标设备之间交换相关的配对参数或特性信息(Pairing Feature),进而基于不同的配对情况,可以采用相应的不同流程来产生上述的STK/LTK。在利用STK/LTK实现加密的链路上,第一目标设备可以将自身对应的IRK加密传输至第一蓝牙音频设备,从而第一蓝牙音频设备可以安全地获取第一目标设备的IRK,以用于计算其标识信息(例如设备蓝牙地址等),实现后续的定向连接过程。For example, the above-mentioned SMP operation may include four main steps: exchanging information (S1), generating encryption keys (S2), encrypting connections (S3), and distributing IRKs (S4). Among them, the step of exchanging information (S1) is mainly used to exchange relevant pairing parameters or feature information (Pairing Feature) between the first Bluetooth audio device and the first target device, and then based on different pairing situations, different processes can be adopted. To generate the above STK/LTK. On a link that uses STK/LTK to implement encryption, the first target device can encrypt and transmit its corresponding IRK to the first Bluetooth audio device, so that the first Bluetooth audio device can securely obtain the IRK of the first target device for use. To calculate its identification information (such as device Bluetooth address, etc.) and implement the subsequent directional connection process.
304、发送与上述标识信息对应的低功耗蓝牙广播消息,该低功耗蓝牙广播消息用于指示第一蓝牙音频设备能够响应第一目标设备发起的低功耗蓝牙音频连接请求。304. Send a low-power Bluetooth broadcast message corresponding to the above identification information. The low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device.
在本申请实施例中,第一蓝牙音频设备在获取上述第一目标设备的标识信息之后,可以基于该标识信息,生成并发送与该标识信息对应的LE Audio广播消息,以使第一目标设备在接收到该LE Audio广播消息之后,可以在确认该LE Audio广播消息与自身的标识信息相对应的情况下,与第一蓝牙音频设备建立LE Audio蓝牙连接。In this embodiment of the present application, after acquiring the identification information of the first target device, the first Bluetooth audio device can generate and send an LE Audio broadcast message corresponding to the identification information based on the identification information, so that the first target device After receiving the LE Audio broadcast message, the LE Audio Bluetooth connection can be established with the first Bluetooth audio device after confirming that the LE Audio broadcast message corresponds to its own identification information.
示例性地,若上述标识信息包括第一目标设备的设备蓝牙地址,尤其可以包括该第一目标设备的BLE地址,则第一蓝牙音频设备可以基于该标识信息,生成针对第一目标设备的定向可连接广播消息(ADV_DIRECT_IND)。其中,该广播消息可以为“定向可连接”的LE Audio广播消息。可以理解,针对不同终端设备的标识信息,第一蓝牙音频设备所生成并发送的LE Audio广播消息也可以不相同,以指向相应的终端设备。For example, if the above identification information includes the device Bluetooth address of the first target device, especially the BLE address of the first target device, then the first Bluetooth audio device can generate an orientation for the first target device based on the identification information. Connectable broadcast message (ADV_DIRECT_IND). Among them, the broadcast message can be a "directed connectable" LE Audio broadcast message. It can be understood that for the identification information of different terminal devices, the LE Audio broadcast messages generated and sent by the first Bluetooth audio device may also be different to point to the corresponding terminal devices.
在此基础上,第一蓝牙音频设备可以通过广播的方式发送上述LE Audio广播消息,从而可以指示接收到该LE Audio广播消息的终端设备对自身进行判断,若判断出自身为该LE Audio广播消息所指定的第一目标设备,则该第一目标设备可以向第一蓝牙音频设备发送相应的低功耗蓝牙音频连接请求,以使第一蓝牙音频设备与该第一目标设备建立LE Audio蓝牙连接。On this basis, the first Bluetooth audio device can send the above-mentioned LE Audio broadcast message by broadcasting, thereby instructing the terminal device that receives the LE Audio broadcast message to judge itself. If it determines that it is the LE Audio broadcast message If the specified first target device is the first target device, the first target device can send a corresponding low-power Bluetooth audio connection request to the first Bluetooth audio device, so that the first Bluetooth audio device establishes a LE Audio Bluetooth connection with the first target device. .
306、接收第一目标设备发送的低功耗蓝牙音频连接请求。306. Receive the low-power Bluetooth audio connection request sent by the first target device.
在本申请实施例中,由于第一蓝牙音频设备所发送的LE Audio广播消息与第一目标设备的标识信息相对应,第一目标设备在接收到该LE Audio广播消息之后,可以确定该LE Audio广播消息对应的标识信息与该第一目标设备自身的标识信息相匹配,进而可以响应于该LE Audio广播消息,向第一蓝牙音频设备发送低功耗蓝牙音频连接请求(即发起低功耗蓝牙音频连接,或称发起低功耗蓝牙音频连接请求)。在此基础上,第一蓝牙音频设备可以接收到上述低功耗蓝牙音频连接请求,该低功耗蓝牙音频连接请求可以特指request指令数据包,并据此针对性地与第一目标设备建立LE Audio蓝牙连接。In the embodiment of the present application, since the LE Audio broadcast message sent by the first Bluetooth audio device corresponds to the identification information of the first target device, the first target device can determine the LE Audio broadcast message after receiving the LE Audio broadcast message. The identification information corresponding to the broadcast message matches the identification information of the first target device itself, and then in response to the LE Audio broadcast message, a low-power Bluetooth audio connection request can be sent to the first Bluetooth audio device (i.e., a low-power Bluetooth audio connection request is initiated). Audio connection, or initiating a low-power Bluetooth audio connection request). On this basis, the first Bluetooth audio device can receive the above-mentioned low-power Bluetooth audio connection request. The low-power Bluetooth audio connection request can specifically refer to the request instruction data packet, and accordingly establish a targeted connection with the first target device. LE Audio Bluetooth connection.
需要说明的是,具有不同标识信息的第二目标设备在接收到上述LE Audio广播消息之后,可以确定该LE Audio广播消息对应的标识信息与该第二目标设备自身的标识信息不匹配,从而可以不响应这一LE Audio广播消息(例如直接丢弃该LE Audio广播消息对应的广播数据包等),有效避免了第一蓝牙音频设备与该第二目标设备误连接。It should be noted that after receiving the above-mentioned LE Audio broadcast message, the second target device with different identification information can determine that the identification information corresponding to the LE Audio broadcast message does not match the identification information of the second target device itself, so that it can Not responding to this LE Audio broadcast message (for example, directly discarding the broadcast data packet corresponding to the LE Audio broadcast message, etc.) effectively avoids misconnection between the first Bluetooth audio device and the second target device.
308、响应于该低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。308. In response to the low-power Bluetooth audio connection request, establish a low-power Bluetooth audio connection with the first target device.
在本申请实施例中,第一蓝牙音频设备在接收到第一目标设备所发送的低功耗蓝牙音频连接请求之后,可以响应于该低功耗蓝牙音频连接请求,针对性地与第一目标设备建立LE Audio蓝牙连接,此处不再赘述。In this embodiment of the present application, after receiving the low-power Bluetooth audio connection request sent by the first target device, the first Bluetooth audio device may respond to the low-power Bluetooth audio connection request and communicate with the first target in a targeted manner. The device establishes a LE Audio Bluetooth connection, which will not be described here.
可见,实施上述实施例所描述的设备连接方法,第一蓝牙音频设备可以通过在经典蓝牙链路上与第一目标设备进行SMP操作,以快速、准确地取该第一目标设备的标识信息,进而可以基于该第一目标设备的标识信息,向该第一目标设备发送“定向可连接”的LE Audio广播消息,从而第一目标设备可以在该针对性的LE Audio广播消息的触发下,与上述第一蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保第一蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的第一目标设备所响应,而具有不同标识信息的第二目标设备在接收到上述LE Audio广播消息时可以不作任何响应。从而,能够使第一蓝牙音频设备优先与第一目标设备建立LE Audio蓝牙连接,并避免该第一蓝牙音频设备与第二目标设备误连接,有利于降低第一蓝牙音频设备误连终端设备的可能性,有效提升了第一蓝牙音频设备进行通信连接的准确性及灵活性。It can be seen that by implementing the device connection method described in the above embodiment, the first Bluetooth audio device can quickly and accurately obtain the identification information of the first target device by performing SMP operations with the first target device on the classic Bluetooth link. Then, based on the identification information of the first target device, a "directed connectable" LE Audio broadcast message can be sent to the first target device, so that the first target device can communicate with the first target device under the trigger of the targeted LE Audio broadcast message. The above-mentioned first Bluetooth audio device establishes a LE Audio Bluetooth connection. Such a device connection method can ensure that the LE Audio broadcast message sent by the first Bluetooth audio device can only be responded to by the first target device expected by the user, and the second target device with different identification information receives the above-mentioned LE Audio broadcast message. There is no need to make any response when sending a message. Therefore, the first Bluetooth audio device can be prioritized to establish a LE Audio Bluetooth connection with the first target device, and the first Bluetooth audio device can be prevented from being mistakenly connected to the second target device, which is beneficial to reducing the risk of the first Bluetooth audio device being mistakenly connected to the terminal device. possibility, effectively improving the accuracy and flexibility of communication connections for the first Bluetooth audio device.
请参阅图4,图4是本申请实施例公开的另一种设备连接方法的流程示意图,该方法可以应用于上述的第一蓝牙音频设备。如图4所示,该设备连接方法可以包括以下步骤:Please refer to Figure 4. Figure 4 is a schematic flowchart of another device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned first Bluetooth audio device. As shown in Figure 4, the device connection method may include the following steps:
402、基于第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收该第一目标设备发送的安全管理信息。402. Based on the security management protocol between the first Bluetooth audio device and the first target device, receive the security management information sent by the first target device.
在本申请实施例中,第一蓝牙音频设备基于其与第一目标设备之间的安全管理协议来获取该第一目标设备的标识信息,具体可以是通过对该第一目标设备所发送的安全管理信息进行处理得到的。示例性地,上述安全管理信息,可以仅包括该第一目标设备对应的蓝牙设备地址解析秘钥IRK,也可以包括载有上述IRK的加密数据包等。In this embodiment of the present application, the first Bluetooth audio device obtains the identification information of the first target device based on the security management protocol between it and the first target device. Specifically, it may be through the security information sent to the first target device. Obtained by processing management information. For example, the above security management information may only include the Bluetooth device address resolution key IRK corresponding to the first target device, or may include an encrypted data packet carrying the above IRK, etc.
在一些实施例中,第一蓝牙音频设备与第一目标设备之间可以执行基于安全管理协议的SMP操作,以使该第一蓝牙音频设备可以获取第一目标设备通过SMP操作所发送的安全管理信息。示例性地,在第一蓝牙音频设备与第一目标设备建立经典蓝牙连接的情况下,可以在两者之间的经典蓝牙链路上配置该第一蓝牙音频设备与第一目标设备之间的安全管理协议,从而两者均可以基于该经典蓝牙链路执行SMP操作,相互向对方传递各自的IRK。以该安全管理信息包含第一目标设备的IRK为例,第一蓝牙音频设备可以基于上述安全管理协议,接收到第一目标设备所发送的安全管理信息,进而可以根据该安全管理信息直接获取,或者对其解析得到第一目标设备对应的IRK,以便于在后续步骤中基于对IRK的相关解析计算规则,由该IRK计算得到针对第一目标设备的标识信息。In some embodiments, an SMP operation based on the security management protocol can be performed between the first Bluetooth audio device and the first target device, so that the first Bluetooth audio device can obtain the security management sent by the first target device through the SMP operation. information. For example, when a first Bluetooth audio device establishes a classic Bluetooth connection with a first target device, the connection between the first Bluetooth audio device and the first target device can be configured on the classic Bluetooth link between the two. Security Management Protocol, so that both can perform SMP operations based on this classic Bluetooth link and pass their respective IRKs to each other. Taking the security management information including the IRK of the first target device as an example, the first Bluetooth audio device can receive the security management information sent by the first target device based on the above security management protocol, and then can directly obtain it based on the security management information. Or parse it to obtain the IRK corresponding to the first target device, so that in subsequent steps, based on the relevant parsing and calculation rules for the IRK, the identification information for the first target device can be calculated from the IRK.
404、根据上述安全管理信息对应的计算规则,对该安全管理信息进行计算,以生成第一目标设备的设备蓝牙地址。404. Calculate the security management information according to the calculation rules corresponding to the above security management information to generate the device Bluetooth address of the first target device.
在本申请实施例中,上述第一目标设备的标识信息,可以包括该第一目标设备的设备蓝牙地址。示例性地,该设备蓝牙地址可以包括RPA(Resolvable Private Address,可解析私有地址)类型的BLE地址,第一蓝牙音频设备可以基于该BLE地址生成“定向可连接”的LE Audio广播消息,以指示接收到该LE Audio广播消息的第一目标设备在确认其指向自身后,与该第一蓝牙音频设备建立相应的LE Audio蓝牙连接。In this embodiment of the present application, the identification information of the first target device may include the device Bluetooth address of the first target device. For example, the device Bluetooth address may include an RPA (Resolvable Private Address, resolvable private address) type BLE address, and the first Bluetooth audio device may generate a "directed connectable" LE Audio broadcast message based on the BLE address to indicate The first target device that receives the LE Audio broadcast message establishes a corresponding LE Audio Bluetooth connection with the first Bluetooth audio device after confirming that it points to itself.
在一些实施例中,上述蓝牙设备地址可以包括两部分,其中一部分可以包括用于进行哈希(hash)运算的随机数prand,另一部分则可以由该随机数prand与上述IRK进行哈希运算得到。具体举例来说,该蓝牙设备地址可以包括48bits,其中高24bits可以包括22bits的随机数prand以及2bits的指定比特(例如10、01等,可以用于标识、校验等功能),低24bits则可以由第一蓝牙音频设备根据上述22bits的随机数prand以及第一目标设备对应的IRK进行哈希运算得到。在此基础上,第一蓝牙音频设备可以在后续步骤中生成包含该设备蓝牙地址的LE Audio广播消息,并通过广播的方式发送该LE Audio广播消息。In some embodiments, the above-mentioned Bluetooth device address may include two parts, one part of which may include a random number prand used for hash operation, and the other part may be obtained by hashing the random number prand with the above-mentioned IRK. . For example, the Bluetooth device address can include 48 bits, of which the high 24 bits can include 22 bits of random number prand and 2 bits of designated bits (such as 10, 01, etc., which can be used for identification, verification, etc.), and the low 24 bits can include It is obtained by the first Bluetooth audio device performing a hash operation based on the above-mentioned 22-bit random number prand and the IRK corresponding to the first target device. On this basis, the first Bluetooth audio device can generate a LE Audio broadcast message containing the Bluetooth address of the device in subsequent steps, and send the LE Audio broadcast message by broadcasting.
406、根据上述设备蓝牙地址,生成携带该设备蓝牙地址的低功耗蓝牙广播消息。406. According to the Bluetooth address of the above device, generate a low-power Bluetooth broadcast message carrying the Bluetooth address of the device.
在本申请实施例中,第一蓝牙音频设备可以根据其所生成的针对第一目标设备的设备蓝牙地址,进一步生成携带该设备蓝牙地址的LE Audio广播消息。可选地,该LE Audio广播消息还可以包括该第一蓝牙音频设备自身的标识信息,例如设备地址标识信息、设备身份标识信息、设备名称标识信息、设备型号标识信息等,以供接收到该LE Audio广播消息的终端设备在确认自身为该LE Audio广播消息所指定的第一目标设备之后,可以据此向上述第一蓝牙音频设备发起低功耗蓝牙音频连接。In this embodiment of the present application, the first Bluetooth audio device can further generate an LE Audio broadcast message carrying the Bluetooth address of the device based on the device Bluetooth address it generates for the first target device. Optionally, the LE Audio broadcast message may also include identification information of the first Bluetooth audio device itself, such as device address identification information, device identity identification information, device name identification information, device model identification information, etc., for receiving the After confirming that the terminal device of the LE Audio broadcast message is the first target device specified by the LE Audio broadcast message, the terminal device can initiate a low-power Bluetooth audio connection to the above-mentioned first Bluetooth audio device accordingly.
在一些实施例中,第一目标设备接收到上述LE Audio广播消息之后,可以获取其所携带的设备蓝牙地址,并进一步提取其中的随机数prand。在此基础上,第一目标设备可以将该随机数prand与自身的IRK进行哈希运算,若由此得到的校验蓝牙地址与上述LE Audio广播消息所携带的设备蓝牙地址相匹配,则可以确认上述LE Audio广播消息指向该第一目标设备。In some embodiments, after receiving the above LE Audio broadcast message, the first target device can obtain the Bluetooth address of the device it carries, and further extract the random number prand therein. On this basis, the first target device can hash the random number prand with its own IRK. If the verification Bluetooth address obtained matches the device Bluetooth address carried in the above LE Audio broadcast message, then it can Confirm that the above LE Audio broadcast message points to the first target device.
在另一些实施例中,第二目标设备接收到上述LE Audio广播消息之后,同样可以提取其所携带的设备蓝牙地址中的随机数prand,并将该随机数prand与自身的IRK进行哈希运算,若由此得到的校验蓝牙地址与上述LE Audio广播消息所携带的设备蓝牙地址不匹配,则可以确认上述LE Audio广播消息并非指向该第二目标设备。在此基础上,上述匹配的第一目标设备可以向第一蓝牙音频设备发起低功耗蓝牙音频连接,而不匹配的第二目标设备则可以忽略这一LE Audio广播消息,从而可以实现第一蓝牙音频设备的定向连接。In other embodiments, after the second target device receives the above-mentioned LE Audio broadcast message, it can also extract the random number prand in the Bluetooth address of the device it carries, and perform a hash operation on the random number prand and its own IRK. , if the verification Bluetooth address obtained thereby does not match the device Bluetooth address carried in the above-mentioned LE Audio broadcast message, it can be confirmed that the above-mentioned LE Audio broadcast message is not directed to the second target device. On this basis, the above-mentioned matching first target device can initiate a low-power Bluetooth audio connection to the first Bluetooth audio device, while the unmatched second target device can ignore this LE Audio broadcast message, thereby achieving the first Directed connections for Bluetooth audio devices.
408、发送携带该设备蓝牙地址的低功耗蓝牙广播消息。408. Send a low-power Bluetooth broadcast message carrying the Bluetooth address of the device.
其中,步骤408与上述步骤304类似。需要说明的是,终端设备在接收到携带上述设备蓝牙地址的LE Audio广播消息之后,若判断出自身为该LE Audio广播消息所指定的第一目标设备,则该第一目标设备可以向第一蓝牙音频设备发送相应的低功耗蓝牙音频连接请求,以使第一蓝牙音频设备与该第一目标设备建立LE Audio蓝牙连接。Among them, step 408 is similar to the above-mentioned step 304. It should be noted that, after receiving the LE Audio broadcast message carrying the Bluetooth address of the above-mentioned device, if the terminal device determines that it is the first target device specified by the LE Audio broadcast message, the first target device can send a message to the first target device. The Bluetooth audio device sends a corresponding low-power Bluetooth audio connection request, so that the first Bluetooth audio device establishes a LE Audio Bluetooth connection with the first target device.
410、接收第一目标设备发送的低功耗蓝牙音频连接请求。410. Receive the low-power Bluetooth audio connection request sent by the first target device.
412、响应于该低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。412. In response to the low-power Bluetooth audio connection request, establish a low-power Bluetooth audio connection with the first target device.
其中,步骤410以及步骤412与上述步骤306以及步骤308类似,此处不再赘述。Among them, step 410 and step 412 are similar to the above-mentioned step 306 and step 308, and will not be described again here.
可见,实施上述实施例所描述的设备连接方法,第一蓝牙音频设备可以基于其通过SMP操作所快速、准确获取的第一目标设备的标识信息,向该第一目标设备发送“定向可连接”的LE Audio广播消息,从而第一目标设备可以在该针对性的LE Audio广播消息的触发下,与上述第一蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保第一蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的第一目标设备所响应,从而能够避免该第一蓝牙音频设备与第二目标设备误连接,有利于降低第一蓝牙音频设备误连终端设备的可能性,有效提升了第一蓝牙音频设备进行通信连接的准确性及灵活性。此外,由第一蓝牙音频设备利用第一目标设备的IRK来计算RPA类型的BLE地址,可以确保相应的 LE Audio广播消息仅能被该第一目标设备正确解析并匹配,从而能够赋予上述LE Audio广播消息“定向可连接”的特性,有利于提升第一蓝牙音频设备定向连接终端设备的准确性及可靠性。It can be seen that by implementing the device connection method described in the above embodiment, the first Bluetooth audio device can send a "directional connectable" message to the first target device based on the identification information of the first target device that it quickly and accurately obtains through the SMP operation. LE Audio broadcast message, so that the first target device can establish a LE Audio Bluetooth connection with the above-mentioned first Bluetooth audio device under the trigger of the targeted LE Audio broadcast message. Such a device connection method can ensure that the LE Audio broadcast message sent by the first Bluetooth audio device can only be responded to by the first target device expected by the user, thereby avoiding misconnection between the first Bluetooth audio device and the second target device. It is beneficial to reduce the possibility of the first Bluetooth audio device mistakenly connecting to the terminal device, and effectively improves the accuracy and flexibility of the communication connection of the first Bluetooth audio device. In addition, the first Bluetooth audio device uses the IRK of the first target device to calculate the RPA type BLE address, which can ensure that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the first target device, thereby being able to give the above LE Audio The "directionally connectable" feature of the broadcast message is conducive to improving the accuracy and reliability of the first Bluetooth audio device's directional connection to the terminal device.
请参阅图5,图5是本申请实施例公开的又一种设备连接方法的流程示意图,该方法可以应用于上述的第一蓝牙音频设备,该第一蓝牙音频设备可以与第二蓝牙音频设备建立通信连接,其中,该第二蓝牙音频设备与第一蓝牙音频设备可以属于同一蓝牙设备集合。如图5所示,该设备连接方法可以包括以下步骤:Please refer to Figure 5. Figure 5 is a schematic flow chart of yet another device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned first Bluetooth audio device. The first Bluetooth audio device can be connected to a second Bluetooth audio device. A communication connection is established, wherein the second Bluetooth audio device and the first Bluetooth audio device may belong to the same Bluetooth device set. As shown in Figure 5, the device connection method may include the following steps:
502、基于第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收该第一目标设备发送的安全管理信息。502. Based on the security management protocol between the first Bluetooth audio device and the first target device, receive the security management information sent by the first target device.
其中,步骤502与上述步骤402类似。在本申请实施例中,已建立经典蓝牙连接的第一蓝牙音频设备和第二蓝牙音频设备可以分别与第一目标设备建立LE Audio蓝牙连接,以提升蓝牙音频设备进行通信连接的灵活性,同时也有利于提升各个蓝牙音频设备基于BLE技术传输音频数据的可靠性。Among them, step 502 is similar to the above-mentioned step 402. In the embodiment of this application, the first Bluetooth audio device and the second Bluetooth audio device that have established a classic Bluetooth connection can respectively establish LE Audio Bluetooth connections with the first target device to improve the flexibility of communication connections between the Bluetooth audio devices. At the same time, It is also helpful to improve the reliability of audio data transmission by various Bluetooth audio devices based on BLE technology.
需要说明的是,基于发起经典蓝牙连接请求的主体差异(例如在不同场景下可以由第一目标设备、第一蓝牙音频设备或第二蓝牙音频设备发出page包),或者响应该经典蓝牙连接请求的主体差异(例如在不同场景下可以由第一目标设备、第二蓝牙音频设备或第二蓝牙音频设备开启page scan模式,以接收page包),在需要与第一目标设备建立经典蓝牙连接时,可以是由第一蓝牙音频设备与第一目标设备建立经典蓝牙连接,也可以是该第一蓝牙音频设备的同组设备(即第二蓝牙音频设备)与第一目标设备建立经典蓝牙连接,还可以是上述第一蓝牙音频设备和第二蓝牙音频设备同时与第一目标设备建立经典蓝牙连接。在此基础上,无论第一蓝牙音频设备和/或第二蓝牙音频设备通过何种方式与第一目标设备建立经典蓝牙连接,该第一蓝牙音频设备及第二蓝牙音频设备均可在后续步骤中对第一目标设备所发送的安全管理信息进行同步,或者直接对由该安全管理信息所确定的第一目标设备的标识信息进行同步,并开启各自的LE Audio广播,以分别发送与上述标识信息对应的LE Audio广播消息,进而可以分别与第一目标设备建立LE Audio蓝牙连接。It should be noted that based on the difference in the subject initiating the classic Bluetooth connection request (for example, the page packet may be issued by the first target device, the first Bluetooth audio device or the second Bluetooth audio device in different scenarios), or in response to the classic Bluetooth connection request Subject differences (for example, in different scenarios, the page scan mode can be turned on by the first target device, the second Bluetooth audio device, or the second Bluetooth audio device to receive the page packet), when it is necessary to establish a classic Bluetooth connection with the first target device , it can be that the first Bluetooth audio device establishes a classic Bluetooth connection with the first target device, or it can be that a device in the same group of the first Bluetooth audio device (i.e., the second Bluetooth audio device) establishes a classic Bluetooth connection with the first target device, It is also possible that the first Bluetooth audio device and the second Bluetooth audio device establish a classic Bluetooth connection with the first target device at the same time. On this basis, no matter how the first Bluetooth audio device and/or the second Bluetooth audio device establishes a classic Bluetooth connection with the first target device, the first Bluetooth audio device and the second Bluetooth audio device can be used in subsequent steps. Synchronize the security management information sent by the first target device, or directly synchronize the identification information of the first target device determined by the security management information, and turn on the respective LE Audio broadcast to send the above identification respectively. The LE Audio broadcast message corresponding to the information can then establish a LE Audio Bluetooth connection with the first target device respectively.
在一些实施例中,上述第一蓝牙音频设备和第二蓝牙音频设备可以具备主从关系,以第一蓝牙音频设备及第二蓝牙音频设备均为耳机设备为例,上述第一蓝牙音频设备可以为主耳机,第二蓝牙音频设备可以为从耳机,此时可以由作为主耳机的第一蓝牙音频设备与第一目标设备建立经典蓝牙连接,并基于该第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收第一目标设备发送的安全管理信息。在此基础上,第二蓝牙音频设备可以通过其与第一蓝牙音频设备之间的经典蓝牙连接,同步获取上述安全管理信息,或者同步获取由该安全管理信息所确定的第一目标设备的标识信息。In some embodiments, the first Bluetooth audio device and the second Bluetooth audio device may have a master-slave relationship. Taking the first Bluetooth audio device and the second Bluetooth audio device as both earphone devices as an example, the first Bluetooth audio device may As the master earphone, the second Bluetooth audio device can be the slave earphone. At this time, the first Bluetooth audio device as the master earphone can establish a classic Bluetooth connection with the first target device, and based on the first Bluetooth audio device and the first target device The security management protocol between the two devices receives the security management information sent by the first target device. On this basis, the second Bluetooth audio device can synchronously obtain the above-mentioned security management information through the classic Bluetooth connection with the first Bluetooth audio device, or synchronously obtain the identity of the first target device determined by the security management information. information.
504、根据上述安全管理信息,确定第一目标设备的标识信息,并发送与该标识信息对应的低功耗蓝牙广播消息。504. Based on the above security management information, determine the identification information of the first target device, and send a low-power Bluetooth broadcast message corresponding to the identification information.
其中,步骤504与上述步骤404以及步骤406类似,上述第一目标设备的标识信息可以包括该第一目标设备的设备蓝牙地址,即第一蓝牙音频设备可以发送携带该设备蓝牙地址的LE Audio广播消息,该LE Audio广播消息可以用于指示第一目标设备向该第一蓝牙音频设备发起低功耗蓝牙音频连接。Among them, step 504 is similar to the above-mentioned step 404 and step 406. The identification information of the first target device may include the device Bluetooth address of the first target device, that is, the first Bluetooth audio device may send an LE Audio broadcast carrying the device Bluetooth address. message, the LE Audio broadcast message can be used to instruct the first target device to initiate a low-power Bluetooth audio connection to the first Bluetooth audio device.
506、向第二蓝牙音频设备发送上述第一目标设备的标识信息,以使第二蓝牙音频设备发送与该标识信息对应的低功耗蓝牙广播消息。506. Send the identification information of the first target device to the second Bluetooth audio device, so that the second Bluetooth audio device sends a low-power Bluetooth broadcast message corresponding to the identification information.
在本申请实施例中,第一蓝牙音频设备可以在根据上述安全管理信息确定出第一目标设备的标识信息之后,将该标识信息主动发送至第二蓝牙音频设备,以实现第一蓝牙音频设备和第二蓝牙音频设备之间的信息同步。其中,上述标识信息可以包括第一目标设备的设备蓝牙地址,从而第二蓝牙音频设备也可以发送携带该设备蓝牙地址的LE Audio广播消息,该LE Audio广播消息可以用于指示第一目标设备向该第二蓝牙音频设备发起低功耗蓝牙音频连接。In this embodiment of the present application, the first Bluetooth audio device may, after determining the identification information of the first target device based on the above security management information, actively send the identification information to the second Bluetooth audio device to implement the first Bluetooth audio device. Synchronize information with the second Bluetooth audio device. Wherein, the above-mentioned identification information may include the device Bluetooth address of the first target device, so that the second Bluetooth audio device may also send an LE Audio broadcast message carrying the Bluetooth address of the device. The LE Audio broadcast message may be used to instruct the first target device to The second Bluetooth audio device initiates a low-power Bluetooth audio connection.
作为一种可选的实施方式,第二蓝牙音频设备也可以通过监听的方式,利用监听数据获取第一目标设备的标识信息,以实现第一蓝牙音频设备和第二蓝牙音频设备之间的信息同步。需要说明的是,由于对第一目标设备所发送的安全管理信息进行计算,以得到该第一目标设备的标识信息的过程是在第一蓝牙音频设备内完成的,第二蓝牙音频设备并非通过监听直接获取上述标识信息,而是获取上述安全管理 信息(即监听数据可以包括该安全管理信息),并由第二蓝牙音频设备对该安全管理信息进行类似的计算,以得到第一目标设备的标识信息。示例性地,第一蓝牙音频设备可以通过其与第一目标设备之间的经典蓝牙链路,接收该第一目标设备所发送的安全管理信息,该安全管理信息可以包含第一目标设备的IRK,从而第一蓝牙音频设备可以采用指定的随机数prand_1对该IRK进行计算,得到针对第一目标设备的BLE地址。与此同时,第二蓝牙音频设备可以对上述第一蓝牙音频设备与第一目标设备之间的经典蓝牙链路进行监听,并根据监听数据获取第一目标设备所发送的安全管理信息,进而可以采用另一指定的随机数prand_2(可以与上述prand_1相同,也可以不相同),对该安全管理信息所包含的IRK进行计算,得到针对第一目标设备的BLE地址。在此基础上,上述第一蓝牙音频设备及第二蓝牙音频设备均可发送针对第一目标设备的“定向可连接”的LE Audio广播消息,以指示该第一目标设备分别与第一蓝牙音频设备及第二蓝牙音频设备建立LE Audio蓝牙连接。As an optional implementation, the second Bluetooth audio device can also use monitoring data to obtain the identification information of the first target device through monitoring, so as to realize the information exchange between the first Bluetooth audio device and the second Bluetooth audio device. Synchronize. It should be noted that since the process of calculating the security management information sent by the first target device to obtain the identification information of the first target device is completed within the first Bluetooth audio device, the second Bluetooth audio device does not The monitoring directly obtains the above identification information, but obtains the above security management information (that is, the monitoring data may include the security management information), and the second Bluetooth audio device performs similar calculations on the security management information to obtain the first target device's Identification information. For example, the first Bluetooth audio device may receive the security management information sent by the first target device through the classic Bluetooth link between it and the first target device. The security management information may include the IRK of the first target device. , so that the first Bluetooth audio device can use the specified random number prand_1 to calculate the IRK and obtain the BLE address for the first target device. At the same time, the second Bluetooth audio device can monitor the classic Bluetooth link between the first Bluetooth audio device and the first target device, and obtain the security management information sent by the first target device based on the monitoring data, and then can Using another specified random number prand_2 (which may or may not be the same as the above prand_1), the IRK contained in the security management information is calculated to obtain the BLE address of the first target device. On this basis, both the first Bluetooth audio device and the second Bluetooth audio device can send a "directed connectable" LE Audio broadcast message directed to the first target device to instruct the first target device to communicate with the first Bluetooth audio device respectively. The device and the second Bluetooth audio device establish a LE Audio Bluetooth connection.
508、接收第一目标设备发送的低功耗蓝牙音频连接请求。508. Receive the low-power Bluetooth audio connection request sent by the first target device.
510、响应于上述低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。510. In response to the above low-power Bluetooth audio connection request, establish a low-power Bluetooth audio connection with the first target device.
其中,步骤508以及步骤510与上述步骤306以及步骤308类似。需要说明的是,在本申请实施例中,除了第一蓝牙音频设备之外,第二蓝牙音频设备也可以同时执行上述步骤508以及步骤510,即第一蓝牙音频设备和第二蓝牙音频设备可以分别与第一目标设备建立LE Audio蓝牙连接。Among them, step 508 and step 510 are similar to the above-mentioned step 306 and step 308. It should be noted that in this embodiment of the present application, in addition to the first Bluetooth audio device, the second Bluetooth audio device can also perform the above steps 508 and 510 at the same time, that is, the first Bluetooth audio device and the second Bluetooth audio device can Establish a LE Audio Bluetooth connection with the first target device respectively.
可见,实施上述实施例所描述的设备连接方法,蓝牙音频设备可以基于其通过SMP操作所快速、准确获取的第一目标设备的标识信息,向该第一目标设备发送“定向可连接”的LE Audio广播消息,从而第一目标设备可以在该针对性的LE Audio广播消息的触发下,与上述蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的第一目标设备所响应,从而能够避免该蓝牙音频设备与第二目标设备误连接,有利于降低蓝牙音频设备误连终端设备的可能性,有效提升了蓝牙音频设备进行通信连接的准确性及灵活性。此外,通过在第一蓝牙音频设备及第二蓝牙音频设备之间同步第一目标设备的标识信息,可以使该第一蓝牙音频设备及第二蓝牙音频设备分别与第一目标设备建立LE Audio蓝牙连接,以提升蓝牙音频设备进行通信连接的灵活性,同时也有利于提升各个蓝牙音频设备基于BLE技术传输音频数据的可靠性。It can be seen that by implementing the device connection method described in the above embodiment, the Bluetooth audio device can send a "directed connectable" LE to the first target device based on the identification information of the first target device quickly and accurately obtained through the SMP operation. Audio broadcast message, so that the first target device can establish a LE Audio Bluetooth connection with the above-mentioned Bluetooth audio device under the trigger of the targeted LE Audio broadcast message. Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the first target device expected by the user, thereby preventing the Bluetooth audio device from being mistakenly connected to the second target device, which is conducive to reducing the cost of Bluetooth audio. The possibility of audio equipment mistakenly connecting to terminal equipment effectively improves the accuracy and flexibility of communication connections for Bluetooth audio equipment. In addition, by synchronizing the identification information of the first target device between the first Bluetooth audio device and the second Bluetooth audio device, the first Bluetooth audio device and the second Bluetooth audio device can establish LE Audio Bluetooth with the first target device respectively. connection to improve the flexibility of communication connections for Bluetooth audio devices, and also help improve the reliability of audio data transmission by each Bluetooth audio device based on BLE technology.
请参阅图6,图6是本申请实施例公开的又一种设备连接方法的流程示意图,该方法可以应用于上述的第二蓝牙音频设备。如图6所示,该设备连接方法可以包括以下步骤:Please refer to Figure 6. Figure 6 is a schematic flowchart of yet another device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned second Bluetooth audio device. As shown in Figure 6, the device connection method may include the following steps:
602、对第一蓝牙音频设备与第一目标设备之间的蓝牙链路进行监听,获取监听数据,其中,第二蓝牙音频设备与第一蓝牙音频设备属于同一蓝牙设备集合。602. Monitor the Bluetooth link between the first Bluetooth audio device and the first target device to obtain monitoring data, where the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set.
604、根据上述监听数据,计算得到第一目标设备的标识信息。604. Based on the above monitoring data, calculate the identification information of the first target device.
其中,步骤602以及步骤604与上述实施例中第二蓝牙音频设备通过监听的方式,利用监听数据获取第一目标设备的标识信息的实施过程类似,此处不再赘述。需要说明的是,在上述监听数据包括第一目标设备的安全管理信息,且该安全管理信息包括蓝牙设备地址解析秘钥IRK,而上述标识信息包括设备蓝牙地址的情况下,第二蓝牙音频设备可以根据上述IRK的相关解析计算规则,对该IRK进行计算,以生成第一目标设备的设备蓝牙地址。 Steps 602 and 604 are similar to the implementation process in which the second Bluetooth audio device uses monitoring data to obtain the identification information of the first target device through monitoring in the above embodiment, and will not be described again here. It should be noted that when the above-mentioned monitoring data includes the security management information of the first target device, and the security management information includes the Bluetooth device address resolution key IRK, and the above-mentioned identification information includes the device Bluetooth address, the second Bluetooth audio device The IRK can be calculated according to the relevant parsing and calculation rules of the above IRK to generate the device Bluetooth address of the first target device.
606、发送与该标识信息对应的低功耗蓝牙广播消息,该低功耗蓝牙广播消息用于指示第二蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求。606. Send a Bluetooth Low Energy broadcast message corresponding to the identification information. The Bluetooth Low Energy broadcast message is used to indicate that the second Bluetooth audio device can respond to the Bluetooth Low Energy audio connection request initiated by the first target device.
608、接收第一目标设备发送的低功耗蓝牙音频连接请求。608. Receive the low-power Bluetooth audio connection request sent by the first target device.
610、响应于上述低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。610. In response to the above low-power Bluetooth audio connection request, establish a low-power Bluetooth audio connection with the first target device.
其中,步骤606、步骤608以及步骤610分别与上述步骤304、步骤306以及步骤308类似。第二蓝牙音频设备可以采用与第一蓝牙音频设备相同的方式,向第一目标设备发送“定向可连接”的LE Audio广播消息,以针对性地与该第一目标设备建立LE Audio蓝牙连接。Among them, step 606, step 608 and step 610 are similar to the above-mentioned step 304, step 306 and step 308 respectively. The second Bluetooth audio device can use the same method as the first Bluetooth audio device to send a "directed connectable" LE Audio broadcast message to the first target device to establish a LE Audio Bluetooth connection with the first target device in a targeted manner.
作为一种可选的实施方式,上述第一蓝牙音频设备可以在其根据第一目标设备的安全管理信息,成功获取该第一目标设备的标识信息之后,直接将该标识信息发送至第二蓝牙音频设备。在此基础上,第二蓝牙音频设备可以通过接收的方式直接获取第一目标设备的标识信息,即,第二蓝牙音频设备可以接 收第一蓝牙音频设备发送的该第一目标设备的标识信息,继而可以执行上述步骤606、步骤608以及步骤610,与第一目标设备建立低功耗蓝牙音频连接。As an optional implementation, the above-mentioned first Bluetooth audio device can directly send the identification information to the second Bluetooth device after it successfully obtains the identification information of the first target device according to the security management information of the first target device. Audio equipment. On this basis, the second Bluetooth audio device can directly obtain the identification information of the first target device by receiving, that is, the second Bluetooth audio device can receive the identification information of the first target device sent by the first Bluetooth audio device, Then, the above steps 606, 608 and 610 can be executed to establish a low-power Bluetooth audio connection with the first target device.
请参阅图7,图7是本申请实施例公开的一种设备连接方法的流程示意图,该方法可以应用于上述的终端设备(即上述实施例中的第一目标设备)。如图7所示,该设备连接方法可以包括以下步骤:Please refer to FIG. 7 . FIG. 7 is a schematic flowchart of a device connection method disclosed in an embodiment of the present application. This method can be applied to the above-mentioned terminal device (ie, the first target device in the above-mentioned embodiment). As shown in Figure 7, the device connection method may include the following steps:
702、基于第一蓝牙音频设备与该终端设备之间的安全管理协议,向第一蓝牙音频设备发送与该终端设备的标识信息对应的安全管理信息。702. Based on the security management protocol between the first Bluetooth audio device and the terminal device, send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device.
在本申请实施例中,为了使蓝牙音频设备(例如上述的第一蓝牙音频设备和/或第二蓝牙音频设备)针对性地与该终端设备建立蓝牙连接,尤其包括建立LE Audio蓝牙连接,需要由第一蓝牙音频设备发出“定向可连接”的LE Audio广播消息,以指示该终端设备向第一蓝牙音频设备发送相应的低功耗蓝牙音频连接请求。示例性地,终端设备可以通过向第一蓝牙音频设备发送与其标识信息对应的安全管理信息,以使第一蓝牙音频设备可以响应于该安全管理信息,获取该终端设备的标识信息,并基于该标识信息发出针对该终端设备的LE Audio广播消息。In the embodiment of the present application, in order for the Bluetooth audio device (such as the above-mentioned first Bluetooth audio device and/or the second Bluetooth audio device) to establish a Bluetooth connection with the terminal device specifically, including establishing a LE Audio Bluetooth connection, it is necessary The first Bluetooth audio device sends a "directed connectable" LE Audio broadcast message to instruct the terminal device to send a corresponding low-power Bluetooth audio connection request to the first Bluetooth audio device. For example, the terminal device can send the security management information corresponding to its identification information to the first Bluetooth audio device, so that the first Bluetooth audio device can respond to the security management information, obtain the identification information of the terminal device, and based on the The identification information sends a LE Audio broadcast message targeted at the terminal device.
在一些实施例中,终端设备可以在通过其与第一蓝牙音频设备之间的蓝牙链路(包括经典蓝牙链路或LE蓝牙链路),配置该第一蓝牙音频设备与终端设备之间的安全管理协议,以使该终端设备及第一蓝牙音频设备均可在两者之间的蓝牙链路上执行基于该安全管理协议的SMP操作,从而可以利用该SMP操作传输上述安全管理信息。其中,上述安全管理协议,可以用于管理蓝牙音频设备与终端设备之间的配对、身份验证以及加密等协议内规定的蓝牙设备交互操作,包括实现指定私有信息的传递等,以协助实现蓝牙音频设备与该终端设备的定向连接。In some embodiments, the terminal device can configure the connection between the first Bluetooth audio device and the terminal device through a Bluetooth link (including a classic Bluetooth link or an LE Bluetooth link) between the terminal device and the first Bluetooth audio device. Security management protocol, so that both the terminal device and the first Bluetooth audio device can perform SMP operations based on the security management protocol on the Bluetooth link between the two, so that the SMP operation can be used to transmit the above security management information. Among them, the above-mentioned security management protocol can be used to manage the pairing, authentication, encryption and other Bluetooth device interaction operations specified in the protocol between Bluetooth audio devices and terminal devices, including the transfer of designated private information, etc., to assist in the implementation of Bluetooth audio The device's directed connection to this end device.
在此基础上,终端设备可以基于上述安全管理协议,通过SMP操作向第一蓝牙音频设备发送与该终端设备的标识信息对应的安全管理信息。示例性地,上述标识信息可以包括该终端设备的设备蓝牙地址,该设备蓝牙地址可以由该终端设备对应的蓝牙设备地址解析密钥IRK确定,则上述安全管理信息,可以仅包括该终端设备对应的IRK,也可以包括载有上述IRK的加密数据包等。第一蓝牙音频设备在接收到该安全管理信息后,可以从中提取终端设备对应IRK,并根据安全管理信息对应的计算规则,进一步计算出针对该终端设备的设备蓝牙地址,进而可以生成并发送携带该设备蓝牙地址的“定向可连接”的LE Audio广播消息。On this basis, the terminal device can send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device through an SMP operation based on the above security management protocol. For example, the above identification information may include the device Bluetooth address of the terminal device, and the device Bluetooth address may be determined by the Bluetooth device address resolution key IRK corresponding to the terminal device, then the above security management information may only include the device corresponding to the terminal device. The IRK may also include encrypted data packets containing the above IRK, etc. After receiving the security management information, the first Bluetooth audio device can extract the IRK corresponding to the terminal device, and further calculate the device Bluetooth address for the terminal device according to the calculation rules corresponding to the security management information, and then can generate and send the Bluetooth address of the terminal device. "Directed Connectable" LE Audio broadcast message of the device's Bluetooth address.
704、接收第一蓝牙音频设备响应于上述安全管理信息发送的第一低功耗蓝牙广播消息。704. Receive the first low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the above security management information.
在本申请实施例中,终端设备在向第一蓝牙音频设备发送上述安全管理信息之后,第一蓝牙音频设备可以根据该安全管理信息获取该终端设备的标识信息(例如该终端设备的设备蓝牙地址等),进而可以发出与该标识信息对应的LE Audio广播消息。在此基础上,终端设备可以接收到上述LE Audio广播消息,并在后续步骤中对该LE Audio广播消息进行判断,若确认其指向该终端设备自身,则可以据此向第一蓝牙音频设备发起LE Audio蓝牙连接。In this embodiment of the present application, after the terminal device sends the above security management information to the first Bluetooth audio device, the first Bluetooth audio device can obtain the identification information of the terminal device (such as the device Bluetooth address of the terminal device) based on the security management information. etc.), and then the LE Audio broadcast message corresponding to the identification information can be sent. On this basis, the terminal device can receive the above-mentioned LE Audio broadcast message, and judge the LE Audio broadcast message in subsequent steps. If it is confirmed that it points to the terminal device itself, it can initiate a request to the first Bluetooth audio device accordingly. LE Audio Bluetooth connection.
706、在确定上述第一低功耗蓝牙广播消息与终端设备的标识信息对应的情况下,响应于该第一低功耗蓝牙广播消息,向第一蓝牙音频设备发送低功耗蓝牙音频连接请求,以使第一蓝牙音频设备响应于该低功耗蓝牙音频连接请求,与该终端设备建立低功耗蓝牙音频连接。706. When it is determined that the first Bluetooth Low Energy broadcast message corresponds to the identification information of the terminal device, in response to the first Bluetooth Low Energy broadcast message, send a Bluetooth Low Energy audio connection request to the first Bluetooth audio device. , so that the first Bluetooth audio device responds to the low-power Bluetooth audio connection request and establishes a low-power Bluetooth audio connection with the terminal device.
在本申请实施例中,终端设备在接收到第一蓝牙音频设备所发送的“定向可连接”的第一LE Audio广播消息时,可以判断该第一LE Audio广播消息是否指向该终端设备自身,以确定是否需要与第一蓝牙音频设备建立LE Audio蓝牙连接。In the embodiment of this application, when the terminal device receives the first LE Audio broadcast message of "directional connectability" sent by the first Bluetooth audio device, it can determine whether the first LE Audio broadcast message is directed to the terminal device itself, To determine whether a LE Audio Bluetooth connection needs to be established with the first Bluetooth audio device.
示例性地,在上述标识信息包括设备蓝牙地址的情况下,终端设备可以根据上述安全管理信息对应的计算规则,对其所发出的安全管理信息以及该目标蓝牙地址进行计算,得到校验蓝牙地址。具体举例来说,终端设备可以将上述安全管理信息中所包含的该终端设备的IRK,与从目标蓝牙地址中提取的随机数prand进行哈希运算,得到相应的校验蓝牙地址。终端设备可以将上述目标蓝牙地址以及校验蓝牙地址进行比对,若该目标蓝牙地址与校验蓝牙地址相匹配,则可以确定上述第一LE Audio广播消息与该终端设备的设备蓝牙地址对应,即,可以确认上述第一LE Audio广播消息指向该终端设备。在此基础上,终端设备可以响应于上述第一LE Audio广播消息,向第一蓝牙音频设备发送低功耗蓝牙音频连接请求, 以与该第一蓝牙音频设备建立LE Audio蓝牙连接。For example, when the identification information includes the Bluetooth address of the device, the terminal device can calculate the security management information it sends and the target Bluetooth address according to the calculation rules corresponding to the security management information to obtain the verification Bluetooth address. . For example, the terminal device can perform a hash operation on the IRK of the terminal device contained in the above security management information and the random number prand extracted from the target Bluetooth address to obtain the corresponding verification Bluetooth address. The terminal device can compare the above-mentioned target Bluetooth address and the verification Bluetooth address. If the target Bluetooth address matches the verification Bluetooth address, it can be determined that the above-mentioned first LE Audio broadcast message corresponds to the device Bluetooth address of the terminal device. That is, it can be confirmed that the above-mentioned first LE Audio broadcast message is directed to the terminal device. On this basis, the terminal device can respond to the above-mentioned first LE Audio broadcast message and send a low-power Bluetooth audio connection request to the first Bluetooth audio device to establish a LE Audio Bluetooth connection with the first Bluetooth audio device.
作为一种可选的实施方式,与上述第一蓝牙音频设备属于同一蓝牙设备集合的第二蓝牙音频设备,也可以与该终端设备建立LE Audio蓝牙连接。其中,在终端设备向第一蓝牙音频设备发送与该终端设备的标识信息对应的安全管理信息的过程中,第一蓝牙音频设备可以在根据该安全管理信息确定出终端设备的标识信息的前后,与第二蓝牙音频设备进行信息同步,以使第二蓝牙音频设备可以获取到上述终端设备的标识信息。As an optional implementation manner, a second Bluetooth audio device that belongs to the same Bluetooth device set as the above-mentioned first Bluetooth audio device can also establish a LE Audio Bluetooth connection with the terminal device. Wherein, in the process of the terminal device sending the security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device, the first Bluetooth audio device may determine the identification information of the terminal device based on the security management information, Information synchronization is performed with the second Bluetooth audio device so that the second Bluetooth audio device can obtain the identification information of the above-mentioned terminal device.
在一些实施例中,第一蓝牙音频设备在确定出上述标识信息之后,可以将该标识信息主动发送至第二蓝牙音频设备,以使第二蓝牙音频设备也可以类似地发送与该标识信息对应的第二LE Audio广播消息。In some embodiments, after determining the above identification information, the first Bluetooth audio device can actively send the identification information to the second Bluetooth audio device, so that the second Bluetooth audio device can also similarly send the identification information corresponding to the identification information. The second LE Audio broadcast message.
在另一些实施例中,第二蓝牙音频设备可以对上述第一蓝牙音频设备与终端设备之间的蓝牙链路进行监听,并根据监听所得到的上述安全管理信息独立确定出终端设备的标识信息,继而可以发送与该标识信息对应的第二LE Audio广播消息。In other embodiments, the second Bluetooth audio device can monitor the Bluetooth link between the first Bluetooth audio device and the terminal device, and independently determine the identification information of the terminal device based on the security management information obtained by monitoring. , and then the second LE Audio broadcast message corresponding to the identification information can be sent.
在此基础上,终端设备可以分别确定第一蓝牙音频设备及第二蓝牙音频设备所发送的LE Audio广播消息是否与该终端设备的标识信息相对应,并向确认对应的LE Audio广播消息的发送端(即上述第一蓝牙音频设备和/或第二蓝牙音频设备)发送相应的低功耗蓝牙音频连接请求,以使上述第一蓝牙音频设备和/或第二蓝牙音频设备可以响应于该低功耗蓝牙音频连接请求,与该终端设备建立LE Audio蓝牙连接。On this basis, the terminal device can respectively determine whether the LE Audio broadcast message sent by the first Bluetooth audio device and the second Bluetooth audio device corresponds to the identification information of the terminal device, and confirm the sending of the corresponding LE Audio broadcast message. The terminal (i.e., the above-mentioned first Bluetooth audio device and/or the second Bluetooth audio device) sends a corresponding low-power Bluetooth audio connection request, so that the above-mentioned first Bluetooth audio device and/or the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request. Power consumption Bluetooth audio connection request to establish a LE Audio Bluetooth connection with the terminal device.
在一些实施例中,终端设备在接收到上述第二蓝牙音频设备发送的第二LE Audio广播消息之后,还可以优先判断该第二蓝牙音频设备与上述第一蓝牙音频设备是否属于同一蓝牙设备集合,并仅在两者属于同一蓝牙设备集合的情况下,才允许与该第二蓝牙音频设备建立LE Audio蓝牙连接,避免错误连接了属于不同集合的其他蓝牙音频设备。In some embodiments, after receiving the second LE Audio broadcast message sent by the second Bluetooth audio device, the terminal device may also prioritize whether the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set. , and only when the two belong to the same Bluetooth device set, the LE Audio Bluetooth connection is allowed to be established with the second Bluetooth audio device to avoid mistakenly connecting other Bluetooth audio devices belonging to different sets.
示例性地,终端设备可以根据上述第二LE Audio广播消息以及第一LE Audio广播消息,判断相应的第二蓝牙音频设备与第一蓝牙音频设备是否属于同一蓝牙设备集合。具体举例来说,终端设备在接收到上述第一LE Audio广播消息之后,可以获取相应的第一蓝牙音频设备的设备标识(例如IRK、设备蓝牙地址、产品标识码等),并将其加入候选名单或白名单中。继而,该终端设备在接收到上述第二LE Audio广播消息之后,可以针对第二蓝牙音频设备获取相同类型的设备标识,并将其与上述候选名单或白名单中的设备标识进行比对。若通过比对,确认第一蓝牙音频设备与第二蓝牙音频设备的设备标识相匹配,则终端设备可以确定该第一蓝牙音频设备与第二蓝牙音频设备属于同一蓝牙设备集合,进而可以在确定出第二LE Audio广播消息也与该终端设备的标识信息对应的情况下,进一步地向该第二蓝牙音频设备发送低功耗蓝牙音频连接请求,以使该第二蓝牙音频设备响应于该低功耗蓝牙音频连接请求,与该终端设备建立LE Audio蓝牙连接。For example, the terminal device can determine whether the corresponding second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set based on the above-mentioned second LE Audio broadcast message and the first LE Audio broadcast message. For example, after receiving the first LE Audio broadcast message, the terminal device can obtain the device identification (such as IRK, device Bluetooth address, product identification code, etc.) of the corresponding first Bluetooth audio device, and add it to the candidate list. list or whitelist. Then, after receiving the second LE Audio broadcast message, the terminal device can obtain the same type of device identification for the second Bluetooth audio device and compare it with the device identification in the above candidate list or white list. If it is confirmed through comparison that the device identifiers of the first Bluetooth audio device and the second Bluetooth audio device match, the terminal device can determine that the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set, and can then determine If the second LE Audio broadcast message also corresponds to the identification information of the terminal device, further send a low-power Bluetooth audio connection request to the second Bluetooth audio device, so that the second Bluetooth audio device responds to the low-power Bluetooth audio connection request. Power consumption Bluetooth audio connection request to establish a LE Audio Bluetooth connection with the terminal device.
可见,实施上述实施例所描述的设备连接方法,终端设备可以通过与蓝牙音频设备之间的SMP操作,使该蓝牙音频设备可以快速、准确地获取该终端设备的标识信息,并向该终端设备发送“定向可连接”的LE Audio广播消息,从而终端设备可以在该针对性的LE Audio广播消息的触发下,与上述蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的终端设备所响应,从而能够避免该蓝牙音频设备与其他处于可连接状态的设备误连接,有利于降低蓝牙音频设备误连终端设备的可能性,有效提升了蓝牙音频设备进行通信连接的准确性及灵活性。此外,通过向蓝牙音频设备发送该终端设备的IRK,可以由蓝牙音频设备计算出对应的RPA类型的BLE地址,进而可以确保相应的LE Audio广播消息仅能被该终端设备正确解析并匹配,有利于提升蓝牙音频设备定向连接终端设备的准确性及可靠性。此外,通过在第一蓝牙音频设备及第二蓝牙音频设备之间同步该终端设备的标识信息,终端设备可以分别与该第一蓝牙音频设备及第二蓝牙音频设备建立LE Audio蓝牙连接,以提升终端设备与蓝牙音频设备进行通信连接的灵活性,同时也有利于提升各个耳机基于BLE技术传输音频数据的可靠性。It can be seen that by implementing the device connection method described in the above embodiment, the terminal device can perform SMP operations with the Bluetooth audio device, so that the Bluetooth audio device can quickly and accurately obtain the identification information of the terminal device and send it to the terminal device. Send a "directed connectable" LE Audio broadcast message, so that the terminal device can establish a LE Audio Bluetooth connection with the above-mentioned Bluetooth audio device when triggered by the targeted LE Audio broadcast message. Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the terminal device expected by the user, thereby preventing the Bluetooth audio device from being mistakenly connected to other devices in a connectable state, and helping to reduce the risk of The possibility of Bluetooth audio devices mistakenly connecting to terminal devices effectively improves the accuracy and flexibility of communication connections for Bluetooth audio devices. In addition, by sending the IRK of the terminal device to the Bluetooth audio device, the Bluetooth audio device can calculate the corresponding RPA type BLE address, thereby ensuring that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the terminal device. It is beneficial to improve the accuracy and reliability of directional connection of Bluetooth audio devices to terminal devices. In addition, by synchronizing the identification information of the terminal device between the first Bluetooth audio device and the second Bluetooth audio device, the terminal device can establish LE Audio Bluetooth connections with the first Bluetooth audio device and the second Bluetooth audio device respectively to improve The flexibility of communication and connection between terminal devices and Bluetooth audio devices also helps improve the reliability of audio data transmission by each headset based on BLE technology.
请参阅图8,图8是本申请实施例公开的一种设备连接方法的时序图,该方法可以应用于由上述第一 蓝牙音频设备和终端设备(即第一目标设备)所组成的蓝牙通信系统中。如图8所示,该设备连接方法可以包括以下步骤:Please refer to Figure 8. Figure 8 is a sequence diagram of a device connection method disclosed in an embodiment of the present application. This method can be applied to Bluetooth communication composed of the above-mentioned first Bluetooth audio device and terminal device (ie, the first target device). in the system. As shown in Figure 8, the device connection method may include the following steps:
802、在第一蓝牙音频设备与第一目标设备建立经典蓝牙连接的情况下,由第一目标设备基于该第一蓝牙音频设备与该第一目标设备之间的安全管理协议,向第一蓝牙音频设备发送与该第一目标设备的标识信息对应的安全管理信息。802. When the first Bluetooth audio device establishes a classic Bluetooth connection with the first target device, the first target device sends a request to the first Bluetooth device based on the security management protocol between the first Bluetooth audio device and the first target device. The audio device sends security management information corresponding to the identification information of the first target device.
示例性地,上述安全管理信息可以包含该第一目标设备的IRK,即第一目标设备可以通过基于安全管理协议的SMP操作,将自身的IRK传输至第一蓝牙音频设备。For example, the above security management information may include the IRK of the first target device, that is, the first target device may transmit its IRK to the first Bluetooth audio device through an SMP operation based on the security management protocol.
804、第一蓝牙音频设备基于该第一蓝牙音频设备与该第一目标设备之间的安全管理协议,接收第一目标设备所发送的安全管理信息,并根据该安全管理信息,确定该第一目标设备的标识信息。804. The first Bluetooth audio device receives the security management information sent by the first target device based on the security management protocol between the first Bluetooth audio device and the first target device, and determines the first Bluetooth audio device based on the security management information. Identification information of the target device.
806、第一蓝牙音频设备发送与上述标识信息对应的第一低功耗蓝牙广播消息。806. The first Bluetooth audio device sends the first low-power Bluetooth broadcast message corresponding to the above identification information.
示例性地,上述标识信息可以包括设备蓝牙地址,则第一蓝牙音频设备可以根据上述安全管理信息对应的计算规则,对该安全管理信息进行计算(即对第一目标设备的IRK进行计算),以生成第一目标设备的设备蓝牙地址,进而可以根据该设备蓝牙地址,生成并发送携带该设备蓝牙地址的LE Audio广播消息。For example, the above-mentioned identification information may include the device Bluetooth address, then the first Bluetooth audio device may calculate the security management information according to the calculation rules corresponding to the above-mentioned security management information (that is, calculate the IRK of the first target device), To generate the device Bluetooth address of the first target device, and then generate and send the LE Audio broadcast message carrying the device Bluetooth address according to the device Bluetooth address.
808、第一目标设备接收第一低功耗蓝牙广播消息,在确定该第一低功耗蓝牙广播消息与该第一目标设备的标识信息对应的情况下,响应于该第一低功耗蓝牙广播消息,向第一蓝牙音频设备发送低功耗蓝牙音频连接请求。808. The first target device receives the first Bluetooth low energy broadcast message, and when it is determined that the first Bluetooth low energy broadcast message corresponds to the identification information of the first target device, responds to the first Bluetooth low energy broadcast message. Broadcast message to send low-power Bluetooth audio connection request to the first Bluetooth audio device.
810、第一蓝牙音频设备接收第一目标设备所发送的低功耗蓝牙音频连接请求,并响应于该低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。810. The first Bluetooth audio device receives the low-power Bluetooth audio connection request sent by the first target device, and responds to the low-power Bluetooth audio connection request to establish a low-power Bluetooth audio connection with the first target device.
可选地,第一蓝牙音频设备在与第一目标设备建立蓝牙连接之前,还可以与其他设备(可记为第二目标设备)建立过蓝牙连接。示例性地,在执行上述步骤802之前,该设备连接方法还可以包括以下步骤:Optionally, before establishing a Bluetooth connection with the first target device, the first Bluetooth audio device may also establish a Bluetooth connection with another device (which may be recorded as the second target device). Exemplarily, before performing the above step 802, the device connection method may also include the following steps:
801A、第一蓝牙音频设备与第二目标设备断开蓝牙连接,该第二目标设备的标识信息与第一目标设备的标识信息不相同。801A. The first Bluetooth audio device disconnects the Bluetooth connection from the second target device, and the identification information of the second target device is different from the identification information of the first target device.
示例性地,上述蓝牙连接可以包括经典蓝牙连接和/或LE Audio蓝牙连接,本申请实施例中不作具体限定。For example, the above-mentioned Bluetooth connection may include a classic Bluetooth connection and/or a LE Audio Bluetooth connection, which is not specifically limited in the embodiments of this application.
801B、第一蓝牙音频设备进入配对状态。801B. The first Bluetooth audio device enters the pairing state.
其中,上述配对状态是指第一蓝牙音频设备处于可发现且可连接的状态,在配对状态下,第一蓝牙音频设备可以停止发出任何LE Audio广播消息。The above-mentioned pairing state means that the first Bluetooth audio device is in a discoverable and connectable state. In the pairing state, the first Bluetooth audio device can stop sending any LE Audio broadcast messages.
801C、在确定第一蓝牙音频设备处于配对状态的情况下,第一目标设备向第一蓝牙音频设备发送经典蓝牙连接请求。801C. When it is determined that the first Bluetooth audio device is in the pairing state, the first target device sends a classic Bluetooth connection request to the first Bluetooth audio device.
需要说明的是,第一目标设备可以通过扫描的方式发现处于配对状态的第一蓝牙音频设备,并自动或者由用户手动确认向该第一蓝牙音频设备发起经典蓝牙连接。在一些实施例中,第一目标设备可以在向第一蓝牙音频设备发起经典蓝牙连接时,将该第一蓝牙音频设备添加到第一目标设备的白名单中,以便于后续实现快速的回连、重连等操作,同时也有助于在与该第一蓝牙音频设备建立LE Audio蓝牙连接时辅助验证。在另一些实施例中,第一目标设备也可以在向第一蓝牙音频设备发起LE Audio蓝牙连接时,才将该第一蓝牙音频设备添加到第一目标设备的白名单中,从而可以通过维护上述白名单,加快后续确认该第一蓝牙音频设备所发送的LE Audio广播消息是否与该第一目标设备的标识信息相对应的过程,有助于提升第一蓝牙音频设备与终端设备建立蓝牙连接,尤其是建立LE Audio蓝牙连接的效率。It should be noted that the first target device can discover the first Bluetooth audio device in the paired state by scanning, and automatically or manually confirm by the user to initiate a classic Bluetooth connection to the first Bluetooth audio device. In some embodiments, when the first target device initiates a classic Bluetooth connection to the first Bluetooth audio device, the first Bluetooth audio device can be added to the whitelist of the first target device to facilitate subsequent rapid connection back. , reconnect and other operations, and also help to assist in verification when establishing a LE Audio Bluetooth connection with the first Bluetooth audio device. In other embodiments, the first target device may only add the first Bluetooth audio device to the whitelist of the first target device when it initiates a LE Audio Bluetooth connection to the first Bluetooth audio device, so that it can be maintained through maintenance The above whitelist speeds up the subsequent process of confirming whether the LE Audio broadcast message sent by the first Bluetooth audio device corresponds to the identification information of the first target device, and helps to improve the establishment of a Bluetooth connection between the first Bluetooth audio device and the terminal device. , especially the efficiency of establishing LE Audio Bluetooth connections.
801D、第一蓝牙音频设备接收第一目标设备发送的经典蓝牙连接请求,并响应于该经典蓝牙连接请求,与第一目标设备建立经典蓝牙连接。801D. The first Bluetooth audio device receives the classic Bluetooth connection request sent by the first target device, and responds to the classic Bluetooth connection request to establish a classic Bluetooth connection with the first target device.
在此基础上,通过进一步执行上述步骤802至步骤810,可以使蓝牙音频设备定向地与用户预期的第一目标设备建立LE Audio蓝牙连接。On this basis, by further performing the above steps 802 to 810, the Bluetooth audio device can establish a LE Audio Bluetooth connection with the first target device expected by the user in a directional manner.
需要说明的是,上述第二目标设备在接收到第一蓝牙音频设备发送的与第一目标设备的标识信息对 应的LE Audio广播消息时,可以不响应并丢弃该LE Audio广播消息,从而能够有效避免第一蓝牙音频设备与该第二目标设备的误连接。It should be noted that when the above-mentioned second target device receives the LE Audio broadcast message corresponding to the identification information of the first target device sent by the first Bluetooth audio device, it may not respond and discard the LE Audio broadcast message, thereby effectively Avoid misconnection between the first Bluetooth audio device and the second target device.
请一并参阅图9,图9是本申请实施例公开的另一种设备连接方法的时序图,该方法可以应用于由上述第一蓝牙音频设备、第二蓝牙音频设备和终端设备(即第一目标设备)所组成的蓝牙通信系统中,其中,第一蓝牙音频设备与第二蓝牙音频设备可以属于同一蓝牙设备集合。示例性地,以第一蓝牙音频设备及第二蓝牙音频设备均为蓝牙音频设备设备为例,上述第一蓝牙音频设备可以为主蓝牙音频设备,而第二蓝牙音频设备可以为从蓝牙音频设备。如图9所示,该设备连接方法可以包括以下步骤:Please refer to Figure 9 together. Figure 9 is a sequence diagram of another device connection method disclosed in an embodiment of the present application. This method can be applied to the first Bluetooth audio device, the second Bluetooth audio device and the terminal device (i.e., the first Bluetooth audio device). In a Bluetooth communication system composed of a target device), the first Bluetooth audio device and the second Bluetooth audio device may belong to the same Bluetooth device set. For example, taking the first Bluetooth audio device and the second Bluetooth audio device as both Bluetooth audio devices, the first Bluetooth audio device may be the master Bluetooth audio device, and the second Bluetooth audio device may be the slave Bluetooth audio device. . As shown in Figure 9, the device connection method may include the following steps:
902、第一目标设备基于该第一蓝牙音频设备与该第一目标设备之间的安全管理协议,向第一蓝牙音频设备发送与该第一目标设备的标识信息对应的安全管理信息。902. The first target device sends security management information corresponding to the identification information of the first target device to the first Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the first target device.
904、第一蓝牙音频设备基于该第一蓝牙音频设备与该第一目标设备之间的安全管理协议,接收第一目标设备所发送的安全管理信息,并根据该安全管理信息,确定该第一目标设备的标识信息。904. The first Bluetooth audio device receives the security management information sent by the first target device based on the security management protocol between the first Bluetooth audio device and the first target device, and determines the first Bluetooth audio device based on the security management information. Identification information of the target device.
示例性地,上述安全管理信息可以包含该第一目标设备的IRK,即第一目标设备可以通过基于安全管理协议的SMP操作,将自身的IRK传输至第一蓝牙音频设备。在此基础上,上述标识信息可以包括设备蓝牙地址,则第一蓝牙音频设备可以根据上述安全管理信息对应的计算规则,对该安全管理信息进行计算(即对第一目标设备的IRK进行计算),以确定出第一目标设备的设备蓝牙地址,并将其应用于后续发送“定向可连接”的LE Audio广播消息的步骤中。For example, the above security management information may include the IRK of the first target device, that is, the first target device may transmit its IRK to the first Bluetooth audio device through an SMP operation based on the security management protocol. On this basis, the above-mentioned identification information may include the Bluetooth address of the device, and the first Bluetooth audio device may calculate the security management information (that is, calculate the IRK of the first target device) according to the calculation rules corresponding to the above-mentioned security management information. , to determine the device Bluetooth address of the first target device, and apply it to the subsequent steps of sending the "directed connectable" LE Audio broadcast message.
906、第一蓝牙音频设备向第二蓝牙音频设备发送上述第一目标设备的标识信息。906. The first Bluetooth audio device sends the identification information of the first target device to the second Bluetooth audio device.
在本申请实施例中,第一蓝牙音频设备在确定出第一目标设备的标识信息(例如该第一目标设备的设备蓝牙地址等)后,可以主动将该标识信息发送至第二蓝牙音频设备,以实现第一蓝牙音频设备和第二蓝牙音频设备之间的信息同步。In this embodiment of the present application, after determining the identification information of the first target device (such as the device Bluetooth address of the first target device, etc.), the first Bluetooth audio device can actively send the identification information to the second Bluetooth audio device. , to achieve information synchronization between the first Bluetooth audio device and the second Bluetooth audio device.
在另一些实施例中,第二蓝牙音频设备也可以通过监听的方式获取上述第一目标设备的标识信息,以实现第一蓝牙音频设备和第二蓝牙音频设备之间的信息同步。示例性地,第二蓝牙音频设备可以对上述第一蓝牙音频设备与第一目标设备之间的经典蓝牙链路进行监听,获取第一目标设备所发送的安全管理信息,进而可以独立确定出第一目标设备的标识信息,并将其应用于后续发送“定向可连接”的LE Audio广播消息的步骤中。In other embodiments, the second Bluetooth audio device may also obtain the identification information of the first target device through monitoring to achieve information synchronization between the first Bluetooth audio device and the second Bluetooth audio device. For example, the second Bluetooth audio device can monitor the classic Bluetooth link between the first Bluetooth audio device and the first target device, obtain the security management information sent by the first target device, and then independently determine the second Bluetooth audio device. Identification information of a target device and apply it to subsequent steps of sending "directed connectable" LE Audio broadcast messages.
908A、第一蓝牙音频设备发送与上述标识信息对应的第一低功耗蓝牙广播消息。908A. The first Bluetooth audio device sends the first low-power Bluetooth broadcast message corresponding to the above identification information.
908B、第二蓝牙音频设备发送与上述标识信息对应的第二低功耗蓝牙广播消息。908B. The second Bluetooth audio device sends a second low-power Bluetooth broadcast message corresponding to the above identification information.
910、第一目标设备分别接收第一蓝牙音频设备及第二蓝牙音频设备所发送的低功耗蓝牙广播消息,在确定该低功耗蓝牙广播消息与该第一目标设备的标识信息对应的情况下,响应于该低功耗蓝牙广播消息,向相应的第一蓝牙音频设备和/或第二蓝牙音频设备发送低功耗蓝牙音频连接请求。910. The first target device receives the low-power Bluetooth broadcast message sent by the first Bluetooth audio device and the second Bluetooth audio device respectively, and determines that the low-power Bluetooth broadcast message corresponds to the identification information of the first target device. Next, in response to the low-power Bluetooth audio broadcast message, send a low-power Bluetooth audio connection request to the corresponding first Bluetooth audio device and/or the second Bluetooth audio device.
912A、第一蓝牙音频设备接收第一目标设备所发送的低功耗蓝牙音频连接请求,并响应于该低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。912A. The first Bluetooth audio device receives the low-power Bluetooth audio connection request sent by the first target device, and responds to the low-power Bluetooth audio connection request to establish a low-power Bluetooth audio connection with the first target device.
912B、第二蓝牙音频设备接收第一目标设备所发送的低功耗蓝牙音频连接请求,并响应于该低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。912B. The second Bluetooth audio device receives the low-power Bluetooth audio connection request sent by the first target device, and responds to the low-power Bluetooth audio connection request to establish a low-power Bluetooth audio connection with the first target device.
需要说明的是,类似于上述步骤701A至步骤701D,第一蓝牙音频设备及第二蓝牙音频设备也可以与第二目标设备建立过蓝牙连接,在图9中不多加展示。第二目标设备在接收到第一蓝牙音频设备和/或第二蓝牙音频设备所发送的与第一目标设备的标识信息对应的LE Audio广播消息时,可以不响应并丢弃该LE Audio广播消息,从而能够有效避免与第一蓝牙音频设备和/或第二蓝牙音频设备误连接。It should be noted that, similar to the above steps 701A to 701D, the first Bluetooth audio device and the second Bluetooth audio device may also establish a Bluetooth connection with the second target device, which is not shown in FIG. 9 . When the second target device receives the LE Audio broadcast message corresponding to the identification information of the first target device sent by the first Bluetooth audio device and/or the second Bluetooth audio device, it may not respond and discard the LE Audio broadcast message, Thus, misconnection with the first Bluetooth audio device and/or the second Bluetooth audio device can be effectively avoided.
可见,实施上述实施例所描述的设备连接方法,蓝牙音频设备可以通过在经典蓝牙链路上与第一目标设备进行SMP操作,以快速、准确地取该第一目标设备的标识信息,进而可以基于该第一目标设备的标识信息,向该第一目标设备发送“定向可连接”的LE Audio广播消息,从而第一目标设备可以在该针对性的LE Audio广播消息的触发下,与上述蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的第一目标设备所响应,而具有不同标识信息的第二目标设备在接收到上述LE Audio广播消息时可以不作任何响应。从而,能够使蓝牙音 频设备优先与第一目标设备建立LE Audio蓝牙连接,并避免该蓝牙音频设备与第二目标设备误连接,有利于降低蓝牙音频设备误连终端设备的可能性,有效提升了蓝牙音频设备进行通信连接的准确性及灵活性。It can be seen that by implementing the device connection method described in the above embodiment, the Bluetooth audio device can quickly and accurately obtain the identification information of the first target device by performing SMP operations with the first target device on the classic Bluetooth link, and thus can Based on the identification information of the first target device, a "directed connectable" LE Audio broadcast message is sent to the first target device, so that the first target device can communicate with the above-mentioned Bluetooth under the trigger of the targeted LE Audio broadcast message. The audio device establishes a LE Audio Bluetooth connection. Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the first target device expected by the user, and the second target device with different identification information receives the above LE Audio broadcast message. No response is required. As a result, the Bluetooth audio device can be prioritized to establish a LE Audio Bluetooth connection with the first target device, and the Bluetooth audio device can be prevented from being mistakenly connected to the second target device, which is beneficial to reducing the possibility of the Bluetooth audio device being mistakenly connected to the terminal device, and effectively improving the The accuracy and flexibility of communication connections for Bluetooth audio devices.
请参阅图10,图10是本申请实施例公开的一种设备连接装置的模块化示意图,该设备连接装置可以应用于上述的第一蓝牙音频设备。如图10所示,该设备连接装置可以包括信息获取单元1001、第一广播发送单元1002、第一请求接收单元1003以及第一连接单元1004,其中:Please refer to Figure 10. Figure 10 is a modular schematic diagram of a device connection device disclosed in an embodiment of the present application. The device connection device can be applied to the above-mentioned first Bluetooth audio device. As shown in Figure 10, the device connection device may include an information acquisition unit 1001, a first broadcast sending unit 1002, a first request receiving unit 1003 and a first connection unit 1004, where:
信息获取单元1001,用于基于第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取第一目标设备的标识信息;The information acquisition unit 1001 is configured to acquire the identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device;
第一广播发送单元1002,用于发送与上述标识信息对应的低功耗蓝牙广播消息,该低功耗蓝牙广播消息用于指示第一蓝牙音频设备能够响应第一目标设备发起低功耗蓝牙音频连接请求;The first broadcast sending unit 1002 is configured to send a low-power Bluetooth broadcast message corresponding to the above identification information. The low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the first target device to initiate low-power Bluetooth audio. connection request;
第一请求接收单元1003,用于接收第一目标设备发送的低功耗蓝牙音频连接请求;The first request receiving unit 1003 is configured to receive a low-power Bluetooth audio connection request sent by the first target device;
第一连接单元1004,用于响应于该低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。The first connection unit 1004 is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
可见,采用上述实施例所描述的设备连接装置,蓝牙音频设备可以通过在经典蓝牙链路上与第一目标设备进行SMP操作,以快速、准确地取该第一目标设备的标识信息,进而可以基于该第一目标设备的标识信息,向该第一目标设备发送“定向可连接”的LE Audio广播消息,从而第一目标设备可以在该针对性的LE Audio广播消息的触发下,与上述蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的第一目标设备所响应,而具有不同标识信息的第二目标设备在接收到上述LE Audio广播消息时可以不作任何响应。从而,能够使蓝牙音频设备优先与第一目标设备建立LE Audio蓝牙连接,并避免该蓝牙音频设备与第二目标设备误连接,有利于降低蓝牙音频设备误连终端设备的可能性,有效提升了蓝牙音频设备进行通信连接的准确性及灵活性。It can be seen that using the device connection device described in the above embodiment, the Bluetooth audio device can quickly and accurately obtain the identification information of the first target device by performing SMP operations with the first target device on the classic Bluetooth link, and thus can Based on the identification information of the first target device, a "directed connectable" LE Audio broadcast message is sent to the first target device, so that the first target device can communicate with the above-mentioned Bluetooth under the trigger of the targeted LE Audio broadcast message. The audio device establishes a LE Audio Bluetooth connection. Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the first target device expected by the user, and the second target device with different identification information receives the above LE Audio broadcast message. No response is required. Therefore, the Bluetooth audio device can be prioritized to establish a LE Audio Bluetooth connection with the first target device, and the Bluetooth audio device can be prevented from being mistakenly connected to the second target device, which is conducive to reducing the possibility of the Bluetooth audio device being mistakenly connected to the terminal device, and effectively improving the The accuracy and flexibility of communication connections for Bluetooth audio devices.
在一种实施例中,该设备连接装置还可以包括未图示的信息同步单元,该信息同步单元可以用于向第二蓝牙音频设备发送第一目标设备的标识信息,以使该第二蓝牙音频设备发送与该标识信息对应的低功耗蓝牙广播消息。In one embodiment, the device connection device may also include an information synchronization unit (not shown). The information synchronization unit may be used to send identification information of the first target device to the second Bluetooth audio device, so that the second Bluetooth audio device The audio device sends a low-power Bluetooth broadcast message corresponding to the identification information.
可选地,也可以由该第二蓝牙音频设备对上述第一蓝牙音频设备与第一目标设备之间的蓝牙链路进行监听,并根据监听数据计算得到第一目标设备的标识信息。Optionally, the second Bluetooth audio device may also monitor the Bluetooth link between the first Bluetooth audio device and the first target device, and calculate the identification information of the first target device based on the monitoring data.
其中,上述第二蓝牙音频设备可以与第一蓝牙音频设备属于同一蓝牙设备集合。Wherein, the above-mentioned second Bluetooth audio device may belong to the same Bluetooth device set as the first Bluetooth audio device.
在一种实施例中,上述信息获取单元1001,可以包括未图示的接收子单元以及确定子单元,其中:In one embodiment, the above-mentioned information acquisition unit 1001 may include a receiving subunit and a determining subunit (not shown), where:
接收子单元,用于基于该第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收第一目标设备发送的安全管理信息;A receiving subunit configured to receive security management information sent by the first target device based on the security management protocol between the first Bluetooth audio device and the first target device;
确定子单元,用于根据安全管理信息,确定第一目标设备的标识信息。The determining subunit is used to determine the identification information of the first target device according to the security management information.
在一种实施例中,上述接收子单元,具体可以用于:In one embodiment, the above receiving subunit can be used for:
通过第一蓝牙音频设备与第一目标设备之间的蓝牙链路,配置该第一蓝牙音频设备与第一目标设备之间的安全管理协议;Configuring a security management protocol between the first Bluetooth audio device and the first target device through the Bluetooth link between the first Bluetooth audio device and the first target device;
基于上述安全管理协议,接收第一目标设备发送的安全管理信息。Based on the above security management protocol, receive security management information sent by the first target device.
其中,上述蓝牙链路可以为异步无连接ACL类型的蓝牙链路。Wherein, the above-mentioned Bluetooth link may be an asynchronous connectionless ACL type Bluetooth link.
在一种实施例中,上述标识信息可以包括设备蓝牙地址,上述安全管理信息可以包括蓝牙设备地址解析秘钥IRK,则上述确定子单元,具体可以用于:In one embodiment, the above-mentioned identification information may include the device Bluetooth address, and the above-mentioned security management information may include the Bluetooth device address resolution key IRK, then the above-mentioned determination subunit may be used to:
根据上述IRK对应的计算规则,对该IRK进行计算,以生成第一目标设备的设备蓝牙地址。According to the calculation rules corresponding to the above IRK, the IRK is calculated to generate the device Bluetooth address of the first target device.
在一些实施例中,上述第一蓝牙音频设备可以为支持同时建立经典蓝牙连接和低功耗蓝牙音频连接的设备,在此基础上,该设备连接装置在上述信息获取单元1001获取第一目标设备的标识信息之前,还可以进入配对状态(可由未图示的配对单元实现),该配对状态是指蓝牙音频设备处于可发现且可连接的状态;In some embodiments, the above-mentioned first Bluetooth audio device may be a device that supports the simultaneous establishment of a classic Bluetooth connection and a low-power Bluetooth audio connection. On this basis, the device connection device acquires the first target device in the above-mentioned information acquisition unit 1001. Before entering the identification information, you can also enter the pairing state (which can be implemented by a pairing unit not shown). The pairing state means that the Bluetooth audio device is discoverable and connectable;
在此基础上,上述第一请求接收单元1003,还可以用于:On this basis, the above-mentioned first request receiving unit 1003 can also be used to:
接收第一目标设备发送的经典蓝牙连接请求;Receive the classic Bluetooth connection request sent by the first target device;
上述第一连接单元1004,还可以用于:The above-mentioned first connection unit 1004 can also be used for:
响应于该经典蓝牙连接请求,与第一目标设备建立经典蓝牙连接;In response to the classic Bluetooth connection request, establish a classic Bluetooth connection with the first target device;
从而,上述信息获取单元1001,具体可以用于在与第一目标设备之间的经典蓝牙链路上,基于第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取该第一目标设备的标识信息。Therefore, the above-mentioned information acquisition unit 1001 can be specifically configured to obtain the first target based on the security management protocol between the first Bluetooth audio device and the first target device on the classic Bluetooth link with the first target device. Identification information of the device.
可选地,该设备连接装置在进入配对状态之前,还可以与第二目标设备断开蓝牙连接(可由上述第一连接单元1004实现),该第二目标设备的标识信息与第一目标设备的标识信息不相同;Optionally, before entering the pairing state, the device connection device can also disconnect the Bluetooth connection with the second target device (which can be implemented by the first connection unit 1004), and the identification information of the second target device is the same as that of the first target device. The identification information is not the same;
其中,第二目标设备在接收到蓝牙音频设备发送的与第一目标设备的标识信息对应的低功耗蓝牙广播消息时,可以不响应并丢弃该低功耗蓝牙广播消息。Wherein, when the second target device receives the Bluetooth low energy broadcast message corresponding to the identification information of the first target device sent by the Bluetooth audio device, it may not respond and discard the Bluetooth low energy broadcast message.
或者,上述第一蓝牙音频设备也可以为仅支持建立低功耗蓝牙音频连接的设备,在此基础上,上述第一连接单元1004,还可以用于:Alternatively, the above-mentioned first Bluetooth audio device may also be a device that only supports establishing a low-power Bluetooth audio connection. On this basis, the above-mentioned first connection unit 1004 may also be used for:
与第一目标设备建立低功耗蓝牙连接;Establish a low-power Bluetooth connection with the first target device;
从而,上述信息获取单元1001,具体可以用于在与第一目标设备之间的低功耗蓝牙链路上,基于第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取该第一目标设备的标识信息。Therefore, the above-mentioned information acquisition unit 1001 can be specifically configured to obtain the third Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the first target device on the low-power Bluetooth link with the first target device. Identification information of a target device.
可见,采用上述实施例所描述的设备连接装置,蓝牙音频设备可以基于其通过SMP操作所快速、准确获取的第一目标设备的标识信息,向该第一目标设备发送“定向可连接”的LE Audio广播消息,从而第一目标设备可以在该针对性的LE Audio广播消息的触发下,与上述蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的第一目标设备所响应,从而能够避免该蓝牙音频设备与第二目标设备误连接,有利于降低蓝牙音频设备误连终端设备的可能性,有效提升了蓝牙音频设备进行通信连接的准确性及灵活性。此外,由蓝牙音频设备利用第一目标设备的IRK来计算RPA类型的BLE地址,可以确保相应的LE Audio广播消息仅能被该第一目标设备正确解析并匹配,从而能够赋予上述LE Audio广播消息“定向可连接”的特性,有利于提升蓝牙音频设备定向连接终端设备的准确性及可靠性。此外,通过在第一蓝牙音频设备及第二蓝牙音频设备之间同步第一目标设备的标识信息,可以使该第一蓝牙音频设备及第二蓝牙音频设备分别与第一目标设备建立LE Audio蓝牙连接,以提升蓝牙音频设备进行通信连接的灵活性,同时也有利于提升各个耳机基于BLE技术传输音频数据的可靠性。It can be seen that using the device connection device described in the above embodiment, the Bluetooth audio device can send a "directed connectable" LE to the first target device based on the identification information of the first target device quickly and accurately obtained through the SMP operation. Audio broadcast message, so that the first target device can establish a LE Audio Bluetooth connection with the above-mentioned Bluetooth audio device under the trigger of the targeted LE Audio broadcast message. Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the first target device expected by the user, thereby preventing the Bluetooth audio device from being mistakenly connected to the second target device, which is conducive to reducing the cost of Bluetooth audio. The possibility of audio equipment mistakenly connecting to terminal equipment effectively improves the accuracy and flexibility of communication connections for Bluetooth audio equipment. In addition, the Bluetooth audio device uses the IRK of the first target device to calculate the RPA type BLE address, which can ensure that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the first target device, so that the above LE Audio broadcast message can be given The "directionally connectable" feature helps improve the accuracy and reliability of Bluetooth audio devices' directional connection to terminal devices. In addition, by synchronizing the identification information of the first target device between the first Bluetooth audio device and the second Bluetooth audio device, the first Bluetooth audio device and the second Bluetooth audio device can establish LE Audio Bluetooth with the first target device respectively. connection to improve the flexibility of communication connections for Bluetooth audio devices, and also help improve the reliability of audio data transmission by each headset based on BLE technology.
请参阅图11,图11是本申请实施例公开的另一种设备连接装置的模块化示意图,该设备连接装置可以应用于上述的第二蓝牙音频设备。如图11所示,该设备连接装置可以包括监听单元1101、计算单元1102、第二广播发送单元1103、第二请求接收单元1104以及第二连接单元1105,其中:Please refer to FIG. 11 , which is a modular schematic diagram of another device connection device disclosed in an embodiment of the present application. The device connection device can be applied to the above-mentioned second Bluetooth audio device. As shown in Figure 11, the device connection device may include a listening unit 1101, a computing unit 1102, a second broadcast sending unit 1103, a second request receiving unit 1104 and a second connection unit 1105, where:
监听单元1101,用于对第一蓝牙音频设备与第一目标设备之间的蓝牙链路进行监听,获取监听数据,其中,第二蓝牙音频设备与第一蓝牙音频设备属于同一蓝牙设备集合;The monitoring unit 1101 is used to monitor the Bluetooth link between the first Bluetooth audio device and the first target device and obtain monitoring data, where the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
计算单元1102,用于根据监听数据,计算得到第一目标设备的标识信息;The calculation unit 1102 is configured to calculate the identification information of the first target device according to the monitoring data;
第二广播发送单元1103,用于发送与标识信息对应的低功耗蓝牙广播消息,低功耗蓝牙广播消息用于指示第二蓝牙音频设备响应第一目标设备发起的低功耗蓝牙音频连接请求;The second broadcast sending unit 1103 is used to send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
第二请求接收单元1104,用于接收第一目标设备发送的低功耗蓝牙音频连接请求;The second request receiving unit 1104 is configured to receive a low-power Bluetooth audio connection request sent by the first target device;
第二连接单元1105,用于响应于低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。The second connection unit 1105 is configured to respond to a low-power Bluetooth audio connection request and establish a low-power Bluetooth audio connection with the first target device.
在一种实施例中,上述监听数据可以包括第一目标设备的安全管理信息,该安全管理信息具体可以包括蓝牙设备地址解析秘钥IRK,上述标识信息则可以包括设备蓝牙地址,从而上述计算单元1102具体可以用于:In one embodiment, the above-mentioned monitoring data may include security management information of the first target device. The security management information may specifically include the Bluetooth device address resolution key IRK. The above-mentioned identification information may include the device Bluetooth address, so that the above-mentioned computing unit 1102 can be specifically used for:
根据IRK对应的计算规则,对该IRK进行计算,以生成第一目标设备的设备蓝牙地址。According to the calculation rules corresponding to the IRK, the IRK is calculated to generate the device Bluetooth address of the first target device.
请一并参阅图12,图12是本申请实施例公开的又一种设备连接装置的模块化示意图,该设备连接装置也可以应用于上述的第二蓝牙音频设备。如图12所示,该设备连接装置可以包括信息接收单元1201、 第三广播发送单元1202、第三请求接收单元1203以及第三连接单元1204,其中:Please also refer to FIG. 12 , which is a modular schematic diagram of yet another device connection device disclosed in an embodiment of the present application. The device connection device can also be applied to the above-mentioned second Bluetooth audio device. As shown in Figure 12, the device connection device may include an information receiving unit 1201, a third broadcast sending unit 1202, a third request receiving unit 1203 and a third connection unit 1204, where:
信息接收单元1201,用于接收第一蓝牙音频设备发送的第一目标设备的标识信息,其中,第二蓝牙音频设备与第一蓝牙音频设备属于同一蓝牙设备集合;The information receiving unit 1201 is configured to receive the identification information of the first target device sent by the first Bluetooth audio device, where the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
第三广播发送单元1202,用于发送与标识信息对应的低功耗蓝牙广播消息,低功耗蓝牙广播消息用于指示第二蓝牙音频设备响应第一目标设备发起的低功耗蓝牙音频连接请求;The third broadcast sending unit 1202 is used to send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
第三请求接收单元1203,用于接收第一目标设备发送的低功耗蓝牙音频连接请求;The third request receiving unit 1203 is configured to receive a low-power Bluetooth audio connection request sent by the first target device;
第三连接单元1204,用于响应于低功耗蓝牙音频连接请求,与第一目标设备建立低功耗蓝牙音频连接。The third connection unit 1204 is configured to respond to a low-power Bluetooth audio connection request and establish a low-power Bluetooth audio connection with the first target device.
请参阅图13,图13是本申请实施例公开的第四种设备连接装置的模块化示意图,该设备连接装置可以应用于上述的终端设备。如图13所示,该设备连接装置可以包括信息发送单元1301、广播接收单元1302以及请求发送单元1303,其中:Please refer to Figure 13. Figure 13 is a modular schematic diagram of a fourth device connection device disclosed in an embodiment of the present application. This device connection device can be applied to the above-mentioned terminal equipment. As shown in Figure 13, the device connection device may include an information sending unit 1301, a broadcast receiving unit 1302 and a request sending unit 1303, where:
信息发送单元1301,用于基于第一蓝牙音频设备与终端设备之间的安全管理协议,向该第一蓝牙音频设备发送与终端设备的标识信息对应的安全管理信息;The information sending unit 1301 is configured to send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the terminal device;
广播接收单元1302,用于接收第一蓝牙音频设备响应于上述安全管理信息发送的第一低功耗蓝牙广播消息;The broadcast receiving unit 1302 is configured to receive the first low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the above security management information;
请求发送单元1303,用于在确定上述第一低功耗蓝牙广播消息与终端设备的标识信息对应的情况下,响应于该第一低功耗蓝牙广播消息,向第一蓝牙音频设备发送低功耗蓝牙音频连接请求,以使该第一蓝牙音频设备响应于上述低功耗蓝牙音频连接请求,与终端设备建立低功耗蓝牙音频连接。The request sending unit 1303 is configured to send a low-power Bluetooth audio device to the first Bluetooth audio device in response to the first low-power Bluetooth broadcast message when it is determined that the first low-power Bluetooth broadcast message corresponds to the identification information of the terminal device. and a Bluetooth low energy audio connection request, so that the first Bluetooth audio device responds to the Bluetooth low energy audio connection request and establishes a low power Bluetooth audio connection with the terminal device.
在一种实施例中,上述信息发送单元1301,可以包括未图示的协议配置子单元以及信息发送子单元,其中:In one embodiment, the above-mentioned information sending unit 1301 may include a protocol configuration subunit and an information sending subunit (not shown), wherein:
协议配置子单元,用于通过第一蓝牙音频设备与终端设备之间的蓝牙链路,配置该第一蓝牙音频设备与终端设备之间的安全管理协议;The protocol configuration subunit is used to configure the security management protocol between the first Bluetooth audio device and the terminal device through the Bluetooth link between the first Bluetooth audio device and the terminal device;
信息发送子单元,用于基于上述安全管理协议,向第一蓝牙音频设备发送与终端设备的标识信息对应的安全管理信息,该安全管理信息用于使第一蓝牙音频设备根据上述安全管理信息,确定终端设备的标识信息,并发送与该标识信息对应的第一低功耗蓝牙广播消息。The information sending subunit is configured to send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device based on the above-mentioned security management protocol. The security management information is used to cause the first Bluetooth audio device to, according to the above-mentioned security management information, Determine the identification information of the terminal device, and send the first low-power Bluetooth broadcast message corresponding to the identification information.
在一种实施例中,上述标识信息可以包括设备蓝牙地址,则上述广播接收单元1302,具体可以用于:In one embodiment, the above identification information may include the Bluetooth address of the device, then the above broadcast receiving unit 1302 may be used to:
接收第一蓝牙音频设备响应于上述安全管理信息发送的携带目标蓝牙地址的第一低功耗蓝牙广播消息。Receive a first low-power Bluetooth broadcast message carrying a target Bluetooth address sent by the first Bluetooth audio device in response to the above security management information.
在此基础上,上述请求发送单元1303可以包括未图示的计算子单元、比对子单元以及发送子单元,其中:On this basis, the above request sending unit 1303 may include a calculation subunit, a comparison subunit and a sending subunit (not shown), where:
计算子单元,用于根据上述安全管理信息对应的计算规则,对该安全管理信息以及目标蓝牙地址进行计算,得到校验蓝牙地址;The calculation subunit is used to calculate the security management information and the target Bluetooth address according to the calculation rules corresponding to the above security management information to obtain the verification Bluetooth address;
比对子单元,用于将目标蓝牙地址以及校验蓝牙地址进行比对;Comparison subunit, used to compare the target Bluetooth address and the verification Bluetooth address;
发送子单元,用于在上述目标蓝牙地址与校验蓝牙地址相匹配的情况下,确定上述第一低功耗蓝牙广播消息与该终端设备的设备蓝牙地址对应,并响应于上述第一低功耗蓝牙广播消息,向第一蓝牙音频设备发送低功耗蓝牙音频连接请求。The sending subunit is configured to determine that the first low-power Bluetooth broadcast message corresponds to the device Bluetooth address of the terminal device when the above-mentioned target Bluetooth address matches the verification Bluetooth address, and respond to the above-mentioned first low-power Bluetooth address. The Bluetooth consumption broadcast message sends a low-power Bluetooth audio connection request to the first Bluetooth audio device.
在一种实施例中,该设备连接装置还可以包括未图示的连接单元,其中:In one embodiment, the device connection device may also include a connection unit not shown, wherein:
上述请求发送单元1303,还可以用于在上述信息发送单元1301向第一蓝牙音频设备发送与终端设备的标识信息对应的安全管理信息之前,在确定第一蓝牙音频设备处于配对状态的情况下,向该第一蓝牙音频设备发送经典蓝牙连接请求,上述配对状态是指第一蓝牙音频设备处于可发现且可连接的状态;The above request sending unit 1303 may also be used to determine that the first Bluetooth audio device is in a pairing state before the above information sending unit 1301 sends the security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device. Send a classic Bluetooth connection request to the first Bluetooth audio device. The above pairing state means that the first Bluetooth audio device is in a discoverable and connectable state;
连接单元,用于与响应该经典蓝牙连接请求的第一蓝牙音频设备建立经典蓝牙连接。A connection unit configured to establish a classic Bluetooth connection with the first Bluetooth audio device that responds to the classic Bluetooth connection request.
在一种实施例中,上述安全管理信息,可以用于使第一蓝牙音频设备根据该安全管理信息,确定终端设备的标识信息,并由该第一蓝牙音频设备向第二蓝牙音频设备发送该终端设备的标识信息,其中,第二蓝牙音频设备与第一蓝牙音频设备属于同一蓝牙设备集合;或者,由第二蓝牙音频设备对第一蓝牙 音频设备与该终端设备之间的蓝牙链路进行监听,并根据监听得到的上述安全管理信息计算得到该终端设备的标识信息;In one embodiment, the above security management information can be used to enable the first Bluetooth audio device to determine the identification information of the terminal device based on the security management information, and the first Bluetooth audio device sends the identification information to the second Bluetooth audio device. The identification information of the terminal device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set; or the second Bluetooth audio device performs the Bluetooth link between the first Bluetooth audio device and the terminal device. Monitor, and calculate the identification information of the terminal device based on the above-mentioned security management information obtained by monitoring;
其中,上述终端设备的标识信息,用于由第一蓝牙音频设备和/或第二蓝牙音频设备发送与该标识信息对应的低功耗蓝牙广播消息。Wherein, the identification information of the terminal device is used for the first Bluetooth audio device and/or the second Bluetooth audio device to send a low-power Bluetooth broadcast message corresponding to the identification information.
在一种实施例中,上述广播接收单元1302还可以用于:In one embodiment, the above broadcast receiving unit 1302 can also be used to:
接收第二蓝牙音频设备发送的第二低功耗蓝牙广播消息;Receive the second low-power Bluetooth broadcast message sent by the second Bluetooth audio device;
在此基础上,该设备连接装置还可以根据第二低功耗蓝牙广播消息以及第一低功耗蓝牙广播消息,判断第一蓝牙音频设备与第二蓝牙音频设备是否属于同一蓝牙设备集合(可由未图示的判断单元实现);On this basis, the device connection device can also determine whether the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set based on the second Bluetooth low energy broadcast message and the first Bluetooth low energy broadcast message (can be determined by Judgment unit implementation not shown);
在此基础上,上述请求发送单元1303具体可以用于:On this basis, the above request sending unit 1303 can be specifically used to:
在确定第一蓝牙音频设备与第二蓝牙音频设备属于同一蓝牙设备集合,且第二低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于该第二低功耗蓝牙广播消息,向第二蓝牙音频设备发送低功耗蓝牙音频连接请求,以使第二蓝牙音频设备响应于该低功耗蓝牙音频连接请求,与终端设备建立低功耗蓝牙音频连接。When it is determined that the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set, and the second Bluetooth Low Energy broadcast message corresponds to the identification information of the terminal device, in response to the second Bluetooth Low Energy Broadcast a message to send a low-power Bluetooth audio connection request to the second Bluetooth audio device, so that the second Bluetooth audio device responds to the low-power Bluetooth audio connection request and establishes a low-power Bluetooth audio connection with the terminal device.
可见,采用上述实施例所描述的设备连接装置,终端设备可以通过与蓝牙音频设备之间的SMP操作,使该蓝牙音频设备可以快速、准确地获取该终端设备的标识信息,并向该终端设备发送“定向可连接”的LE Audio广播消息,从而终端设备可以在该针对性的LE Audio广播消息的触发下,与上述蓝牙音频设备建立LE Audio蓝牙连接。这样的设备连接方式,可以确保蓝牙音频设备所发出的LE Audio广播消息仅能够被用户预期的终端设备所响应,从而能够避免该蓝牙音频设备与其他处于可连接状态的设备误连接,有利于降低蓝牙音频设备误连终端设备的可能性,有效提升了蓝牙音频设备进行通信连接的准确性及灵活性。此外,通过向蓝牙音频设备发送该终端设备的IRK,可以由蓝牙音频设备计算出对应的RPA类型的BLE地址,进而可以确保相应的LE Audio广播消息仅能被该终端设备正确解析并匹配,有利于提升蓝牙音频设备定向连接终端设备的准确性及可靠性。此外,通过在第一蓝牙音频设备及第二蓝牙音频设备之间同步该终端设备的标识信息,终端设备可以分别与该第一蓝牙音频设备及第二蓝牙音频设备建立LE Audio蓝牙连接,以提升终端设备与蓝牙音频设备进行通信连接的灵活性,同时也有利于提升各个耳机基于BLE技术传输音频数据的可靠性。It can be seen that by using the device connection device described in the above embodiment, the terminal device can perform SMP operation with the Bluetooth audio device, so that the Bluetooth audio device can quickly and accurately obtain the identification information of the terminal device and send it to the terminal device. Send a "directed connectable" LE Audio broadcast message, so that the terminal device can establish a LE Audio Bluetooth connection with the above-mentioned Bluetooth audio device when triggered by the targeted LE Audio broadcast message. Such a device connection method can ensure that the LE Audio broadcast message sent by the Bluetooth audio device can only be responded to by the terminal device expected by the user, thereby preventing the Bluetooth audio device from being mistakenly connected to other devices in a connectable state, and helping to reduce the risk of The possibility of Bluetooth audio devices mistakenly connecting to terminal devices effectively improves the accuracy and flexibility of communication connections for Bluetooth audio devices. In addition, by sending the IRK of the terminal device to the Bluetooth audio device, the Bluetooth audio device can calculate the corresponding RPA type BLE address, thereby ensuring that the corresponding LE Audio broadcast message can only be correctly parsed and matched by the terminal device. It is beneficial to improve the accuracy and reliability of directional connection of Bluetooth audio devices to terminal devices. In addition, by synchronizing the identification information of the terminal device between the first Bluetooth audio device and the second Bluetooth audio device, the terminal device can establish LE Audio Bluetooth connections with the first Bluetooth audio device and the second Bluetooth audio device respectively to improve The flexibility of communication and connection between terminal devices and Bluetooth audio devices also helps improve the reliability of audio data transmission by each headset based on BLE technology.
请参阅图14,图14是本申请实施例公开的一种蓝牙音频设备的模块化示意图。如图14所示,该蓝牙音频设备可以包括:Please refer to Figure 14, which is a modular schematic diagram of a Bluetooth audio device disclosed in an embodiment of the present application. As shown in Figure 14, the Bluetooth audio device may include:
存储有可执行程序代码的存储器1401; Memory 1401 storing executable program code;
与存储器1401耦合的处理器1402; processor 1402 coupled to memory 1401;
其中,处理器1402调用存储器1401中存储的可执行程序代码,可以执行上述实施例所描述的任意一种应用于第一蓝牙音频设备或第二蓝牙音频设备的设备连接方法中的全部或部分步骤。The processor 1402 calls the executable program code stored in the memory 1401 to execute all or part of the steps in any of the device connection methods described in the above embodiments that are applied to the first Bluetooth audio device or the second Bluetooth audio device. .
请参阅图15,图15是本申请实施例公开的一种终端设备的模块化示意图。如图15所示,该终端设备可以包括:Please refer to FIG. 15 , which is a modular schematic diagram of a terminal device disclosed in an embodiment of the present application. As shown in Figure 15, the terminal device may include:
存储有可执行程序代码的存储器1501; Memory 1501 storing executable program code;
与存储器1501耦合的处理器1502; processor 1502 coupled to memory 1501;
其中,处理器1502调用存储器1501中存储的可执行程序代码,可以执行上述实施例所描述的任意一种应用于终端设备的设备连接方法中的全部或部分步骤。The processor 1502 calls the executable program code stored in the memory 1501 to execute all or part of the steps in any device connection method applied to the terminal device described in the above embodiments.
此外,本申请实施例进一步公开了一种计算机可读存储介质,其存储用于电子数据交换的计算机程序,其中,该计算机程序使得计算机可以执行上述实施例所描述的任意一种设备连接方法中的全部或部分步骤。In addition, embodiments of the present application further disclose a computer-readable storage medium that stores a computer program for electronic data exchange, wherein the computer program enables the computer to perform any of the device connection methods described in the above embodiments. all or part of the steps.
此外,本申请实施例进一步公开一种计算机程序产品,当该计算机程序产品在计算机上运行时,使得计算机可以执行上述实施例所描述的任意一种设备连接方法中的全部或部分步骤。In addition, the embodiment of the present application further discloses a computer program product. When the computer program product is run on a computer, the computer can perform all or part of the steps in any of the device connection methods described in the above embodiments.
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质包括只读存储器(Read-Only  Memory,ROM)、随机存储器(Random Access Memory,RAM)、可编程只读存储器(Programmable Read-only Memory,PROM)、可擦除可编程只读存储器(Erasable Programmable Read Only Memory,EPROM)、一次可编程只读存储器(One-time Programmable Read-Only Memory,OTPROM)、电子抹除式可复写只读存储器(Electrically-Erasable Programmable Read-Only Memory,EEPROM)、只读光盘(Compact Disc Read-Only Memory,CD-ROM)或其它光盘存储器、磁盘存储器、磁带存储器、或者能够用于携带或存储数据的计算机可读的任何其它介质。Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing relevant hardware through a program. The program can be stored in a computer-readable storage medium, and the storage medium includes a read-only storage medium. Memory (Read-Only Memory, ROM), Random Access Memory (RAM), Programmable Read-only Memory (PROM), Erasable Programmable Read Only Memory, EPROM), One-time Programmable Read-Only Memory (OTPROM), Electronically Erasable Programmable Read-Only Memory (EEPROM), Compact Disc Read-Only Memory (CD-ROM) or other optical disk storage, magnetic disk storage, magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.
以上对本申请实施例公开的一种设备连接方法及装置、存储介质、芯片进行了详细介绍,本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的一般技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。The above is a detailed introduction to a device connection method, device, storage medium, and chip disclosed in the embodiments of the present application. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only for It helps to understand the methods and core ideas of this application; at the same time, for those of ordinary skill in the field, there will be changes in the specific implementation methods and application scope based on the ideas of this application. In summary, the content of this specification It should not be construed as a limitation on this application.

Claims (42)

  1. 一种设备连接方法,其特征在于,应用于第一蓝牙音频设备,所述方法包括:A device connection method, characterized in that it is applied to a first Bluetooth audio device, and the method includes:
    基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息;Based on the security management protocol between the first Bluetooth audio device and the first target device, obtain the identification information of the first target device;
    发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第一蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;Send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
    接收所述第一目标设备发送的低功耗蓝牙音频连接请求;Receive a low-power Bluetooth audio connection request sent by the first target device;
    响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。In response to the Bluetooth low energy audio connection request, a Bluetooth low energy audio connection is established with the first target device.
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:The method of claim 1, further comprising:
    向第二蓝牙音频设备发送所述第一目标设备的标识信息,以使所述第二蓝牙音频设备发送与所述标识信息对应的低功耗蓝牙广播消息,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;或者,Send the identification information of the first target device to a second Bluetooth audio device, so that the second Bluetooth audio device sends a low-power Bluetooth broadcast message corresponding to the identification information, and the second Bluetooth audio device communicates with the The first Bluetooth audio device belongs to the same Bluetooth device set; or,
    所述第二蓝牙音频设备对所述第一蓝牙音频设备与所述第一目标设备之间的蓝牙链路进行监听,并根据监听数据计算得到所述第一目标设备的标识信息。The second Bluetooth audio device monitors the Bluetooth link between the first Bluetooth audio device and the first target device, and calculates the identification information of the first target device based on the monitoring data.
  3. 根据权利要求1所述的方法,其特征在于,所述基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息,包括:The method of claim 1, wherein obtaining the identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device includes:
    基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收所述第一目标设备发送的安全管理信息;Based on the security management protocol between the first Bluetooth audio device and the first target device, receive the security management information sent by the first target device;
    根据所述安全管理信息,确定所述第一目标设备的标识信息。According to the security management information, the identification information of the first target device is determined.
  4. 根据权利要求3所述的方法,其特征在于,基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收所述第一目标设备发送的安全管理信息,包括:The method according to claim 3, characterized in that, based on the security management protocol between the first Bluetooth audio device and the first target device, receiving the security management information sent by the first target device includes:
    通过所述第一蓝牙音频设备与第一目标设备之间的蓝牙链路,配置所述第一蓝牙音频设备与所述第一目标设备之间的安全管理协议;Configuring a security management protocol between the first Bluetooth audio device and the first target device through the Bluetooth link between the first Bluetooth audio device and the first target device;
    基于所述安全管理协议,接收所述第一目标设备发送的安全管理信息。Based on the security management protocol, receive security management information sent by the first target device.
  5. 根据权利要求4所述的方法,其特征在于,所述蓝牙链路为异步无连接ACL类型的蓝牙链路。The method according to claim 4, characterized in that the Bluetooth link is an asynchronous connectionless ACL type Bluetooth link.
  6. 根据权利要求3所述的方法,其特征在于,所述标识信息包括设备蓝牙地址,所述安全管理信息包括蓝牙设备地址解析秘钥IRK,所述根据所述安全管理信息,确定所述第一目标设备的标识信息,包括:The method of claim 3, wherein the identification information includes a device Bluetooth address, the security management information includes a Bluetooth device address resolution key IRK, and the first step is determined based on the security management information. Identification information of the target device, including:
    根据所述IRK对应的计算规则,对所述IRK进行计算,以生成所述第一目标设备的设备蓝牙地址。The IRK is calculated according to the calculation rules corresponding to the IRK to generate the device Bluetooth address of the first target device.
  7. 根据权利要求1至6任一项所述的方法,其特征在于,所述第一蓝牙音频设备为支持同时建立经典蓝牙连接和低功耗蓝牙音频连接的设备;The method according to any one of claims 1 to 6, characterized in that the first Bluetooth audio device is a device that supports the simultaneous establishment of a classic Bluetooth connection and a low-power Bluetooth audio connection;
    或者,所述第一蓝牙音频设备为仅支持建立低功耗蓝牙音频连接的设备。Alternatively, the first Bluetooth audio device is a device that only supports establishing a low-power Bluetooth audio connection.
  8. 根据权利要求7所述的方法,其特征在于,在所述第一蓝牙音频设备为支持同时建立经典蓝牙连接和低功耗蓝牙音频连接的设备的情况下,在所述基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息之前,所述方法还包括:The method according to claim 7, characterized in that, in the case where the first Bluetooth audio device is a device that supports the simultaneous establishment of a classic Bluetooth connection and a low-power Bluetooth audio connection, the method based on the first Bluetooth Security management protocol between the audio device and the first target device, before obtaining the identification information of the first target device, the method further includes:
    进入配对状态,所述配对状态是指所述第一蓝牙音频设备处于可发现且可连接的状态;Entering the pairing state, the pairing state means that the first Bluetooth audio device is in a discoverable and connectable state;
    接收第一目标设备发送的经典蓝牙连接请求,并响应于所述经典蓝牙连接请求,与所述第一目标设备建立经典蓝牙连接;Receive a classic Bluetooth connection request sent by the first target device, and in response to the classic Bluetooth connection request, establish a classic Bluetooth connection with the first target device;
    所述基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息,包括:Obtaining the identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device includes:
    在与所述第一目标设备之间的经典蓝牙链路上,基于所述第一蓝牙音频设备与所述第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息。On the classic Bluetooth link with the first target device, the identification information of the first target device is obtained based on the security management protocol between the first Bluetooth audio device and the first target device.
  9. 根据权利要求7所述的方法,其特征在于,在所述第一蓝牙音频设备为仅支持建立低功耗蓝牙音频连接的设备的情况下,在所述基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获 取所述第一目标设备的标识信息之前,所述方法还包括:The method according to claim 7, characterized in that when the first Bluetooth audio device is a device that only supports establishing a low-power Bluetooth audio connection, the method based on the first Bluetooth audio device and the third A security management protocol between target devices. Before obtaining the identification information of the first target device, the method further includes:
    与所述第一目标设备建立低功耗蓝牙连接;Establish a low-power Bluetooth connection with the first target device;
    所述基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息,包括:Obtaining the identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device includes:
    在与所述第一目标设备之间的低功耗蓝牙链路上,基于所述第一蓝牙音频设备与所述第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息。On the low-power Bluetooth link with the first target device, obtain the identity of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device. information.
  10. 根据权利要求8所述的方法,其特征在于,在所述进入配对状态之前,所述方法还包括:The method according to claim 8, characterized in that before entering the pairing state, the method further includes:
    与第二目标设备断开蓝牙连接,所述第二目标设备的标识信息与第一目标设备的标识信息不相同;Disconnect the Bluetooth connection with the second target device, the identification information of the second target device is different from the identification information of the first target device;
    其中,所述第二目标设备在接收到所述第一蓝牙音频设备发送的与所述第一目标设备的标识信息对应的低功耗蓝牙广播消息时,不响应所述低功耗蓝牙广播消息。Wherein, when the second target device receives the Bluetooth low energy broadcast message corresponding to the identification information of the first target device sent by the first Bluetooth audio device, it does not respond to the Bluetooth low energy broadcast message. .
  11. 一种设备连接方法,其特征在于,应用于第二蓝牙音频设备,所述方法包括:A device connection method, characterized in that it is applied to a second Bluetooth audio device, and the method includes:
    对第一蓝牙音频设备与第一目标设备之间的蓝牙链路进行监听,获取监听数据,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;Monitor the Bluetooth link between the first Bluetooth audio device and the first target device to obtain monitoring data, where the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
    根据所述监听数据,计算得到所述第一目标设备的标识信息;According to the monitoring data, calculate the identification information of the first target device;
    发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;Send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
    接收所述第一目标设备发送的低功耗蓝牙音频连接请求;Receive a low-power Bluetooth audio connection request sent by the first target device;
    响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。In response to the Bluetooth low energy audio connection request, a Bluetooth low energy audio connection is established with the first target device.
  12. 根据权利要求11所述的方法,其特征在于,所述监听数据包括所述第一目标设备的安全管理信息,所述安全管理信息包括蓝牙设备地址解析秘钥IRK,所述标识信息包括设备蓝牙地址,所述根据所述监听数据,计算得到所述第一目标设备的标识信息,包括:The method of claim 11, wherein the monitoring data includes security management information of the first target device, the security management information includes a Bluetooth device address resolution key IRK, and the identification information includes device Bluetooth The address, the identification information of the first target device calculated based on the listening data, includes:
    根据所述IRK对应的计算规则,对所述IRK进行计算,以生成所述第一目标设备的设备蓝牙地址。The IRK is calculated according to the calculation rules corresponding to the IRK to generate the device Bluetooth address of the first target device.
  13. 一种设备连接方法,其特征在于,应用于第二蓝牙音频设备,所述方法包括:A device connection method, characterized in that it is applied to a second Bluetooth audio device, and the method includes:
    接收第一蓝牙音频设备发送的第一目标设备的标识信息,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;Receive the identification information of the first target device sent by the first Bluetooth audio device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
    发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;Send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the second Bluetooth audio device can respond to the low-power Bluetooth audio connection request initiated by the first target device. ;
    接收所述第一目标设备发送的低功耗蓝牙音频连接请求;Receive a low-power Bluetooth audio connection request sent by the first target device;
    响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。In response to the Bluetooth low energy audio connection request, a Bluetooth low energy audio connection is established with the first target device.
  14. 一种设备连接方法,其特征在于,应用于终端设备,所述方法包括:A device connection method, characterized in that it is applied to terminal equipment, and the method includes:
    基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息;Based on the security management protocol between the first Bluetooth audio device and the terminal device, send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device;
    接收所述第一蓝牙音频设备响应于所述安全管理信息发送的第一低功耗蓝牙广播消息;Receive a first low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the security management information;
    在确定所述第一低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于所述第一低功耗蓝牙广播消息,向所述第一蓝牙音频设备发送低功耗蓝牙音频连接请求,以使所述第一蓝牙音频设备响应于所述低功耗蓝牙音频连接请求,与所述终端设备建立低功耗蓝牙音频连接。When it is determined that the first Bluetooth low energy broadcast message corresponds to the identification information of the terminal device, in response to the first Bluetooth low energy broadcast message, send a low-power Bluetooth audio device to the first Bluetooth audio device. and a Bluetooth audio connection request, so that the first Bluetooth audio device responds to the Bluetooth low energy audio connection request and establishes a low-power Bluetooth audio connection with the terminal device.
  15. 根据权利要求14所述的方法,其特征在于,所述基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息,包括:The method according to claim 14, characterized in that, based on the security management protocol between the first Bluetooth audio device and the terminal device, the identification information of the terminal device is sent to the first Bluetooth audio device. Corresponding security management information includes:
    通过第一蓝牙音频设备与所述终端设备之间的蓝牙链路,配置所述第一蓝牙音频设备与所述终端设备之间的安全管理协议;Configuring a security management protocol between the first Bluetooth audio device and the terminal device through the Bluetooth link between the first Bluetooth audio device and the terminal device;
    基于所述安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息,所述安全管理信息用于使所述第一蓝牙音频设备根据所述安全管理信息,确定所述终端设备的标识信息,并发送与所述标识信息对应的第一低功耗蓝牙广播消息。Based on the security management protocol, security management information corresponding to the identification information of the terminal device is sent to the first Bluetooth audio device, where the security management information is used to enable the first Bluetooth audio device to perform the security management according to the security management protocol. information, determine the identification information of the terminal device, and send the first low-power Bluetooth broadcast message corresponding to the identification information.
  16. 根据权利要求14所述的方法,其特征在于,所述标识信息包括设备蓝牙地址,所述接收所述 第一蓝牙音频设备响应于所述安全管理信息发送的第一低功耗蓝牙广播消息,包括:The method of claim 14, wherein the identification information includes a device Bluetooth address, and the receiving a first low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the security management information, include:
    接收所述第一蓝牙音频设备响应于所述安全管理信息发送的携带目标蓝牙地址的第一低功耗蓝牙广播消息;Receive a first low-power Bluetooth broadcast message carrying a target Bluetooth address sent by the first Bluetooth audio device in response to the security management information;
    所述在确定所述第一低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于所述第一低功耗蓝牙广播消息,向所述第一蓝牙音频设备发送低功耗蓝牙音频连接请求,包括:When it is determined that the first Bluetooth low energy broadcast message corresponds to the identification information of the terminal device, in response to the first Bluetooth low energy broadcast message, send a low-power Bluetooth audio device to the first Bluetooth audio device. Power consumption Bluetooth audio connection request, including:
    根据所述安全管理信息对应的计算规则,对所述安全管理信息以及所述目标蓝牙地址进行计算,得到校验蓝牙地址;Calculate the security management information and the target Bluetooth address according to the calculation rules corresponding to the security management information to obtain a verification Bluetooth address;
    将所述目标蓝牙地址以及所述校验蓝牙地址进行比对,若所述目标蓝牙地址与所述校验蓝牙地址相匹配,则确定所述第一低功耗蓝牙广播消息与所述终端设备的设备蓝牙地址对应,并响应于所述第一低功耗蓝牙广播消息,向所述第一蓝牙音频设备发送低功耗蓝牙音频连接请求。The target Bluetooth address and the verification Bluetooth address are compared. If the target Bluetooth address matches the verification Bluetooth address, it is determined that the first low-power Bluetooth broadcast message is the same as the terminal device. corresponding to the Bluetooth address of the device, and in response to the first Bluetooth low energy broadcast message, sending a Bluetooth low energy audio connection request to the first Bluetooth audio device.
  17. 根据权利要求14至16任一项所述的方法,其特征在于,所述基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息之前,所述方法还包括:The method according to any one of claims 14 to 16, characterized in that, based on the security management protocol between the first Bluetooth audio device and the terminal device, sending the message to the first Bluetooth audio device and the Before obtaining the security management information corresponding to the identification information of the terminal device, the method further includes:
    在确定第一蓝牙音频设备处于配对状态的情况下,向所述第一蓝牙音频设备发送经典蓝牙连接请求,所述配对状态是指所述第一蓝牙音频设备处于可发现且可连接的状态;When it is determined that the first Bluetooth audio device is in a pairing state, send a classic Bluetooth connection request to the first Bluetooth audio device, where the pairing state means that the first Bluetooth audio device is in a discoverable and connectable state;
    与响应所述经典蓝牙连接请求的所述第一蓝牙音频设备建立经典蓝牙连接。Establishing a classic Bluetooth connection with the first Bluetooth audio device responding to the classic Bluetooth connection request.
  18. 根据权利要求14至16任一项所述的方法,其特征在于,所述安全管理信息,用于使所述第一蓝牙音频设备根据所述安全管理信息,确定所述终端设备的标识信息,并由所述第一蓝牙音频设备向第二蓝牙音频设备发送所述终端设备的标识信息,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;或者,所述第二蓝牙音频设备对所述第一蓝牙音频设备与所述终端设备之间的蓝牙链路进行监听,并根据监听得到的所述安全管理信息计算得到所述终端设备的标识信息;The method according to any one of claims 14 to 16, characterized in that the security management information is used to enable the first Bluetooth audio device to determine the identification information of the terminal device according to the security management information, And the first Bluetooth audio device sends the identification information of the terminal device to the second Bluetooth audio device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set; or, The second Bluetooth audio device monitors the Bluetooth link between the first Bluetooth audio device and the terminal device, and calculates the identification information of the terminal device based on the security management information obtained through monitoring;
    其中,所述终端设备的标识信息,用于由所述第一蓝牙音频设备和/或所述第二蓝牙音频设备发送与所述标识信息对应的低功耗蓝牙广播消息。Wherein, the identification information of the terminal device is used for the first Bluetooth audio device and/or the second Bluetooth audio device to send a low-power Bluetooth broadcast message corresponding to the identification information.
  19. 根据权利要求18所述的方法,其特征在于,所述方法还包括:The method of claim 18, further comprising:
    接收所述第二蓝牙音频设备发送的第二低功耗蓝牙广播消息;Receive a second low-power Bluetooth broadcast message sent by the second Bluetooth audio device;
    根据所述第二低功耗蓝牙广播消息以及所述第一低功耗蓝牙广播消息,判断所述第一蓝牙音频设备与所述第二蓝牙音频设备是否属于同一蓝牙设备集合;Determine whether the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set according to the second Bluetooth low energy broadcast message and the first Bluetooth low energy broadcast message;
    在确定所述第一蓝牙音频设备与所述第二蓝牙音频设备属于同一蓝牙设备集合,且所述第二低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于所述第二低功耗蓝牙广播消息,向所述第二蓝牙音频设备发送低功耗蓝牙音频连接请求,以使所述第二蓝牙音频设备响应于所述低功耗蓝牙音频连接请求,与所述终端设备建立低功耗蓝牙音频连接。When it is determined that the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set, and the second low-power Bluetooth broadcast message corresponds to the identification information of the terminal device, in response to the The second low-power Bluetooth broadcast message sends a low-power Bluetooth audio connection request to the second Bluetooth audio device, so that the second Bluetooth audio device responds to the low-power Bluetooth audio connection request and communicates with the second low-power Bluetooth audio connection request. The above terminal device establishes a low-power Bluetooth audio connection.
  20. 一种设备连接装置,其特征在于,应用于第一蓝牙音频设备,所述设备连接装置包括:A device connection device, characterized in that it is applied to a first Bluetooth audio device, and the device connection device includes:
    信息获取单元,用于基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息;An information acquisition unit configured to acquire identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device;
    第一广播发送单元,用于发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第一蓝牙音频设备能够响应所述第一目标设备发起的低功耗蓝牙音频连接请求;A first broadcast sending unit configured to send a low-power Bluetooth broadcast message corresponding to the identification information. The low-power Bluetooth broadcast message is used to indicate that the first Bluetooth audio device can respond to the first target device’s initiation. Bluetooth low energy audio connection request;
    第一请求接收单元,用于接收所述第一目标设备发送的低功耗蓝牙音频连接请求;A first request receiving unit configured to receive a low-power Bluetooth audio connection request sent by the first target device;
    第一连接单元,用于响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。A first connection unit configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
  21. 根据权利要求20所述的设备连接装置,其特征在于,所述设备连接装置还包括:The equipment connection device according to claim 20, characterized in that the equipment connection device further includes:
    信息同步单元,用于向第二蓝牙音频设备发送所述第一目标设备的标识信息,以使所述第二蓝牙音频设备发送与所述标识信息对应的低功耗蓝牙广播消息,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;或者,An information synchronization unit configured to send identification information of the first target device to a second Bluetooth audio device, so that the second Bluetooth audio device sends a low-power Bluetooth broadcast message corresponding to the identification information. The second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set; or,
    所述第二蓝牙音频设备对所述第一蓝牙音频设备与所述第一目标设备之间的蓝牙链路进行监听,并 根据监听数据计算得到所述第一目标设备的标识信息。The second Bluetooth audio device monitors the Bluetooth link between the first Bluetooth audio device and the first target device, and calculates the identification information of the first target device based on the monitoring data.
  22. 根据权利要求20所述的设备连接装置,其特征在于,所述信息获取单元在用于基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息时,包括:The device connection device according to claim 20, wherein the information acquisition unit is configured to acquire the first target device based on a security management protocol between the first Bluetooth audio device and the first target device. identification information, including:
    基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收所述第一目标设备发送的安全管理信息;Based on the security management protocol between the first Bluetooth audio device and the first target device, receive the security management information sent by the first target device;
    根据所述安全管理信息,确定所述第一目标设备的标识信息。According to the security management information, the identification information of the first target device is determined.
  23. 根据权利要求22所述的设备连接装置,其特征在于,所述信息获取单元在用于基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,接收所述第一目标设备发送的安全管理信息时,包括:The device connection device according to claim 22, wherein the information acquisition unit is configured to receive the first target device based on a security management protocol between the first Bluetooth audio device and the first target device. The security management information sent includes:
    通过所述第一蓝牙音频设备与第一目标设备之间的蓝牙链路,配置所述第一蓝牙音频设备与所述第一目标设备之间的安全管理协议;Configuring a security management protocol between the first Bluetooth audio device and the first target device through the Bluetooth link between the first Bluetooth audio device and the first target device;
    基于所述安全管理协议,接收所述第一目标设备发送的安全管理信息。Based on the security management protocol, receive security management information sent by the first target device.
  24. 根据权利要求23所述的设备连接装置,其特征在于,所述蓝牙链路为异步无连接ACL类型的蓝牙链路。The device connection device according to claim 23, wherein the Bluetooth link is an asynchronous connectionless ACL type Bluetooth link.
  25. 根据权利要求22所述的设备连接装置,其特征在于,所述标识信息包括设备蓝牙地址,所述安全管理信息包括蓝牙设备地址解析秘钥IRK,所述信息获取单元在用于根据所述安全管理信息,确定所述第一目标设备的标识信息时,包括:The device connection device according to claim 22, wherein the identification information includes a device Bluetooth address, the security management information includes a Bluetooth device address resolution key IRK, and the information acquisition unit is used to obtain the device according to the security Management information, when determining the identification information of the first target device, includes:
    根据所述IRK对应的计算规则,对所述IRK进行计算,以生成所述第一目标设备的设备蓝牙地址。The IRK is calculated according to the calculation rules corresponding to the IRK to generate the device Bluetooth address of the first target device.
  26. 根据权利要求20至25任一项所述的设备连接装置,其特征在于,所述第一蓝牙音频设备为支持同时建立经典蓝牙连接和低功耗蓝牙音频连接的设备;The device connection device according to any one of claims 20 to 25, wherein the first Bluetooth audio device is a device that supports the simultaneous establishment of a classic Bluetooth connection and a low-power Bluetooth audio connection;
    或者,所述第一蓝牙音频设备为仅支持建立低功耗蓝牙音频连接的设备。Alternatively, the first Bluetooth audio device is a device that only supports establishing a low-power Bluetooth audio connection.
  27. 根据权利要求26所述的设备连接装置,其特征在于,在所述第一蓝牙音频设备为支持同时建立经典蓝牙连接和低功耗蓝牙音频连接的设备的情况下,所述设备连接装置还包括:The device connection device according to claim 26, wherein when the first Bluetooth audio device is a device that supports the simultaneous establishment of a classic Bluetooth connection and a low-power Bluetooth audio connection, the device connection device further includes :
    配对单元,用于在所述信息获取单元基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息之前,进入配对状态,所述配对状态是指所述第一蓝牙音频设备处于可发现且可连接的状态;A pairing unit configured to enter a pairing state before the information acquisition unit acquires the identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device. The state means that the first Bluetooth audio device is in a discoverable and connectable state;
    所述第一请求接收单元,还用于接收第一目标设备发送的经典蓝牙连接请求;The first request receiving unit is also used to receive a classic Bluetooth connection request sent by the first target device;
    所述第一连接单元,还用于响应于所述经典蓝牙连接请求,与所述第一目标设备建立经典蓝牙连接;The first connection unit is also configured to respond to the classic Bluetooth connection request and establish a classic Bluetooth connection with the first target device;
    所述信息获取单元,还用于在与所述第一目标设备之间的经典蓝牙链路上,基于所述第一蓝牙音频设备与所述第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息。The information acquisition unit is also configured to obtain the information based on the security management protocol between the first Bluetooth audio device and the first target device on the classic Bluetooth link with the first target device. The identification information of the first target device.
  28. 根据权利要求26所述的设备连接装置,其特征在于,在所述第一蓝牙音频设备为仅支持建立低功耗蓝牙音频连接的设备的情况下,所述第一连接单元,还用于在所述信息获取单元基于所述第一蓝牙音频设备与第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息之前,与所述第一目标设备建立低功耗蓝牙连接;The device connection device according to claim 26, wherein when the first Bluetooth audio device is a device that only supports establishing a low-power Bluetooth audio connection, the first connection unit is also used to: The information acquisition unit establishes a low-power Bluetooth connection with the first target device before acquiring the identification information of the first target device based on the security management protocol between the first Bluetooth audio device and the first target device. ;
    所述信息获取单元,还用于在与所述第一目标设备之间的低功耗蓝牙链路上,基于所述第一蓝牙音频设备与所述第一目标设备之间的安全管理协议,获取所述第一目标设备的标识信息。The information acquisition unit is also configured to, on the low-power Bluetooth link with the first target device, based on the security management protocol between the first Bluetooth audio device and the first target device, Obtain the identification information of the first target device.
  29. 根据权利要求27所述的设备连接装置,其特征在于,所述第一连接单元,还用于在所述配对单元进入配对状态之前,与第二目标设备断开蓝牙连接,所述第二目标设备的标识信息与第一目标设备的标识信息不相同;The device connection device according to claim 27, wherein the first connection unit is further configured to disconnect the Bluetooth connection from the second target device before the pairing unit enters the pairing state, and the second target device The identification information of the device is different from the identification information of the first target device;
    其中,所述第二目标设备在接收到所述第一蓝牙音频设备发送的与所述第一目标设备的标识信息对应的低功耗蓝牙广播消息时,不响应所述低功耗蓝牙广播消息。Wherein, when the second target device receives the Bluetooth low energy broadcast message corresponding to the identification information of the first target device sent by the first Bluetooth audio device, it does not respond to the Bluetooth low energy broadcast message. .
  30. 一种设备连接装置,其特征在于,应用于第二蓝牙音频设备,所述设备连接装置包括:A device connection device, characterized in that it is applied to a second Bluetooth audio device, and the device connection device includes:
    监听单元,用于对第一蓝牙音频设备与第一目标设备之间的蓝牙链路进行监听,获取监听数据,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;A monitoring unit configured to monitor the Bluetooth link between the first Bluetooth audio device and the first target device and obtain monitoring data, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device. gather;
    计算单元,用于根据所述监听数据,计算得到所述第一目标设备的标识信息;A computing unit configured to calculate identification information of the first target device according to the monitoring data;
    第二广播发送单元,用于发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备响应所述第一目标设备发起的低功耗蓝牙音频连接请求;A second broadcast sending unit, configured to send a low-power Bluetooth broadcast message corresponding to the identification information, where the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to a call initiated by the first target device. Bluetooth low energy audio connection request;
    第二请求接收单元,用于接收所述第一目标设备发送的低功耗蓝牙音频连接请求;A second request receiving unit, configured to receive a low-power Bluetooth audio connection request sent by the first target device;
    第二连接单元,用于响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。The second connection unit is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
  31. 根据权利要求30所述的设备连接装置,其特征在于,所述监听数据包括所述第一目标设备的安全管理信息,所述安全管理信息包括蓝牙设备地址解析秘钥IRK,所述标识信息包括设备蓝牙地址,所述计算单元在用于根据所述监听数据,计算得到所述第一目标设备的标识信息时,包括:The device connection device according to claim 30, wherein the monitoring data includes security management information of the first target device, the security management information includes a Bluetooth device address resolution key IRK, and the identification information includes Device Bluetooth address. When the calculation unit is used to calculate the identification information of the first target device based on the monitoring data, it includes:
    根据所述IRK对应的计算规则,对所述IRK进行计算,以生成所述第一目标设备的设备蓝牙地址。The IRK is calculated according to the calculation rules corresponding to the IRK to generate the device Bluetooth address of the first target device.
  32. 一种设备连接装置,其特征在于,应用于第二蓝牙音频设备,所述设备连接装置包括:A device connection device, characterized in that it is applied to a second Bluetooth audio device, and the device connection device includes:
    信息接收单元,用于接收第一蓝牙音频设备发送的第一目标设备的标识信息,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;An information receiving unit configured to receive the identification information of the first target device sent by the first Bluetooth audio device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set;
    第三广播发送单元,用于发送与所述标识信息对应的低功耗蓝牙广播消息,所述低功耗蓝牙广播消息用于指示所述第二蓝牙音频设备响应所述第一目标设备发起的低功耗蓝牙音频连接请求;A third broadcast sending unit, configured to send a low-power Bluetooth broadcast message corresponding to the identification information, where the low-power Bluetooth broadcast message is used to instruct the second Bluetooth audio device to respond to a call initiated by the first target device. Bluetooth low energy audio connection request;
    第三请求接收单元,用于接收所述第一目标设备发送的低功耗蓝牙音频连接请求;A third request receiving unit configured to receive a low-power Bluetooth audio connection request sent by the first target device;
    第三连接单元,用于响应于所述低功耗蓝牙音频连接请求,与所述第一目标设备建立低功耗蓝牙音频连接。The third connection unit is configured to establish a low-power Bluetooth audio connection with the first target device in response to the low-power Bluetooth audio connection request.
  33. 一种设备连接装置,其特征在于,应用于终端设备,所述设备连接装置包括:An equipment connection device, characterized in that it is applied to terminal equipment, and the equipment connection device includes:
    信息发送单元,用于基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息;An information sending unit configured to send security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device based on the security management protocol between the first Bluetooth audio device and the terminal device;
    广播接收单元,用于接收所述第一蓝牙音频设备响应于所述安全管理信息发送的低功耗蓝牙广播消息;A broadcast receiving unit configured to receive a low-power Bluetooth broadcast message sent by the first Bluetooth audio device in response to the security management information;
    请求发送单元,用于在确定所述低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于所述低功耗蓝牙广播消息,向所述第一蓝牙音频设备发送低功耗蓝牙音频连接请求,以使所述第一蓝牙音频设备响应于所述低功耗蓝牙音频连接请求,与所述终端设备建立低功耗蓝牙音频连接。A request sending unit, configured to respond to the Bluetooth low energy broadcast message and send a low-power Bluetooth audio device to the first Bluetooth audio device when it is determined that the low-power Bluetooth broadcast message corresponds to the identification information of the terminal device. and a power consumption Bluetooth audio connection request, so that the first Bluetooth audio device responds to the low power Bluetooth audio connection request and establishes a low power Bluetooth audio connection with the terminal device.
  34. 根据权利要求33所述的设备连接装置,其特征在于,所述信息发送单元在用于基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息时,包括:The device connection device according to claim 33, wherein the information sending unit is configured to send a message to the first Bluetooth audio device based on a security management protocol between the first Bluetooth audio device and the terminal device. The security management information corresponding to the identification information of the terminal device includes:
    通过第一蓝牙音频设备与所述终端设备之间的蓝牙链路,配置所述第一蓝牙音频设备与所述终端设备之间的安全管理协议;Configuring a security management protocol between the first Bluetooth audio device and the terminal device through the Bluetooth link between the first Bluetooth audio device and the terminal device;
    基于所述安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息,所述安全管理信息用于使所述第一蓝牙音频设备根据所述安全管理信息,确定所述终端设备的标识信息,并发送与所述标识信息对应的第一低功耗蓝牙广播消息。Based on the security management protocol, security management information corresponding to the identification information of the terminal device is sent to the first Bluetooth audio device, and the security management information is used to enable the first Bluetooth audio device to perform the security management according to the security management protocol. information, determine the identification information of the terminal device, and send the first low-power Bluetooth broadcast message corresponding to the identification information.
  35. 根据权利要求33所述的设备连接装置,其特征在于,所述标识信息包括设备蓝牙地址,所述广播接收单元在用于接收所述第一蓝牙音频设备响应于所述安全管理信息发送的第一低功耗蓝牙广播消息时,包括:The device connection device according to claim 33, wherein the identification information includes a device Bluetooth address, and the broadcast receiving unit is configured to receive the first Bluetooth audio device sent in response to the security management information. A Bluetooth Low Energy broadcast message includes:
    接收所述第一蓝牙音频设备响应于所述安全管理信息发送的携带目标蓝牙地址的第一低功耗蓝牙广播消息;Receive a first low-power Bluetooth broadcast message carrying a target Bluetooth address sent by the first Bluetooth audio device in response to the security management information;
    所述请求发送单元,还用于根据所述安全管理信息对应的计算规则,对所述安全管理信息以及所述目标蓝牙地址进行计算,得到校验蓝牙地址;以及,The request sending unit is also configured to calculate the security management information and the target Bluetooth address according to the calculation rules corresponding to the security management information to obtain a verification Bluetooth address; and,
    将所述目标蓝牙地址以及所述校验蓝牙地址进行比对,若所述目标蓝牙地址与所述校验蓝牙地址相匹配,则确定所述第一低功耗蓝牙广播消息与所述终端设备的设备蓝牙地址对应,并响应于所述第一低功耗蓝牙广播消息,向所述第一蓝牙音频设备发送低功耗蓝牙音频连接请求。The target Bluetooth address and the verification Bluetooth address are compared. If the target Bluetooth address matches the verification Bluetooth address, it is determined that the first low-power Bluetooth broadcast message is the same as the terminal device. corresponding to the Bluetooth address of the device, and in response to the first Bluetooth low energy broadcast message, sending a Bluetooth low energy audio connection request to the first Bluetooth audio device.
  36. 根据权利要求33至35任一项所述的设备连接装置,其特征在于,所述请求发送单元,还用于在所述信息发送单元基于第一蓝牙音频设备与所述终端设备之间的安全管理协议,向所述第一蓝牙音频设备发送与所述终端设备的标识信息对应的安全管理信息之前,在确定第一蓝牙音频设备处于配对状态的情况下,向所述第一蓝牙音频设备发送经典蓝牙连接请求,所述配对状态是指所述第一蓝牙音频设备处于可发现且可连接的状态;The device connection device according to any one of claims 33 to 35, wherein the request sending unit is further configured to perform the information sending unit based on the security between the first Bluetooth audio device and the terminal device. Management protocol: before sending the security management information corresponding to the identification information of the terminal device to the first Bluetooth audio device, when it is determined that the first Bluetooth audio device is in a pairing state, sending the security management information to the first Bluetooth audio device. Classic Bluetooth connection request, the pairing state means that the first Bluetooth audio device is in a discoverable and connectable state;
    所述设备连接装置还包括:The equipment connection device also includes:
    连接单元,用于与响应所述经典蓝牙连接请求的所述第一蓝牙音频设备建立经典蓝牙连接。A connection unit configured to establish a classic Bluetooth connection with the first Bluetooth audio device that responds to the classic Bluetooth connection request.
  37. 根据权利要求33至35任一项所述的设备连接装置,其特征在于,所述安全管理信息,用于使所述第一蓝牙音频设备根据所述安全管理信息,确定所述终端设备的标识信息,并由所述第一蓝牙音频设备向第二蓝牙音频设备发送所述终端设备的标识信息,其中,所述第二蓝牙音频设备与所述第一蓝牙音频设备属于同一蓝牙设备集合;或者,所述第二蓝牙音频设备对所述第一蓝牙音频设备与所述终端设备之间的蓝牙链路进行监听,并根据监听得到的所述安全管理信息计算得到所述终端设备的标识信息;The device connection device according to any one of claims 33 to 35, wherein the security management information is used to enable the first Bluetooth audio device to determine the identity of the terminal device according to the security management information. information, and the first Bluetooth audio device sends the identification information of the terminal device to a second Bluetooth audio device, wherein the second Bluetooth audio device and the first Bluetooth audio device belong to the same Bluetooth device set; or , the second Bluetooth audio device monitors the Bluetooth link between the first Bluetooth audio device and the terminal device, and calculates the identification information of the terminal device based on the security management information obtained by monitoring;
    其中,所述终端设备的标识信息,用于由所述第一蓝牙音频设备和/或所述第二蓝牙音频设备发送与所述标识信息对应的低功耗蓝牙广播消息。Wherein, the identification information of the terminal device is used for the first Bluetooth audio device and/or the second Bluetooth audio device to send a low-power Bluetooth broadcast message corresponding to the identification information.
  38. 根据权利要求37所述的设备连接装置,其特征在于,所述广播接收单元,还用于接收所述第二蓝牙音频设备发送的第二低功耗蓝牙广播消息;The device connection device according to claim 37, wherein the broadcast receiving unit is further configured to receive a second low-power Bluetooth broadcast message sent by the second Bluetooth audio device;
    所述设备连接装置还包括:The equipment connection device also includes:
    判断单元,用于根据所述第二低功耗蓝牙广播消息以及所述第一低功耗蓝牙广播消息,判断所述第一蓝牙音频设备与所述第二蓝牙音频设备是否属于同一蓝牙设备集合;A determination unit configured to determine whether the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set according to the second Bluetooth low energy broadcast message and the first Bluetooth low energy broadcast message. ;
    所述请求发送单元,还用于在确定所述第一蓝牙音频设备与所述第二蓝牙音频设备属于同一蓝牙设备集合,且所述第二低功耗蓝牙广播消息与所述终端设备的标识信息对应的情况下,响应于所述第二低功耗蓝牙广播消息,向所述第二蓝牙音频设备发送低功耗蓝牙音频连接请求,以使所述第二蓝牙音频设备响应于所述低功耗蓝牙音频连接请求,与所述终端设备建立低功耗蓝牙音频连接。The request sending unit is also configured to determine that the first Bluetooth audio device and the second Bluetooth audio device belong to the same Bluetooth device set, and the second low-power Bluetooth broadcast message and the identification of the terminal device If the information corresponds to the second Bluetooth low energy broadcast message, send a low-power Bluetooth audio connection request to the second Bluetooth audio device, so that the second Bluetooth audio device responds to the low-power Bluetooth audio device. Power consumption Bluetooth audio connection request to establish a low-power Bluetooth audio connection with the terminal device.
  39. 一种蓝牙音频设备,其特征在于,所述蓝牙音频设备包括存储器及处理器,所述存储器中存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器实现如权利要求1至10任一项所述的设备连接方法,或者如权利要求11至13任一项所述的设备连接方法。A Bluetooth audio device, characterized in that the Bluetooth audio device includes a memory and a processor, and a computer program is stored in the memory. When the computer program is executed by the processor, the processor implements the following steps: The device connection method according to any one of claims 1 to 10, or the device connection method according to any one of claims 11 to 13.
  40. 一种终端设备,其特征在于,所述终端设备包括存储器及处理器,所述存储器中存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器实现如权利要求14至19任一项所述的设备连接方法。A terminal device, characterized in that the terminal device includes a memory and a processor, a computer program is stored in the memory, and when the computer program is executed by the processor, the processor implements the method of claim 14 to the device connection method described in any one of 19.
  41. 一种计算机可读存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至10任一项所述的设备连接方法,或者如权利要求11至13任一项所述的设备连接方法,或者如权利要求14至19任一项所述的设备连接方法。A computer-readable storage medium with a computer program stored thereon, characterized in that when the computer program is executed by a processor, the device connection method as claimed in any one of claims 1 to 10 is implemented, or as claimed in claim 11 The device connection method according to any one of claims 14 to 13, or the device connection method according to any one of claims 14 to 19.
  42. 一种芯片,包括处理器,其特征在于,所述处理器用于读取并执行存储器中存储的计算机程序,以执行如权利要求1至10任一项所述的设备连接方法,或者如权利要求11至13任一项所述的设备连接方法,或者执行如权利要求14至19任一项所述的设备连接方法。A chip, including a processor, characterized in that the processor is configured to read and execute a computer program stored in a memory to execute the device connection method as claimed in any one of claims 1 to 10, or as claimed in claim 1 The device connection method according to any one of claims 11 to 13, or the device connection method according to any one of claims 14 to 19.
PCT/CN2022/142139 2022-06-21 2022-12-27 Device connection method and apparatus, and storage medium and chip WO2023246056A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210705490.XA CN117319970A (en) 2022-06-21 2022-06-21 Device connection method and device, storage medium and chip
CN202210705490.X 2022-06-21

Publications (1)

Publication Number Publication Date
WO2023246056A1 true WO2023246056A1 (en) 2023-12-28

Family

ID=89248577

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/142139 WO2023246056A1 (en) 2022-06-21 2022-12-27 Device connection method and apparatus, and storage medium and chip

Country Status (2)

Country Link
CN (1) CN117319970A (en)
WO (1) WO2023246056A1 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109862549A (en) * 2019-03-28 2019-06-07 南昌黑鲨科技有限公司 Bluetooth connecting method, device, readable storage medium storing program for executing and mobile device
WO2021027686A1 (en) * 2019-08-09 2021-02-18 华为技术有限公司 Bluetooth device mutual identification or mutual trust method
CN113038442A (en) * 2021-03-16 2021-06-25 北京百瑞互联技术有限公司 Method, device and system for matching and connecting low-power-consumption Bluetooth equipment
CN113286284A (en) * 2021-05-26 2021-08-20 南京紫牛软件科技有限公司 Connection control method, device, equipment and medium for terminal and Bluetooth equipment
WO2022089494A1 (en) * 2020-10-30 2022-05-05 华为技术有限公司 Communication method and apparatus, and electronic device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109862549A (en) * 2019-03-28 2019-06-07 南昌黑鲨科技有限公司 Bluetooth connecting method, device, readable storage medium storing program for executing and mobile device
WO2021027686A1 (en) * 2019-08-09 2021-02-18 华为技术有限公司 Bluetooth device mutual identification or mutual trust method
WO2022089494A1 (en) * 2020-10-30 2022-05-05 华为技术有限公司 Communication method and apparatus, and electronic device
CN113038442A (en) * 2021-03-16 2021-06-25 北京百瑞互联技术有限公司 Method, device and system for matching and connecting low-power-consumption Bluetooth equipment
CN113286284A (en) * 2021-05-26 2021-08-20 南京紫牛软件科技有限公司 Connection control method, device, equipment and medium for terminal and Bluetooth equipment

Also Published As

Publication number Publication date
CN117319970A (en) 2023-12-29

Similar Documents

Publication Publication Date Title
EP3794853B1 (en) Secure systems and methods for establishing wireless audio sharing connection
US10917920B2 (en) Method and apparatus for connecting alternative communication means using bluetooth low energy (LE)
CN113366439B (en) Method and device for connecting Bluetooth device
US20190215879A1 (en) Method and apparatus for connecting device by using bluetooth technology
CN113014483B (en) Multi-path transmission method and equipment
WO2020077658A1 (en) Extended connection method and extended connection system for bluetooth devices
US10863559B2 (en) Method and apparatus for communicating in a wireless communication network
KR102509480B1 (en) Ring network of bluetooth speakers
WO2016080798A1 (en) Method for performing pairing between devices in wireless communication system supporting bluetooth communication and apparatus therefor
WO2022143071A1 (en) Connection establishment method and electronic device
US11622196B2 (en) Method for transmitting audio data by using short-range wireless communication in wireless communication system, and apparatus for same
US10492060B2 (en) Method and device for transmitting/receiving data in wireless communication system
CN114390491A (en) Networking method, device and system
WO2023246056A1 (en) Device connection method and apparatus, and storage medium and chip
WO2022198391A1 (en) Communication method, communication apparatus, and terminal
CN113810887B (en) Bluetooth protocol connection method and device, storage medium and related equipment
WO2014000489A1 (en) Method for establishing communication link between multi-mode rru and bbu, multi-mode rru and bbu
CN115396856A (en) Method, device, equipment and storage medium for establishing Bluetooth link
US10349456B2 (en) Video communication system, video transmission terminal, video reception terminal, communication method, and recording medium
WO2024012343A1 (en) Networking method and electronic device
WO2023065881A1 (en) Bluetooth connection method and apparatus, electronic device, and storage medium
WO2024016885A1 (en) Bluetooth connection method and apparatus, electronic device, and computer readable storage medium
JP2013172275A (en) Communication device and communication method for the same
CN115209510B (en) Wireless network connection method and device, electronic equipment and storage medium
WO2023134386A1 (en) Device connection method and apparatus, and device, storage medium and chip

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22947791

Country of ref document: EP

Kind code of ref document: A1