Nothing Special   »   [go: up one dir, main page]

WO2024001134A1 - 音频设备的连接方法、装置、存储介质及设备 - Google Patents

音频设备的连接方法、装置、存储介质及设备 Download PDF

Info

Publication number
WO2024001134A1
WO2024001134A1 PCT/CN2022/143466 CN2022143466W WO2024001134A1 WO 2024001134 A1 WO2024001134 A1 WO 2024001134A1 CN 2022143466 W CN2022143466 W CN 2022143466W WO 2024001134 A1 WO2024001134 A1 WO 2024001134A1
Authority
WO
WIPO (PCT)
Prior art keywords
service
connection
audio
audio device
electronic device
Prior art date
Application number
PCT/CN2022/143466
Other languages
English (en)
French (fr)
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 WO2024001134A1 publication Critical patent/WO2024001134A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B5/00Near-field transmission systems, e.g. inductive or capacitive transmission systems
    • H04B5/70Near-field transmission systems, e.g. inductive or capacitive transmission systems specially adapted for specific purposes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R3/00Circuits for transducers, loudspeakers or microphones
    • 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
    • H04W76/14Direct-mode setup
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/15Setup of multiple wireless link connections

Definitions

  • the present application relates to the technical field of wireless equipment, and specifically relates to a connection method, device, storage medium and equipment for audio equipment.
  • TWS Truste Wireless Stereo
  • the left and right earphones of TWS earphones are independent of each other and do not need to be connected with cables to achieve wireless separation of the left and right channels. More and more users are equipping their smartphones, tablets, laptops and other electronic devices with Bluetooth headsets to play audio.
  • Low Energy Audio is a new audio transmission technology of the Bluetooth protocol. More and more Bluetooth devices support low-power audio transmission technology.
  • Embodiments of the present application provide an audio device connection method, device, storage medium and equipment, which can improve the connection speed when the electronic device and the wireless audio device are connected for the first time.
  • embodiments of the present application provide a method for connecting an audio device, which is applied to a wireless audio device, where the wireless audio device includes a first audio device and a second audio device; the method includes:
  • the first audio device establishes a first link connection with the electronic device
  • the first audio device When the first audio device receives a first service query for a preset service initiated by the electronic device, the query result corresponding to the preset service is sent to the electronic device. Carrying the first address information of the second audio device;
  • the second audio device Based on the first address information, the second audio device establishes a second link connection with the electronic device.
  • inventions of the present application also provide an audio device connection device, which is applied to wireless audio devices.
  • the wireless audio devices include a first audio device and a second audio device.
  • the device includes a device located on the first audio device.
  • the first connection module is used to establish a first link connection with the electronic device
  • a first sending module configured to send a query result corresponding to the preset service to the electronic device upon receiving a first service query for a preset service initiated by the electronic device. carries the first address information of the second audio device;
  • a second connection module configured to establish a second link connection between the second audio device and the electronic device based on the first address information.
  • connection method for audio equipment which is applied to wireless audio equipment.
  • the method includes:
  • connection device for audio equipment which is applied to electronic equipment.
  • the device includes:
  • the third connection module is used to establish a first link connection with the first audio device of the wireless audio device
  • a query module configured to initiate a first service query for a preset service to the first audio device, and obtain the first address information in the query result of the preset service;
  • the first audio device establishes a first link connection with the electronic device
  • the query result corresponding to the preset service is sent to the electronic device, so that the electronic device Establish a second link connection with the second audio device based on the first address information, wherein the query result carries the first address information of the second audio device.
  • a sixth aspect, applied to first audio equipment, the device includes:
  • the fourth connection module is used to establish a first link connection with the electronic device
  • the second connection module is configured to, upon receiving a first service query for a preset service initiated by the electronic device, send the query result corresponding to the preset service to the electronic device, so that the electronic device The device establishes a second link connection with the second audio device based on the first address information, wherein the query result carries the first address information of the second audio device.
  • embodiments of the present application also provide a computer-readable storage medium on which a computer program is stored.
  • the computer program is run on a computer, the computer is caused to execute the method provided by any embodiment of the present application. How to connect audio equipment.
  • embodiments of the present application further provide a wireless audio device, including a processor, a memory, and a wireless transceiver.
  • the memory stores a computer program.
  • the feature is that the processor uses the computer program to call the computer program.
  • Figure 1 shows the connection process when the TWS Bluetooth headset and the mobile phone are connected for the first time in related technology.
  • Figure 4 is a schematic diagram of a service in the embodiment of the present application.
  • FIG. 6 is another schematic flowchart of an audio device connection method provided by an embodiment of the present application.
  • FIG. 9 is a schematic structural diagram of a connection device for audio equipment provided by an embodiment of the present application.
  • FIG. 10 is another structural schematic diagram of a connection device for audio equipment provided by an embodiment of the present application.
  • FIG. 12 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • an embodiment means that a particular feature, structure or characteristic described in connection with the embodiment can be included in at least one embodiment of the present application.
  • the appearances of this phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those skilled in the art understand, both explicitly and implicitly, that the embodiments described herein may be combined with other embodiments.
  • An embodiment of the present application provides a connection method for audio equipment, which is applied to wireless audio equipment.
  • the wireless audio equipment includes a first audio device and a second audio device; the method includes:
  • the first audio device establishes a first link connection with the electronic device
  • the query result corresponding to the preset service is sent to the electronic device.
  • the query result Carrying the first address information of the second audio device;
  • the second audio device Based on the first address information, the second audio device establishes a second link connection with the electronic device.
  • the above methods before the step of sending the query result of the first service query to the electronic device when the first audio device receives the first service query initiated by the electronic device, the above methods also include:
  • the first audio device determines a service identification sequence, wherein the service identification of the preset service is located at the first position of the service identification sequence;
  • the service identification sequence is sent to the electronic device, and the service identification sequence is used to instruct the electronic device to initiate the first service query according to the service identification sequence.
  • the above methods before the step of sending the query result of the first service query to the electronic device when the first audio device receives the first service query initiated by the electronic device, the above methods also include:
  • the service identifier is used to instruct the electronic device to initiate a first service query for the preset service.
  • the method before the first audio device establishes a first link connection with the electronic device, the method further includes:
  • the device connection record When the device connection record is empty, the first address information of the second audio device is obtained, and the first address information of the second audio device is written into the preset service of the first audio device.
  • establishing a second link connection between the second audio device and the electronic device based on the first address information includes:
  • the second audio device sends a broadcast signal, the broadcast signal includes the first address information, and the broadcast signal is used to cause the electronic device to initiate a connection request to the second audio device based on the first address information;
  • the second audio device establishes the second link connection with the electronic device in response to the connection request.
  • the method further includes:
  • the first audio device and the electronic device establish a first LE AUDIO connection based on the first link connection;
  • the second audio device and the electronic device establish a second LE AUDIO connection based on the second link connection.
  • the wireless audio device includes a first audio device and a second audio device, and the device includes a first connection module and a first sending module located on the first audio device, and a second connection module located on the second audio device, wherein:
  • the first connection module is used to establish a first link connection with the electronic device
  • a first sending module configured to send a query result corresponding to the preset service to the electronic device upon receiving a first service query for a preset service initiated by the electronic device. carries the first address information of the second audio device;
  • a second connection module configured to establish a second link connection between the second audio device and the electronic device based on the first address information.
  • FIG. 1 shows the TWS Bluetooth headset in related technology.
  • the connection process when connecting to a mobile phone for the first time. After earphone 1 and earphone 2 complete the pairing session, both earphones turn on LE Audio broadcast. The phone will also open the Bluetooth connection, scan the broadcast signal, and establish LE with one earphone. Audio connection, and then parse the broadcast of another headset to determine whether the headset and the currently connected headset belong to the same coordination set, that is, based on the SIRK (Set Identity Resolving Key, combined identification parsing value) of the connected headset.
  • SIRK Set Identity Resolving Key, combined identification parsing value
  • FIG. 2 shows LE Audio in related technologies.
  • the structural information of the dedicated address can be parsed in the broadcast.
  • the high-order 24 bits of the address are the random number part (prand), of which the two highest bits are "10".
  • the low-order 24 bits are the hash value obtained by hashing the random number and IRK.
  • This connection scheme requires the electronic device to wait until a protocol connection is established with the first audio device before performing a checksum connection of the hash value based on the broadcast of the second audio device. There is Technical issues with slow connections.
  • the wireless audio device may be a Bluetooth headset, or other types of audio playback devices that support the Bluetooth protocol, such as a Bluetooth speaker.
  • the wireless audio device includes a first audio device and a second audio device.
  • the Bluetooth headset includes a first headset and a second headset. When the user uses the first headset and the second headset, the The first earphone and the second earphone need to be paired and connected first.
  • FIG. 3 is a schematic flowchart of an audio device connection method provided by an embodiment of the present application.
  • the specific process of the audio device connection method provided by the embodiment of the present application may be as follows:
  • the wireless audio device as a Bluetooth headset
  • the first audio device as the first headset
  • the second audio device as the second headset
  • the two earphones may be paired and connected with each other, or the two earphones may not be paired with each other.
  • the headphone box The Bluetooth address of one earphone can be sent to the other earphone automatically or in response to the user's control operation, so that each of the two earphones obtains the Bluetooth address of the other earphone; or, before the earphone leaves the factory, the setting will
  • the address of one earphone in a pair of earphones is stored in the other earphone.
  • the query result corresponding to the preset service for setting two earphones includes the Bluetooth address of the other earphone.
  • the Bluetooth headset can control the activation of the headset through a headset box containing the Bluetooth headset.
  • the headset box includes a box body and a box cover movably connected to the box body.
  • the headphone box is also provided with a cover sensor, and the cover sensor cover is configured to generate a cover opening signal when the box cover switches from a closed state to an open state, and the headphone box sends the cover opening signal to the Bluetooth headset.
  • the cover opening operation of the headphone box can be detected by detecting the cover opening signal. That is to say, when the Bluetooth headset receives the cover opening signal sent by the headphone box, it is determined that the headphone box has performed a cover opening operation.
  • the activation of the Bluetooth headset is triggered by opening the cover.
  • the first headset is provided with a first wireless connection module, such as a low-power Bluetooth module; the second headset is provided with a second wireless connection module.
  • the activation of two earphones can also be controlled through control operations.
  • the two earphones are respectively provided with control buttons, or a touch sensor is arranged in a specific area, and the user controls the activation of the two earphones through pressing or touching operations. Turn on.
  • a mutual pairing connection is performed between the two earphones. After the connection is established, the two earphones each send the Bluetooth address of the device to the other earphone.
  • the “first” and “second” in the “first audio device” and “second audio device” in the embodiment of the present application are only used to distinguish the two earphones.
  • the first and second audio devices are The wireless audio device that is connected to the electronic device is the first audio device, and the wireless audio device that is later connected to the electronic device is the second audio device.
  • the mobile phone After the mobile phone and the Bluetooth headset complete their respective service queries, the mobile phone initiates a connection with the Bluetooth headset using the LE-Audio protocol. Only then is the LE-Audio connection between the two devices completed, and then the mobile phone can control the headset. , and transmit audio data to headphones, etc.
  • GATT Generic Attribute Profile
  • a service query is initiated to the first earphone.
  • low-power Bluetooth connections are based on the GATT (Generic Attribute Profile) protocol.
  • GATT is a general specification for sending and receiving short data segments over a Bluetooth connection. These data segments are called attributes.
  • Electronic devices obtain these attribute information by sending service queries to the headset.
  • Figure 4 it is a schematic diagram of a service in the embodiment of the present application.
  • a service includes multiple characteristics, and a characteristic can include multiple attributes.
  • the electronic device can initiate a service query based on the service identifier to obtain the corresponding query result.
  • a preset service is set in the first earphone, and a specific field is set in the preset service for storing the Bluetooth address of the second earphone.
  • the electronic device can obtain the Bluetooth address, that is, the first address information, by initiating a service query to the first earphone.
  • the Bluetooth address of the second headset in the default service is set when the Bluetooth headset leaves the factory, or it can be set after the two headsets are paired for the first time.
  • the method when the first audio device receives the first service query initiated by the electronic device, before the step of sending the query result of the first service query to the electronic device, the method further includes: the first audio device Determine the service identification sequence, where the service identification of the preset service is located at the first position of the service identification sequence; send the service identification sequence to the electronic device, and the service identification sequence is used to instruct the electronic device to initiate a first service query according to the service identification sequence.
  • For the electronic device receive the service identification sequence sent by the first audio device; initiate a first service query to the first audio device according to the query sequence indicated by the service identification sequence; when receiving the first service query from the first audio device When the query result is returned, the first address information is read from the query result.
  • the electronic device After receiving the service identification sequence, the electronic device initiates a first service query to the first earphone according to the query sequence indicated by the service identification sequence.
  • the electronic device Read the first address information from the query result.
  • the first service query here refers to a query for a preset service, that is, a service query initiated based on the service identifier of the preset service.
  • the electronic device may sequentially send multiple service query instructions to the first earphone according to the query sequence indicated by the service identification sequence, so as to obtain the information of the service corresponding to each service identification respectively.
  • the first earphone after establishing a connection with the electronic device, can first send the service identifier of the preset service to the electronic device, and the electronic device queries the preset service based on the service identifier to obtain it as soon as possible. Address information to the second headset. After completing the service query of the preset service, you can query other services.
  • a connection request is initiated to the device sending the broadcast signal to communicate with the first address
  • the second earphone corresponding to the information establishes a second link connection.
  • the second earphone After the second earphone is started, it will send a broadcast signal.
  • the second earphone After the second earphone is started, it sends a LE-Audio broadcast.
  • the LE-Audio broadcast signal carries the first address information of the second earphone.
  • An embodiment of the present application also provides a method for connecting audio equipment, which is applied to electronic equipment.
  • the method includes:
  • the step of initiating a first service query for a preset service to the first audio device is performed according to the query sequence indicated by the service identification sequence.
  • the method further includes:
  • the method further includes:
  • FIG. 6 is another schematic flowchart of an audio device connection method provided by an embodiment of the present application. The method includes:
  • This embodiment is applied to electronic equipment. Please refer to the above embodiments for the specific implementation of each step, which will not be described again here.
  • the method before initiating a first service query for the preset service to the first audio device and obtaining the first address information in the query result of the preset service, the method further includes: receiving a message sent by the first audio device. the service identification sequence; and, according to the query sequence indicated by the service identification sequence, perform the step of initiating a first service query for the preset service to the first audio device.
  • the method further includes:
  • the method further includes:
  • FIG. 7 is a schematic diagram of a scenario of a connection method for audio equipment provided by an embodiment of the present application. It can be seen that compared with the existing technology solution, after the electronic device establishes the underlying LE link connection with the first earphone and before establishing the LE-Audio connection, the electronic device can obtain the Bluetooth address of the second earphone and send it to the second earphone. Initiating an LE connection does not require waiting for all services to be queried.
  • the electronic device After establishing an LE connection with the second earphone, the electronic device initiates a second service query to the second earphone in the same manner, and after completing all second service queries, establishes a LE-Audio connection with the second earphone, here
  • the LE-Audio connection between the first earphone and the electronic device is recorded as the first protocol connection
  • the LE-Audio connection between the second earphone and the electronic device is recorded as the second protocol connection.
  • the entire connection process between the electronic device and the two headphones is completed.
  • the second earphone since the first earphone has established a Bluetooth connection with the electronic device, the second earphone no longer needs to send the Bluetooth address of the first earphone to the electronic device through the preset service. Of course, it can also send . For another example, whoever establishes a connection with the electronic device first, the first earphone or the second earphone, first sends the Bluetooth address of the other earphone to the electronic device through a preset service, and then the earphone that establishes the connection with the electronic device does not need to be used. Then send the Bluetooth address of another headset to the electronic device through the preset service method, and of course you can continue to send it.
  • the two audio devices After two audio devices are started, they pair with each other, and one audio device obtains the Bluetooth address of the other audio device and writes the obtained Bluetooth address into the preset service.
  • the two wireless audio devices After the two wireless audio devices are started, they both send broadcast signals.
  • the user establishes an LE connection with the first audio device by manually selecting the device on the electronic device.
  • the electronic device initiates a query for the preset service to the first audio device to obtain the second audio included in the preset service.
  • Bluetooth address information of the device and when a broadcast signal carrying the first address information, such as an LE-Audio broadcast, is scanned, the connection request is initiated to the device sending the broadcast signal to establish an LE connection with the second audio device.
  • the electronic device establishes a LE-Audio connection with the first audio device after completing all service inquiries for the first audio device, and establishes a LE-Audio connection with the second audio device after completing all service inquiries for the second audio device. connect.
  • the electronic device does not need to wait to establish a protocol connection with the first audio device, but can initiate a connection to the second audio device after completing the underlying link connection.
  • the connection solution in significantly improves the connection speed when electronic devices and wireless audio devices are connected for the first time.
  • An embodiment of the present application also provides a method for connecting an audio device, which is applied to the first audio device.
  • the method includes:
  • the first audio device establishes a first link connection with the electronic device
  • the query result corresponding to the preset service is sent to the electronic device, so that the electronic device A second link connection is established with the second audio device based on the first address information, wherein the query result carries the first address information of the second audio device.
  • the above methods before the step of sending the query result of the first service query to the electronic device when the first audio device receives the first service query initiated by the electronic device, the above methods also include:
  • the first audio device determines a service identification sequence, wherein the service identification of the preset service is located at the first position of the service identification sequence;
  • the service identification sequence is sent to the electronic device, and the service identification sequence is used to instruct the electronic device to initiate the first service query according to the service identification sequence.
  • the above methods before the step of sending the query result of the first service query to the electronic device when the first audio device receives the first service query initiated by the electronic device, the above methods also include:
  • the service identifier is used to instruct the electronic device to initiate a first service query for the preset service.
  • the method before the first audio device establishes a first link connection with the electronic device, the method further includes:
  • the device connection record When the device connection record is empty, the first address information of the second audio device is obtained, and the first address information of the second audio device is written into the preset service of the first audio device.
  • FIG. 8 is a schematic flowchart of another method of connecting an audio device provided by an embodiment of the present application. The method is applied to the first audio device, and the method includes:
  • the first audio device establishes a first link connection with the electronic device
  • the first audio device When the first audio device receives the first service query for the preset service initiated by the electronic device, send the query result corresponding to the preset service to the electronic device, so that the electronic device communicates with the second based on the first address information.
  • the audio device establishes a second link connection, where the query result carries the first address information of the second audio device.
  • the method when the first audio device receives the first service query initiated by the electronic device, before sending the query result of the first service query to the electronic device, the method further includes: the first audio device determines the service identifier. sequence, wherein the service identifier of the preset service is located at the first position in the service identifier sequence; the service identifier sequence is sent to the electronic device, and the service identifier sequence is used to instruct the electronic device to initiate a first service query according to the service identifier sequence.
  • the method when the first audio device receives the first service query initiated by the electronic device, before sending the query result of the first service query to the electronic device, the method further includes: obtaining the service identifier of the preset service , and sends the service identifier to the electronic device, where the service identifier is used to instruct the electronic device to initiate a first service query for the preset service.
  • the electronic device does not need to wait to establish a protocol connection with the first audio device, but can initiate a connection to the second audio device after completing the underlying link connection.
  • the connection solution in significantly improves the connection speed when electronic devices and wireless audio devices are connected for the first time.
  • connection device 400 of the audio device is applied to a wireless audio device.
  • the wireless audio device includes a first audio device and a second audio device.
  • the connection device 400 of the audio device includes a first connection module 401 located on the first audio device and The first sending module 402, and the second connection module 403 located in the second audio device.
  • the first connection module 401 is used to establish a first link connection with the electronic device
  • the first sending module 402 is configured to send the query result corresponding to the preset service to the electronic device upon receiving the first service query for the preset service initiated by the electronic device.
  • the result carries the first address information of the second audio device;
  • the second connection module 403 is configured to establish a second link connection between the second audio device and the electronic device based on the first address information.
  • the first sending module 402 is further configured to: determine a service identification sequence, wherein the service identification of the preset service is located at the first position of the service identification sequence; send the service identification sequence to the For the electronic device, the service identification sequence is used to instruct the electronic device to initiate the first service query according to the service identification sequence.
  • the first sending module 402 is further configured to: obtain a service identifier of the preset service, and send the service identifier to the electronic device, where the service identifier is used to instruct the electronic device to initiate A first service query for the preset service.
  • the device further includes:
  • An acquisition module configured to establish a pairing connection with the second audio device after the first audio device is started; obtain a device connection record; and, when the device connection record is empty, obtain the second audio device's first address information, and writing the first address information of the second audio device into the preset service of the first audio device.
  • the first link connection and the second link connection are BLE link connections.
  • the audio equipment connection device provided in the embodiment of the present application belongs to the same concept as the audio equipment connection method in the above embodiment.
  • the audio equipment connection method provided in the embodiment can be realized.
  • the electronic device does not need to wait to establish a protocol connection with the first audio device, but can initiate a connection to the second audio device after completing the underlying link connection.
  • connection solutions in the technology that significantly improve the connection speed when electronic devices and wireless audio devices are connected for the first time.
  • An embodiment of the present application also provides a connection device for audio equipment, which is applied to electronic equipment. Please refer to FIG. 10 , which is another schematic structural diagram of a connection device for audio equipment provided by an embodiment of the present application.
  • the device 500 includes:
  • the third connection module 501 is used to establish a first link connection with the first audio device
  • Query module 502 configured to initiate a first service query for a preset service to the first audio device, and obtain the first address information in the query result of the preset service;
  • the third connection module 501 is also configured to: when a broadcast signal carrying the first address information is scanned, establish a second link connection with the device that sends the broadcast signal.
  • the query module 502 is further configured to: receive a service identification sequence sent by the first audio device; and, in accordance with the query sequence indicated by the service identification sequence, initiate a preset request to the first audio device. Set the first service query step of the service.
  • the third connection module 501 is also configured to: after completing the service query for the first audio device, establish a first protocol connection with the first audio device; The second audio device initiates a second service query, and establishes a second protocol connection with the second audio device after the second service query is completed.
  • the electronic device does not need to wait to establish a protocol connection with the first audio device, but can initiate a connection to the second audio device after completing the underlying link connection.
  • connection solutions in the technology that significantly improve the connection speed when electronic devices and wireless audio devices are connected for the first time.
  • connection device 600 of the audio equipment includes:
  • the fourth connection module 601 is used to establish a first link connection with the electronic device
  • the second connection module 602 is configured to, upon receiving a first service query for a preset service initiated by the electronic device, send the query result corresponding to the preset service to the electronic device, so that the The electronic device establishes a second link connection with the second audio device based on the first address information, wherein the query result carries the first address information of the second audio device.
  • An embodiment of the present application also provides an electronic device.
  • the electronic device may be a smart phone, tablet computer or other devices.
  • FIG. 12 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • Electronic device 700 includes processor 701, memory 702, and wireless transceiver 703. Among them, the processor 701 is electrically connected to the memory 702 and the wireless transceiver 703.
  • the processor 701 is the control center of the electronic device 700. It uses various interfaces and lines to connect various parts of the entire electronic device, and executes electronic tasks by running or calling computer programs stored in the memory 702 and calling data stored in the memory 702. The various functions of the device and process data to provide overall monitoring of the electronic device.
  • Memory 702 may be used to store computer programs and data.
  • the computer program stored in memory 702 contains instructions that can be executed in the processor.
  • Computer programs can be composed of various functional modules.
  • the processor 701 executes various functional applications and data processing by calling the computer program stored in the memory 702 .
  • the wireless transceiver 703 can be used to send and receive wireless signals, and the electronic device 700 establishes a wireless connection with the wireless audio device through the wireless transceiver 703 .
  • the wireless transceiver can be a Bluetooth module, such as a low-power Bluetooth module.
  • the processor 701 in the electronic device 700 loads instructions corresponding to the processes of one or more computer programs into the memory 702, and the processor 701 runs the computer program stored in the memory 702.
  • the electronic device 700 performs the following steps:
  • FIG. 13 is another schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • the electronic device 700 also includes: a radio frequency circuit 704, a display screen 705, a control circuit 708, an input unit 708, an audio circuit 708, a sensor 709, and a power supply 710.
  • the processor 701 is electrically connected to the radio frequency circuit 704, the display screen 705, the control circuit 706, the input unit 708, the audio circuit 708, the sensor 709 and the power supply 710 respectively.
  • the radio frequency circuit 704 is used to transmit and receive radio frequency signals to communicate with network equipment or other electronic equipment through wireless communication.
  • the display screen 705 can be used to display information input by the user or information provided to the user as well as various graphical user interfaces of the electronic device. These graphical user interfaces can be composed of images, text, icons, videos, and any combination thereof.
  • the control circuit 706 is electrically connected to the display screen 705 and is used to control the display screen 705 to display information.
  • the input unit 708 may be used to receive inputted numbers, character information, or user characteristic information (such as fingerprints), and to generate keyboard, mouse, joystick, optical, or trackball signal inputs related to user settings and function control.
  • the input unit 708 may include a fingerprint recognition module.
  • the audio circuit 708 can provide an audio interface between the user and the electronic device through speakers and microphones.
  • the audio circuit 708 includes a microphone.
  • the microphone is electrically connected to the processor 701 .
  • the microphone is used to receive voice information input by the user.
  • the Sensor 709 is used to collect external environment information.
  • the sensor 709 may include one or more sensors such as an ambient brightness sensor, an acceleration sensor, and a gyroscope.
  • the power supply 710 is used to power various components of the electronic device 700 .
  • the power supply 710 can be logically connected to the processor 701 through a power management system, so that functions such as charging, discharging, and power consumption management can be implemented through the power management system.
  • the electronic device 700 may also include a camera, etc., which will not be described again here.
  • the processor 701 in the electronic device 700 loads instructions corresponding to the processes of one or more computer programs into the memory 702, and the processor 701 runs the computer program stored in the memory 702.
  • the electronic device 700 performs the following steps:
  • the first audio device establishes a first link connection with the electronic device
  • the query result corresponding to the preset service is sent to the electronic device.
  • the query result Carrying the first address information of the second audio device;
  • the second audio device Based on the first address information, the second audio device establishes a second link connection with the electronic device.
  • Embodiments of the present application also provide a wireless audio device.
  • the wireless audio device may be a Bluetooth earphone in a pair of Bluetooth earphones, or may be a speaker on one side of a Bluetooth speaker, etc.
  • the wireless audio device includes a processor, a memory, and a wireless transceiver.
  • the memory stores a computer program. The feature is that the processor causes the wireless audio device to execute:
  • the query result corresponding to the preset service is sent to the electronic device, so that the electronic device is based on the first address information and
  • the second audio device establishes a second link connection, wherein the query result carries the first address information of the second audio device.
  • the second audio device in this solution can form a pair of wireless audio devices with the wireless audio device.
  • Embodiments of the present application also provide a computer-readable storage medium.
  • a computer program is stored in the computer-readable storage medium.
  • the computer program executes the steps described in any of the above embodiments. How to connect audio equipment.
  • the computer-readable storage medium may include but is not limited to: read-only memory (ROM, Read Only Memory), random access memory (RAM, Random Access Memory), magnetic disks or optical disks, etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Physics & Mathematics (AREA)
  • Acoustics & Sound (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Communication Control (AREA)

Abstract

本申请实施例公开了一种音频设备的连接方法、装置、存储介质及设备,其中,第一音频设备与电子设备建立第一链路连接;在第一音频设备接收到电子设备发起的对预设服务的第一服务查询的情况下,将预设服务对应的查询结果发送至电子设备,查询结果中携带有第二音频设备的第一地址信息;基于第一地址信息,第二音频设备与电子设备建立第二链路连接。采用本申请实施例,电子设备无需等到与第一音频设备建立协议连接,而是在完成底层的链路连接后,即可发起对第二音频设备的连接,相对于现有技术中的连接方案,显著提高了电子设备与无线音频设备首次连接时的连接速度。

Description

音频设备的连接方法、装置、存储介质及设备
本申请要求于2022年06月30日提交中国专利局、申请号为202210770869.9、申请名称为“音频设备的连接方法、装置、存储介质及设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及无线设备技术领域,具体涉及一种音频设备的连接方法、装置、存储介质及设备。
背景技术
随着蓝牙(Bluetooth,BT)等短距离无线技术的发展,支持无线连接的无线设备种类也日益增多。例如TWS(True Wireless Stereo,真无线立体声)耳机,TWS耳机的左右两只耳机相互独立、无需线缆相连,即可实现左右声道的无线分离。越来越多的用户为自己的智能手机、平板电脑、笔记本电脑等电子设备配备蓝牙耳机来播放音频。
低功耗音频(Low Energy Audio,LE-Audio)是蓝牙协议的一项新的音频传输技术,越来越多的蓝牙设备支持低功耗音频传输技术。
发明内容
本申请实施例提供一种音频设备的连接方法、装置、存储介质及设备,能够提高电子设备与无线音频设备首次连接时的连接速度。
第一方面,本申请实施例提供一种音频设备的连接方法,应用于无线音频设备,所述无线音频设备包括第一音频设备和第二音频设备;所述方法包括:
所述第一音频设备与电子设备建立第一链路连接;
在所述第一音频设备接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
第二方面,本申请实施例还提供一种音频设备的连接装置,应用于无线音频设备,所述无线音频设备包括第一音频设备和第二音频设备,所述装置包括位于所述第一音频设备的第一连接模块和第一发送模块,以及位于所述第二音频设备的第二连接模块,其中:
第一连接模块,用于与电子设备建立第一链路连接;
第一发送模块,用于在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
第二连接模块,用于基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
第三方面,本申请实施例提供一种音频设备的连接方法,应用于无线音频设备,该方法包括:
与第一音频设备建立第一链路连接;
向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
第四方面,本申请实施例还提供一种音频设备的连接装置,应用于电子设备,所述装置包括:
第三连接模块,用于与无线音频设备的第一音频设备建立第一链路连接;
查询模块,用于向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
所述第三连接模块还用于:在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
第五方面,本申请实施例提供一种音频设备的连接方法,应用于第一音频设备,所述方法包括:
所述第一音频设备与电子设备建立第一链路连接;
在所述第一音频设备接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,使得所述电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,所述查询结果中携带有所述第二音频设备的所述第一地址信息。
第六方面,应用于第一音频设备,所述装置包括:
第四连接模块,用于与电子设备建立第一链路连接;
第二连接模块,用于在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,使得所述电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,所述查询结果中携带有所述第二音频设备的所述第一地址信息。
第七方面,本申请实施例还提供一种计算机可读存储介质,其上存储有计算机程序,当所述计算机程序在计算机上运行时,使得所述计算机执行如本申请任一实施例提供的音频设备的连接方法。
第八方面,本申请实施例还提供一种电子设备,包括处理器、存储器和无线收发器,所述存储器有计算机程序,所述处理器通过调用所述计算机程序,用于使得电子设备执行如本申请任一实施例提供的应用于电子设备的音频设备的连接方法。
第九方面,本申请实施例还提供一种无线音频设备,包括处理器、存储器和无线收发器,所述存储器存储有计算机程序,其特征在于,所述处理器通过调用所述计算机程序,用于使得无线音频设备执行如本申请任一实施例提供的应用于无线音频设备的音频设备的连接方法。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为相关技术中TWS蓝牙耳机与手机之间首次连接时的连接流程。
图2为相关技术中LE Audio广播中可解析专用地址的结构信息。
图3为本申请实施例提供的音频设备的连接方法的一种流程示意图。
图4为本申请实施例中的一个服务的示意图。
图5为本申请实施例中服务查询的示意图。
图6为本申请实施例提供的音频设备的连接方法的另一种流程示意图。
图7为本申请实施例提供的音频设备的连接方法的应用场景示意图。
图8为本申请实施例提供的音频设备的连接方法的又一种流程示意图。
图9为本申请实施例提供的音频设备的连接装置的一种结构示意图。
图10为本申请实施例提供的音频设备的连接装置的另一种结构示意图。
图11为本申请实施例提供的音频设备的连接装置的又一种结构示意图。
图12为本申请实施例提供的电子设备的一种结构示意图。
图13为本申请实施例提供的电子设备的另一种结构示意图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述。显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域技术人员在没有付出创造性劳动前提下所获得的所有其他实施例,都属于本申请的保护范围。
在本文中提及“实施例”意味着,结合实施例描述的特定特征、结构或特性可以包含在本申请的至少一个实施例中。在说明书中的各个位置出现该短语并不一定均是指相同的实施例,也不是与其它实施例互斥的独立的或备选的实施例。本领域技术人员显式地和隐式地理解的是,本文所描述的实施例可以与其它实施例相结合。
本申请实施例提供一种音频设备的连接方法,应用于无线音频设备,所述无线音频设备包括第一音频设备和第二音频设备;所述方法包括:
所述第一音频设备与电子设备建立第一链路连接;
在所述第一音频设备接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
在一些实施例中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
所述第一音频设备确定服务标识序列,其中,所述预设服务的服务标识位于所述服务标识序列的第一位;
将所述服务标识序列发送至所述电子设备,所述服务标识序列用于指示所述电子设备按照所述服务标识序列发起所述第一服务查询。
在一些实施例中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
获取所述预设服务的服务标识,并将所述服务标识发送至所述电子设备,所述服务标识用于指示所述电子设备发起对所述预设服务的第一服务查询。
在一些实施例中,所述第一音频设备与电子设备建立第一链路连接之前,所述方法还包括:
在所述第一音频设备启动后,建立与第二音频设备的配对连接;
获取设备连接记录;
当所述设备连接记录为空时,获取所述第二音频设备的第一地址信息,并将所述第二音频设备的第一地址信息写入所述第一音频设备的预设服务中。
在一些实施例中,所述基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接包括:
所述第二音频设备发送广播信号,所述广播信号中包含所述第一地址信息,所述广播信号用于使得电子设备基于所述第一地址信息向所述第二音频设备发起连接请求;所述第二音频设备响应于所述连接请求与所述电子设备建立所述第二链路连接。
在一些实施例中,所述方法还包括:
所述第一音频设备与所述电子设备基于所述第一链路连接建立第一LE AUDIO连接;
所述第二音频设备与所述电子设备基于所述第二链路连接建立第二LE AUDIO连接。
在一些实施例中,应用于无线音频设备,所述无线音频设备包括第一音频设备和第二音频设备,所述装置包括位于所述第一音频设备的第一连接模块和第一发送模块,以及位于所述第二音频设备的第二连接模块,其中:
第一连接模块,用于与电子设备建立第一链路连接;
第一发送模块,用于在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
第二连接模块,用于基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
在相关技术中,支持低功耗音频传输的TWS蓝牙耳机在使用时,其左右两个耳机需要分别与电子设备建立LE-Audio连接,如图1所示,图1为相关技术中TWS蓝牙耳机与手机之间首次连接时的连接流程,在耳机1和耳机2完成配对会后,两个耳机均打开LE Audio广播,手机也会打开蓝牙连接,对广播信号进行扫描,并与一个耳机建立LE Audio连接,之后,再对另一个耳机的广播进行解析,以判断该耳机与当前已经连接的耳机是否属于相同协调集,即根据已连接的耳机的SIRK(Set Identity Resolving Key,组合标识解析值)与另一个耳机的广播信息里的特定字段计算出一个哈希值,并判断计算出的哈希值是否与广播里的哈希值一致,如图2所示,图2为相关技术中LE Audio广播中可解析专用地址的结构信息,其中,该地址中的高位24bits是随机数部分(prand),其中最高两个bits为“10”,低位24bits是随机数和IRK经过hash运算得到的hash值,运算的公式为hash=ah(IRK,prand)。如果一致,则与第二个耳机建立连接,这种连接方案需要电子设备等到与第一音频设备建立协议连接后,才去根据第二音频设备的广播进行哈希值的校验和连接,存在连接速度慢的技术问题。
为了解决这一技术问题,本申请实施例提供一种音频设备的连接方法,应用于无线音频设备。例如,该无线音频设备可以是蓝牙耳机,或者支持蓝牙协议的其他类型的音频播放设备,例如蓝牙音箱等。该无线音频设备包括第一音频设备和第二音频设备,以无线音频设备为蓝牙耳机为例,该蓝牙耳机包括第一耳机和第二耳机,用户在使用第一耳机和第二耳机时,第一耳机和第二耳机之间需要先配对连接。
请参阅图3,图3为本申请实施例提供的音频设备的连接方法的一种流程示意图。本申请实施例提供的音频设备的连接方法的具体流程可以如下:
101、第一音频设备与电子设备建立第一链路连接。
下文中以无线音频设备为蓝牙耳机,第一音频设备为第一耳机,第二音频设备为第二耳机为例,对本申请实施例的方案进行详细说明。
其中,本申请实施例中的第一耳机和第二耳机启动之后,可以进行两个耳机之间的相互配对连接,也可以不进行两个耳机之间的相互配对连接。
在一实施例中,两个耳机之间不进行相互配对连接,在耳机启动之后,两个耳机分别与耳机盒建立连接(可以是有线连接,例如触点连接;也可以是无线连接,例如蓝牙连接),并通过该耳机盒将各自的蓝牙地址发送给对方;或者,在两个耳机第一次与耳机盒建立连接后,各自将蓝牙地址发送至耳机盒,用户在启动耳机后,耳机盒可以自动地或者响应于用户的控制操作将一耳机的蓝牙地址发送给另一耳机,使得两个耳机中的每一耳机都获取到另一耳机的蓝牙地址;或者, 在耳机出厂之前,设置将一对耳机中的一个耳机的地址存储在另一个耳机中,例如,设置两个耳机的预设服务对应的查询结果中包括另一个耳机的蓝牙地址。
例如,该蓝牙耳机可以通过容置该蓝牙耳机的耳机盒控制耳机的启动,耳机盒包括盒体,以及与盒体活动连接的盒盖。耳机盒还设置有盖传感器,该盖传感器盖被配置为当盒盖从闭合状态切换为打开状态时生成开盖信号,耳机盒将该开盖信号发送给蓝牙耳机。对于蓝牙耳机来说,可以通过检测开盖信号来检测耳机盒的开盖操作。也就是说,当蓝牙耳机接收到耳机盒发送的开盖信号时,判定耳机盒进行了开盖操作。该实施例中,通过开盖操作触发蓝牙耳机的启动,其中,第一耳机中设置有第一无线连接模块,如低功耗蓝牙模块;第二耳机中设置有第二无线连接模块。
又例如,还可以通过控制操作控制两个耳机的启动,例如,两个耳机上分别设置有控制按键,或者在特定区域设置有触控传感器,用户通过按压或者触控等操作控制两个耳机的开启。
在另一实施例中,两个耳机启动后,进行两个耳机之间的相互配对连接,建立连接后,两个耳机各自将本机的蓝牙地址发送至另一耳机。
在另一实施例中,在两个耳机启动之后,进行两个耳机之间的相互配对连接,在建立连接后,两个耳机之间通过广播信号确定出一个耳机作为主耳机,另一个耳机作为从耳机,主耳机获取从耳机的蓝牙地址进行存储。
其中,需要说明的是,本申请实施例中的“第一音频设备”和“第二音频设备”中的“第一”和“第二”仅用于区分两个耳机,例如,在先与电子设备建立连接的无线音频设备为第一音频设备,在后与电子设备建立连接的无线音频设备为第二音频设备。
接下来对LE-Audio连接的流程进行简单说明。以一个蓝牙耳机(无线音频设备)与手机(电子设备)进行LE-Audio连接为例,该蓝牙耳机开启蓝牙低功耗(Bluetooth Low Energy Audio,BLE)广播,手机开启蓝牙后进行BLE扫描,当扫描到该耳机后,可以与该蓝牙耳机建立底层BLE链路的连接,该连接建立后,电子设备并不能直接对耳机进行控制,还需要进行后续的服务查询,其中,服务查询的目的是为了获取对端设备支持的服务(service)以及对应属性的功能,方便后续的连接以及使用。在手机和蓝牙耳机完成各自的服务查询后,手机发起与蓝牙耳机之间的LE-Audio协议的连接,至此才完成两个设备之间的LE-Audio连接,之后手机才可以对耳机进行控制操作,以及向耳机传输音频数据等。
对于第一耳机来说,在完成第一耳机和第二耳机的配对后,进行LE-Audio广播,即发送无线广播信号。电子设备开启蓝牙,进行BLE扫描。当电子设备扫描到第一耳机的LE-Audio广播后,会在用户界面显示第一耳机的信息,用户可以在用户界面点击该信息,以与第一耳机建立LE底层链路的连接,即LE连接,下文中为了区分两个耳机与电子设备之间的LE连接,将第一耳机与电子设备之间的LE连接记为第一链路连接,将第二耳机与电子设备之间的LE连接记为第二链路连接。
102、在第一音频设备接收到电子设备发起的对预设服务的第一服务查询的情况下,将预设服务对应的查询结果发送至电子设备,查询结果中携带有第二音频设备的第一地址信息。
对于电子设备来说,在与第一耳机成功建立第一链路连接后,向第一耳机发起服务查询。其中,低功耗蓝牙连接都是建立在GATT(Generic Attribute Profile,通用属性配置文件)协议之上。GATT是一个在蓝牙连接之上的发送和接收很短的数据段的通用规范,这些数据段被称为属性,电子设备通过向耳机发送服务查询获取这些属性信息。如图4所示,为本申请实施例中的一个服务的示意图。GATT中一个服务(service)包括多个特性(characteristic),一个特性可以包含多个属性(attribute)。
需要说明的是,第一耳机支持的服务可能有多个,包括但不限于以下几种:耳机是否支持媒 体播放功能;耳机是否支持通话功能;耳机是否支持控制操作;耳机具体支持哪些控制操作,等等。对于每一种服务,电子设备向第一耳机发送服务查询指令,第一耳机接收到该服务查询指令后,向电子设备返回其支持的服务的信息。对于第一耳机来说,其支持的服务有多个,对于每一个服务都设置有对应的服务标识,例如,service ID。
如图5所示,电子设备可以基于服务标识发起服务查询,以得到对应的查询结果。其中,在第一耳机中设置一个预设服务,该预设服务中设置有特定字段用于存储第二耳机的蓝牙地址。电子设备通过向第一耳机发起服务查询可以获取到该蓝牙地址,即第一地址信息。
其中,预设服务中的第二耳机的蓝牙地址是在蓝牙耳机出厂时设置,也是可以是在两个耳机首次配对完成后设置。
例如,在一实施例中,该方法还包括:在第一音频设备启动后,建立与第二音频设备的配对连接;获取设备连接记录;当设备连接记录为空时,获取第二音频设备的第一地址信息,并将第二音频设备的第一地址信息写入第一音频设备的预设服务中。
对于第一耳机来说,如果与电子设备之间成功地建立了蓝牙连接,则会将该电子设备的蓝牙地址存储在设备连接记录中,方便下次回连同一电子设备。第一耳机在启动后,先获取设备连接记录,如果设备连接记录为空,则可以判定本次连接为首次连接或者连接记录被清除,对预设服务进行配置。具体地,在完成与第二耳机的配对后,获取到第二耳机的蓝牙地址,将该蓝牙地址写入到预设服务的预设字段,以完成预设服务的配置。反之,如果设备连接记录不为空,可以判定本次连接不是首次连接,而是回连,则只需进行LE-Audio广播的发送即可,电子设备的历史连接设备记录中有该耳机连接记录的情况下,在扫描到该LE-Audio广播后,可以直接与耳机进行回连。
其中,在蓝牙耳机出厂时,该预设服务的该特定字段可以为空,在蓝牙耳机首次配对完成后,将获取的第二耳机的蓝牙地址写入到该特定字段,以完成预设服务的配置。此外,该预设服务中的蓝牙地址是可以修改的,例如,如果用户的第二耳机丢失并更换了新的第二耳机,此时第二耳机的蓝牙地址发生变更,用户可以将第一耳机中的设备连接记录进行清空,然后将新的第二耳机与原第一耳机进行重新配对,在配对完成后,第一耳机会获取新的第二耳机的蓝牙地址,并使用该新的蓝牙地址替换预设服务中旧的蓝牙地址。
此外,对于第一耳机来说,在与电子设备建立第一链路连接后,可以将支持的服务的服务标识发送给电子设备,电子设备可以基于这些服务标识进行服务查询。
例如,在一实施例中,当第一音频设备接收到电子设备发起的第一服务查询时,将第一服务查询的查询结果发送至电子设备的步骤之前,该方法还包括:第一音频设备确定服务标识序列,其中,预设服务的服务标识位于服务标识序列的第一位;将服务标识序列发送至电子设备,服务标识序列用于指示电子设备按照服务标识序列发起第一服务查询。
对于第一耳机来说,当服务标识有多个时,可以将多个服务标识按照特定的顺序排列得到服务标识序列,该服务标识序列指示了电子设备对多个服务进行查询的顺序。为了进一步提高电子设备获取第二耳机的蓝牙地址的速度,可以将预设服务的服务标识是指在服务标识序列的第一位。或者,在其他实施例中,预设服务也可以位于服务标识序列中的任意位置。
对于电子设备来说,接收第一音频设备发送的服务标识序列;按照服务标识序列指示的查询顺序,向第一音频设备发起第一服务查询;当接收到第一音频设备响应于第一服务查询返回的查询结果时,从查询结果中读取第一地址信息。
电子设备接收到该服务标识序列后,根据该服务标识序列指示的查询顺序,向第一耳机发起第一服务查询,当接收到第一音频设备响应于第一服务查询返回的查询结果时,从查询结果中读 取第一地址信息。这里的第一服务查询指的是针对预设服务的查询,即基于预设服务的服务标识发起的服务查询。其中,电子设备可以按照服务标识序列指示的查询顺序,依次发送多个服务查询指令给第一耳机,以分别获取每一服务标识对应的服务的信息。
或者,在另一实施例中,第一耳机在与电子设备建立连接后,可以先将预设服务的服务标识发送给电子设备,电子设备基于该服务标识进行预设服务的查询,以尽快获取到第二耳机的地址信息。可以在完成预设服务的服务查询后,进行其他服务的查询。
103、基于第一地址信息,第二音频设备与电子设备建立第二链路连接。
对于电子设备来说,在通过服务查询获取到第一地址信息后,如果扫描到携带有该第一地址信息的广播信号,则向发送该广播信号的设备发起连接请求,以与该第一地址信息对应的第二耳机建立第二链路连接。其中,第二耳机在启动后,会进行广播信号的发送,例如,第二耳机在启动后,发送LE-Audio广播,该LE-Audio广播信号携带有第二耳机的第一地址信息,在接收到连接请求后,响应于该连接请求,与电子设备建立第二链路连接。
具体实施时,本申请不受所描述的各个步骤的执行顺序的限制,在不产生冲突的情况下,某些步骤还可以采用其它顺序进行或者同时进行,上述各实施例实施方式及其特征在不冲突的情况下,可以任意组合。
本申请实施例提供的音频设备的连接方法,电子设备无需等到与第一音频设备建立协议连接,而是在完成底层的链路连接后,即可发起对第二音频设备的连接,相对于现有技术中的连接方案,显著提高了电子设备与无线音频设备首次连接时的连接速度。
本申请实施例还提供一种音频设备的连接方法,应用于电子设备,所述方法包括:
与第一音频设备建立第一链路连接;
向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
在一些实施例中,所述向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息的步骤之前,所述方法还包括:
接收所述第一音频设备发送的服务标识序列;
按照所述服务标识序列指示的查询顺序,执行向所述第一音频设备发起对预设服务的第一服务查询的步骤。
在一些实施例中,所述方法还包括:
当完成对所述第一音频设备的服务查询后,与所述第一音频设备之间建立第一协议连接;
所述通过所述第一地址信息与所述第二音频设备建立第二链路连接之后,所述方法还包括:
向所述第二音频设备发起第二服务查询,并在所述第二服务查询完成后与所述第二音频设备建立第二协议连接。
本申请实施例还提供一种应用于电子设备的音频设备的连接方法。请参阅图6,图6为本申请实施例提供的音频设备的连接方法的另一种流程示意图。该方法包括:
201、与无线音频设备的第一音频设备建立第一链路连接。
202、向第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息。
203、在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
其中,该实施例应用于电子设备,各步骤的具体实施方式请参见上文实施例,在此不再赘述。
在一些实施例中,向第一音频设备发起对预设服务的第一服务查询,并获取预设服务的查询结果中的第一地址信息的步骤之前,方法还包括:接收第一音频设备发送的服务标识序列;以及,按照服务标识序列指示的查询顺序,执行向第一音频设备发起对预设服务的第一服务查询的步骤。
在一些实施例中,该方法还包括:
当完成对第一音频设备的服务查询后,与第一音频设备之间建立第一协议连接;
通过第一地址信息与第二音频设备建立第二链路连接之后,方法还包括:
向第二音频设备发起第二服务查询,并在第二服务查询完成后与第二音频设备建立第二协议连接。
如上文所述,除了预设服务之外,第一耳机还可能包括其他的服务,对于这些服务,电子设备也要进行查询。对于第一耳机发送的全部服务标识,电子设备均进行了服务查询之后,则判定完成了对一耳机的全部服务查询。之后,电子设备可以与第一耳机之间建立第一协议连接,即LE-Audio连接。或者,在其他实施例中,当电子设备完成了对第一耳机的服务查询后,第一耳机也可以发起对电子设备的服务查询,当双方都完成了服务查询后,则可以建立第一协议连接。请参阅图7,图7为本申请实施例提供的音频设备的连接方法的场景示意图。可以看出,相对于现有技术的方案,电子设备在与第一耳机建立底层的LE链路的连接之后、建立LE-Audio连接之前,即可获取第二耳机的蓝牙地址,向第二耳机发起LE连接,无需等到全部服务都查询完成。此外,电子设备在与第二耳机建立LE连接后,按照同样的方式向第二耳机发起第二服务查询,并在完成全部的第二服务查询后,与第二耳机建立LE-Audio连接,这里为了区分两个耳机不同的连接,将第一耳机与电子设备之间的LE-Audio连接记为第一协议连接,将第二耳机与电子设备之间的LE-Audio连接记为第二协议连接。至此,完成了电子设备与两个耳机之间的整个连接过程。
需要说明的,一些实施例中,由于第一耳机已经与电子设备建立了蓝牙连接,因此,第二耳机可以不用再通过预设服务将第一耳机的蓝牙地址发给电子设备,当然也可以发送。又例如,可以是第一耳机和第二耳机谁先与电子设备建立连接就先通过预设服务的方式将另一个耳机的蓝牙地址发送给电子设备,而后与电子设备建立连接的耳机则可以不用再通过预设服务方式发送另一个耳机的蓝牙地址给电子设备,当然也可以继续发送。
接下来,对电子设备与两个耳机之间首次建立的LE Audio连接的详细过程为例,对本申请实施例的方案进行说明。其中,以两个无线音频设备在启动后进行相互之间的配对连接的情形为例,在其他实施例中,也可以有不配对连接的情况,具体请参见上文。
例如,两个音频设备启动后,相互之间进行配对连接,并且一个音频设备获取另一个音频设备的蓝牙地址,并将获取的蓝牙地址写入到预设服务中。两个无线音频设备启动之后,都进行广播信号的发送。用户通过在电子设备上进行手动选择设备的方式与第一音频设备建立LE连接,然后,电子设备向第一音频设备发起对预设服务的查询以获取到该预设服务中包含的第二音频设备的蓝牙地址信息,并且在扫描到携带有该第一地址信息的广播信号,例如LE-Audio广播时,向发送广播信号的设备发起所述连接请求,以与第二音频设备建立LE连接。此外,电子设备在完成对第一音频设备的全部服务查询后,与第一音频设备建立LE-Audio连接,在完成对第二音频设备的全部服务查询后,与第二音频设备建立LE-Audio连接。
由上,采用该实施例的方法,电子设备无需等到与第一音频设备建立协议连接,而是在完成底层的链路连接后,即可发起对第二音频设备的连接,相对于现有技术中的连接方案,显著提高了电子设备与无线音频设备首次连接时的连接速度。
本申请实施例还提供一种音频设备的连接方法,应用于第一音频设备,所述方法包括:
所述第一音频设备与电子设备建立第一链路连接;
在所述第一音频设备接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,使得所述电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,所述查询结果中携带有所述第二音频设备的所述第一地址信息。
在一些实施例中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
所述第一音频设备确定服务标识序列,其中,所述预设服务的服务标识位于所述服务标识序列的第一位;
将所述服务标识序列发送至所述电子设备,所述服务标识序列用于指示所述电子设备按照所述服务标识序列发起所述第一服务查询。
在一些实施例中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
获取所述预设服务的服务标识,并将所述服务标识发送至所述电子设备,所述服务标识用于指示所述电子设备发起对所述预设服务的第一服务查询。
在一些实施例中,所述第一音频设备与电子设备建立第一链路连接之前,所述方法还包括:
在所述第一音频设备启动后,建立与第二音频设备的配对连接;
获取设备连接记录;
当所述设备连接记录为空时,获取所述第二音频设备的第一地址信息,并将所述第二音频设备的第一地址信息写入所述第一音频设备的预设服务中。
本申请实施例还提供一种音频设备的连接方法,请参阅图8,图8为本申请实施例提供的音频设备的连接方法的又一种流程示意图。该方法应用于第一音频设备,该方法包括:
301、第一音频设备与电子设备建立第一链路连接;
302、在第一音频设备接收到电子设备发起的对预设服务的第一服务查询的情况下,将预设服务对应的查询结果发送至电子设备,使得电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,查询结果中携带有第二音频设备的第一地址信息。
在一些实施例中,当第一音频设备接收到电子设备发起的第一服务查询时,将第一服务查询的查询结果发送至电子设备的步骤之前,方法还包括:第一音频设备确定服务标识序列,其中,预设服务的服务标识位于服务标识序列的第一位;将服务标识序列发送至电子设备,服务标识序列用于指示电子设备按照服务标识序列发起第一服务查询。
在一些实施例中,当第一音频设备接收到电子设备发起的第一服务查询时,将第一服务查询的查询结果发送至电子设备的步骤之前,方法还包括:获取预设服务的服务标识,并将服务标识发送至电子设备,服务标识用于指示电子设备发起对预设服务的第一服务查询。
在一些实施例中,第一音频设备与电子设备建立第一链路连接之前,方法还包括:在第一音频设备启动后,建立与第二音频设备的配对连接;获取设备连接记录;当设备连接记录为空时,获取第二音频设备的第一地址信息,并将第二音频设备的第一地址信息写入第一音频设备的预设服务中。
其中,上述各实施例的具体实施方式请参照上文实施例,在此不再赘述。
由上,采用该实施例的方法,电子设备无需等到与第一音频设备建立协议连接,而是在完成底层的链路连接后,即可发起对第二音频设备的连接,相对于现有技术中的连接方案,显著提高了电子设备与无线音频设备首次连接时的连接速度。
本申请实施例还提供一种音频设备的连接装置。请参阅图9,图9为本申请实施例提供的音 频设备的连接装置的一种结构示意图。其中该音频设备的连接装置400应用于无线音频设备,无线音频设备包括第一音频设备和第二音频设备,该音频设备的连接装置400包括位于所述第一音频设备的第一连接模块401和第一发送模块402,以及位于所述第二音频设备的第二连接模块403。
第一连接模块401,用于与电子设备建立第一链路连接;
第一发送模块402,用于在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
第二连接模块403,用于基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
在一些实施例中,第一发送模块402还用于:确定服务标识序列,其中,所述预设服务的服务标识位于所述服务标识序列的第一位;将所述服务标识序列发送至所述电子设备,所述服务标识序列用于指示所述电子设备按照所述服务标识序列发起所述第一服务查询。
在一些实施例中,第一发送模块402还用于:获取所述预设服务的服务标识,并将所述服务标识发送至所述电子设备,所述服务标识用于指示所述电子设备发起对所述预设服务的第一服务查询。
在一些实施例中,该装置还包括:
获取模块,用于在所述第一音频设备启动后,建立与第二音频设备的配对连接;获取设备连接记录;以及,当所述设备连接记录为空时,获取所述第二音频设备的第一地址信息,并将所述第二音频设备的第一地址信息写入所述第一音频设备的预设服务中。
在一些实施例中,所述第一链路连接和所述第二链路连为BLE链路连接。
应当说明的是,本申请实施例提供的音频设备的连接装置与上文实施例中的音频设备的连接方法属于同一构思,通过该音频设备的连接装置可以实现音频设备的连接方法实施例中提供的任一方法,其具体实现过程详见音频设备的连接方法实施例,此处不再赘述。
本申请实施例提出的音频设备的连接装置,电子设备无需等到与第一音频设备建立协议连接,而是在完成底层的链路连接后,即可发起对第二音频设备的连接,相对于现有技术中的连接方案,显著提高了电子设备与无线音频设备首次连接时的连接速度。
本申请实施例还提供一种音频设备的连接装置,应用于电子设备。请参阅图10,图10为本申请实施例提供的音频设备的连接装置的另一种结构示意图。该装置500包括:
第三连接模块501,用于与第一音频设备建立第一链路连接;
查询模块502,用于向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
第三连接模块501还用于:在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
在一些实施例中,查询模块502还用于:接收所述第一音频设备发送的服务标识序列;以及,按照所述服务标识序列指示的查询顺序,执行向所述第一音频设备发起对预设服务的第一服务查询的步骤。
在一些实施例中,第三连接模块501还用于:当完成对所述第一音频设备的服务查询后,与所述第一音频设备之间建立第一协议连接;以及,向所述第二音频设备发起第二服务查询,并在所述第二服务查询完成后与所述第二音频设备建立第二协议连接。
本申请实施例提出的音频设备的连接装置,电子设备无需等到与第一音频设备建立协议连接,而是在完成底层的链路连接后,即可发起对第二音频设备的连接,相对于现有技术中的连接方案, 显著提高了电子设备与无线音频设备首次连接时的连接速度。
本申请实施例还提供一种音频设备的连接装置,应用于第一音频设备。请参阅图11,图11为本申请实施例提供的音频设备的连接装置的又一种结构示意图。该音频设备的连接装置600包括:
第四连接模块601,用于与电子设备建立第一链路连接;
第二连接模块602,用于在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,使得所述电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,所述查询结果中携带有所述第二音频设备的所述第一地址信息。
本申请实施例还提供一种电子设备。所述电子设备可以是智能手机、平板电脑等设备。请参阅图12,图12为本申请实施例提供的电子设备的一种结构示意图。电子设备700包括处理器701、存储器702和无线收发器703。其中,处理器701与存储器702和无线收发器703电性连接。
处理器701是电子设备700的控制中心,利用各种接口和线路连接整个电子设备的各个部分,通过运行或调用存储在存储器702内的计算机程序,以及调用存储在存储器702内的数据,执行电子设备的各种功能和处理数据,从而对电子设备进行整体监控。
存储器702可用于存储计算机程序和数据。存储器702存储的计算机程序中包含有可在处理器中执行的指令。计算机程序可以组成各种功能模块。处理器701通过调用存储在存储器702的计算机程序,从而执行各种功能应用以及数据处理。
无线收发器703可用于发送和接收无线信号,电子设备700通过无线收发器703与无线音频设备之间建立无线连接。例如,无线收发器可以为蓝牙模块,如低功耗蓝牙模块等。
在本实施例中,电子设备700中的处理器701会将一个或一个以上的计算机程序的进程对应的指令加载到存储器702中,并由处理器701来运行存储在存储器702中的计算机程序,从而使得电子设备700执行如下步骤:
与第一音频设备建立第一链路连接;
向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
在一些实施例中,请参阅图13,图13为本申请实施例提供的电子设备的另一种结构示意图。电子设备700还包括:射频电路704、显示屏705、控制电路708、输入单元708、音频电路708、传感器709以及电源710。其中,处理器701分别与射频电路704、显示屏705、控制电路706、输入单元708、音频电路708、传感器709以及电源710电性连接。
射频电路704用于收发射频信号,以通过无线通信与网络设备或其他电子设备进行通信。
显示屏705可用于显示由用户输入的信息或提供给用户的信息以及电子设备的各种图形用户接口,这些图形用户接口可以由图像、文本、图标、视频和其任意组合来构成。
控制电路706与显示屏705电性连接,用于控制显示屏705显示信息。
输入单元708可用于接收输入的数字、字符信息或用户特征信息(例如指纹),以及产生与用户设置以及功能控制有关的键盘、鼠标、操作杆、光学或者轨迹球信号输入。其中,输入单元708可以包括指纹识别模组。
音频电路708可通过扬声器、传声器提供用户与电子设备之间的音频接口。其中,音频电路708包括麦克风。所述麦克风与所述处理器701电性连接。所述麦克风用于接收用户输入的语音 信息。
传感器709用于采集外部环境信息。传感器709可以包括环境亮度传感器、加速度传感器、陀螺仪等传感器中的一种或多种。
电源710用于给电子设备700的各个部件供电。在一些实施例中,电源710可以通过电源管理系统与处理器701逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。
虽然图中未示出,电子设备700还可以包括摄像头等,在此不再赘述。
在本实施例中,电子设备700中的处理器701会将一个或一个以上的计算机程序的进程对应的指令加载到存储器702中,并由处理器701来运行存储在存储器702中的计算机程序,从而使得电子设备700执行如下步骤:
与第一音频设备建立第一链路连接;
向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
由上可知,本申请实施例提供了一种电子设备,该电子设备无需等到与第一音频设备建立协议连接,而是在完成底层的链路连接后,即可发起对第二音频设备的连接,相对于现有技术中的连接方案,显著提高了电子设备与无线音频设备首次连接时的连接速度。
本申请实施例还提供一种无线音频设备,该无线音频设备包括第一音频设备和第二音频设备。例如,该无线音频设备可以是蓝牙耳机,或者支持蓝牙协议的其他类型的音频播放设备,例如蓝牙音箱等。以无线音频设备为蓝牙耳机为例,该蓝牙耳机包括第一耳机和第二耳机。该无线音频设备包括处理器、存储器和无线收发器,所述存储器存储有计算机程序,其特征在于,所述处理器通过调用所述计算机程序,使得无线音频设备执行:
所述第一音频设备与电子设备建立第一链路连接;
在所述第一音频设备接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
本申请实施例还提供一种无线音频设备,该无线音频设备可以是蓝牙耳机对中的一只蓝牙耳机,也可以是蓝牙音箱中的一侧音箱等。该无线音频设备包括处理器、存储器和无线收发器,所述存储器存储有计算机程序,其特征在于,所述处理器通过调用所述计算机程序,使得无线音频设备执行:
与电子设备建立第一链路连接;
在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,使得所述电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,所述查询结果中携带有所述第二音频设备的所述第一地址信息。
其中,该方案中的第二音频设备可以与该无线音频设备组成一对无线音频设备。
本申请实施例还提供一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机程序,当所述计算机程序在计算机上运行时,所述计算机执行上述任一实施例所述的音频设备的连接方法。
需要说明的是,本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是 可以通过计算机程序来指令相关的硬件来完成,所述计算机程序可以存储于计算机可读存储介质中,所述计算机可读存储介质可以包括但不限于:只读存储器(ROM,Read Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁盘或光盘等。
此外,本申请中的术语“第一”、“第二”和“第三”等是用于区别不同对象,而不是用于描述特定顺序。此外,术语“包括”和“具有”以及它们任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或模块的过程、方法、系统、产品或设备没有限定于已列出的步骤或模块,而是某些实施例还包括没有列出的步骤或模块,或某些实施例还包括对于这些过程、方法、产品或设备固有的其它步骤或模块。
以上对本申请实施例所提供的音频设备的连接方法、装置、存储介质及设备进行了详细介绍。本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。

Claims (20)

  1. 一种音频设备的连接方法,其中,应用于无线音频设备,所述无线音频设备包括第一音频设备和第二音频设备;所述方法包括:
    所述第一音频设备与电子设备建立第一链路连接;
    在所述第一音频设备接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
    基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
  2. 如权利要求1所述的方法,其中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
    所述第一音频设备确定服务标识序列,其中,所述预设服务的服务标识位于所述服务标识序列的第一位;
    将所述服务标识序列发送至所述电子设备,所述服务标识序列用于指示所述电子设备按照所述服务标识序列发起所述第一服务查询。
  3. 如权利要求1所述的方法,其中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
    获取所述预设服务的服务标识,并将所述服务标识发送至所述电子设备,所述服务标识用于指示所述电子设备发起对所述预设服务的第一服务查询。
  4. 如权利要求1所述的方法,其中,所述第一音频设备与电子设备建立第一链路连接之前,所述方法还包括:
    在所述第一音频设备启动后,建立与第二音频设备的配对连接;
    获取设备连接记录;
    当所述设备连接记录为空时,获取所述第二音频设备的第一地址信息,并将所述第二音频设备的第一地址信息写入所述第一音频设备的预设服务中。
  5. 如权利要求1所述的方法,其中,所述基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接包括:
    所述第二音频设备发送广播信号,所述广播信号中包含所述第一地址信息,所述广播信号用于使得电子设备基于所述第一地址信息向所述第二音频设备发起连接请求;所述第二音频设备响应于所述连接请求与所述电子设备建立所述第二链路连接。
  6. 如权利要求1至5任一项所述的方法,其中,所述方法还包括:
    所述第一音频设备与所述电子设备基于所述第一链路连接建立第一LE AUDIO连接;
    所述第二音频设备与所述电子设备基于所述第二链路连接建立第二LE AUDIO连接。
  7. 一种音频设备的连接装置,其中,应用于无线音频设备,所述无线音频设备包括第一音频设备和第二音频设备,所述装置包括位于所述第一音频设备的第一连接模块和第一发送模块,以及位于所述第二音频设备的第二连接模块,其中:
    第一连接模块,用于与电子设备建立第一链路连接;
    第一发送模块,用于在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,所述查询结果中携带有所述第二音频设备的第一地址信息;
    第二连接模块,用于基于所述第一地址信息,所述第二音频设备与所述电子设备建立第二链路连接。
  8. 一种音频设备的连接方法,其中,应用于电子设备,所述方法包括:
    与第一音频设备建立第一链路连接;
    向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
    在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
  9. 如权利要求8所述的方法,其中,所述向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息的步骤之前,所述方法还包括:
    接收所述第一音频设备发送的服务标识序列;
    按照所述服务标识序列指示的查询顺序,执行向所述第一音频设备发起对预设服务的第一服务查询的步骤。
  10. 如权利要求8所述的方法,其中,所述方法还包括:
    当完成对所述第一音频设备的服务查询后,与所述第一音频设备之间建立第一协议连接;
    所述通过所述第一地址信息与所述第二音频设备建立第二链路连接之后,所述方法还包括:
    向所述第二音频设备发起第二服务查询,并在所述第二服务查询完成后与所述第二音频设备建立第二协议连接。
  11. 一种音频设备的连接装置,其中,应用于电子设备,所述装置包括:
    第三连接模块,用于与第一音频设备建立第一链路连接;
    查询模块,用于向所述第一音频设备发起对预设服务的第一服务查询,并获取所述预设服务的查询结果中的第一地址信息;
    所述第三连接模块还用于:在扫描到携带有所述第一地址信息的广播信号的情况下,与发送所述广播信号的设备建立第二链路连接。
  12. 一种音频设备的连接方法,其中,应用于第一音频设备,所述方法包括:
    所述第一音频设备与电子设备建立第一链路连接;
    在所述第一音频设备接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,使得所述电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,所述查询结果中携带有所述第二音频设备的所述第一地址信息。
  13. 如权利要求12所述的连接方法,其中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
    所述第一音频设备确定服务标识序列,其中,所述预设服务的服务标识位于所述服务标识序列的第一位;
    将所述服务标识序列发送至所述电子设备,所述服务标识序列用于指示所述电子设备按照所述服务标识序列发起所述第一服务查询。
  14. 如权利要求12所述的连接方法,其中,所述当所述第一音频设备接收到所述电子设备发起的第一服务查询时,将所述第一服务查询的查询结果发送至所述电子设备的步骤之前,所述方法还包括:
    获取所述预设服务的服务标识,并将所述服务标识发送至所述电子设备,所述服务标识用于指示所述电子设备发起对所述预设服务的第一服务查询。
  15. 如权利要求12至14任一项所述的连接方法,其中,所述第一音频设备与电子设备建立第一链路连接之前,所述方法还包括:
    在所述第一音频设备启动后,建立与第二音频设备的配对连接;
    获取设备连接记录;
    当所述设备连接记录为空时,获取所述第二音频设备的第一地址信息,并将所述第二音频设备的第一地址信息写入所述第一音频设备的预设服务中。
  16. 一种音频设备的连接装置,其中,应用于第一音频设备,所述装置包括:
    第四连接模块,用于与电子设备建立第一链路连接;
    第二连接模块,用于在接收到所述电子设备发起的对预设服务的第一服务查询的情况下,将所述预设服务对应的查询结果发送至所述电子设备,使得所述电子设备基于第一地址信息与第二音频设备建立第二链路连接,其中,所述查询结果中携带有所述第二音频设备的所述第一地址信息。
  17. 一种计算机可读存储介质,其上存储有计算机程序,其中,当所述计算机程序在计算机上运行时,使得所述计算机执行如权利要求1至6任一项所述的音频设备的连接方法,或者执行如权利要求8至10任一项所述的音频设备的连接方法,或者执行如权利要求12至15任一项所述的音频设备的连接方法。
  18. 一种电子设备,包括处理器、存储器以及无线收发器,所述存储器存储有计算机程序,其中,所述处理器通过调用所述计算机程序,用于使得所述电子设备执行如权利要求8至10任一项所述的音频设备的连接方法。
  19. 一种无线音频设备,包括处理器、存储器以及无线收发器,所述存储器存储有计算机程序,其中,所述处理器通过调用所述计算机程序,用于使得所述无线音频设备执行如权利要求1至6任一项所述的音频设备的连接方法。
  20. 一种无线音频设备,包括处理器、存储器以及无线收发器,所述存储器存储有计算机程序,其中,所述处理器通过调用所述计算机程序,用于使得所述无线音频设备执行如权利要求12至15任一项所述的音频设备的连接方法。
PCT/CN2022/143466 2022-06-30 2022-12-29 音频设备的连接方法、装置、存储介质及设备 WO2024001134A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210770869.9 2022-06-30
CN202210770869.9A CN117395635A (zh) 2022-06-30 2022-06-30 音频设备的连接方法、装置、存储介质及设备

Publications (1)

Publication Number Publication Date
WO2024001134A1 true WO2024001134A1 (zh) 2024-01-04

Family

ID=89383939

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/143466 WO2024001134A1 (zh) 2022-06-30 2022-12-29 音频设备的连接方法、装置、存储介质及设备

Country Status (2)

Country Link
CN (1) CN117395635A (zh)
WO (1) WO2024001134A1 (zh)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2020107485A1 (zh) * 2018-11-30 2020-06-04 华为技术有限公司 一种蓝牙连接方法及设备
CN111629369A (zh) * 2020-05-27 2020-09-04 歌尔科技有限公司 一种蓝牙耳机及其配对连接方法、装置和tws耳机
US20200322788A1 (en) * 2019-04-04 2020-10-08 Qualcomm Incorporated Address management for bluetooth devices
CN112469015A (zh) * 2019-09-06 2021-03-09 华为技术有限公司 蓝牙连接的方法和电子设备
CN114363876A (zh) * 2022-01-24 2022-04-15 Oppo广东移动通信有限公司 连接建立方法、装置、设备、存储介质及程序产品
CN114531673A (zh) * 2022-01-30 2022-05-24 恒玄科技(上海)股份有限公司 优化蓝牙连接速度的方法及其蓝牙耳机设备
CN114679710A (zh) * 2020-12-25 2022-06-28 华为技术有限公司 一种tws耳机连接方法及设备

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2020107485A1 (zh) * 2018-11-30 2020-06-04 华为技术有限公司 一种蓝牙连接方法及设备
US20200322788A1 (en) * 2019-04-04 2020-10-08 Qualcomm Incorporated Address management for bluetooth devices
CN112469015A (zh) * 2019-09-06 2021-03-09 华为技术有限公司 蓝牙连接的方法和电子设备
CN111629369A (zh) * 2020-05-27 2020-09-04 歌尔科技有限公司 一种蓝牙耳机及其配对连接方法、装置和tws耳机
CN114679710A (zh) * 2020-12-25 2022-06-28 华为技术有限公司 一种tws耳机连接方法及设备
CN114363876A (zh) * 2022-01-24 2022-04-15 Oppo广东移动通信有限公司 连接建立方法、装置、设备、存储介质及程序产品
CN114531673A (zh) * 2022-01-30 2022-05-24 恒玄科技(上海)股份有限公司 优化蓝牙连接速度的方法及其蓝牙耳机设备

Also Published As

Publication number Publication date
CN117395635A (zh) 2024-01-12

Similar Documents

Publication Publication Date Title
WO2018032455A1 (zh) 一种蓝牙通信的方法及终端
WO2019090726A1 (zh) 选择蓝牙设备的方法、终端和系统
WO2021239032A1 (zh) 蓝牙协议连接方法、装置、存储介质及相关设备
US11991612B2 (en) Bluetooth data transmission method and apparatus, terminal and storage medium
WO2024066694A1 (zh) 音频设备的连接方法、装置、存储介质及设备
CN113766477A (zh) 设备连接方法、装置、电子设备及计算机可读介质
CN111262870B (zh) 视频通话切换方法、装置、存储介质及终端
WO2021136141A1 (zh) 播放方法及电子设备
WO2024016948A1 (zh) 信息更新方法及装置、音频共享方法及系统、电子设备
KR20200090260A (ko) 서비스 처리 방법 및 이동 통신 단말
WO2023036178A1 (zh) 蓝牙连接方法、装置、耳机设备及计算机可读存储介质
CN106095132A (zh) 播放设备按键功能设置方法及装置
WO2020113591A1 (zh) 一种动态调整avrcp版本的方法及终端设备
CN105847408A (zh) 一种数据同步的方法、装置及设备
WO2024001134A1 (zh) 音频设备的连接方法、装置、存储介质及设备
CN112312368B (zh) 数据处理方法、装置、设备和存储介质
WO2024082906A1 (zh) 信息获取方法、装置、蓝牙设备、终端设备及存储介质
WO2024119947A1 (zh) 蓝牙通信方法、装置、电子设备及计算机可读介质
WO2024055738A1 (zh) 音频数据的共享方法、装置、电子设备以及存储介质
WO2023061273A1 (zh) 设备连接方法、装置、电子设备以及存储介质
CN117062256A (zh) 跨设备业务转移的方法、电子设备和系统
CN114844736B (zh) 一种设备及通话控制方法
WO2021164761A1 (zh) 通信方法及相关设备
WO2022237353A1 (zh) 在耳机收纳盒中配置耳机的方法、装置、设备及程序产品
CN114844735A (zh) 一种显示设备及语音转发方法

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: 22949209

Country of ref document: EP

Kind code of ref document: A1