WO2018082335A1 - 连接蓝牙设备的方法、装置、系统及设备 - Google Patents

连接蓝牙设备的方法、装置、系统及设备 Download PDF

Info

Publication number
WO2018082335A1
WO2018082335A1 PCT/CN2017/092358 CN2017092358W WO2018082335A1 WO 2018082335 A1 WO2018082335 A1 WO 2018082335A1 CN 2017092358 W CN2017092358 W CN 2017092358W WO 2018082335 A1 WO2018082335 A1 WO 2018082335A1
Authority
WO
WIPO (PCT)
Prior art keywords
connection
bluetooth device
terminal
state
hsp
Prior art date
Application number
PCT/CN2017/092358
Other languages
English (en)
French (fr)
Inventor
段仕涛
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Priority to EP17867752.2A priority Critical patent/EP3537734B1/en
Publication of WO2018082335A1 publication Critical patent/WO2018082335A1/zh

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
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/02Arrangements for optimising operational condition
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/10Scheduling measurement reports ; Arrangements for measurement reports

Definitions

  • the present disclosure relates to Bluetooth communication technologies in the field of wireless communications, for example, to a method, apparatus, system, and device for connecting Bluetooth devices.
  • a Bluetooth device such as a Bluetooth headset or a Bluetooth device on a car can be connected to a mobile terminal such as a mobile phone to complete the function of answering the call.
  • a Bluetooth headset or a Bluetooth device is connected using the HSP (Headset Profile) protocol or the HFP (Hands Free Profile) protocol, at one moment, a Bluetooth headset or Bluetooth device can only be used with a mobile phone. Connection; the new HFP protocol can support one headset or car Bluetooth device to connect two mobile phones at a time, but only when a mobile phone calls (not at the same time), use a Bluetooth headset that supports the new HFP protocol or a Bluetooth device to answer the call. Incoming calls; you can't choose to answer when two phones are calling at the same time.
  • Bluetooth headsets or Bluetooth chips used in Bluetooth devices that do not support the new HFP protocol, it is not possible to support multiple phones to connect with Bluetooth headsets or Bluetooth devices at the same time.
  • the in-vehicle Bluetooth device cannot guarantee to maintain connection with each mobile phone of the user, and it is not guaranteed that the user selectively receives the incoming call when using the in-vehicle Bluetooth device.
  • a method, device, system and device for connecting a Bluetooth device to a terminal which enable at least two terminals to be connected and used simultaneously with the Bluetooth device.
  • a method of connecting a Bluetooth device comprising:
  • At least one of the two or more terminals receives a connection status report sent by the Bluetooth device, and according to the received connection status report, initiates a connection request to the Bluetooth device and establishes a Bluetooth on the basis of maintaining the Ble connection. a communication connection, wherein the connection request is for indicating that the terminal requests to establish a non-low power Bluetooth communication connection with the Bluetooth device.
  • the detecting that the triggering itself changes state includes one of the following:
  • the terminal detects the operation of the incoming call
  • the terminal detects the operation of making a call
  • the terminal detects the operation of hanging up the phone.
  • the detecting the change of the trigger state itself includes one of the following:
  • the terminal detects an operation of playing audio
  • the terminal detects an operation to stop playing audio.
  • sending a notification message includes one of the following:
  • the sending the notification message includes one of the following:
  • the request for initiating a connection to the Bluetooth device according to the received connection status report according to the received connection status report includes one of the following:
  • At least one of the two or more terminals initiates a request to establish a Bluetooth hands-free specification HFP connection with the Bluetooth device;
  • At least one of the two or more terminals initiates a request to establish a Bluetooth handset specification HSP connection with the Bluetooth device;
  • At least one of the two or more terminals initiates a request to disconnect the HFP connection from the Bluetooth device to only retain the Ble connection;
  • At least one of the two or more terminals initiates disconnection of the HSP with the Bluetooth device only A request to keep a Ble connection.
  • the request for initiating a connection to the Bluetooth device according to the received connection status report according to the received connection status report includes one of the following:
  • At least one of the two or more terminals initiates a request to establish a high quality audio distribution specification A2DP connection with the Bluetooth device;
  • At least one of the two or more terminals initiates a request to disconnect the A2DP connection with the Bluetooth device to only retain the Ble connection.
  • At least one of the two or more terminals requests to establish a non-low power Bluetooth communication connection with the Bluetooth device, including one of the following:
  • At least one of the two or more terminals requests to establish an HSP connection with the Bluetooth device
  • At least one of the two or more terminals requests to establish an HFP connection with the Bluetooth device
  • At least one of the two or more terminals requests to establish an A2DP connection with the Bluetooth device.
  • a method of connecting a terminal comprising:
  • a Bluetooth device establishes and maintains a Ble connection with more than two terminals
  • the Bluetooth device receives the notification message, detects its own connection status, and transmits a connection status report to at least one of the two or more terminals according to the detected connection status and the notification message.
  • connection status of the Bluetooth device itself comprises one of the following:
  • connection status of the Bluetooth device itself comprises one of the following:
  • the A2DP connection is not in use.
  • connection status report of the Bluetooth device includes one of the following:
  • the Bluetooth device is in the connected state of the HFP connection
  • the Bluetooth device is in the connected state of the HSP connection
  • the Bluetooth device is in the connected state of the A2DP connection.
  • the method further includes one of the following operations:
  • the method further includes: on a basis of maintaining a Ble connection, the Bluetooth device receives, by the at least one of the two or more terminals, a connection initiated to the Bluetooth device according to the connection status report. Requesting, the Bluetooth device, in response to the connection request, establish a non-low power Bluetooth communication connection with at least one of the two or more terminals; wherein the connection request indicates that the terminal requests to establish a non-low connection with the Bluetooth device Power Bluetooth communication connection.
  • the Bluetooth device receiving, by the at least one of the two or more terminals, the connection request initiated to the Bluetooth device according to the connection status report includes one of the following:
  • At least one of the two or more terminals initiates a request to establish an HFP connection with the Bluetooth device
  • At least one of the two or more terminals initiates a request to establish an HSP connection with the Bluetooth device
  • At least one of the two or more terminals initiates a request to disconnect the HFP connection from the Bluetooth device to only retain the Ble connection;
  • At least one of the two or more terminals initiates a request to disconnect the HSP connection from the Bluetooth device to only retain the Ble connection.
  • the Bluetooth device receives the two or more terminals on the basis of maintaining a Ble connection.
  • the connection request initiated by the at least one terminal to the Bluetooth device according to the connection status report includes one of the following:
  • At least one of the two or more terminals initiates a request to establish an A2DP connection with the Bluetooth device
  • At least one of the two or more terminals initiates a request to disconnect the A2DP connection with the Bluetooth device and only retain the Ble connection.
  • the method further includes one of the following:
  • the Bluetooth device switches from the HFP connection and the call state to the HFP unconnected state
  • the Bluetooth device switches from being in an HSP connection and in a call state to a state in which the HSP is not connected;
  • the Bluetooth device switches from being in the HFP connection and in the call state to being in the HFP connection but not in the call state;
  • the Bluetooth device switches from being in an HSP connection and in a call state to being in an HSP connection but not in a call state;
  • the Bluetooth device switches from being in an A2DP connection used state to an A2DP unconnected state on the basis of maintaining a Ble connection;
  • the Bluetooth device switches from being in the used state of the A2DP connection to the state in which the A2DP connection is not used.
  • the Bluetooth device responds to the connection request, and establishes a non-low power Bluetooth communication connection with at least one of the two or more terminals, including one of the following:
  • the Bluetooth device establishes an HSP connection with at least one of the two or more terminals;
  • the Bluetooth device establishes an HFP connection with at least one of the two or more terminals;
  • the Bluetooth device establishes an A2DP connection with at least one of the two or more terminals.
  • a device for connecting a Bluetooth device comprising: a connection module, a detection module, and a transceiver module, wherein
  • the connection module is configured to establish and maintain a connection between the terminal and the Bluetooth device; according to the received The connection status report initiates a connection request to the Bluetooth device, wherein the connection request is used to indicate that the terminal requests to establish a non-low power Bluetooth communication connection with the Bluetooth device;
  • the detecting module is configured to detect an operation that triggers a change in the state of the terminal
  • the transceiver module is configured to send a notification message to the Bluetooth device and receive a connection status report of the Bluetooth device when detecting an operation that triggers a change in the state of the terminal.
  • the detecting module detects that the status of the trigger terminal changes includes one of the following:
  • the detecting module detects that the status of the trigger terminal changes includes one of the following:
  • the notification message sent to the Bluetooth device includes one of the following:
  • connection status report includes one of the following:
  • the Bluetooth device is in the connected state of the HFP connection
  • the Bluetooth device is in the connected state of the HSP connection
  • the Bluetooth device is in the connected state of the A2DP connection.
  • the transceiver module initiates any one of the following connection requests to the Bluetooth device on the basis of maintaining the Ble connection:
  • the transceiver module initiates any one of the following connection requests to the Bluetooth device on the basis of maintaining the Ble connection:
  • the establishing a non-low power Bluetooth communication connection includes one of the following:
  • the terminal supports a Ble connection, and supports at least one of an HSP connection, an HFP connection, and an A2DP connection.
  • a device for connecting a terminal comprising: a connection module, a detection module, and a transceiver module, wherein
  • the connection module is configured to establish and maintain a Bluetooth device and a Ble connection of two or more terminals
  • the detecting module is configured to detect a connection status report of the Bluetooth device
  • the transceiver module is configured to receive a notification message, and send a connection status report to at least one of the two or more terminals according to the detected connection status and the notification message.
  • the detecting module detects that the Bluetooth device is in any one of the following connection states:
  • the HSP is connected and the call is in progress.
  • the detecting module detects that the Bluetooth device is in any one of the following connection states:
  • the A2DP connection is not in use.
  • connection status report includes one of the following:
  • the Bluetooth device is in the connected state of the HFP connection
  • the Bluetooth device is in the connected state of the HSP connection
  • the Bluetooth device is in the connected state of the A2DP connection.
  • connection module is further configured to perform one of the following operations:
  • the transceiver module is further configured to: after receiving the Ble connection, receive a connection request initiated by the terminal, and establish a non-low-power Bluetooth with at least one of the two or more terminals in response to the connection request. a communication connection; wherein the connection request indicates that the terminal requests to establish a non-low power Bluetooth communication connection with the Bluetooth device.
  • the connection request initiated by the receiving terminal includes one of the following:
  • the terminal initiates a request to establish an HFP connection with the Bluetooth device
  • the terminal initiates a request to establish an HSP connection with the Bluetooth device
  • the terminal initiates a request to disconnect the HFP connection from the Bluetooth device to retain only the Ble connection;
  • the terminal initiates a request to disconnect the HSP connection from the Bluetooth device to only retain the Ble connection.
  • the connection request initiated by the receiving terminal includes one of the following:
  • the terminal initiates a request to establish an A2DP connection with the Bluetooth device
  • the terminal initiates disconnection of the A2DP connection with the Bluetooth device and only reserves the Ble connection request.
  • the terminal requests to establish a non-low power Bluetooth communication connection with the Bluetooth device, including one of the following:
  • the terminal requests to establish an HSP connection with the Bluetooth device
  • the terminal requests to establish an HFP connection with the Bluetooth device
  • the terminal requests to establish an A2DP connection with the Bluetooth device.
  • the device further includes a switching module configured to perform one of the following operations:
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HFP connection and in a call state to a state in which the HFP is not connected;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HSP connection and in a call state to a state in which the HSP is not connected;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in the HFP connection and in the call state to being in the HFP connection but not in the call state;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HSP connection and in a call state to being in an HSP connection but not in a call state;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in the A2DP connection used state to the A2DP connection unused state.
  • a system for connecting a Bluetooth device comprising a Bluetooth device and at least two terminals;
  • Each of the at least two terminals is configured to establish and maintain a Ble connection with the Bluetooth device; detecting an operation that triggers a change in its own state; and transmitting a notification message to the Bluetooth device when detecting an operation that triggers a change in its own state.
  • the Bluetooth device is configured to establish and maintain a Ble connection with two or more terminals; receive a notification message, detect a connection state in which it is located, and send the terminal to the terminal according to the detected connection status and a notification message. Send a connection status report.
  • the detecting triggering the change of the state of the self includes one of the following:
  • the detecting triggering the change of the state of the self includes one of the following:
  • the detecting the connection state in which the user is located includes one of the following:
  • the HSP is connected and the call is in progress.
  • the detecting the connection state in which the user is located includes one of the following:
  • the A2DP connection is not in use.
  • connection status report of the Bluetooth device includes one of the following:
  • the Bluetooth device is in the connected state of the HFP connection
  • the Bluetooth device is in the connected state of the HSP connection
  • the Bluetooth device is in the connected state of the A2DP connection.
  • the request to initiate the connection to the Bluetooth device on the basis of maintaining the Ble connection includes any one of the following requests:
  • the request to initiate the connection to the Bluetooth device on the basis of maintaining the Ble connection includes any one of the following requests:
  • the establishing a Bluetooth communication connection includes one of the following:
  • the detected connection status includes one of the following:
  • the detected connection status includes one of the following:
  • the A2DP connection is not in use.
  • the Bluetooth device is further configured to perform one of the following operations:
  • the Bluetooth device is further configured to perform one of the following operations:
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HFP connection and in a call state to a state in which the HFP is not connected;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HSP connection and in a call state to a state in which the HSP is not connected;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in the HFP connection and in the call state to being in the HFP connection but not in the call state;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HSP connection and in a call state to being in an HSP connection but not in a call state;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in the A2DP connection used state to the A2DP connection unused state.
  • a terminal comprising a processor, configured to establish and maintain a Ble connection between the terminal and the Bluetooth device; detecting an operation that triggers a change in the state of the terminal; and transmitting a notification message to the Bluetooth device when detecting an operation that triggers a change in the state of the terminal; and receiving a connection status report of the Bluetooth device, and according to the received connection status report, initiate a connection request to the Bluetooth device to establish a Bluetooth communication connection on the basis of maintaining the Ble connection; wherein the connection request indicates that the terminal requests and The Bluetooth device establishes a non-low power Bluetooth communication connection.
  • a Bluetooth device comprising a processor, configured to establish and maintain a Ble connection between the Bluetooth device and the terminal; receive a notification message, detect a connection status of the Bluetooth device, and send a connection status report to the terminal according to the detected connection status and the notification message.
  • a computer readable storage medium storing computer executable instructions arranged to perform the method of any of the above.
  • the method, device, system and device for connecting a Bluetooth device to a terminal provided by the above content establish and maintain a low-cost (Ble) connection between two or more terminals and a Bluetooth device; at least one of the two or more terminals detects that a trigger state occurs.
  • the notification message is sent to the Bluetooth device; at least one of the two or more terminals receives the connection status report sent by the Bluetooth device, and initiates a connection request to the Bluetooth device according to the received connection status report to establish a Bluetooth communication.
  • the connection request indicates that at least one of the two or more terminals requests to establish a Bluetooth communication connection with the Bluetooth device.
  • each terminal Since each terminal establishes and maintains a Ble connection with the Bluetooth device, when a terminal detects an incoming call, the terminal sends a notification message to the Bluetooth device, and the Bluetooth device feeds back to the terminal a connection status report, such as whether it is already in a call or used. Whether the terminal can make a current call or the like, the terminal determines to establish a connection or disconnection with the Bluetooth device according to the received connection status report, so that the two terminals can simultaneously connect with the Bluetooth device, and ensure that the terminal calls or listens to the call. The function of the terminal.
  • the terminal may also detect the operation of triggering the change of its own state, and after sending the notification message to the Bluetooth device, the Bluetooth device according to the detected itself and each terminal. Selecting a connection state, determining whether to access a new incoming call or responding to a new usage requirement, and determining to send a control command to the corresponding terminal, the terminal accessing the incoming call according to the control command to enter the call, or disconnecting the call according to the control command; or Use A2DP according to the control command, or disconnect A2DP.
  • FIG. 1 is a schematic flowchart of a method for connecting a Bluetooth device performed by a terminal side in an embodiment
  • FIG. 2 is a schematic structural diagram of an apparatus for connecting a Bluetooth device in an embodiment
  • FIG. 3 is a schematic flow chart of a method for connecting a terminal in an embodiment
  • FIG. 4 is a schematic structural diagram of an apparatus for connecting a terminal in an embodiment
  • FIG. 5 is a schematic diagram of a terminal side determining process in an embodiment
  • FIG. 6 is a schematic diagram of a working process of a Bluetooth device side in an embodiment
  • FIG. 7 is a schematic diagram of a determination process after receiving a connection status report by a terminal side in an embodiment
  • FIG. 8 is a schematic diagram of a terminal side determining process when the first terminal calls in the first embodiment
  • FIG. 9 is a schematic diagram of a working process of a Bluetooth device side when an first terminal calls in the first embodiment
  • FIG. 10 is a schematic diagram of a determination process after the terminal side receives the connection status report when the first terminal calls in the first embodiment
  • 11 is a schematic diagram of a terminal side determining process when the first terminal talks and the second terminal calls when the second terminal is in the second embodiment
  • FIG. 12 is a schematic diagram of a working process of a Bluetooth device on a first terminal in a second embodiment
  • FIG. 13 is a schematic diagram of a process of determining a connection status report after the first terminal is in a call in the second embodiment
  • FIG. 14 is a schematic diagram of a terminal side determining process when a first terminal talks and a second terminal and a third terminal simultaneously call when a terminal priority is set in Embodiment 3;
  • FIG. 15 is a schematic diagram of a working process of a Bluetooth device side when a first terminal talks and a second terminal and a third terminal simultaneously call when a terminal priority is set in Embodiment 3;
  • 16 is a schematic diagram of a process of determining a connection status report when a terminal is called by a first terminal in a case where a terminal priority is set and a terminal is received by the second terminal and the third terminal in the third embodiment;
  • 17 is a schematic diagram of a terminal side determining process when a first terminal talks in a fourth embodiment and a second terminal and a third terminal simultaneously call;
  • FIG. 18 is a schematic diagram of a working process of a Bluetooth device side when a first terminal talks in a fourth embodiment and a second terminal and a third terminal simultaneously call;
  • 19 is a terminal side of the first terminal in the fourth embodiment, and the second terminal and the third terminal simultaneously call each other.
  • FIG. 20 is a schematic diagram of a terminal side determining process when the first terminal detects an audio playing operation in Embodiment 5;
  • FIG. 21 is a schematic diagram of a working process of a Bluetooth device side when the first terminal detects an audio playback operation in Embodiment 5;
  • 22 is a schematic diagram of a process of determining a connection status report after receiving a connection status report by the terminal end when the first terminal detects an audio playback operation in the fifth embodiment
  • FIG. 23 is a schematic structural diagram of hardware of a terminal provided by an embodiment
  • FIG. 24 is a schematic structural diagram of hardware of a Bluetooth device according to an embodiment.
  • FIG. 1 is a schematic flowchart of a method for connecting a Bluetooth device to a terminal on the terminal side. As shown in FIG. 1 , the method for connecting a Bluetooth device in this embodiment includes the following steps.
  • step 101 more than two terminals establish and maintain a Bluetooth Low Energy (Ble) connection with the Bluetooth device.
  • Ble Bluetooth Low Energy
  • the terminal includes a mobile phone, a tablet or a wearable smart device having at least one of a call function and an audio play function;
  • the Bluetooth device includes a car Bluetooth device or a Bluetooth headset having at least one of a Bluetooth call function and an audio play function.
  • a Ble connection is established, that is, a connection is established between two or more terminals and a Bluetooth device through Ble technology.
  • the terminal and the Bluetooth device can simultaneously support at least one of the HSP connection and the HFP connection and the Ble connection, or the terminal and the Bluetooth device can simultaneously support the Ble connection and the A2DP (Advanced Audio Distribution Profile) connection.
  • the two or more terminals may be terminals less than or equal to six and greater than or equal to two.
  • the HSP connection is connected through the HSP protocol
  • the HFP connection is connected through the HFP protocol.
  • step 102 when at least one of the two or more terminals detects an operation that triggers a change in its own state, a notification message is sent to the Bluetooth device.
  • the detecting the change of the triggering state may include: the terminal detects the operation of the incoming call, the terminal detects the operation of making the call, the terminal detects the operation of hanging up the phone, the terminal detects the operation of playing the audio, or the terminal detects the stop. The operation of playing audio.
  • the sending the notification message may include: a message for transmitting a communication connection, a message for transmitting a communication connection end, a message for transmitting an audio broadcast, or a message for stopping audio playback.
  • step 103 the terminal receives the connection status report sent by the Bluetooth device, and according to the received connection status report, sends a connection request to the Bluetooth device to establish a Bluetooth communication connection, and the connection request indicates the terminal, on the basis of maintaining the Ble connection. Request to establish a non-low power Bluetooth communication connection with the Bluetooth device.
  • initiating a connection request to the Bluetooth device on the basis of maintaining the Ble connection may include one of the following:
  • At least one of the two or more terminals initiates a request to establish an HFP connection with the Bluetooth device
  • At least one of the two or more terminals initiates a request to establish an HSP connection with the Bluetooth device
  • At least one of the two or more terminals initiates a request to disconnect the HFP connection from the Bluetooth device to retain only the Ble connection;
  • At least one of the two or more terminals initiates a request to disconnect the HSP connection from the Bluetooth device only to retain the Ble connection;
  • At least one of the two or more terminals initiates a request to establish an A2DP connection with the Bluetooth device
  • At least one of the two or more terminals initiates a request to disconnect the A2DP connection with the Bluetooth device to only retain the Ble connection.
  • the embodiment provides a device for connecting a Bluetooth device.
  • the device for connecting a Bluetooth device in this embodiment includes: a first connection module 201, and a first detection module. 202 and a first transceiver module 203.
  • the first connection module 201 is configured to establish and maintain a Ble connection between the terminal and the Bluetooth device.
  • the first detecting module 202 is configured to detect an operation that triggers a change in the state of the terminal.
  • the first transceiver module 203 is configured to send a notification message to the Bluetooth device when the operation of triggering the change of the terminal state is detected; receive the connection status report of the Bluetooth device, and maintain the basis of the Ble connection according to the received connection status report. Up, a connection request is initiated to the Bluetooth device, and a Bluetooth communication connection is established, the connection request indicating that the terminal requests to establish a non-low power Bluetooth communication connection with the Bluetooth device.
  • the terminal supports at least one of an HSP, an HFP connection, and an A2DP connection, and the terminal supports the Ble connection.
  • the first transceiver module 203 is configured to initiate any one of the following connection requests to the Bluetooth device on the basis of maintaining the Ble connection:
  • the first connection module 201, the first detection module 202, and the first transceiver module 203 may be a Central Processing Unit (CPU), a Micro Processor Unit (MPU), and a digital signal processor located on the terminal. (DSP, Digital Signal Processor), or Field Programmable Gate Array (FPGA) implementation.
  • CPU Central Processing Unit
  • MPU Micro Processor Unit
  • DSP Digital Signal Processor
  • FPGA Field Programmable Gate Array
  • FIG. 3 is a schematic flowchart of a method for connecting a Bluetooth device to a Bluetooth device in the embodiment. As shown in FIG. 3, the flow of the method for connecting a Bluetooth device on the Bluetooth device side in the embodiment includes the following steps.
  • step 301 the Bluetooth device establishes and maintains a Ble connection with more than two terminals.
  • the Bluetooth device receives the notification message, detects its own connection status, and transmits a connection status report to at least one of the two or more terminals according to the detected connection status and the notification message.
  • the receiving notification message may include one of the following:
  • Receiving a message of a communication connection receiving a message ending the communication connection, receiving a message for audio playback, and receiving a message to stop audio playback.
  • the status of the Bluetooth device may include one of the following: an HFP is not connected, an HSP is not connected, is in an HFP connection but is not in a call, is in an HSP connection but is not in a call, is in an HFP connection and is in a call, and is in an HSP connection and is in a call;
  • the A2DP is not connected, the A2DP connection is used, and the A2DP connection is not used.
  • the connection status report of the Bluetooth device may include one of the following: a Bluetooth device is in a connection state of the HFP connection; the Bluetooth device is in a connection state of the HSP connection; and the Bluetooth device is in a connection state of the A2DP connection.
  • the present embodiment provides a device for connecting a terminal.
  • the device for connecting a terminal in this embodiment includes: a second connection module 401 and a second detection module 402. And a second transceiver module 403.
  • the second connection module 401 is configured to establish and maintain a Ble connection between the Bluetooth device and two or more terminals.
  • the second detecting module 402 is configured to detect a connection status report of the Bluetooth device.
  • the second transceiver module 403 is configured to receive a notification message, and send a connection status report to at least one of the two or more terminals according to the detected connection status and the notification message.
  • the Bluetooth device supports at least one of an HSP connection, an HFP connection, and an A2DP connection, and the Bluetooth device supports a Ble connection.
  • the second detecting module 402 can be configured to detect that the Bluetooth device is in any one of the following connection states:
  • HFP is not connected, HSP is not connected, HFP is connected but not talking, HSP is connected but not talking, HFP is connected and the call is in HSP connection,
  • the A2DP is not connected, the A2DP connection is used, and the A2DP connection is not used.
  • the second transceiver module 403 can be configured to send a connection status report to the terminal according to the detected connection status and the notification message.
  • the Bluetooth device can also be configured to perform one of the following operations:
  • the Bluetooth device can also be configured to perform one of the following operations:
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HFP connection and in a call state to a state in which the HFP is not connected;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HSP connection and in a call state to a state in which the HSP is not connected;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in the HFP connection and in the call state to being in the HFP connection but not in the call state;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in an HSP connection and in a call state to being in an HSP connection but not in a call state;
  • the Bluetooth device On the basis of maintaining the Ble connection, the Bluetooth device is switched from being in the A2DP connection used state to the A2DP connection unused state.
  • the second connection module 401, the detection module 402, and the second transceiver module 403 can be implemented by a CPU, an MPU, a DSP, or an FPGA located on a Bluetooth device.
  • FIG. 5 is a schematic diagram of a terminal side determining process in the embodiment. As shown in FIG. 5, the terminal side determining process in this embodiment includes the following steps.
  • step 501 the terminal detects an operation that triggers a change in its own state.
  • the detecting that the triggering of the change of the self state may include: the terminal detects the operation of the incoming call, the terminal detects the operation of making a call, the terminal detects that the operation terminal that hangs up the phone detects the operation of playing the audio, or the terminal detects the stop. The operation of playing audio.
  • step 502 it is checked whether the terminal is connected to the Bluetooth device. If the terminal is connected to the Bluetooth device, step 504 is performed. If the terminal is not connected to the Bluetooth device, step 503 is performed.
  • the connection may include: a Ble connection, an HSP connection, an HFP connection, or an A2DP connection.
  • step 503 the terminal completes the operation and ends the current processing flow.
  • the completing the operation by the terminal may include: completing the answering call, making a call, hanging up the phone, playing the audio, or stopping the playing of the audio through the terminal.
  • step 504 it is checked whether the terminal is in HSP connection, HFP connection or A2DP connection with the Bluetooth device. If the terminal is in HSP connection, HFP connection or A2DP connection with the Bluetooth device, step 505 is performed, if the terminal is not in HSP connection with the Bluetooth device, Step 506 is performed by connecting any one of the HFP connection and the A2DP connection.
  • the type of connection between the terminal and the Bluetooth device may also be an HSP connection supported by the terminal, and it may be checked whether the terminal is in an HSP connection with the Bluetooth device.
  • step 505 the Bluetooth device performs the operation detected by the terminal (for example, when the terminal detects the operation of answering the call, the Bluetooth device answers the call), and the process flow ends.
  • step 506 it is checked whether the terminal is in the Ble connection with the Bluetooth device. If the terminal is in the Ble connection with the Bluetooth device, step 507 is performed. If the terminal is not in the Ble connection with the Bluetooth device, step 503 is performed.
  • step 507 it is checked whether the Bluetooth device connected to the terminal to support the Ble supports the HSP connection (or the HFP connection). If the Bluetooth device that maintains the Ble connection with the terminal supports the HSP connection (or the HFP connection), step 509 is performed, if the terminal is maintained. The Bluetooth device connected to the Ble does not support the HSP connection (or HFP connection), and step 508 is performed.
  • step 508 a connection error message is displayed, and the current processing flow is ended.
  • step 509 the terminal updates the record on the terminal side and transmits a notification message to the Bluetooth device.
  • the recording of the update terminal side may be performed by recording, in the application layer protocol of the terminal side, an event corresponding to the operation of detecting the change of the triggering state of the terminal, by changing the terminal side application layer protocol (The feature object of the Bluetooth Gatt Service in the Bluetooth Ble protocol in profile) implements an update to the record.
  • the configuration file may be based on a server attribute and a GATT Generic Attribute Profile, and the configuration file may ensure that the terminal and the Bluetooth device communicate when the Ble is connected.
  • the terminal side acts as a server
  • the Bluetooth device side acts as a client
  • the profile server side contains an object Bluetooth Gatt Service
  • the Bluetooth Gatt Service can contain two Bluetooth Gatt Characteristics, one of which The Bluetooth Gatt Characteristic can be used to save the connection status of the HFP, HSP, or A2DP in the Bluetooth device currently in the Ble connection state.
  • FIG. 6 is a schematic diagram of the working process of the Bluetooth device in the embodiment. As shown in FIG. 6, the Bluetooth device side determining process in this embodiment includes the following steps.
  • step 601 the Bluetooth device receives the notification message.
  • step 602 it is checked whether the Bluetooth device is in an HSP connection, an HFP connection, or an A2DP connection with the terminal. If the Bluetooth device and the terminal are in the above-mentioned checked connection type, step 604 is performed, if the Bluetooth device and the terminal are not in any of the above connections. Go to step 603.
  • the Bluetooth device can obtain the connection type supported by the terminal (for example, HSP connection, HFP connection, or A2DP connection) according to the request sent by the terminal. If the request is related to the call, the step 602 can check whether the Bluetooth device is in HFP connection with the terminal or The HSP connection, if the request is related to playing music, in step 602, it can be checked whether the Bluetooth device is in an A2DP connection with the terminal.
  • the connection type supported by the terminal for example, HSP connection, HFP connection, or A2DP connection
  • step 603 the connection status report is sent, indicating that the Bluetooth device and the terminal are in the unconnected state of the checked connection type (for example, the HSP is not connected, the HFP is not connected, or the A2DP is not connected), and the process is terminated.
  • the connection status report is sent, indicating that the Bluetooth device and the terminal are in the unconnected state of the checked connection type (for example, the HSP is not connected, the HFP is not connected, or the A2DP is not connected), and the process is terminated.
  • step 604 it is determined whether the Bluetooth device is in a call state or a play state. If the Bluetooth device is in a call state or a play state, step 606 is performed. If the Bluetooth device is not in the call state and is not in the play state, step 605 is performed. .
  • step 605 the current connection is disconnected, and a connection status report is sent, indicating that the Bluetooth device is in the unconnected state of the checked connection type (eg, HSP is not connected, HFP is not connected, or is in an A2DP unconnected state), and the process ends.
  • the checked connection type eg, HSP is not connected, HFP is not connected, or is in an A2DP unconnected state
  • step 606 the Bluetooth device interface is invoked to notify the user.
  • step 607 an instruction is received to determine whether to change the current state of the Bluetooth device, if the change
  • step 609 if the current state of the Bluetooth device is not changed, step 608 is performed.
  • step 608 the status of the current Bluetooth device is maintained, and a connection status report is sent, indicating that the Bluetooth device is in the connection state of the checked connection type (eg, in an HSP connection and in a call state, an HFP connection, a call state, an HSP connection but not The call status, HFP connection but no call status, A2DP connection used or A2DP connection unused status, the process ends.
  • a connection status report is sent, indicating that the Bluetooth device is in the connection state of the checked connection type (eg, in an HSP connection and in a call state, an HFP connection, a call state, an HSP connection but not The call status, HFP connection but no call status, A2DP connection used or A2DP connection unused status, the process ends.
  • the A2DP connection is in a used state, and the Bluetooth device and the terminal are transmitting audio data through the A2DP (eg, playing music), and the A2DP connection is in an unused state, and the A2DP is established between the Bluetooth device and the terminal. Connected but not transmitting audio data (eg, music is not playing).
  • step 609 the current connection is disconnected, and a connection status report is sent, indicating that the Bluetooth device is in the unconnected state of the checked connection type (eg, HSP is not connected, HFP is not connected, or is in A2DP unconnected state).
  • the Bluetooth device is in the unconnected state of the checked connection type (eg, HSP is not connected, HFP is not connected, or is in A2DP unconnected state).
  • the receiving instruction may be to set a priority of each terminal in advance. If two devices simultaneously send a connection request, the terminal with a higher priority may be selected to complete the connection between the Bluetooth device and the terminal, or may be manually selected by the user to change. The current status of the Bluetooth device.
  • FIG. 7 is a schematic diagram of a determination process after the terminal side receives the connection status report in the embodiment. As shown in FIG. 7 , the process of determining the connection status report by the terminal side in the embodiment includes the following steps.
  • step 701 the terminal receives a connection status report sent by the Bluetooth device.
  • step 702 the terminal determines the connection status of the Bluetooth device in the connection status report, and if the connection status report indicates that the Bluetooth device is in the unconnected state of the checked connection type (eg, HSP connection status, HFP connection status, or A2DP connection status), Step 704 is performed, if the connection status report indicates that the Bluetooth device is in the checked connection type unconnected state (for example, the HSP is not connected, the HFP is not connected, or is in the A2DP unconnected state), step 703 is performed.
  • the connection status report indicates that the Bluetooth device is in the checked connection type unconnected state (for example, the HSP is not connected, the HFP is not connected, or is in the A2DP unconnected state).
  • step 703 the process is exited and the process flow is ended.
  • step 704 the terminal interface is invoked, an HSP connection request, an HFP connection request is initiated to the Bluetooth device, or an A2DP connection request is initiated.
  • step 705 it is determined whether the terminal establishes a connection with the Bluetooth device, if the terminal and the Bluetooth device The connection is established, and step 706 is performed. If the terminal fails to establish a connection with the Bluetooth device, step 702 is performed.
  • step 706 the Bluetooth device is used to complete the answering call, hang up the call, make a call, play the audio, or end the audio.
  • FIG. 8 is a schematic diagram of the process of determining the terminal side when the first terminal calls in the first embodiment. As shown in FIG. 8 , the terminal side determining process when the first terminal calls in the first embodiment includes the following steps.
  • step 801 the first terminal detects an incoming call operation.
  • the method in this embodiment is described by using the first terminal to support the HSP connection as an example.
  • the HSP connection in this embodiment may also be replaced by the HFP connection.
  • step 802 it is checked whether the first terminal is connected to the Bluetooth device. If the first terminal is connected to the Bluetooth device, step 804 is performed. If the first terminal is not connected to the Bluetooth device, step 803 is performed.
  • the connection between the terminal and the Bluetooth device may include: a Ble connection, an HSP connection, or an HFP connection.
  • step 803 the first terminal answers the incoming call, and the current processing flow is ended.
  • step 804 it is checked whether the first terminal is in the HSP connection. If the first terminal is in the HSP connection, step 805 is performed. If the first terminal is not in the HSP connection, step 806 is performed.
  • step 805 the terminal switches to the HSP connection and ends the current processing flow.
  • step 806 it is checked whether the first terminal is in a Ble connection with the Bluetooth device. If the first terminal is in a Ble connection with the Bluetooth device, step 807 is performed. If the first terminal and the Bluetooth device are not in the Ble connection, Go to step 803.
  • step 807 it is checked whether the Bluetooth device that is connected to the first terminal to support the Ble supports the HSP connection. If the Bluetooth device that maintains the Ble connection with the first terminal supports the HSP connection, step 809 is performed, if the Bluetooth connection with the first terminal is maintained. The device does not support the HSP connection. Go to step 808.
  • step 808 a connection error message is displayed, and the current processing flow is ended.
  • step 809 the record on the terminal side is updated and a notification message is sent.
  • the method may further include pairing all the terminals of the user with the Bluetooth device, establishing a Ble connection, and maintaining the Ble connection.
  • FIG. 9 is a schematic diagram of the working process of the Bluetooth device side when the first terminal calls in the first embodiment, as shown in FIG. 9 It is shown that the Bluetooth device side working process when the first terminal calls in the first embodiment includes the following steps.
  • the example in which the terminal supports the HSP connection is taken as an example. If the terminal supports the HFP connection in the embodiment shown in FIG. 8, the HSP connection in the embodiment in FIG. 9 can also be replaced with the HFP connection.
  • step 901 the Bluetooth device receives the notification message.
  • the Bluetooth device can learn the connection type supported by the terminal from the received notification message.
  • the terminal in FIG. 8 supports the HSP connection
  • the Bluetooth device can learn in the notification message that the terminal supports the HSP connection.
  • step 902 it is checked whether the Bluetooth device is in the HSP connection. If the Bluetooth device is in the HSP connection, step 904 is performed. If the Bluetooth device is not in the HSP connection, step 903 is performed.
  • the Bluetooth device can know the connection type supported by the terminal, and in step 902, the Bluetooth device can check whether the Bluetooth device is in the connection type supported by the terminal.
  • step 903 a connection status report is sent, indicating that the Bluetooth device is in an unconnected state, and the current processing flow is ended.
  • step 904 it is determined whether the Bluetooth device is in a call state. If the Bluetooth device is in a call state, step 906 is performed. If the Bluetooth device is not in a call state, step 905 is performed.
  • step 905 the connection between the Bluetooth device and the first terminal is disconnected, and a connection status report is sent, indicating that the Bluetooth device is in an unconnected state of the HSP, and the current processing flow is ended.
  • step 906 the Bluetooth device interface is invoked to notify the user.
  • step 907 an instruction is received to determine whether to change the Bluetooth device status. If the Bluetooth device status is changed, step 909 is performed. If the Bluetooth device status is not changed, step 908 is performed.
  • step 908 the current Bluetooth device connection status is maintained, a connection status report is sent, indicating that the Bluetooth device is in an HSP connection and a call state, or the Bluetooth device is in an HSP connection but not in a call state, and the process is terminated.
  • step 909 the current connection between the Bluetooth device and the first terminal is disconnected, and a connection status report is sent, indicating that the Bluetooth device is in an unconnected state of the HSP.
  • FIG. 10 is a schematic diagram of a process of determining a connection status report after receiving a connection status report by the terminal on the first terminal in the first embodiment, as shown in FIG. 10, in combination with the embodiment shown in FIG.
  • the judgment process after the end side receives the connection status report includes the following steps.
  • step 1001 the first terminal receives a connection status report sent by the Bluetooth device.
  • step 1002 the first terminal determines the connection status of the Bluetooth device in the connection status report. If the connection status report indicates that the Bluetooth device is in the HSP connection state, step 1003 is performed. If the connection status report indicates that the Bluetooth device is in the HSP unconnected state, perform the steps. 1004.
  • step 1003 the process is exited and the process is terminated.
  • step 1004 the first terminal invokes the first terminal interface to initiate an HSP connection to the Bluetooth device.
  • step 1005 it is determined whether the first terminal establishes an HSP connection with the Bluetooth device. If the first terminal establishes an HSP connection with the Bluetooth device, step 1006 is performed. If the first terminal fails to establish an HSP connection with the Bluetooth device, step 1002 is performed.
  • step 1006 the answering call is completed using a Bluetooth device.
  • FIG. 11 is a schematic diagram of the terminal side determining process when the first terminal calls and the second terminal calls in the second embodiment. As shown in FIG. 11, the terminal side determining process when the first terminal calls the second terminal in the second embodiment includes the following steps.
  • step 1101 the second terminal detects an incoming call operation.
  • step 1102 it is checked whether the second terminal is connected to the Bluetooth device. If the second terminal is connected to the Bluetooth device, step 1104 is performed. If the second terminal is not connected to the Bluetooth device, step 1103 is performed.
  • the terminal may be connected to the Bluetooth device, and may include: a Ble connection, an HSP connection, or an HFP connection.
  • step 1103 the second terminal receives an incoming call, and the current processing flow is ended.
  • step 1104 it is checked whether the second terminal is in HSP connection with the Bluetooth device. If the second terminal is in HSP connection with the Bluetooth device, step 1105 is performed. If the second terminal is not in the HSP connection, step 1106 is performed.
  • step 1105 the Bluetooth device performs the operation detected by the terminal, and ends the current processing flow.
  • step 1106 it is checked whether the second terminal is in the Ble connection with the Bluetooth device. If the second terminal is in the Ble connection with the Bluetooth device, step 1107 is performed. If the second terminal is not in the Ble connection, step 1103 is performed.
  • step 1107 it is checked whether the Bluetooth device connected to the second terminal maintains the Ble supports the HSP connection. Then, if the Bluetooth device that is connected to the second terminal to support the Ble supports the HSP connection, step 1109 is performed. If the Bluetooth device that maintains the Ble connection with the second terminal does not support the HSP connection, step 1108 is performed.
  • step 1108 the connection error message is displayed, and the current processing flow is ended.
  • step 1109 the record on the second terminal side is updated, and the second terminal sends a notification message to the Bluetooth device.
  • the method may further include: pairing all the terminals of the user with the Bluetooth device, establishing a Ble connection, and maintaining a Ble connection, the first terminal and the Bluetooth device are in a call state through the HSP connection, and the second terminal has an incoming call. .
  • FIG. 12 is a schematic diagram of the working process of the Bluetooth device on the first terminal in the second embodiment and the second terminal in the second terminal. As shown in FIG. 12, the working process of the Bluetooth device on the first terminal in the second embodiment and the incoming call on the second terminal includes The following steps.
  • step 1201 the Bluetooth device receives the notification.
  • step 1202 it is checked whether the Bluetooth device is in the HSP connection. If the Bluetooth device is in the HSP connection, step 1204 is performed. If the Bluetooth device is not in the HSP connection, step 1203 is performed.
  • step 1203 a connection status report is sent to the second terminal, indicating that the Bluetooth device is in the HSP unconnected state, and the current processing flow is ended.
  • step 1204 it is determined whether the Bluetooth device is in a call state. If the Bluetooth device is in a call state, step 1206 is performed. If the Bluetooth device is not in a call state, step 1205 is performed.
  • step 1205 the current connection between the Bluetooth device and the first terminal is disconnected, and a connection status report is sent to the second terminal, indicating that the Bluetooth device is in the unconnected state of the HSP, and the current processing flow is ended.
  • step 1206 the Bluetooth device interface is invoked to notify the user.
  • step 1207 an instruction is received to determine whether to change the Bluetooth device status. If the Bluetooth device status is changed, step 1209 is performed. If the Bluetooth device status is not changed, step 1208 is performed.
  • step 1208 the connection between the Bluetooth device and the first terminal is maintained, and a connection status report is sent to the second terminal, indicating that the Bluetooth device is in an HSP connection and in a call state, and the current processing flow is ended.
  • step 1209 the connection between the Bluetooth device and the first terminal is disconnected, and a connection status report is sent to the second terminal, indicating that the Bluetooth device is in an unconnected state of the HSP.
  • FIG. 13 is a schematic diagram of a process of determining a connection status report after the first terminal calls the second terminal in the second embodiment, and as shown in FIG. 13, the first terminal in the second embodiment and the second terminal calls the terminal.
  • the judgment process includes the following steps.
  • step 1301 the second terminal receives a connection status report sent by the Bluetooth device.
  • step 1302 the second terminal determines the connection status of the Bluetooth device in the received connection status report. If the connection status report indicates that the Bluetooth device is in the HSP connection state, step 1303 is performed. If the connection status report indicates that the Bluetooth device is in the HSP unconnected state. Go to step 1304.
  • step 1303 the process exits and the process flow ends.
  • step 1304 the second terminal interface is invoked to initiate an HSP connection to the Bluetooth device.
  • step 1305 it is determined whether the second terminal establishes a connection with the Bluetooth device. If the second terminal establishes a connection with the Bluetooth device, step 1306 is performed. If the second terminal fails to establish a connection with the Bluetooth device, step 1302 is performed.
  • step 1306 the incoming call of the second terminal is answered using the Bluetooth device.
  • the HSP connection in the second embodiment can also be replaced by an HFP connection.
  • the terminal side judgment process when the second terminal and the third terminal simultaneously call includes the following steps.
  • step 1401 priority is set for all terminals of the user, the priority is saved in the Bluetooth device, and the second terminal and the third terminal simultaneously detect the incoming call operation.
  • step 1402 it is checked whether the second terminal and the third terminal are connected to the Bluetooth device respectively. If at least one of the second terminal and the third terminal is connected to the Bluetooth device, step 1404 is performed, if both the second terminal and the third terminal are If it is not connected to the Bluetooth device, go to step 1403.
  • the connection may include a Ble connection, an HSP connection, or an HFP connection.
  • step 1403 the second terminal and the third terminal respectively answer the incoming call, and the current processing flow is ended.
  • step 1404 it is checked whether the terminal connected to the Bluetooth device is in an HSP connection, if with the blue The terminal connected to the dental device is in the HSP connection, and step 1405 is performed. If the second terminal and the third terminal are not in the HSP connection, step 1406 is performed.
  • step 1405 the second terminal in the HSP connection establishes an HSP connection with the Bluetooth device, and the third terminal sends a notification message indicating that the terminal has an incoming call; the process flow ends.
  • step 1406 it is checked whether at least one of the second terminal and the third terminal is in a Ble connection with the Bluetooth device. If at least one of the second terminal and the third terminal is in the Ble connection, step 1407 is performed, if the second terminal and The third terminal is not in the Ble connection, and step 1403 is performed.
  • step 1407 it is checked whether the Bluetooth device that is connected to at least one of the second terminal and the third terminal supports the HSP connection, and if the Bluetooth device that maintains the Ble connection with at least one of the second terminal and the third terminal supports the HSP. To connect, go to step 1409. If the Bluetooth device that maintains the Ble connection with at least one of the second terminal and the third terminal does not support the HSP, step 1408 is performed.
  • step 1408 a connection error message is displayed, and the current processing flow is ended.
  • step 1409 the record of the second terminal and the record of the third terminal side are respectively updated, and the notification message is respectively sent by the second terminal and the third terminal.
  • the method may further include: all the terminals of the user are paired with the Bluetooth device, establish a Ble connection, and maintain a Ble connection, and the first terminal and the Bluetooth device are in a state of maintaining a call through the HSP connection, and the second terminal and the third terminal are The terminal has an incoming call at the same time.
  • FIG. 15 is a schematic diagram of the working process of the Bluetooth device on the first terminal in the case of setting the terminal priority in the third embodiment, and the second terminal and the third terminal simultaneously calling, as shown in FIG.
  • the Bluetooth device side working process includes the following steps when the second terminal and the third terminal simultaneously call.
  • step 1501 the Bluetooth device receives the notification message.
  • step 1502 it is checked whether the Bluetooth device is in the HSP connection. If the Bluetooth device is in the HSP connection, step 1504 is performed. If the Bluetooth device is not in the HSP connection, step 1503 is performed.
  • a connection status report is sent to the terminal with high priority among the second terminal and the third terminal, indicating that the Bluetooth device is in the HSP unconnected state, and the connection state is sent to the terminal with the lower priority among the second terminal and the third terminal.
  • the report indicates that the Bluetooth device is in the HSP connection state and ends the processing flow.
  • step 1504 it is determined whether the Bluetooth device is in a call state, if the Bluetooth device is in a call If yes, go to step 1506. If the Bluetooth device is not in the call state, go to step 1505.
  • step 1505 the current connection between the Bluetooth device and the first terminal is disconnected, and a connection status report is sent to the terminal with high priority among the second terminal and the third terminal, indicating that the Bluetooth device is in the unconnected state of the HSP, and the second terminal is The terminal with a lower priority in the third terminal sends a connection status report, indicating that the Bluetooth device is in the HSP connection state, and the current processing flow is ended.
  • step 1506 the Bluetooth device interface is invoked to notify the user.
  • step 1507 it is determined whether the current call terminal is the terminal with the highest priority. If the current call terminal is the terminal with the highest priority, step 1508 is performed. If the current call terminal is not the terminal with the highest priority, step 1509 is performed.
  • step 1508 the current link is maintained, and a connection status report is sent to the remaining terminals, indicating that the Bluetooth device is in an HSP connection and in a call state, and the current processing flow is ended.
  • step 1509 the connection between the Bluetooth device and the first terminal is disconnected, and the connection status report is sent to the terminal with the highest priority, indicating that the Bluetooth device is in the unconnected state of the HSP, and the connection status report is sent to the remaining terminals, indicating that the Bluetooth device is in the HSP connection. status.
  • the user can set priorities for all terminals and record the priority of the terminal in the Bluetooth device.
  • the Bluetooth device When the Bluetooth device is connected to any terminal of the user and is in a call state, any other terminal, or any plurality of terminals simultaneously or When the call is made in sequence, the device can automatically select the terminal with the highest priority to enter the call state according to the above method, which reduces the operation steps of the user and avoids the user missing the important call.
  • FIG. 16 is a schematic diagram of a process of determining a connection status report after the first terminal is in a call, and the second terminal and the third terminal simultaneously receive a call when the second terminal and the third terminal simultaneously call in the third embodiment, as shown in FIG.
  • the terminal terminal receives the connection status report when the second terminal and the third terminal simultaneously call, and the determination process includes the following steps.
  • step 1601 the second terminal and the third terminal receive a connection status report.
  • the connection status report that the highest priority terminal can receive indicates that the Bluetooth device is in the unconnected state of the HSP.
  • the terminal with the highest priority can establish an HSP connection with the Bluetooth device, use the Bluetooth device to make a call, and the connection status report received by the remaining terminals.
  • the Bluetooth device is in the HSP connection state, and the remaining terminals cannot establish an HSP connection with the Bluetooth device.
  • step 1602 the terminal (the terminal with higher priority among the second terminal and the third terminal) determines that the connection status of the Bluetooth device in the connection status report is. If the connection status report indicates that the Bluetooth device is in the HSP connection state, step 1603 is performed. If the connection status report indicates that the Bluetooth device is in the HSP unconnected state, step 1604 is performed.
  • step 1603 the process exits and the process flow ends.
  • the received connection status report is that the terminal in which the Bluetooth device is in the HSP unconnected state initiates an HSP connection to the Bluetooth device, and the incoming call of the remaining terminal is completed by the incoming call terminal.
  • step 1605 it is determined whether the terminal establishes a connection with the Bluetooth device. If the terminal establishes a connection with the Bluetooth device, step 1606 is performed. If the terminal fails to establish a connection with the Bluetooth device, step 1602 is performed.
  • step 1606 the answering call is completed using the Bluetooth device.
  • the HSP connection in the third embodiment can also be replaced by an HFP connection.
  • FIG. 17 is a schematic diagram of the process of determining the terminal side when the first terminal is in a call and the second terminal and the third terminal are in the same time in the fourth embodiment.
  • the first terminal in the fourth embodiment calls the second terminal and the third terminal.
  • the terminal side judgment process when the terminal simultaneously calls includes the following steps.
  • step 1701 the second terminal and the third terminal simultaneously detect an incoming call operation.
  • step 1702 it is checked whether at least one of the second terminal and the third terminal is connected to the Bluetooth device, and if at least one of the second terminal and the third terminal is connected to the Bluetooth device, step 1704 is performed, if the second terminal and The third terminal is not connected to the Bluetooth device, and step 1703 is performed.
  • the connection may include a Ble connection, an HSP connection, or an HFP connection.
  • step 1703 the second terminal and the third terminal respectively answer the incoming call, and the current processing flow is ended.
  • step 1704 it is checked whether at least one of the second terminal and the third terminal is in an HSP connection. If at least one of the second terminal and the third terminal is in an HSP connection, step 1705 is performed, if the second terminal and the third terminal are None of them are in the HSP connection, and step 1706 is performed.
  • step 1705 the terminal connected to the HSP and the Bluetooth device establish an HSP connection; the remaining terminal sends a notification message indicating that the terminal has an incoming call; the process flow ends.
  • step 1706 it is checked whether at least one of the second terminal and the third terminal is in the Ble connection. If at least one of the second terminal and the third terminal is in the Ble connection, step 1707 is performed, if the second terminal and the third terminal are None of them are in the Ble connection, and step 1703 is performed.
  • step 1707 it is checked whether the Bluetooth device that maintains the Ble connection with at least one of the second terminal and the third terminal supports the HSP connection, and if the Bluetooth device that maintains the Ble connection with at least one of the second terminal and the third terminal supports the HSP To connect, step 1709 is performed. If the Bluetooth device that maintains the Ble connection with at least one of the second terminal and the third terminal does not support the HSP connection, step 1708 is performed.
  • step 1708 a connection error message is displayed, and the current processing flow is ended.
  • step 1709 the records of the second terminal and the third terminal are updated, and the notification message is sent by the second terminal and the third terminal.
  • the method further includes: establishing, by the user, all the terminals and the Bluetooth device, and maintaining the Ble connection, the first terminal is maintaining the call state by using the HSP connection or the HFP connection, and the second terminal and the third terminal simultaneously have the incoming call.
  • FIG. 18 is a schematic diagram of the working process of the Bluetooth device on the first terminal in the fourth embodiment, and the second terminal and the third terminal simultaneously call, as shown in FIG. 18, the first terminal in the fourth embodiment, and the second terminal and the third terminal
  • the Bluetooth device side working process when the terminal simultaneously calls includes the following steps.
  • step 1801 the Bluetooth device receives the notification message.
  • step 1802 it is checked whether the Bluetooth device is in the HSP connection. If the Bluetooth device is in the HSP connection, step 1804 is performed. If the Bluetooth device is not in the HSP connection, step 1803 is performed.
  • step 1803 the connection status report is sent to the terminal with the highest priority, indicating that the Bluetooth device is in the HSP unconnected state; the connection status report is sent to the remaining terminals, indicating that the Bluetooth device is in the HSP connection state, and the current processing flow is ended.
  • step 1804 it is determined whether the Bluetooth device is in a call state. If the Bluetooth device is in a call state, step 1806 is performed. If the Bluetooth device is not in a call state, step 1805 is performed.
  • step 1805 the connection between the Bluetooth device and the first terminal is disconnected, and the connection status report is sent to the selected terminal, indicating that the Bluetooth device is in the unconnected state of the HSP, and the connection status report is sent to the remaining terminals, indicating that the Bluetooth device is in the HSP connection state. .
  • step 1806 the Bluetooth device interface is invoked to notify the user.
  • step 1807 it is determined whether to change the Bluetooth device connection status. If the Bluetooth device connection status is not changed, step 1808 is performed, and if the Bluetooth device connection status is changed, step 1809 is performed.
  • step 1808 the current link is maintained, and a connection status report is sent to the remaining terminals, indicating that the Bluetooth device is in an HSP connection and in a call state, and the current processing flow is ended.
  • step 1809 the connection between the Bluetooth device and the first terminal is disconnected, and the connection status report is sent to the terminal that is selected to talk, indicating that the Bluetooth device is in the unconnected state of the HSP, and the connection status report is sent to the remaining terminals, indicating that the Bluetooth device is in the HSP connection. status.
  • the Bluetooth device When the Bluetooth device is connected to any terminal of the user and is in a call state, when any other terminal, or any plurality of terminals call simultaneously or sequentially, the above device may select any one terminal to enter the call by using a user instruction according to the above method.
  • the state prevents users from missing important calls.
  • FIG. 19 is a schematic diagram of a process of determining a connection status report when the first terminal and the third terminal simultaneously call each other in the fourth embodiment, and as shown in FIG. 19, the first terminal in the fourth embodiment is in a call.
  • the terminal side receives the connection status report, and the determining process includes the following steps.
  • step 1901 the second terminal and the third terminal receive a connection status report.
  • the connection status report received by the terminal selected by the second terminal and the third terminal may indicate that the Bluetooth device is in the HSP unconnected state, and the terminal selected to make the call may establish an HSP connection with the Bluetooth device, and use the Bluetooth device to make a call, and the remaining terminal
  • the received connection status report indicates that the Bluetooth device is in the HSP connection state, and the remaining terminals may not establish an HSP connection with the Bluetooth device.
  • the user selects the terminal that is using the Bluetooth device to talk and keeps the call state unchanged.
  • the connection status report received by the remaining terminal indicates that the Bluetooth device is in the HSP connection state, and the remaining terminals may not establish an HSP connection with the Bluetooth device.
  • step 1902 the terminal (the terminal selected to be in the second terminal and the third terminal) determines the connection status of the Bluetooth device in the connection status report. If the connection status report indicates that the Bluetooth device is in the HSP connection state, step 1903 is performed. The connection status report indicates that the Bluetooth device is in the HSP unconnected state, and step 1904 is performed.
  • step 1903 the process exits and the process flow ends.
  • the received connection status report is that the Bluetooth device is in the HSP unconnected state.
  • the terminal initiates an HSP connection to the Bluetooth device, and the incoming call of the remaining terminal is answered by the incoming call terminal.
  • step 1905 it is determined whether the terminal establishes a connection with the Bluetooth device. If the terminal establishes a connection with the Bluetooth device, step 1906 is performed. If the terminal fails to establish a connection with the Bluetooth device, step 1902 is performed.
  • step 1906 the Bluetooth device is used to answer the call.
  • the HSP connection in the above fourth embodiment can also be replaced by an HFP connection.
  • FIG. 20 is a schematic diagram of the terminal side determining process when the first terminal detects the audio playing operation in the fifth embodiment. As shown in FIG. 20, the terminal side determining process includes the following steps when the first terminal detects the audio playing operation in the fifth embodiment.
  • step 2001 the first terminal detects an audio playback operation.
  • step 2002 it is checked whether the first terminal is connected to the Bluetooth device. If the first terminal is connected to the Bluetooth device, step 2004 is performed. If the first terminal is not connected to the Bluetooth device, step 2003 is performed.
  • the connection between the first terminal and the Bluetooth device may include: a Ble connection and an A2DP connection.
  • step 2003 the audio is played by the first terminal, and the current processing flow is ended.
  • step 2004, it is checked whether the first terminal is in the A2DP connection. If the first terminal is in the A2DP connection, step 2005 is performed. If the first terminal is not in the A2DP connection, step 2006 is performed.
  • step 2005 the Bluetooth device plays the audio and ends the processing flow.
  • step 2006 it is checked whether the first terminal is in the Ble connection. If the first terminal is in the Ble connection, step 2007 is performed. If the first terminal is not in the Ble connection, step 2003 is performed.
  • step 2007 it is checked whether the Bluetooth device that is connected to the terminal to support the Ble supports the A2DP connection. If the Bluetooth device that is connected to the terminal to support the Ble supports the A2DP connection, step 2009 is performed. If the Bluetooth device that maintains the Ble connection with the terminal does not support the A2DP connection, Perform step 2008.
  • step 2008 a connection error message is displayed, and the processing flow is ended.
  • step 2009 the record on the first terminal side is updated and a notification message is sent.
  • the user can obtain at least one of the audio information stored in the Bluetooth device playing terminal, the stored video information, the received audio information, and the received video information through the A2DP connection.
  • FIG. 21 is a schematic diagram of the working process of the Bluetooth device side when the first terminal detects the audio playing operation in the fifth embodiment. As shown in FIG. 21, the working process of the Bluetooth device side when the first terminal detects the audio playing operation in the fifth embodiment includes the following steps. .
  • step 2101 the Bluetooth device receives the notification message.
  • step 2102 it is checked whether the Bluetooth device is in the A2DP connection. If the Bluetooth device is in the A2DP connection, step 2104 is performed. If the Bluetooth device is not in the A2DP connection, step 2103 is performed.
  • step 2103 the connection status report is sent to the first device, indicating that the Bluetooth device is in the A2DP unconnected state, and the current processing flow is ended.
  • step 2104 it is determined whether the Bluetooth device is in the audio playing state. If the Bluetooth device is in the audio playing state, step 2106 is performed, and if the Bluetooth device is not in the audio playing state, step 2105 is performed.
  • step 2105 the current A2DP connection is disconnected, and a connection status report is sent to the first terminal, indicating that the Bluetooth device is in the A2DP unconnected state, and the current processing flow is ended.
  • step 2106 the Bluetooth device interface is invoked to notify the user.
  • step 2107 an instruction is received to determine whether to change the Bluetooth device connection status. If the Bluetooth device connection status is changed, step 2109 is performed. If the Bluetooth device connection status is not changed, step 2108 is performed.
  • step 2108 the current Bluetooth device connection status is maintained, and a connection status report is sent to the first terminal, indicating that the Bluetooth device is in the A2DP connection used state, or the Bluetooth device is in the A2DP connection unused state, and the process is terminated.
  • step 2109 the current connection is disconnected, and a connection status report is sent to the first terminal, indicating that the Bluetooth device is in the A2DP unconnected state.
  • Figure 22 is a schematic diagram of the process of determining the connection status report received by the terminal side when the first terminal detects the audio playback operation in the fifth embodiment, as shown in Figure 22, when the first terminal detects the audio playback operation in the fifth embodiment, the terminal side receives the audio playback operation.
  • the connection status report determination process includes the following steps.
  • step 2201 the first terminal receives a connection status report sent by the Bluetooth device.
  • step 2202 the first terminal determines the connection status of the Bluetooth device in the connection status report. If the connection status report indicates that the Bluetooth device is in the A2DP connection state, step 2203 is performed, if the connection is The status report indicates that the Bluetooth device is in the A2DP unconnected state, and step 2204 is performed.
  • step 2203 the process is exited and the process flow is ended.
  • step 2204 the first terminal interface is invoked to initiate an A2DP connection to the Bluetooth device.
  • step 2205 it is determined whether the first terminal establishes an A2DP connection with the Bluetooth device. If the terminal establishes an A2DP connection with the Bluetooth device, step 2206 is performed. If the terminal fails to establish an A2DP connection with the Bluetooth device, step 2202 is performed.
  • step 2206 the audio is played using a Bluetooth device.
  • the processing method and processing flow of the switching may adopt the processing methods of Embodiment 2 to Embodiment 5 described above.
  • the Bluetooth device can select according to the detected connection status and the set priority.
  • the Bluetooth device can include a car Bluetooth device and a Bluetooth headset.
  • the embodiment provides a system for connecting a terminal to a Bluetooth device, and the system includes a Bluetooth device and at least two terminals.
  • the at least two terminals are configured to establish and maintain a Ble connection with the Bluetooth device; detecting an operation that triggers a change in its own state; and detecting a triggering operation of the change in its own state, sending a notification message to the Bluetooth device; receiving the Bluetooth device Connecting a status report and initiating a connection request to the Bluetooth device according to the received connection status report, wherein the connection request indicates that the terminal requests to establish a Bluetooth communication connection with the Bluetooth device.
  • the Bluetooth device is configured to establish and maintain a Ble connection with two or more terminals; receive a notification message, detect a connection state in which it is located, and send a connection status report to the terminal according to the detected connection status and a notification message.
  • the Bluetooth device is further configured to perform one of the following operations:
  • the present embodiment provides a terminal, where the terminal includes a first processor 230, where the first processor is configured to establish and maintain a connection between the terminal and the Bluetooth device; and detect an operation that triggers a change in the state of the terminal; Transmitting a notification message to the Bluetooth device; receiving a connection status report of the Bluetooth device, and initiating a connection request to the Bluetooth device according to the received connection status report, the connection request is used to indicate that the terminal requests
  • the Bluetooth device establishes a non-low power Bluetooth communication connection.
  • the terminal provided in the foregoing embodiment may further include:
  • the first processor 230, the first memory 231, and the first communication interface 232 can complete communication with each other through the first bus 233.
  • the first communication interface 232 can transmit information.
  • the first processor 230 can invoke logic instructions in the first memory 231 to perform the method performed by the terminal in the above embodiments.
  • logic instructions in the first memory 231 described above may be implemented in the form of a software functional unit and sold or used as a stand-alone product, and may be stored in a computer readable storage medium.
  • the first memory 231 is used as a computer readable storage medium, and can be used to store a software program, a computer executable program, a program instruction or a module corresponding to the method in the above embodiment.
  • the first processor 230 executes the function application and the data processing by executing a software program, an instruction or a module stored in the first memory 231, that is, the method executed by the terminal in the above embodiment.
  • the first memory 231 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function; the storage data area may store data created according to usage of the terminal, and the like. Further, the first memory 231 may include a high speed random access memory, and may further include a nonvolatile memory.
  • the embodiment provides a Bluetooth device, where the Bluetooth device includes a second processor 240, and the second processor is configured to establish and maintain a Ble connection between the Bluetooth device and the terminal; receive a notification message, and detect a connection state of the Bluetooth device. And sending a connection status report to the terminal according to the detected connection status and the notification message.
  • the Bluetooth device can be set to perform one of the following operations:
  • the Bluetooth device in the foregoing embodiment may further include:
  • the second memory 241 may further include a second communication interface 242 and a second bus 243.
  • the second processor 240, the second memory 241, and the second communication interface 242 can complete communication with each other through the second bus 243.
  • the second communication interface 242 can transmit information.
  • the second processor 240 can invoke the logic instructions in the second memory 241 to perform the method performed by the Bluetooth device in the above embodiments.
  • logic instructions in the second memory 241 described above may be implemented in the form of a software functional unit and sold or used as a stand-alone product, and may be stored in a computer readable storage medium.
  • the second memory 241 is used as a computer readable storage medium, and can be used to store a software program, a computer executable program, a program instruction or a module corresponding to the method executed by the Bluetooth device in the above embodiment.
  • the second processor 240 executes the function application and the data processing by executing the software program, the instruction or the module stored in the second memory 241, that is, the method performed by the Bluetooth device in the above embodiment.
  • the second memory 241 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function; the storage data area may store data created according to usage of the terminal, and the like. Further, the second memory 241 may include a high speed random access memory, and may also include a nonvolatile memory.
  • the embodiment further provides a computer readable storage medium storing computer executable instructions arranged to perform the method of any of the above embodiments.
  • the technical solution in the above embodiments may be embodied in the form of a software product stored in a storage medium, including one or more instructions for causing a computer device (which may be a personal computer, a server, or a network) The device or the like) performs all or part of the steps of the method described in the above embodiments.
  • the foregoing storage medium may be a non-transitory storage medium, including: a USB flash drive, a mobile hard disk, a read-only memory (ROM), and a random access memory (Random Access).
  • a medium that can store program code such as a memory, a RAM, or an optical disk, or a transient storage medium.
  • a method, apparatus, system and device for connecting a Bluetooth device enable at least two terminals to be simultaneously connected to a Bluetooth device.

Landscapes

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

Abstract

一种连接蓝牙设备的方法、装置、系统及设备,其中,所述方法包括:两个以上终端与蓝牙设备建立并保持蓝牙低功耗Ble连接;两个以上终端中的至少一个终端检测到触发自身状态发生变化的操作时,向蓝牙设备发送通知消息;两个以上终端中的至少一个终端接收蓝牙设备发送的连接状态报告,并根据接收到的连接状态报,在保持Ble连接的基础上,向蓝牙设备发送连接请求建立蓝牙通信连接,连接请求表示两个以上终端中的至少一个终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。

Description

连接蓝牙设备的方法、装置、系统及设备 技术领域
本公开涉及无线通信领域中的蓝牙通信技术,例如涉及一种连接蓝牙设备的方法、装置、系统及设备。
背景技术
相关技术中,蓝牙设备如蓝牙耳机或者车载蓝牙设备,可与移动终端如手机连接,完成接听电话的功能。如果蓝牙耳机或者车载蓝牙设备使用蓝牙手机规格(HSP,Headset Profile)协议或蓝牙免提规格(HFP,Hands Free Profile)协议连接,在一个时刻,一个蓝牙耳机或者车载蓝牙设备只能与一部手机连接;新的HFP协议可以支持一个耳机或者车载蓝牙设备一个时刻连接两部手机,但是,只能在一部手机来电(不是同时)时,使用支持新的HFP协议的蓝牙耳机或者车载蓝牙设备接听来电;而不能在两部手机同时来电时进行选择接听。如果两部手机同时来电,相关技术中,只能通知到耳机或者车载蓝牙设备。对于不支持新的HFP协议的手机、蓝牙耳机或者车载蓝牙设备中所使用的蓝牙芯片,则无法支持多部手机与蓝牙耳机或者车载蓝牙设备同时连接。
相关技术中,当用户使用两部以上的手机时,车载蓝牙设备不能保证与用户的每一部手机都保持连接,更不能保证用户使用车载蓝牙设备时选择性地接听手机来电。
发明内容
一种终端连接蓝牙设备的方法、装置、系统及设备,能够使得至少两个终端同时与蓝牙设备连接及使用。
一种连接蓝牙设备的方法,包括:
两个以上终端与蓝牙设备建立并保持蓝牙低功耗Ble连接;
所述两个以上终端中的至少一个终端检测到触发自身状态发生变化的操作时,向所述蓝牙设备发送通知消息;以及
所述两个以上终端中的至少一个终端接收所述蓝牙设备发送的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求,建立蓝牙通信连接,其中,所述连接请求用于表示终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
可选的,所述检测到触发自身状态发生变化的操作包括以下之一:
终端检测到来电的操作;
终端检测到拨打电话的操作;以及
终端检测到挂断电话的操作。
可选的,所述检测到触发自身状态发生变化的操作还包括以下之一:
终端检测到播放音频的操作;以及
终端检测到停止播放音频的操作。
可选的,发送通知消息包括以下之一:
发送通信连接的消息;以及
发送结束通信连接的消息。
可选的,所述发送通知消息包括以下之一:
发送音频播放的消息;以及
发送停止音频播放的消息。
可选的,所述根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下之一:
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立蓝牙免提规格HFP连接的请求;
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立蓝牙手机规格HSP连接的请求;
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HSP连接仅 保留Ble连接的请求。
可选的,所述根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下之一:
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立高质量音频分发规范A2DP连接的请求;以及
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开A2DP连接仅保留Ble连接的请求。
可选的,所述两个以上终端中的至少一个终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接包括以下之一:
两个以上终端中的至少一个终端请求与蓝牙设备建立HSP连接;
两个以上终端中的至少一个终端请求与蓝牙设备建立HFP连接;以及
两个以上终端中的至少一个终端请求与蓝牙设备建立A2DP连接。
一种连接终端的方法,包括:
蓝牙设备与两个以上终端建立并保持Ble连接;以及
蓝牙设备接收通知消息,检测自身的连接状态,根据检测到的连接状态及通知消息向所述两个以上终端中的至少一个终端发送连接状态报告。
可选的,所述的方法,其中,所述蓝牙设备自身的连接状态包括以下之一:
处于HFP未连接状态;
处于HSP未连接状态;
处于HFP连接但未通话状态;
处于HSP连接但未通话;
处于HFP连接且通话状态;以及
处于HSP连接且通话状态。
可选的,所述的方法,其中,所述蓝牙设备自身的连接状态包括以下之一:
处于A2DP未连接状态;
处于A2DP连接已使用状态;以及
处于A2DP连接未使用状态。
可选的,所述的方法,其中,所述蓝牙设备的连接状态报告包括以下之一:
蓝牙设备处于HFP连接的连接状态;
蓝牙设备处于HSP连接的连接状态;以及
蓝牙设备处于A2DP连接的连接状态。
可选的,所述的方法,还包括以下操作之一:
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连接或HFP连接;以及
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
可选的,所述的方法,还包括:在保持Ble连接的基础上,所述蓝牙设备接收所述两个以上终端中的至少一个终端根据所述连接状态报告向所述蓝牙设备发起的连接请求,蓝牙设备响应所述连接请求,与所述两个以上终端中的至少一个终端建立非低功耗蓝牙通信连接;其中,所述连接请求表示所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
可选的,在保持Ble连接的基础上,所述蓝牙设备接收所述两个以上终端中的至少一个终端根据所述连接状态报告向所述蓝牙设备发起的连接请求包括以下之一:
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立HFP连接的请求;
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立HSP连接的请求;
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
可选的,在保持Ble连接的基础上,所述蓝牙设备接收所述两个以上终端中 的至少一个终端根据所述连接状态报告向所述蓝牙设备发起的连接请求包括以下之一:
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立A2DP连接的请求;以及
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开A2DP连接切仅保留Ble连接的请求。
可选的,所述的方法,还包括以下之一:
在保持Ble连接的基础上,所述蓝牙设备从处于HFP连接且通话状态切换为HFP未连接的状态;
在保持Ble连接的基础上,所述蓝牙设备从处于HSP连接且通话状态切换为HSP未连接的状态;
在保持Ble连接的基础上,所述蓝牙设备从处于HFP连接且通话状态切换为处于HFP连接但未通话的状态;
在保持Ble连接的基础上,所述蓝牙设备从处于HSP连接且通话状态切换为处于HSP连接但未通话的状态;
在保持Ble连接的基础上,所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP未连接的状态;以及
在保持Ble连接的基础上,所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP连接未使用的状态。
可选的,所述蓝牙设备响应所述连接请求,与所述两个以上终端中的至少一个终端建立非低功耗蓝牙通信连接包括以下之一:
蓝牙设备与两个以上终端中的至少一个终端建立HSP连接;
蓝牙设备与两个以上终端中的至少一个终端建立HFP连接;以及
蓝牙设备与两个以上终端中的至少一个终端建立A2DP连接。
一种连接蓝牙设备的装置,包括:连接模块、检测模块以及收发模块,其中,
所述连接模块设置为建立并保持终端与蓝牙设备的Ble连接;根据接收到的 连接状态报告向所述蓝牙设备发起连接请求,其中,所述连接请求用于表示终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接;
所述检测模块设置为检测触发终端状态发生变化的操作;以及
所述收发模块设置为检测到触发终端状态发生变化的操作时,向蓝牙设备发送通知消息,以及接收蓝牙设备的连接状态报告。
可选的,所述检测模块检测触发终端状态发生变化的操作包括以下之一:
检测到来电的操作;
检测到拨打电话的操作;以及
检测到挂断电话的操作。
可选的,所述检测模块检测触发终端状态发生变化的操作包括以下之一:
检测到播放音频的操作;以及
检测到停止播放音频的操作。
可选的,所述向蓝牙设备发送的通知消息包括以下之一:
音频播放的消息;以及
停止音频播放的消息。
可选的,所述连接状态报告包括以下之一:
蓝牙设备处于HFP连接的连接状态;
蓝牙设备处于HSP连接的连接状态;以及
蓝牙设备处于A2DP连接的连接状态。
可选的,所述收发模块在保持Ble连接的基础上,向蓝牙设备发起以下任意一种连接请求:
发起与所述蓝牙设备建立HFP连接的请求;
发起与所述蓝牙设备建立HSP连接的请求;
发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
可选的,所述收发模块在保持Ble连接的基础上,向蓝牙设备发起以下任意一种连接请求:
发起与所述蓝牙设备建立A2DP连接的请求;以及
发起与所述蓝牙设备断开A2DP连接仅保留Ble连接的请求。
可选的,所述建立非低功耗蓝牙通信连接包括以下之一:
与蓝牙设备建立HSP连接;
与蓝牙设备建立HFP连接;以及
与蓝牙设备建立A2DP连接。
可选的,所述终端支持Ble连接,且支持HSP连接、HFP连接、以及A2DP连接中的至少一种连接。
一种连接终端的装置,包括:连接模块、检测模块以及收发模块,其中,
所述连接模块设置为建立并保持蓝牙设备与两个以上终端的Ble连接;
所述检测模块设置为检测蓝牙设备的连接状态报告;以及
所述收发模块设置为接收通知消息,以及根据检测到的连接状态及通知消息向两个以上终端中的至少一个终端发送连接状态报告。
可选的,所述检测模块检测到蓝牙设备处于以下任意一种连接状态:
处于HFP未连接;
处于HSP未连接
处于HFP连接但未通话;
处于HSP连接但未通话;
处于HFP连接且通话;以及
处于HSP连接且通话。
可选的,所述检测模块检测到蓝牙设备处于以下任意选一种连接状态:
处于A2DP未连接;
处于A2DP连接已使用;以及
处于A2DP连接未使用。
可选的,所述连接状态报告包括以下之一:
蓝牙设备处于HFP连接的连接状态;
蓝牙设备处于HSP连接的连接状态;以及
蓝牙设备处于A2DP连接的连接状态。
可选的,所述连接模块还设置为执行以下操作之一:
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连接;
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HFP连接;以及
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
可选的,所述收发模块还设置为在保持Ble连接的基础上,接收终端发起的连接请求,响应所述连接请求,与所述两个以上终端中的至少一个终端建立非低功耗蓝牙通信连接;其中,所述连接请求表示终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
可选的,所述在保持Ble连接的基础上,接收终端发起的连接请求包括以下之一:
终端发起与所述蓝牙设备建立HFP连接的请求;
终端发起与所述蓝牙设备建立HSP连接的请求;
终端发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
终端发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
可选的,所述在保持Ble连接的基础上,接收终端发起的连接请求包括以下之一:
终端发起与所述蓝牙设备建立A2DP连接的请求;以及
终端发起与所述蓝牙设备断开A2DP连接仅保留Ble连接请求。
可选的,所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接包括以下之一:
所述终端请求与所述蓝牙设备建立HSP连接;
所述终端请求与所述蓝牙设备建立HFP连接;以及
所述终端请求与所述蓝牙设备建立A2DP连接。
可选的,所述的装置,还包括切换模块,设置为执行以下操作之一:
在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为HFP未连接的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为HSP未连接的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为处于HFP连接但未通话的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为处于HSP连接但未通话的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP未连接的状态;以及
在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP连接未使用的状态。
一种连接蓝牙设备的系统,包括蓝牙设备与至少两个终端;其中,
所述至少两个终端中的每个终端设置为建立并保持自身与蓝牙设备的Ble连接;检测触发自身状态发生变化的操作;检测到触发自身状态发生变化的操作时,向蓝牙设备发送通知消息;接收蓝牙设备的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求,建立蓝牙通信连接,所述连接请求表示所述终端请求与所述蓝牙设备建立蓝牙通信连接;以及
所述蓝牙设备设置为建立并保持自身与两个以上终端的Ble连接;接收通知消息,检测自身所处的连接状态,根据检测到的连接状态及通知消息向终端发 送连接状态报告。
可选的,所述检测触发自身状态发生变化的操作包括以下之一:
检测到来电的操作;
检测到拨打电话的操作;以及
检测到挂断电话的操作。
可选的,所述检测触发自身状态发生变化的操作包括以下之一:
检测到播放音频的操作;以及
检测到停止播放音频的操作。
可选的,所述检测自身所处的连接状态包括以下之一:
处于HFP未连接;
处于HSP未连接;
处于HFP连接但未通话;
处于HSP连接但未通话;
处于HFP连接且通话;以及
处于HSP连接且通话。
可选的,所述检测自身所处的连接状态包括以下之一:
处于A2DP未连接;
处于A2DP连接已使用;以及
处于A2DP连接未使用。
可选的,所述蓝牙设备的连接状态报告包括以下之一:
蓝牙设备处于HFP连接的连接状态;
蓝牙设备处于HSP连接的连接状态;以及
蓝牙设备处于A2DP连接的连接状态。
可选的,所述在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下任意一种请求:
发起与所述蓝牙设备建立HFP连接的请求;
发起与所述蓝牙设备建立HSP连接的请求;
发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求以及
发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
可选的,所述在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下任意一种请求:
发起与所述蓝牙设备建立A2DP连接的请求;
发起与所述蓝牙设备断开A2DP连接仅保留Ble连接。
可选的,所述建立蓝牙通信连接包括以下之一:
与所述蓝牙设备建立HSP连接;
与所述蓝牙设备建立HFP连接;以及
与所述蓝牙设备建立A2DP连接。
可选的,所述检测到的连接状态包括以下之一:
处于HFP未连接状态;
处于HSP未连接状态;
处于HFP连接但未通话状态;
处于HSP连接但未通话状态;
处于HFP连接且通话状态;以及
处于HSP连接且通话状态。
可选的,所述检测到的连接状态包括以下之一:
处于A2DP未连接状态;
处于A2DP连接已使用状态;
处于A2DP连接未使用状态。
可选的,所述蓝牙设备还设置为执行以下操作之一:
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连 接;
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HFP连接;以及
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
可选的,所述蓝牙设备还设置为执行以下操作之一:
在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为HFP未连接的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为HSP未连接的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为处于HFP连接但未通话的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为处于HSP连接但未通话的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP未连接的状态;以及
在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP连接未使用的状态。
一种终端,包括处理器,设置为建立并保持终端与蓝牙设备的Ble连接;检测触发终端状态发生变化的操作;检测到触发终端状态发生变化的操作时,向蓝牙设备发送通知消息;以及接收蓝牙设备的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求,建立蓝牙通信连接;其中,所述连接请求表示所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
一种蓝牙设备,包括处理器,设置为建立并保持蓝牙设备与终端的Ble连接;接收通知消息,检测蓝牙设备所处的连接状态,根据检测到的连接状态及通知消息向终端发送连接状态报告。
一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令设置为执行上述任一项的方法。
以上内容提供的终端连接蓝牙设备的方法、装置、系统及设备,建立并保持两个以上终端与蓝牙设备的低耗(Ble)连接;两个以上终端中的至少一个终端检测到触发自身状态发生变化的操作时,发送通知消息给蓝牙设备;两个以上终端中的至少一个终端接收蓝牙设备发送的连接状态报告,并根据接收到的连接状态报告向所述蓝牙设备发起连接请求,建立蓝牙通信连接,所述连接请求表示所述两个以上终端中的至少一个终端请求与所述蓝牙设备建立蓝牙通信连接。
由于每个终端与蓝牙设备之间建立并保持有Ble连接,在有终端检测到来电时,终端向蓝牙设备发送通知消息,蓝牙设备向终端反馈自身的连接状态报告,比如是否已处于通话或使用、是否可以终端当前通话等,由终端根据收到的连接状态报告确定与蓝牙设备建立连接或断开连接,如此,就能实现两个终端同时与蓝牙设备连接,并保证终端来电的接听或使用终端的功能。
随着蓝牙设备功能的增强,当蓝牙设备支持选择功能时,也可以在终端检测到触发自身状态发生变化的操作,向蓝牙设备发送通知消息后,由蓝牙设备根据检测到的自身与每个终端的连接状态进行选择,确定是否接入新的来电或是否响应新的使用需求,确定后向相应终端发送控制命令,终端根据控制命令接入来电进入通话、或根据控制命令断开通话;或者,根据控制命令使用A2DP、或断开使用A2DP。
在不增加设备的基础上,可以完成两个以上终端与蓝牙设备的连接,并保证终端的能接听来电或使用终端的功能,成本低、实现简单,适用范围广。
还可以根据重要程度或使用需求为终端设置优先级,在第一个终端通话或使用过程中有第二个终端来电或需使用时,根据终端设置的优先级确定是否选择连接,可以更灵活地使用终端和蓝牙设备、符合用户的个性化需求。
附图说明
图1为一实施例中终端侧执行的连接蓝牙设备的方法的流程示意图;
图2为一实施例中连接蓝牙设备的装置的结构示意图;
图3为一实施例中连接终端的方法的流程示意图;
图4为一实施例中连接终端的装置的结构示意图;
图5为一实施例中终端侧判断过程示意图;
图6为一实施例中蓝牙设备侧工作过程示意图;
图7为一实施例中终端侧收到连接状态报告后的判断过程示意图;
图8为实施例一中第一终端来电时终端侧判断过程示意图;
图9为实施例一中第一终端来电时蓝牙设备侧工作过程示意图;
图10为实施例一中第一终端来电时终端侧收到连接状态报告后的判断过程示意图;
图11为实施例二中第一终端通话且第二终端来电时终端侧判断过程示意图;
图12为实施例二中第一终端通话且第二终端来电时蓝牙设备侧工作过程示意图;
图13为实施例二中第一终端通话且第二终端来电时终端侧收到连接状态报告后判断过程示意图;
图14为实施例三中在设置终端优先级情况下第一终端通话且第二终端和第三终端同时来电时终端侧判断过程示意图;
图15为实施例三中在设置终端优先级情况下第一终端通话且第二终端和第三终端同时来电时蓝牙设备侧工作过程示意图;
图16为实施例三中在设置终端优先级情况下第一终端通话且第二终端和第三终端同时来电时终端侧收到连接状态报告后判断过程示意图;
图17为实施例四中第一终端通话且第二终端和第三终端同时来电时终端侧判断过程示意图;
图18为实施例四中第一终端通话且第二终端和第三终端同时来电时蓝牙设备侧工作过程示意图;
图19为实施例四中第一终端通话且第二终端和第三终端同时来电时终端侧 收到连接状态报告后判断过程示意图;
图20为实施例五中第一终端检测到音频播放操作时终端侧判断过程示意图;
图21为实施例五中第一终端检测到音频播放操作时蓝牙设备侧工作过程示意图;
图22为实施例五中第一终端检测到音频播放操作时终端侧收到连接状态报告后判断过程示意图;以及
图23是一实施例提供的终端的硬件结构示意图;以及
图24是一实施例提供的蓝牙设备的硬件结构示意图。
具体实施方式
为了能够更加详尽地了解以下实施例的特点与技术内容,下面结合附图对以下实施例的实现进行详细阐述,所附附图仅供参考说明之用。
图1为本实施例中终端侧实现连接蓝牙设备的方法的流程示意图,如图1所示,本实施例中连接蓝牙设备的方法包括以下步骤。
在步骤101中,两个以上终端与蓝牙设备建立并保持蓝牙低功耗(Bluetooth Low Energy,Ble)连接。
终端包括具有通话功能和音频播放功能中至少一种功能的手机、平板或可穿戴的智能设备;蓝牙设备包括具有蓝牙通话功能和音频播放功能中至少一种功能的车载蓝牙设备或蓝牙耳机。建立Ble连接即两个以上终端与蓝牙设备之间通过Ble技术建立连接。
所述终端与蓝牙设备可以同时支持HSP连接和HFP连接中的至少一种以及Ble连接,或者终端与蓝牙设备可以同时支持Ble连接和高质量音频分发规范(A2DP,Advanced Audio Distribution Profile)连接。所述两个以上终端可以为小于或等于六个且大于或等于两个的终端。其中,HSP连接即通过HSP协议进行连接,HFP连接即通过HFP协议进行连接。
在步骤102中,两个以上终端中的至少一个终端检测到触发自身状态发生变化的操作时,向所述蓝牙设备发送通知消息。
所述检测到触发自身状态发生变化的操作可以包括:终端检测到来电的操作、终端检测到拨打电话的操作、终端检测到挂断电话的操作、终端检测到播放音频的操作或终端检测到停止播放音频的操作。
所述发送通知消息可以包括:发送通信连接的消息、发送结束通信连接的消息、发送音频播放的消息或停止音频播放的消息。
在步骤103中,终端接收蓝牙设备发送的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向蓝牙设备发送连接请求,建立蓝牙通信连接,所述连接请求表示终端请求与蓝牙设备建立非低功耗蓝牙通信连接。
所述根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求可以包括以下之一:
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立HFP连接的请求;
所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立HSP连接的请求;
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求;
所述两个以上终端中的至少一个终端发起与述蓝牙设备建立A2DP连接的请求;以及
所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开A2DP连接仅保留Ble连接的请求。
为实现图1所示的方法,本实施例提供了一种连接蓝牙设备的装置,如图2所示,本实施例中的连接蓝牙设备的装置包括:第一连接模块201、第一检测模块202和第一收发模块203。
所述第一连接模块201设置为建立并保持终端与蓝牙设备的Ble连接。
所述第一检测模块202设置为检测触发终端状态发生变化的操作。
所述第一收发模块203设置为检测到触发终端状态发生变化的操作时,向蓝牙设备发送通知消息;接收蓝牙设备的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求,建立蓝牙通信连接,所述连接请求表示所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
所述终端支持HSP、HFP连接和A2DP连接中的至少一种连接,且终端支持Ble连接。
所述第一收发模块203设置为在保持Ble连接的基础上,可以向蓝牙设备发起以下任意一种连接请求:
发起与所述蓝牙设备建立HFP连接的请求;
发起与所述蓝牙设备建立HSP连接的请求;
发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;
发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求;
发起与所述蓝牙设备建立A2DP连接的请求;以及
发起与所述蓝牙设备断开A2DP连接仅保留Ble连接的请求。
所述第一连接模块201、第一检测模块202和第一收发模块203可由位于终端上的中央处理器(CPU,Central Processing Unit)、微处理器(MPU,Micro Processor Unit)、数字信号处理器(DSP,Digital Signal Processor)、或现场可编程门阵列(FPGA,Field Programmable Gate Array)实现。
图3为本实施例中蓝牙设备侧实现连接蓝牙设备的方法的流程示意图,如图3所示,本实施例中蓝牙设备侧实现连接蓝牙设备的方法的流程包括以下步骤。
在步骤301中,蓝牙设备与两个以上终端建立并保持Ble连接。
在步骤302中,蓝牙设备接收通知消息,检测自身的连接状态,根据检测到的连接状态及通知消息向所述两个以上终端中的至少一个终端发送连接状态报告。
所述接收通知消息可以包括以下之一:
接收通信连接的消息;接收结束通信连接的消息、接收音频播放的消息以及接收停止音频播放的消息。
所述蓝牙设备的状态可以包括以下之一:处于HFP未连接、处于HSP未连接、处于HFP连接但未通话、处于HSP连接但未通话、处于HFP连接且通话以及处于HSP连接且通话;
处于A2DP未连接、处于A2DP连接已使用和处于A2DP连接未使用。
所述蓝牙设备的连接状态报告可以包括以下之一:蓝牙设备处于HFP连接的连接状态;蓝牙设备处于HSP连接的连接状态;以及蓝牙设备处于A2DP连接的连接状态。
为实现图3所示的方法,本实施例提供了一种连接终端的装置,如图4所示,本实施例中的连接终端的装置的包括:第二连接模块401、第二检测模块402和第二收发模块403。
所述第二连接模块401设置为建立并保持蓝牙设备与两个以上终端的Ble连接。
所述第二检测模块402设置为检测蓝牙设备的连接状态报告。
所述第二收发模块403设置为接收通知消息,以及根据检测到的连接状态及通知消息向两个以上终端中的至少一个终端发送连接状态报告。
所述蓝牙设备支持HSP连接、HFP连接以及A2DP连接中的至少一种,且蓝牙设备支持Ble连接。
所述第二检测模块402可设置为检测到蓝牙设备处于以下任意一种连接状态:
处于HFP未连接、处于HSP未连接、处于HFP连接但未通话、处于HSP连接但未通话、处于HFP连接且通话、处于HSP连接且通话、
处于A2DP未连接、处于A2DP连接已使用以及处于A2DP连接未使用。
所述第二收发模块403可以设置为根据检测到的连接状态及通知消息向终端发送连接状态报告。
所述蓝牙设备还可设置为执行以下操作之一:
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连接;
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HFP连接;以及
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
所述蓝牙设备还可设置为执行以下操作之一:
在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为HFP未连接的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为HSP未连接的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为处于HFP连接但未通话的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为处于HSP连接但未通话的状态;
在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP未连接的状态;以及
在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP连接未使用的状态。
所述第二连接模块401、检测模块402、第二收发模块403可由位于蓝牙设备上的CPU、MPU、DSP或FPGA实现。
图5为本实施例中终端侧判断过程示意图,如图5所示,本实施例中终端侧判断过程包括以下步骤。
在步骤501中,终端检测到触发自身状态发生变化的操作。
所述检测到触发自身状态发生变化的操作可以包括:终端检测到来电的操作、终端检测到拨打电话的操作、终端检测到挂断电话的操作终端检测到播放音频的操作、或终端检测到停止播放音频的操作。
在步骤502中,检查终端是否与蓝牙设备连接,如果终端与蓝牙设备连接,执行步骤504,如果终端未与蓝牙设备连接,执行步骤503。
所述连接可以包括:Ble连接、HSP连接、HFP连接、或者A2DP连接。
在步骤503中,通过终端完成操作,结束本次处理流程。
所述通过终端完成操作可以包括:通过终端完成接听电话、拨打电话、挂断电话、播放音频或停止播放音频。
在步骤504中,检查终端是否与蓝牙设备处于HSP连接、HFP连接或者A2DP连接,如果终端与蓝牙设备处于HSP连接、HFP连接或者A2DP连接,执行步骤505,如果终端未与蓝牙设备处于HSP连接、HFP连接以及A2DP连接中的任一种连接,执行步骤506。
终端与蓝牙设备之间的连接类型还可以是终端支持的HSP连接,可以检查终端与蓝牙设备之间是否处于HSP连接。
在步骤505中,蓝牙设备执行终端检测到的操作(如,终端检测到接听电话的操作时,蓝牙设备接听电话),结束本次处理流程。
在步骤506中,检查终端是否与蓝牙设备处于Ble连接,如果终端与蓝牙设备处于Ble连接,执行步骤507,如果终端未与蓝牙设备处于Ble连接,执行步骤503。
在步骤507中,检查与终端保持Ble连接的蓝牙设备是否支持HSP连接(或HFP连接),如果与终端保持Ble连接的蓝牙设备支持HSP连接(或HFP连接),执行步骤509,如果与终端保持Ble连接的蓝牙设备不支持HSP连接(或HFP连接),执行步骤508。
在步骤508中,显示连接错误信息,结束本次处理流程。
在步骤509中,终端更新终端侧的记录,并向蓝牙设备发送通知消息。
本实施例中,所述更新终端侧的记录,可以是将终端检测到触发自身状态发生变化的操作对应的事件记录在终端侧的应用层协议(profile)中,通过改变终端侧应用层协议(profile)中的蓝牙Ble协议中的蓝牙通用属性服务(Bluetooth Gatt Service)的特征对象(Characteristic)实现对记录的更新。
所述配置文件可以基于服务器属性和客户端属性(GATT Generic Attribute Profile),配置文件可以保证终端和蓝牙设备处于Ble连接的时候进行通信。终端侧作为服务器端(Server),蓝牙设备侧作为客户端(client),该profile的服务器(server)端,包含一个对象Bluetooth Gatt Service,所述Bluetooth Gatt Service可以包含两个Bluetooth Gatt Characteristic,其中一个Bluetooth Gatt Characteristic可以用于保存当前处于Ble连接状态的蓝牙设备中HFP、HSP、或A2DP的连接状态。
图6为本实施例中蓝牙设备侧工作过程示意图,如图6所示,本实施例中蓝牙设备侧判断过程包括以下步骤。
在步骤601中,蓝牙设备接收通知消息。
在步骤602中,检查蓝牙设备是否与终端处于HSP连接、HFP连接或者A2DP连接,如果蓝牙设备与终端处于上述所检查的连接类型,执行步骤604,如果蓝牙设备与终端未处于上述任一种连接,执行步骤603。
蓝牙设备可以根据终端发送的请求,获取终端支持的连接类型(如,HSP连接、HFP连接或者A2DP连接),如果请求与接打电话相关,步骤602中可以检查蓝牙设备是否与终端处于HFP连接或者HSP连接,如果请求与播放音乐有关,步骤602中可以检查蓝牙设备是否与终端处于A2DP连接。
在步骤603中,发送连接状态报告,说明蓝牙设备与终端处于所检查的连接类型未连接状态(如,HSP未连接状态、HFP未连接状态或者处于A2DP未连接状态),结束本次处理流程。
在步骤604中,判断蓝牙设备是否处在通话状态或者播放状态,如果蓝牙设备处在通话状态或者播放状态,执行步骤606,如果蓝牙设备未处在通话状态也未处在播放状态,执行步骤605。
在步骤605中,断开当前连接,发送连接状态报告,说明蓝牙设备处于所检查的连接类型未连接状态(如,HSP未连接、HFP未连接状态或者处于A2DP未连接状态),结束本次处理流程。
在步骤606中,调用蓝牙设备接口以通知用户。
在步骤607中,接收指令,判断是否改变蓝牙设备的当前状态,如果改变 蓝牙设备的当前状态,执行步骤609,如果不改变蓝牙设备的当前状态,执行步骤608。
在步骤608中,保持当前蓝牙设备的状态,发送连接状态报告,说明蓝牙设备处于所检查的连接类型的连接状态(如,处于HSP连接且通话状态、HFP连接且通话状态、处于HSP连接但未通话状态、HFP连接但未通话状态、处于A2DP连接已使用状态或处于A2DP连接未使用状态),结束本次处理流程。
其中,所述处于A2DP连接已使用状态,可以是蓝牙设备与终端正在通过A2DP传输音频数据(如,正在播放音乐),所述处于A2DP连接未使用状态可以是蓝牙设备与终端之间建立了A2DP连接但未传输音频数据(如,未播放音乐)。
在步骤609中,断开当前连接,发送连接状态报告,说明蓝牙设备处于所检查的连接类型未连接状态(如,HSP未连接状态、HFP未连接状态或者处于A2DP未连接状态)。
所述接收指令可以是通过提前设置每个终端的优先级,如果两个设备同时发送连接请求,可以选择其中优先级高的终端完成蓝牙设备与该终端的连接,也可以由用户手动选择是否改变蓝牙设备的当前状态。
图7为本实施例中终端侧收到连接状态报告后的判断过程示意图,如图7所示,本实施例中终端侧收到连接状态报告后的判断过程包括以下步骤。
在步骤701中,终端接收蓝牙设备发送的连接状态报告。
在步骤702中,终端判断连接状态报告中蓝牙设备的连接状态,如果连接状态报告表明蓝牙设备处于所检查的连接类型未连接状态(如,HSP连接状态、HFP连接状态或者处于A2DP连接状态),执行步骤704,如果连接状态报告表明蓝牙设备处于所检查的连接类型未连接状态(如,HSP未连接状态、HFP未连接状态或者处于A2DP未连接状态),执行步骤703。
在步骤703中,退出,结束本次处理流程。
在步骤704中,调用终端接口,向蓝牙设备发起HSP连接请求、HFP连接请求,或者,发起A2DP连接请求。
在步骤705中,判定终端是否与蓝牙设备建立连接,如果终端与蓝牙设备 建立连接,执行步骤706,如果终端与蓝牙设备建立连接失败,执行步骤702。
在步骤706中,使用蓝牙设备完成接听电话、挂断电话、拨打电话、播放音频或结束音频。
图8为本实施例一中第一终端来电时终端侧判断过程示意图,如图8所示,实施例一中第一终端来电时终端侧判断过程包括以下步骤。
在步骤801中,第一终端检测到来电操作。
本实施例中,以第一终端支持HSP连接为例,对本实施例中的方法进行说明,本实施例中的HSP连接也可以替换为HFP连接。
步骤802中,检查第一终端是否与蓝牙设备连接,如果第一终端与蓝牙设备连接,执行步骤804,如果第一终端未与蓝牙设备连接,执行步骤803。
所述终端与蓝牙设备之间的连接可以包括:Ble连接、HSP连接、或HFP连接。
在步骤803中,通过第一终端接听来电,结束本次处理流程。
在步骤804中,检查第一终端是否处于HSP连接,如果第一终端处于HSP连接,执行步骤805,如果第一终端未处于HSP连接,执行步骤806。
在步骤805中,终端切换到HSP连接,结束本次处理流程。
在步骤806中,检查第一终端与蓝牙设备之间是否处于Ble连接,如果第一终端与蓝牙设备之间处于Ble连接,执行步骤807,如果第一终端与蓝牙设备之间未处于Ble连接,执行步骤803。
在步骤807中,检查与第一终端保持Ble连接的蓝牙设备是否支持HSP连接,如果与第一终端保持Ble连接的蓝牙设备支持HSP连接,执行步骤809,如果与第一终端保持Ble连接的蓝牙设备不支持HSP连接,执行步骤808。
在步骤808中,显示连接错误信息,结束本次处理流程。
在步骤809中,更新终端侧的记录,并发送通知消息。
所述执行步骤801之前,所述方法还可以包括用户所有终端与蓝牙设备配对,建立Ble连接,并保持Ble连接。
图9为实施例一中第一终端来电时蓝牙设备侧工作过程示意图,如图9所 示,实施例一中第一终端来电时蓝牙设备侧工作过程包括以下步骤。结合图8所在的实施例,以终端支持HSP连接为例。若图8所在的实施例中,终端支持HFP连接,图9所在的实施例中的HSP连接也可以替换为HFP连接。
在步骤901中,蓝牙设备接收通知消息。
其中,蓝牙设备可以从接收的通知消息中获知终端支持的连接类型,结合图8所在的实施例,图8中的终端支持HSP连接,则蓝牙设备可以在通知消息中获知终端支持HSP连接。
在步骤902中,检查蓝牙设备是否处于HSP连接,如果蓝牙设备处于HSP连接,执行步骤904,如果蓝牙设备未处于HSP连接,执行步骤903。
在步骤901中,蓝牙设备可以获知了终端支持的连接类型,在步骤902中,蓝牙设备可以检查蓝牙设备是否处于终端支持的连接类型中。
在步骤903中,发送连接状态报告,说明蓝牙设备处于HSP未连接状态,结束本次处理流程。
在步骤904中,判断蓝牙设备是否处在通话状态,如果蓝牙设备处在通话状态,执行步骤906,如果蓝牙设备未处在通话状态,执行步骤905。
在步骤905中,断开蓝牙设备与第一终端之间的连接,发送连接状态报告,说明蓝牙设备处于HSP未连接状态,结束本次处理流程。
在步骤906中,调用蓝牙设备接口通知用户。
在步骤907中,接收指令,判断是否改变蓝牙设备状态,如果改变蓝牙设备状态,执行步骤909,如果不改变蓝牙设备状态,执行步骤908。
在步骤908中,保持当前蓝牙设备连接状态,发送连接状态报告,说明蓝牙设备处于HSP连接且通话状态,或说明蓝牙设备处于HSP连接但未通话状态,结束本次处理流程。
在步骤909中,断开蓝牙设备与第一终端之间的当前连接,发送连接状态报告,说明蓝牙设备处于HSP未连接状态。
图10为实施例一中第一终端来电时终端侧收到连接状态报告后的判断过程示意图,如图10所示,结合图9所在的实施例,实施例一中第一终端来电时终 端侧收到连接状态报告后的判断过程包括以下步骤。
在步骤1001中,第一终端接收蓝牙设备发送的连接状态报告。
在步骤1002中,第一终端判断连接状态报告中蓝牙设备的连接状态,如果连接状态报告表明蓝牙设备处于HSP连接状态,执行步骤1003,如果连接状态报告表明蓝牙设备处于HSP未连接状态,执行步骤1004。
在步骤1003中,退出,结束本次处理流程。
在步骤1004中,第一终端调用第一终端接口,向蓝牙设备发起HSP连接。
在步骤1005中,判定第一终端是否与蓝牙设备建立HSP连接,如果第一终端与蓝牙设备建立HSP连接,执行步骤1006,如果第一终端与蓝牙设备建立HSP连接失败,执行步骤1002。
在步骤1006中,使用蓝牙设备完成接听电话。
图11为实施例二中第一终端通话且第二终端来电时终端侧判断过程示意图,如图11所示,实施例二中第一终端通话第二终端来电时终端侧判断过程包括以下步骤。
在步骤1101中,第二终端检测到来电操作。
在步骤1102中,检查第二终端是否与蓝牙设备连接,如果第二终端与蓝牙设备连接,执行步骤1104,如果第二终端与蓝牙设备未连接,执行步骤1103。
所述终端与蓝牙设备连接可以包括:Ble连接、HSP连接或HFP连接。
在步骤1103中,通过第二终端接听来电,结束本次处理流程。
在步骤1104中,检查第二终端是否与蓝牙设备处于HSP连接,如果第二终端与蓝牙设备处于HSP连接,执行步骤1105,如果第二终端未处于HSP连接,执行步骤1106。
在步骤1105中,蓝牙设备执行终端检测到的操作,结束本次处理流程。
在步骤1106中,检查第二终端与蓝牙设备是否处于Ble连接,如果第二终端与蓝牙设备处于Ble连接,执行步骤1107,如果第二终端未处于Ble连接,执行步骤1103。
在步骤1107中,检查与第二终端保持Ble连接的蓝牙设备是否支持HSP连 接,如果与第二终端保持Ble连接的蓝牙设备支持HSP连接,执行步骤1109,如果与第二终端保持Ble连接的蓝牙设备不支持HSP连接,执行步骤1108。
在步骤1108中,显示连接错误信息,结束本次处理流程。
在步骤1109中,更新第二终端侧的记录,第二终端并向蓝牙设备发送通知消息。
所述执行步骤1101之前,所述方法还可以包括用户所有终端与蓝牙设备配对,建立Ble连接,并保持Ble连接,第一终端与蓝牙设备正在通过HSP连接保持通话状态的同时第二终端有来电。
图12为实施例二中第一终端通话且第二终端来电时蓝牙设备侧工作过程示意图,如图12所示,实施例二中第一终端通话且第二终端来电时蓝牙设备侧工作过程包括以下步骤。
在步骤1201中,蓝牙设备接收通知。
在步骤1202中,检查蓝牙设备是否处于HSP连接,如果蓝牙设备处于HSP连接,执行步骤1204,如果蓝牙设备未处于HSP连接,执行步骤1203。
在步骤1203中,向第二终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态,结束本次处理流程。
在步骤1204中,判断蓝牙设备是否处在通话状态,如果蓝牙设备处在通话状态,执行步骤1206,如果蓝牙设备未处在通话状态,执行步骤1205。
在步骤1205中,断开蓝牙设备与第一终端的当前连接,向第二终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态,结束本次处理流程。
在步骤1206中,调用蓝牙设备接口通知用户。
在步骤1207中,接收指令,判断是否改变蓝牙设备状态,如果改变蓝牙设备状态,执行步骤1209,如果不改变蓝牙设备状态,执行步骤1208。
在步骤1208中,保持蓝牙设备与第一终端的连接,向第二终端发送连接状态报告,说明蓝牙设备处于HSP连接且通话状态,结束本次处理流程。
在步骤1209中,断开蓝牙设备与第一终端的连接,向第二终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态。
图13为实施例二中第一终端通话且第二终端来电时终端侧收到连接状态报告后判断过程示意图,如图13所示,实施例二中第一终端通话且第二终端来电时终端侧收到连接状态报告后判断过程包括以下步骤。
在步骤1301中,第二终端接收蓝牙设备发送的连接状态报告。
在步骤1302中,第二终端判断接收的连接状态报告中蓝牙设备的连接状态,如果连接状态报告表明蓝牙设备处于HSP连接状态,执行步骤1303,如果连接状态接报告表明蓝牙设备处于HSP未连接状态,执行步骤1304。
在步骤1303中,退出,结束本次处理流程。
在步骤1304中,调用第二终端接口,向蓝牙设备发起HSP连接。
在步骤1305中,判定第二终端是否与蓝牙设备建立连接,如果第二终端与蓝牙设备建立连接,执行步骤1306,如果第二终端与蓝牙设备建立连接失败,执行步骤1302。
在步骤1306中,使用蓝牙设备接听第二终端的来电。
实施例二中的HSP连接还可以替换为HFP连接。
图14为实施例三中在设置终端优先级情况下第一终端通话且第二终端和第三终端同时来电时终端侧判断过程示意图,如图14所示,实施例三中在设置终端优先级情况下第一终端通话,第二终端、第三终端同时来电时终端侧判断过程包括以下步骤。
在步骤1401中,针对用户的所有终端设置优先级,该优先级保存在蓝牙设备中,第二终端、第三终端同时检测到来电操作。
在步骤1402中,分别检查第二终端、第三终端是否与蓝牙设备连接,如果第二终端、第三终端中至少一个终端与蓝牙设备连接,执行步骤1404,如果第二终端和第三终端均不与蓝牙设备连接,执行步骤1403。
所述连接可以包括:Ble连接、HSP连接或HFP连接。
在步骤1403中,分别通过第二终端和第三终端接听来电,结束本次处理流程。
在步骤1404中,检查与蓝牙设备连接的终端是否处于HSP连接,如果与蓝 牙设备连接的终端处于HSP连接,执行步骤1405,如果第二终端和第三终端均未处于HSP连接,执行步骤1406。
在步骤1405中,处于HSP连接的第二终端和蓝牙设备建立HSP连接,第三终端发送通知消息,说明该终端有来电;结束本次处理流程。
在步骤1406中,检查第二终端、第三终端中至少一个终端是否与蓝牙设备处于Ble连接,如果第二终端、第三终端中至少一个终端处于Ble连接,执行步骤1407,如果第二终端和第三终端均未处于Ble连接,执行步骤1403。
在步骤1407中,检查与第二终端、第三终端中至少一个终端保持Ble连接的蓝牙设备是否支持HSP连接,如果与第二终端、第三终端中至少一个终端保持Ble连接的蓝牙设备支持HSP连接,执行步骤1409,如果与第二终端、第三终端中至少一个终端保持Ble连接的蓝牙设备不支持HSP,执行步骤1408。
在步骤1408中,显示连接错误信息,结束本次处理流程。
在步骤1409中,分别更新第二终端的记录和第三终端侧的记录,并由第二终端和第三终端分别发送通知消息。
执行步骤1401之前,所述方法还可以包括用户所有终端与蓝牙设备配对,建立Ble连接,并保持Ble连接,第一终端与蓝牙设备之间正在通过HSP连接保持通话状态同时第二终端、第三终端同时有来电。
图15为实施例三中在设置终端优先级情况下第一终端通话且第二终端、第三终端同时来电时蓝牙设备侧工作过程示意图,如图15所示,实施例三中在设置终端优先级情况下第一终端通话且第二终端、第三终端同时来电时蓝牙设备侧工作过程包括以下步骤。
在步骤1501中,蓝牙设备接收通知消息。
在步骤1502中,检查蓝牙设备是否处于HSP连接,如果蓝牙设备处于HSP连接,执行步骤1504,如果蓝牙设备未处于HSP连接,执行步骤1503。
在步骤1503中,向第二终端和第三终端中优先级高的终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态,向第二终端和第三终端中优先级低的终端发送连接状态报告,说明蓝牙设备处于HSP连接状态,结束本次处理流程。
在步骤1504中,判断蓝牙设备是否处在通话状态,如果蓝牙设备处在通话 状态,执行步骤1506,如果蓝牙设备未处在通话状态,执行步骤1505。
在步骤1505中,断开蓝牙设备与第一终端的当前连接,向第二终端和第三终端中优先级高的终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态,向第二终端和第三终端中优先级低的终端发送连接状态报告,说明蓝牙设备处于HSP连接状态,结束本次处理流程。
在步骤1506中,调用蓝牙设备接口通知用户。
在步骤1507中,判断当前通话终端是否为优先级最高的终端,如果当前通话终端为优先级最高的终端,执行步骤1508,如果当前通话终端不是优先级最高的终端,执行步骤1509。
在步骤1508中,保持当前链接,向剩余终端发送连接状态报告,说明蓝牙设备处于HSP连接且通话状态,结束本次处理流程。
在步骤1509中,断开蓝牙设备与第一终端的连接,向优先级最高的终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态,向剩余终端发送连接状态报告,说明蓝牙设备处于HSP连接状态。
用户可以对所有终端设置优先级,并将终端的优先级记录在蓝牙设备中,在蓝牙设备与用户的任意一个终端保持连接并处于通话状态时,其余任意一个终端,或任意多个终端同时或者先后来电时,所述的装置可以根据上述的方法自动选择优先级最高的终端进入通话状态,减少了用户的操作步骤,也避免了用户漏接重要电话。
图16为实施例三中在设置终端优先级情况下第一终端通话且第二终端、第三终端同时来电时终端侧收到连接状态报告后判断过程示意图,如图16所示,本实施例三中在设置终端优先级情况下第一终端通话且第二终端、第三终端同时来电时终端侧收到连接状态报告后判断过程包括以下步骤。
在步骤1601中,第二终端和第三终端接收连接状态报告。
优先级最高的终端可以接收到的连接状态报告可以说明蓝牙设备处于HSP未连接状态,优先级最高的终端可以与蓝牙设备建立HSP连接,使用蓝牙设备进行通话,剩余终端接收到的连接状态报告说明蓝牙设备处于HSP连接状态,剩余终端不能与蓝牙设备建立HSP连接。
在步骤1602中,终端(第二终端和第三终端中优先级较高的终端)判断是连接状态报告中蓝牙设备的连接状态,如果连接状态报告表明该蓝牙设备处于HSP连接状态,执行步骤1603,如果连接状态报告表明蓝牙设备处于HSP未连接状态,执行步骤1604。
在步骤1603中,退出,结束本次处理流程。
在步骤1604中,接收到的连接状态报告为蓝牙设备处于HSP未连接状态的终端向蓝牙设备发起HSP连接,剩余终端的来电则通过来电终端完成接听。
在步骤1605中,判定该终端与蓝牙设备是否建立连接,如果该终端与蓝牙设备建立连接,执行步骤1606,如果该终端与蓝牙设备建立连接失败,执行步骤1602。
在步骤1606中,使用蓝牙设备完成接听电话。
实施例三中的HSP连接还可以替换为HFP连接。
图17为实施例四中第一终端通话且第二终端、第三终端同时来电时终端侧判断过程示意图,如图17所示,本实施例四中第一终端通话且第二终端、第三终端同时来电时终端侧判断过程包括以下步骤。
在步骤1701中,第二终端、第三终端同时检测到来电操作。
在步骤1702中,分别检查第二终端、第三终端中至少一个终端是否与蓝牙设备连接,如果第二终端、第三终端中至少一个终端与蓝牙设备连接,执行步骤1704,如果第二终端和第三终端中均未与蓝牙设备连接,执行步骤1703。
所述连接可以包括:Ble连接、HSP连接或HFP连接。
在步骤1703中,分别通过第二终端和第三终端接听来电,结束本次处理流程。
在步骤1704中,检查第二终端和第三终端中至少一个终端是否处于HSP连接,如果第二终端和第三终端中至少一个终端处于HSP连接,执行步骤1705,如果第二终端和第三终端均未处于HSP连接,执行步骤1706。
在步骤1705中,处于HSP连接的终端和蓝牙设备建立HSP连接;剩余一个终端发送通知消息,说明该终端有来电;结束本次处理流程。
在步骤1706中,检查第二终端和第三终端中至少一个终端是否处于Ble连接,如果第二终端和第三终端中至少一个终端处于Ble连接,执行步骤1707,如果第二终端和第三终端均未处于Ble连接,执行步骤1703。
在步骤1707中,检查与第二终端、第三终端中至少一个终端保持Ble连接的蓝牙设备是否支持HSP连接,如果与第二终端、第三终端中至少一个终端保持Ble连接的蓝牙设备支持HSP连接,执行步骤1709,如果与第二终端和第三终端中至少一个终端保持Ble连接的蓝牙设备不支持HSP连接,执行步骤1708。
在步骤1708中,显示连接错误信息,结束本次处理流程。
在步骤1709中,更新第二终端、第三终端侧的记录,并由第二终端、第三终端发送通知消息。
所述执行步骤1701之前,所述方法还包括用户所有的终端与蓝牙设备建立并保持Ble连接,第一终端正在利用HSP连接或HFP连接保持通话状态同时第二终端、第三终端同时有来电。
图18为实施例四中第一终端通话且第二终端和第三终端同时来电时蓝牙设备侧工作过程示意图,如图18所示,实施例四中第一终端通话且第二终端和第三终端同时来电时蓝牙设备侧工作过程包括以下步骤。
在步骤1801中,蓝牙设备接收通知消息。
在步骤1802中,检查蓝牙设备是否处于HSP连接,如果蓝牙设备处于HSP连接,执行步骤1804,如果蓝牙设备未处于HSP连接,执行步骤1803。
在步骤1803中,向优先级最高的终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态;向剩余终端发送连接状态报告,说明蓝牙设备处于HSP连接状态,结束本次处理流程。
在步骤1804中,判断蓝牙设备是否处在通话状态,如果蓝牙设备处在通话状态,执行步骤1806,如果蓝牙设备未处在通话状态,执行步骤1805。
在步骤1805中,断开蓝牙设备与第一终端的连接,向被选择的终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态,向剩余终端发送连接状态报告,说明蓝牙设备处于HSP连接状态。
在步骤1806中,调用蓝牙设备接口通知用户。
在步骤1807中,根据用户指令,判断是否改变蓝牙设备连接状态,如果不改变蓝牙设备连接状态,执行步骤1808,如果改变蓝牙设备连接状态,执行步骤1809。
在步骤1808中,保持当前链接,向剩余终端发送连接状态报告,说明蓝牙设备处于HSP连接且通话状态,结束本次处理流程。
在步骤1809中,断开蓝牙设备与第一终端的连接,向被选择通话的终端发送连接状态报告,说明蓝牙设备处于HSP未连接状态,向剩余终端发送连接状态报告,说明蓝牙设备处于HSP连接状态。
在蓝牙设备与用户的任意一个终端保持连接并处于通话状态时,其余任意一个终端,或任意多个终端同时或者先后来电时,上述的装置可以根据上述的方法通过用户指令选择任意一个终端进入通话状态,避免了用户漏接重要电话。
图19为实施例四中第一终端通话且第二终端和第三终端同时来电时终端侧收到连接状态报告后判断过程示意图,如图19所示,本实施例四中第一终端通话且第二终端和第三终端同时来电时终端侧收到连接状态报告后判断过程包括以下步骤。
在步骤1901中,第二终端和第三终端接收连接状态报告。
第二终端和第三终端中被选择通话的终端接收到的连接状态报告可以说明蓝牙设备处于HSP未连接状态,被选择通话的终端可以与蓝牙设备建立HSP连接,使用蓝牙设备进行通话,剩余终端接收到的连接状态报告说明蓝牙设备处于HSP连接状态,剩余终端可以不与蓝牙设备建立HSP连接。用户选择正在使用蓝牙设备通话的终端保持通话状态不变,剩余终端接收到的连接状态报告说明蓝牙设备处于HSP连接状态,剩余终端可以不与蓝牙设备建立HSP连接。
在步骤1902中,终端(第二终端和第三终端中被选择通话的终端)判断连接状态报告中该蓝牙设备的连接状态,如果连接状态报告表明蓝牙设备处于HSP连接状态,执行步骤1903,如果连接状态报告表明该蓝牙设备处于HSP未连接状态,执行步骤1904。
在步骤1903中,退出,结束本次处理流程。
在步骤1904中,接收到的连接状态报告为蓝牙设备处于HSP未连接状态的 终端向蓝牙设备发起HSP连接,剩余终端的来电则通过来电终端完成接听。
在步骤1905中,判定该终端是否与蓝牙设备建立连接,如果终端与蓝牙设备建立连接,执行步骤1906,如果该终端与蓝牙设备建立连接失败,执行步骤1902。
步骤1906中,使用蓝牙设备接听电话。
上述实施例四中的HSP连接还可以替换为HFP连接。
图20为实施例五中第一终端检测到音频播放操作时终端侧判断过程示意图,如图20所示,实施例五中第一终端检测到音频播放操作时终端侧判断过程包括以下步骤。
在步骤2001中,第一终端检测到音频播放操作。
步骤2002中,检查第一终端是否与蓝牙设备连接,如果第一终端与蓝牙设备连接,执行步骤2004,如果第一终端未与蓝牙设备连接,执行步骤2003。
第一终端与蓝牙设备之间的连接可以包括:Ble连接和A2DP连接。
在步骤2003中,通过第一终端播放音频,结束本次处理流程。
在步骤2004中,检查第一终端是否处于A2DP连接,如果第一终端处于A2DP连接,执行步骤2005,如果第一终端未处于A2DP连接,执行步骤2006。
在步骤2005中,蓝牙设备播放音频,结束本次处理流程。
在步骤2006中,检查第一终端是否处于Ble连接,如果第一终端处于Ble连接,执行步骤2007,如果第一终端未处于Ble连接,执行步骤2003。
在步骤2007中,检查与终端保持Ble连接的蓝牙设备是否支持A2DP连接,如果与终端保持Ble连接的蓝牙设备支持A2DP连接,执行步骤2009,如果与终端保持Ble连接的蓝牙设备不支持A2DP连接,执行步骤2008。
在步骤2008中,显示连接错误信息,结束本次处理流程。
在步骤2009中,更新第一终端侧的记录,并发送通知消息。
用户可以通过A2DP连接获取蓝牙设备播放终端中存储的音频信息、存储的视频信息、接收到的音频信息和接收到的视频信息中的至少之一。
图21为实施例五中第一终端检测到音频播放操作时蓝牙设备侧工作过程示意图,如图21所示,实施例五中第一终端检测到音频播放操作时蓝牙设备侧工作过程包括以下步骤。
在步骤2101中,蓝牙设备接收通知消息。
在步骤2102中,检查蓝牙设备是否处于A2DP连接,如果蓝牙设备处于A2DP连接,执行步骤2104,如果蓝牙设备未处于A2DP连接,执行步骤2103。
在步骤2103中,向第一设备发送连接状态报告,说明蓝牙设备处于A2DP未连接状态,结束本次处理流程。
在步骤2104中,判断蓝牙设备是否处在音频播放状态,如果蓝牙设备处在音频播放状态,执行步骤2106,如果蓝牙设备未处在音频播放状态,执行步骤2105。
在步骤2105中,断开当前A2DP连接,向第一终端发送连接状态报告,说明蓝牙设备处于A2DP未连接状态,结束本次处理流程。
在步骤2106中,调用蓝牙设备接口通知用户。
在步骤2107中,接收指令,判断是否改变蓝牙设备连接状态,如果改变蓝牙设备连接状态,执行步骤2109,如果不改变蓝牙设备连接状态,执行步骤2108。
在步骤2108中,保持当前蓝牙设备连接状态,向第一终端发送连接状态报告,说明蓝牙设备处于A2DP连接已使用状态,或说明蓝牙设备处于A2DP连接未使用状态,结束本次处理流程。
在步骤2109中,断开当前连接,向第一终端发送连接状态报告,说明蓝牙设备处于A2DP未连接状态。
图22为实施例五中第一终端检测到音频播放操作时终端侧收到连接状态报告判断过程示意图,如图22所示,实施例五中第一终端检测到音频播放操作时终端侧收到连接状态报告判断过程包括以下步骤。
在步骤2201中,第一终端接收蓝牙设备发送的连接状态报告。
在步骤2202中,第一终端判断连接状态报告中蓝牙设备的连接状态,如果连接状态报告表明蓝牙设备处于A2DP连接状态,执行步骤2203,如果连接状 态报告表明蓝牙设备处于A2DP未连接状态,执行步骤2204。
在步骤2203中,退出,结束本次处理流程。
在步骤2204中,调用第一终端接口,向蓝牙设备发起A2DP连接。
在步骤2205中,判定该第一终端是否与蓝牙设备建立A2DP连接,如果终端与蓝牙设备建立A2DP连接,执行步骤2206,如果终端与蓝牙设备建立A2DP连接失败,执行步骤2202。
在步骤2206中,使用蓝牙设备播放音频。
两个以上终端进行音频播放切换时,切换的处理方式及处理流程可以采用上述的实施例二至实施例五的处理方法。
可选的,如果终端设置有优先级,蓝牙设备可以根据检测到的自身的连接状态以及设置的优先级进行选择。
所述蓝牙设备可以包括车载蓝牙设备和蓝牙耳机。
本实施例提供了一种终端连接蓝牙设备的系统,该系统包括蓝牙设备与至少两个终端。
所述至少两个终端设置为建立并保持自身与蓝牙设备的Ble连接;检测触发自身状态发生变化的操作;检测到触发自身状态发生变化的操作时,向蓝牙设备发送通知消息;接收蓝牙设备的连接状态报告,并根据接收到的连接状态报告向所述蓝牙设备发起连接请求,其中,所述连接请求表示所述终端请求与所述蓝牙设备建立蓝牙通信连接。
所述蓝牙设备设置为建立并保持自身与两个以上终端的Ble连接;接收通知消息,检测自身所处的连接状态,根据检测到的连接状态及通知消息向终端发送连接状态报告。
可选的,所述蓝牙设备还可用于执行以下操作之一:
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连接;
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HFP连接;以及
建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
本实施例提供了一种终端,所述终端包括第一处理器230,第一处理器设置为建立并保持终端与蓝牙设备的Ble连接;检测触发终端状态发生变化的操作;检测到触发终端状态发生变化的操作时,向蓝牙设备发送通知消息;接收蓝牙设备的连接状态报告,并根据接收到的连接状态报告向所述蓝牙设备发起连接请求,所述连接请求用于表示所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
参见图23,上述实施例中提供的终端,还可以包括:
第一存储器(memory)231,第一通信接口(Communications Interface)232和第一总线233。其中,第一处理器230、第一存储器231以及第一通信接口232可以通过第一总线233完成相互间的通信。第一通信接口232可以传输信息。第一处理器230可以调用第一存储器231中的逻辑指令,以执行上述实施例中终端执行的方法。
此外,上述的第一存储器231中的逻辑指令可以通过软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。
第一存储器231作为一种计算机可读存储介质,可用于存储软件程序、计算机可执行程序,上述实施例中的方法对应的程序指令或模块。第一处理器230通过运行存储在第一存储器231中的软件程序、指令或模块,从而执行功能应用以及数据处理,即实现上述实施例中终端执行的方法。
第一存储器231可包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据终端的使用所创建的数据等。此外,第一存储器231可以包括高速随机存取存储器,还可以包括非易失性存储器。
本实施例提供了一种蓝牙设备,所述蓝牙设备包括第二处理器240,第二处理器设置为建立并保持蓝牙设备与终端的Ble连接;接收通知消息,检测蓝牙设备所处的连接状态,根据检测到的连接状态及通知消息向终端发送连接状态报告。
所述蓝牙设备可设置为执行以下操作之一:
建立并保持所述蓝牙设备与终端的HSP连接;
建立并保持所述蓝牙设备与终端的HFP连接;以及
建立并保持所述蓝牙设备与终端的A2DP连接。
参见图24,上述实施例的蓝牙设备还可以包括:
第二存储器(memory)241,还可以包括第二通信接口(Communications Interface)242和第二总线243。其中,第二处理器240、第二存储器241以及第二通信接口242可以通过第二总线243完成相互间的通信。第二通信接口242可以传输信息。第二处理器240可以调用第二存储器241中的逻辑指令,以执行上述实施例中蓝牙设备执行的方法。
此外,上述的第二存储器241中的逻辑指令可以通过软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。
第二存储器241作为一种计算机可读存储介质,可用于存储软件程序、计算机可执行程序,上述实施例中蓝牙设备执行的方法对应的程序指令或模块。第二处理器240通过运行存储在第二存储器241中的软件程序、指令或模块,从而执行功能应用以及数据处理,即实现上述实施例中蓝牙设备执行的方法。
第二存储器241可包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据终端的使用所创建的数据等。此外,第二存储器241可以包括高速随机存取存储器,还可以包括非易失性存储器。
本实施例还提供了一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令设置为执行上述任一实施例中的方法。
上述实施例中的技术方案可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括一个或多个指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行上述实施例所述方法的全部或部分步骤。而前述的存储介质可以是非暂态存储介质,包括:U盘、移动硬盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access  Memory,RAM)、磁碟或者光盘等多种可以存储程序代码的介质,也可以是暂态存储介质。
工业实用性
一种连接蓝牙设备的方法、装置、系统及设备,能够使得至少两个终端同时与蓝牙设备连接。

Claims (53)

  1. 一种连接蓝牙设备的方法,包括:
    两个以上终端与蓝牙设备建立并保持蓝牙低功耗Ble连接;
    所述两个以上终端中的至少一个终端检测到触发自身状态发生变化的操作时,向所述蓝牙设备发送通知消息;以及
    所述两个以上终端中的至少一个终端接收所述蓝牙设备发送的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求,建立蓝牙通信连接,其中,所述连接请求用于表示终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
  2. 根据权利要求1所述的方法,其中,所述检测到触发自身状态发生变化的操作包括以下之一:
    终端检测到来电的操作;
    终端检测到拨打电话的操作;以及
    终端检测到挂断电话的操作。
  3. 根据权利要求1所述的方法,其中,所述检测到触发自身状态发生变化的操作还包括以下之一:
    终端检测到播放音频的操作;以及
    终端检测到停止播放音频的操作。
  4. 根据权利要求1所述的方法,其中,发送通知消息包括以下之一:
    发送通信连接的消息;以及
    发送结束通信连接的消息。
  5. 根据权利要求1所述的方法,其中,所述发送通知消息包括以下之一:
    发送音频播放的消息;以及
    发送停止音频播放的消息。
  6. 根据权利要求1或2所述的方法,其中,所述根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下之一:
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立蓝牙免提规格HFP连接的请求;
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立蓝牙手机规格HSP连接的请求;
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
  7. 根据权利要求1或2所述的方法,其中,所述根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下之一:
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立高质量音频分发规范A2DP连接的请求;以及
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开A2DP连接仅保留Ble连接的请求。
  8. 根据权利要求1所述的方法,其中,所述两个以上终端中的至少一个终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接包括以下之一:
    两个以上终端中的至少一个终端请求与蓝牙设备建立HSP连接;
    两个以上终端中的至少一个终端请求与蓝牙设备建立HFP连接;以及
    两个以上终端中的至少一个终端请求与蓝牙设备建立A2DP连接。
  9. 一种连接终端的方法,包括:
    蓝牙设备与两个以上终端建立并保持Ble连接;以及
    蓝牙设备接收通知消息,检测自身的连接状态,根据检测到的连接状态及通知消息向所述两个以上终端中的至少一个终端发送连接状态报告。
  10. 根据权利要求9所述的方法,其中,所述蓝牙设备自身的连接状态包括以下之一:
    处于HFP未连接状态;
    处于HSP未连接状态;
    处于HFP连接但未通话状态;
    处于HSP连接但未通话;
    处于HFP连接且通话状态;以及
    处于HSP连接且通话状态。
  11. 根据权利要求9所述的方法,其中,所述蓝牙设备自身的连接状态包括以下之一:
    处于A2DP未连接状态;
    处于A2DP连接已使用状态;以及
    处于A2DP连接未使用状态。
  12. 根据权利要求9所述的方法,其中,所述蓝牙设备的连接状态报告包括以下之一:
    蓝牙设备处于HFP连接的连接状态;
    蓝牙设备处于HSP连接的连接状态;以及
    蓝牙设备处于A2DP连接的连接状态。
  13. 根据权利要求9所述的方法,还包括以下操作之一:
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连接或HFP连接;以及
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
  14. 根据权利要求9所述的方法,还包括:在保持Ble连接的基础上,所述蓝牙设备接收所述两个以上终端中的至少一个终端根据所述连接状态报告向所述蓝牙设备发起的连接请求,蓝牙设备响应所述连接请求,与所述两个以上终端中的至少一个终端建立非低功耗蓝牙通信连接;其中,所述连接请求表示所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
  15. 根据权利要求14所述的方法,其中,在保持Ble连接的基础上,所述蓝牙设备接收所述两个以上终端中的至少一个终端根据所述连接状态报告向所述蓝牙设备发起的连接请求包括以下之一:
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立HFP连接的请求;
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立HSP连接的请求;
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
  16. 根据权利要求14所述的方法,其中,在保持Ble连接的基础上,所述 蓝牙设备接收所述两个以上终端中的至少一个终端根据所述连接状态报告向所述蓝牙设备发起的连接请求包括以下之一:
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备建立A2DP连接的请求;以及
    所述两个以上终端中的至少一个终端发起与所述蓝牙设备断开A2DP连接切仅保留Ble连接的请求。
  17. 根据权利要求9所述的方法,还包括以下之一:
    在保持Ble连接的基础上,所述蓝牙设备从处于HFP连接且通话状态切换为HFP未连接的状态;
    在保持Ble连接的基础上,所述蓝牙设备从处于HSP连接且通话状态切换为HSP未连接的状态;
    在保持Ble连接的基础上,所述蓝牙设备从处于HFP连接且通话状态切换为处于HFP连接但未通话的状态;
    在保持Ble连接的基础上,所述蓝牙设备从处于HSP连接且通话状态切换为处于HSP连接但未通话的状态;
    在保持Ble连接的基础上,所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP未连接的状态;以及
    在保持Ble连接的基础上,所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP连接未使用的状态。
  18. 根据权利要求14所述的方法,其中,所述蓝牙设备响应所述连接请求,与所述两个以上终端中的至少一个终端建立非低功耗蓝牙通信连接包括以下之一:
    蓝牙设备与两个以上终端中的至少一个终端建立HSP连接;
    蓝牙设备与两个以上终端中的至少一个终端建立HFP连接;以及
    蓝牙设备与两个以上终端中的至少一个终端建立A2DP连接。
  19. 一种连接蓝牙设备的装置,包括:连接模块、检测模块以及收发模块,其中,
    所述连接模块设置为建立并保持终端与蓝牙设备的Ble连接;根据接收到的连接状态报告向所述蓝牙设备发起连接请求,其中,所述连接请求用于表示终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接;
    所述检测模块设置为检测触发终端状态发生变化的操作;以及
    所述收发模块设置为检测到触发终端状态发生变化的操作时,向蓝牙设备发送通知消息,以及接收蓝牙设备的连接状态报告。
  20. 根据权利要求19所述的装置,其中,所述检测模块检测触发终端状态发生变化的操作包括以下之一:
    检测到来电的操作;
    检测到拨打电话的操作;以及
    检测到挂断电话的操作。
  21. 根据权利要求19所述的装置,其中,所述检测模块检测触发终端状态发生变化的操作包括以下之一:
    检测到播放音频的操作;以及
    检测到停止播放音频的操作。
  22. 根据权利要求19所述的装置,其中,所述向蓝牙设备发送的通知消息包括以下之一:
    音频播放的消息;以及
    停止音频播放的消息。
  23. 根据权利要求19所述的装置,其中,所述连接状态报告包括以下之一:
    蓝牙设备处于HFP连接的连接状态;
    蓝牙设备处于HSP连接的连接状态;以及
    蓝牙设备处于A2DP连接的连接状态。
  24. 根据权利要求19所述的装置,其中,所述收发模块在保持Ble连接的基础上,向蓝牙设备发起以下任意一种连接请求:
    发起与所述蓝牙设备建立HFP连接的请求;
    发起与所述蓝牙设备建立HSP连接的请求;
    发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
    发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
  25. 根据权利要求19所述的装置,其中,所述收发模块在保持Ble连接的基础上,向蓝牙设备发起以下任意一种连接请求:
    发起与所述蓝牙设备建立A2DP连接的请求;以及
    发起与所述蓝牙设备断开A2DP连接仅保留Ble连接的请求。
  26. 根据权利要求19所述的装置,其中,所述建立非低功耗蓝牙通信连接包括以下之一:
    与蓝牙设备建立HSP连接;
    与蓝牙设备建立HFP连接;以及
    与蓝牙设备建立A2DP连接。
  27. 根据权利要求19所述的装置,其中,所述终端支持Ble连接,且支持 HSP连接、HFP连接、以及A2DP连接中的至少一种连接。
  28. 一种连接终端的装置,包括:连接模块、检测模块以及收发模块,其中,
    所述连接模块设置为建立并保持蓝牙设备与两个以上终端的Ble连接;
    所述检测模块设置为检测蓝牙设备的连接状态报告;以及
    所述收发模块设置为接收通知消息,以及根据检测到的连接状态及通知消息向两个以上终端中的至少一个终端发送连接状态报告。
  29. 根据权利要求28所述的装置,其中,所述检测模块检测到蓝牙设备处于以下任意一种连接状态:
    处于HFP未连接;
    处于HSP未连接
    处于HFP连接但未通话;
    处于HSP连接但未通话;
    处于HFP连接且通话;以及
    处于HSP连接且通话。
  30. 根据权利要求28所述的装置,其中,所述检测模块检测到蓝牙设备处于以下任意选一种连接状态:
    处于A2DP未连接;
    处于A2DP连接已使用;以及
    处于A2DP连接未使用。
  31. 根据权利要求28所述的装置,其中,所述连接状态报告包括以下之一:
    蓝牙设备处于HFP连接的连接状态;
    蓝牙设备处于HSP连接的连接状态;以及
    蓝牙设备处于A2DP连接的连接状态。
  32. 根据权利要求28所述的装置,其中,所述连接模块还设置为执行以下操作之一:
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连接;
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HFP连接;以及
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
  33. 根据权利要求28所述的装置,其中,所述收发模块还设置为在保持Ble连接的基础上,接收终端发起的连接请求,响应所述连接请求,与所述两个以上终端中的至少一个终端建立非低功耗蓝牙通信连接;其中,所述连接请求表示终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
  34. 根据权利要求33所述的装置,其中,所述在保持Ble连接的基础上,接收终端发起的连接请求包括以下之一:
    终端发起与所述蓝牙设备建立HFP连接的请求;
    终端发起与所述蓝牙设备建立HSP连接的请求;
    终端发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求;以及
    终端发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
  35. 根据权利要求33所述的装置,其中,所述在保持Ble连接的基础上,接收终端发起的连接请求包括以下之一:
    终端发起与所述蓝牙设备建立A2DP连接的请求;以及
    终端发起与所述蓝牙设备断开A2DP连接仅保留Ble连接请求。
  36. 根据权利要求33所述的装置,其中,所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接包括以下之一:
    所述终端请求与所述蓝牙设备建立HSP连接;
    所述终端请求与所述蓝牙设备建立HFP连接;以及
    所述终端请求与所述蓝牙设备建立A2DP连接。
  37. 根据权利要求29所述的装置,还包括切换模块,设置为执行以下操作之一:
    在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为HFP未连接的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为HSP未连接的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为处于HFP连接但未通话的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为处于HSP连接但未通话的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP未连接的状态;以及
    在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP连接未使用的状态。
  38. 一种连接蓝牙设备的系统,包括蓝牙设备与至少两个终端;其中,
    所述至少两个终端中的每个终端设置为建立并保持自身与蓝牙设备的Ble连接;检测触发自身状态发生变化的操作;检测到触发自身状态发生变化的操作时,向蓝牙设备发送通知消息;接收蓝牙设备的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求,建立蓝牙通信连接,所述连接请求表示所述终端请求与所述蓝牙设备建立蓝牙通信连接;以及
    所述蓝牙设备设置为建立并保持自身与两个以上终端的Ble连接;接收通知消息,检测自身所处的连接状态,根据检测到的连接状态及通知消息向终端发送连接状态报告。
  39. 根据权利要求38所述的系统,其中,所述检测触发自身状态发生变化的操作包括以下之一:
    检测到来电的操作;
    检测到拨打电话的操作;以及
    检测到挂断电话的操作。
  40. 根据权利要求38所述的系统,中,所述检测触发自身状态发生变化的操作包括以下之一:
    检测到播放音频的操作;以及
    检测到停止播放音频的操作。
  41. 根据权利要求38所述的系统,其中,所述检测自身所处的连接状态包括以下之一:
    处于HFP未连接;
    处于HSP未连接;
    处于HFP连接但未通话;
    处于HSP连接但未通话;
    处于HFP连接且通话;以及
    处于HSP连接且通话。
  42. 根据权利要求38所述的系统,其中,所述检测自身所处的连接状态包括以下之一:
    处于A2DP未连接;
    处于A2DP连接已使用;以及
    处于A2DP连接未使用。
  43. 根据权利要求38所述的系统,其中,所述蓝牙设备的连接状态报告包括以下之一:
    蓝牙设备处于HFP连接的连接状态;
    蓝牙设备处于HSP连接的连接状态;以及
    蓝牙设备处于A2DP连接的连接状态。
  44. 根据权利要求38所述的系统,其中,所述在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下任意一种请求:
    发起与所述蓝牙设备建立HFP连接的请求;
    发起与所述蓝牙设备建立HSP连接的请求;
    发起与所述蓝牙设备断开HFP连接仅保留Ble连接的请求以及
    发起与所述蓝牙设备断开HSP连接仅保留Ble连接的请求。
  45. 根据权利要求38所述的系统,其中,所述在保持Ble连接的基础上,向所述蓝牙设备发起连接请求包括以下任意一种请求:
    发起与所述蓝牙设备建立A2DP连接的请求;
    发起与所述蓝牙设备断开A2DP连接仅保留Ble连接。
  46. 根据权利要求38所述的系统,其中,所述建立蓝牙通信连接包括以下之一:
    与所述蓝牙设备建立HSP连接;
    与所述蓝牙设备建立HFP连接;以及
    与所述蓝牙设备建立A2DP连接。
  47. 根据权利要求38所述的系统,其中,所述检测到的连接状态包括以下之一:
    处于HFP未连接状态;
    处于HSP未连接状态;
    处于HFP连接但未通话状态;
    处于HSP连接但未通话状态;
    处于HFP连接且通话状态;以及
    处于HSP连接且通话状态。
  48. 根据权利要求38所述的系统,其中,所述检测到的连接状态包括以下之一:
    处于A2DP未连接状态;
    处于A2DP连接已使用状态;
    处于A2DP连接未使用状态。
  49. 根据权利要求38所述的系统,其中,所述蓝牙设备还设置为执行以下操作之一:
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HSP连接;
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的HFP连接;以及
    建立并保持所述蓝牙设备与所述两个以上终端中的至少一个终端的A2DP连接。
  50. 根据权利要求38所述的系统,其中,所述蓝牙设备还设置为执行以下操作之一:
    在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为HFP未连接的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为HSP未连接的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于HFP连接且通话状态切换为处于HFP连接但未通话的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于HSP连接且通话状态切换为处于HSP连接但未通话的状态;
    在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP未连接的状态;以及
    在保持Ble连接的基础上,将所述蓝牙设备从处于A2DP连接已使用状态切换为A2DP连接未使用的状态。
  51. 一种终端,包括处理器,设置为建立并保持终端与蓝牙设备的Ble连接;检测触发终端状态发生变化的操作;检测到触发终端状态发生变化的操作时, 向蓝牙设备发送通知消息;以及接收蓝牙设备的连接状态报告,并根据接收到的连接状态报告,在保持Ble连接的基础上,向所述蓝牙设备发起连接请求,建立蓝牙通信连接;其中,所述连接请求表示所述终端请求与所述蓝牙设备建立非低功耗蓝牙通信连接。
  52. 一种蓝牙设备,包括处理器,设置为建立并保持蓝牙设备与终端的Ble连接;接收通知消息,检测蓝牙设备所处的连接状态,根据检测到的连接状态及通知消息向终端发送连接状态报告。
  53. 一种计算机可读存储介质,存储有计算机可执行指令,所述计算机可执行指令设置为执行权利要求1-18中任一项的方法。
PCT/CN2017/092358 2016-11-07 2017-07-10 连接蓝牙设备的方法、装置、系统及设备 WO2018082335A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
EP17867752.2A EP3537734B1 (en) 2016-11-07 2017-07-10 Method and device for connecting a bluetooth device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610975510.XA CN108377482B (zh) 2016-11-07 2016-11-07 一种终端连接蓝牙设备的方法、装置、系统及设备
CN201610975510.X 2016-11-07

Publications (1)

Publication Number Publication Date
WO2018082335A1 true WO2018082335A1 (zh) 2018-05-11

Family

ID=62076587

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/092358 WO2018082335A1 (zh) 2016-11-07 2017-07-10 连接蓝牙设备的方法、装置、系统及设备

Country Status (3)

Country Link
EP (1) EP3537734B1 (zh)
CN (1) CN108377482B (zh)
WO (1) WO2018082335A1 (zh)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108650668A (zh) * 2018-05-17 2018-10-12 歌尔科技有限公司 连接请求处理方法、蓝牙耳机、穿戴设备及系统
CN113329389A (zh) * 2021-06-29 2021-08-31 北京小米移动软件有限公司 基于蓝牙连接的服务提供方法、装置、设备及存储介质
CN114079893A (zh) * 2020-08-13 2022-02-22 华为技术有限公司 蓝牙通信方法、终端设备及计算机可读存储介质

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110010139B (zh) * 2019-03-28 2021-12-21 南昌黑鲨科技有限公司 音频输入输出方法、系统及计算机可读存储介质
CN113225693B (zh) * 2019-04-18 2022-04-15 华为技术有限公司 一种蓝牙连接方法、设备及系统
CN112312368A (zh) * 2019-08-01 2021-02-02 阿里巴巴集团控股有限公司 数据处理方法、装置、设备和存储介质
CN111935801B (zh) * 2020-07-16 2023-04-28 中国联合网络通信集团有限公司 语音接入方法、系统、终端设备及计算机可读存储介质
CN114079892A (zh) * 2020-08-12 2022-02-22 华为技术有限公司 蓝牙通信方法、可穿戴设备及系统
CN114979352A (zh) * 2021-02-22 2022-08-30 华为技术有限公司 事件通知方法、蓝牙设备以及蓝牙系统
CN115696283A (zh) * 2021-07-28 2023-02-03 华为技术有限公司 音频控制方法、电子设备、音频设备和存储介质
CN115865140A (zh) * 2021-09-24 2023-03-28 Oppo广东移动通信有限公司 通话控制方法及装置、电子设备、计算机可读存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102378365A (zh) * 2010-08-24 2012-03-14 诺基亚公司 已存在的无线连接的通告
CN105406923A (zh) * 2015-12-28 2016-03-16 惠州Tcl移动通信有限公司 一种移动终端的蓝牙互连方法及系统
CN105429663A (zh) * 2015-12-18 2016-03-23 深圳市宏电技术股份有限公司 一种低功耗、高传输速率的可穿戴设备及其数据传输系统
CN106030455A (zh) * 2014-02-21 2016-10-12 三星电子株式会社 电子设备及其节电方法
CN106488383A (zh) * 2015-08-28 2017-03-08 宇龙计算机通信科技(深圳)有限公司 一种连接蓝牙设备的方法及装置

Family Cites Families (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140012913A1 (en) * 2012-07-05 2014-01-09 Devrim Varoglu Peer-Peer Device Activation and Setup
US9204243B2 (en) * 2013-03-15 2015-12-01 Blackberry Limited Method and apparatus pertaining to use of bluetooth and bluetooth low energy
KR20140146954A (ko) * 2013-06-18 2014-12-29 삼성전자주식회사 서비스 제공 방법 및 이를 위한 전자 기기
US9426749B2 (en) * 2014-05-05 2016-08-23 Intel IP Corporation Method and apparatus for Bluetooth-based Wi-Fi synchronization
CN104173057B (zh) * 2014-08-18 2016-04-13 复旦大学 基于移动通信的可穿戴式跌倒检测系统
US9763063B2 (en) * 2014-10-06 2017-09-12 Derek D. Kumar Secure broadcast beacon communications
KR20160042569A (ko) * 2014-10-10 2016-04-20 삼성전자주식회사 다중 연결 방법 및 이를 지원하는 전자 장치
CN104469660B (zh) * 2014-11-20 2018-04-10 青岛歌尔声学科技有限公司 基于蓝牙的组网方法
CN104540090B (zh) * 2014-12-25 2018-04-06 惠州Tcl移动通信有限公司 一种基于低功耗蓝牙的组网互连方法及系统
CN104618458B (zh) * 2015-01-13 2019-01-01 金廷岳 一种室内定位方法及系统使用改良的讯号指纹采集方法
CN105516896A (zh) * 2015-12-02 2016-04-20 惠州Tcl移动通信有限公司 一种可穿戴设备与移动终端的蓝牙互连方法及系统

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102378365A (zh) * 2010-08-24 2012-03-14 诺基亚公司 已存在的无线连接的通告
CN106030455A (zh) * 2014-02-21 2016-10-12 三星电子株式会社 电子设备及其节电方法
CN106488383A (zh) * 2015-08-28 2017-03-08 宇龙计算机通信科技(深圳)有限公司 一种连接蓝牙设备的方法及装置
CN105429663A (zh) * 2015-12-18 2016-03-23 深圳市宏电技术股份有限公司 一种低功耗、高传输速率的可穿戴设备及其数据传输系统
CN105406923A (zh) * 2015-12-28 2016-03-16 惠州Tcl移动通信有限公司 一种移动终端的蓝牙互连方法及系统

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3537734A4 *

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108650668A (zh) * 2018-05-17 2018-10-12 歌尔科技有限公司 连接请求处理方法、蓝牙耳机、穿戴设备及系统
WO2019218548A1 (zh) * 2018-05-17 2019-11-21 歌尔科技有限公司 连接请求处理方法、装置、蓝牙耳机、穿戴设备、系统及存储介质
US11178707B2 (en) 2018-05-17 2021-11-16 Goertek Technology Co., Ltd. Connection request processing method and apparatus, bluetooth earphone, wearable device, system and storage medium
CN114079893A (zh) * 2020-08-13 2022-02-22 华为技术有限公司 蓝牙通信方法、终端设备及计算机可读存储介质
CN114079893B (zh) * 2020-08-13 2023-10-13 华为技术有限公司 蓝牙通信方法、终端设备及计算机可读存储介质
CN113329389A (zh) * 2021-06-29 2021-08-31 北京小米移动软件有限公司 基于蓝牙连接的服务提供方法、装置、设备及存储介质

Also Published As

Publication number Publication date
CN108377482A (zh) 2018-08-07
EP3537734A1 (en) 2019-09-11
EP3537734B1 (en) 2022-06-22
EP3537734A4 (en) 2020-04-01
CN108377482B (zh) 2021-05-28

Similar Documents

Publication Publication Date Title
WO2018082335A1 (zh) 连接蓝牙设备的方法、装置、系统及设备
US11812485B2 (en) Bluetooth communication method and terminal
EP3361698B1 (en) Managing connections of a user device
CN111818503B (zh) 语音通话方法、系统、芯片、电子设备及存储介质
WO2019090726A1 (zh) 选择蓝牙设备的方法、终端和系统
WO2016131261A1 (zh) 一种多点连接控制方法、装置、终端及多点蓝牙耳机
CN109548184B (zh) 连接移动终端与蓝牙设备的方法、装置以及移动终端
KR102253561B1 (ko) 셀룰러 네트워크 상의 voip 콜 터널링 제어
WO2014047853A1 (zh) 一种蓝牙设备之间连接的方法及设备
CN110602681B (zh) 信息处理方法和电子设备
WO2017028567A1 (zh) 网络电话连接处理方法及装置
WO2011017875A1 (zh) 一种终端控制蓝牙耳机有序连接的方法及系统
WO2021196577A1 (zh) 蓝牙耳机的连接切换方法、装置、设备及存储介质
US9338290B2 (en) Method and apparatus for facilitating a communication session
WO2023087793A1 (zh) 音频业务处理方法、装置、电子设备及存储介质
KR101543163B1 (ko) 블루투스 연결 제어 방법
WO2023045784A1 (zh) 通话控制方法、装置、电子设备及计算机可读存储介质
WO2021239032A1 (zh) 蓝牙协议连接方法、装置、存储介质及相关设备
WO2022051901A1 (zh) 语音通话方法、系统、芯片、电子设备及存储介质
WO2023109282A1 (zh) 来电处理方法、装置、电子设备及存储介质
WO2014194671A1 (zh) 业务处理方法、终端设备和业务漫游网络
CN115987950A (zh) 通话方法、装置及设备
WO2015172370A1 (zh) 一种通信消息转移的方法及相关装置
WO2016070337A1 (zh) 一种基于蓝牙的处理信息的方法、装置及终端设备
TW201424331A (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: 17867752

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2017867752

Country of ref document: EP

Effective date: 20190607