WO2020082387A1 - 音频通道更换方法及相关设备 - Google Patents

音频通道更换方法及相关设备 Download PDF

Info

Publication number
WO2020082387A1
WO2020082387A1 PCT/CN2018/112240 CN2018112240W WO2020082387A1 WO 2020082387 A1 WO2020082387 A1 WO 2020082387A1 CN 2018112240 W CN2018112240 W CN 2018112240W WO 2020082387 A1 WO2020082387 A1 WO 2020082387A1
Authority
WO
WIPO (PCT)
Prior art keywords
earphone
mobile terminal
audio output
headset
audio
Prior art date
Application number
PCT/CN2018/112240
Other languages
English (en)
French (fr)
Inventor
龚金华
颜聪炜
Original Assignee
深圳市欢太科技有限公司
Oppo广东移动通信有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳市欢太科技有限公司, Oppo广东移动通信有限公司 filed Critical 深圳市欢太科技有限公司
Priority to CN201880098189.9A priority Critical patent/CN112771889A/zh
Priority to PCT/CN2018/112240 priority patent/WO2020082387A1/zh
Publication of WO2020082387A1 publication Critical patent/WO2020082387A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/725Cordless telephones
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R1/00Details of transducers, loudspeakers or microphones
    • H04R1/10Earpieces; Attachments therefor ; Earphones; Monophonic headphones

Definitions

  • the present application relates to the field of electronic technology, and in particular to an audio channel replacement method and related equipment.
  • wireless devices include wireless headphones and wireless speakers.
  • Mobile terminals such as smart phones, tablet computers, etc.
  • Embodiments of the present application provide an audio channel replacement method and related equipment, so as to ensure that users can listen to audio in time after removing the headphones, and improve the accuracy of audio output.
  • an embodiment of the present application provides an audio channel replacement method, which is applied to a mobile terminal, the mobile terminal is in communication connection with a first headset of a wireless headset, and the first headset communicates with a second headset of the wireless headset Connection, the method includes:
  • an embodiment of the present application provides an audio channel replacement device, which is applied to a mobile terminal, and the mobile terminal is in communication connection with a first headset of a wireless headset, and the first headset communicates with a second headset of the wireless headset Connected, the device includes:
  • the processing unit is configured to set the audio output channel and the audio input channel to the wireless earphones; when it is determined that both the first earphone and the second earphone are in a non-wearing state, replace the audio output channel to the The audio output device of the mobile terminal; when switching the audio output channel to the audio output device of the mobile terminal, replace the audio input channel with the audio input device of the mobile terminal.
  • an embodiment of the present application provides a mobile terminal, including a processor, a memory, a communication interface, and one or more programs, where the one or more programs are stored in the memory and configured to be processed by the above
  • the above program includes instructions for performing the steps in the method described in the first aspect of the embodiments of the present application.
  • an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program for electronic data exchange, wherein the computer program causes the computer to execute the first embodiment of the present application. Part or all of the steps described in the method described in one aspect.
  • an embodiment of the present application provides a computer program product, wherein the computer program product includes a non-transitory computer-readable storage medium storing the computer program, and the computer program is operable to cause the computer to execute Examples of some or all of the steps described in the method described in the first aspect.
  • the computer program product may be a software installation package.
  • the mobile terminal first sets the audio output channel and the audio input channel as wireless headphones, and when it is determined that both the first and second headphones of the wireless headphones are in a non-wearing state, directly output the audio
  • the channel is replaced with the audio output device of the mobile terminal, and the audio input channel is replaced with the audio input device of the mobile terminal, so as to ensure that the user can listen to the audio in time after removing the earphone, and improve the accuracy of the audio output.
  • 1A is a schematic diagram of a program running space of a smart phone
  • Figure 1B is a system architecture diagram of an Android system
  • FIG. 2A is a schematic flowchart of an audio channel replacement method provided by an embodiment of the present application.
  • 2B is a schematic diagram of an example of a location of an infrared proximity sensor provided by an embodiment of the present application
  • 2C is a schematic diagram of an example of a position of a pressure proximity sensor provided by an embodiment of the present application.
  • FIG. 3 is a schematic flowchart of another audio channel replacement method disclosed in an embodiment of the present application.
  • FIG. 4 is a schematic structural diagram of a mobile terminal disclosed in an embodiment of the present application.
  • FIG. 5 is a block diagram of functional units of an audio channel replacement device disclosed in an embodiment of the present application.
  • currently mobile terminals such as smartphones are generally provided with a program running space
  • the program running space includes a user space and an operating system space, where the user space runs one or more application programs, and the one or more applications
  • the program is a third-party application program installed on the mobile terminal.
  • the software algorithm of the audio output control method described in the embodiments of the present application may run in the user space, and the operating system space runs the operating system of the mobile terminal.
  • the mobile terminal can specifically run the Android Android system, the mobile operating system iOS developed by Apple, etc., which is not limited here.
  • the corresponding user space includes the application layer (Applications) in the Android system
  • the operating system space may include the application framework layer (Application) in the Android system Framework), system runtime library layer (including system runtime library layer Libraries and Android runtime Android Runtime), Linux kernel layer (Linux Kernel).
  • the application layer includes various application programs that directly interact with users, or service programs written in the Java language and running in the background.
  • the application framework layer provides a series of class libraries needed to develop Android applications, which can be used to reuse components, and can also be personalized through inheritance.
  • the system runtime layer is the support of the application framework and provides services for various components in the Android system.
  • the system runtime library layer is composed of the system class library and the Android runtime.
  • the Android runtime contains two parts: the core library and the Dalvik virtual machine.
  • the Linux kernel layer is used to implement core functions such as hardware device drivers, process and memory management, network protocol stack, power management, and wireless communication.
  • Mobile terminals can include various handheld devices with wireless communication capabilities, in-vehicle devices, wearable devices (such as smart watches, smart bracelets, pedometers, etc.), computing devices or other processing devices that are communicatively connected to wireless modems, and Various forms of user equipment (User Equipment, UE), mobile station (Mobile Station, MS), terminal equipment (terminal), etc.
  • UE User Equipment
  • MS Mobile Station
  • terminal terminal
  • the above-mentioned devices are collectively referred to as mobile terminals.
  • FIG. 2A is a schematic flowchart of an audio channel replacement method provided by an embodiment of the present application, which is applied to a mobile terminal.
  • the mobile terminal is in communication connection with a first headset of a wireless headset, and the first headset is connected to The second earphone communication connection of the wireless earphone, the audio channel replacement method includes:
  • Step 201 The mobile terminal sets the audio output channel and the audio input channel to the wireless headset.
  • step 201 is performed; and / or after the mobile terminal establishes a communication connection with the first headset, if the application running in the foreground of the mobile terminal is the target application, step 201 is performed.
  • the target application is an application that requires audio input or audio output, such as a call application, an instant messaging application, an audio playback application, a video playback application, a shopping application, a news application, etc .; and / or in determining the first headset and / or the second When the headset is in the wearing state, step 201 is executed.
  • Step 202 When it is determined that both the first earphone and the second earphone are in a non-wearing state, the mobile terminal replaces the audio output channel with the audio output device of the mobile terminal.
  • the audio output device of the mobile terminal includes, for example, a receiver, a speaker, and a microphone.
  • Step 203 When switching the audio output channel to the audio output device of the mobile terminal, the mobile terminal replaces the audio input channel with the audio input device of the mobile terminal.
  • the audio input device of the mobile terminal includes, for example, a receiver, a speaker, and a microphone.
  • this audio channel replacement method is suitable for call scenarios, multimedia playback scenarios, recording scenarios, instant messaging chat scenarios that can send voice or play voice, and so on.
  • the first earphone has audio output and audio input functions
  • the second earphone also has audio output and audio input functions; or, the first earphone has only audio output, and the second earphone has audio output and audio input functions; Alternatively, the first earphone has audio output and audio input functions, while the second earphone has only audio output.
  • the mobile terminal first sets the audio output channel and the audio input channel as wireless headphones, and when it is determined that both the first earphone and the second earphone are in a non-wearing state, the audio output channel is directly replaced with
  • the audio output device of the mobile terminal and the replacement of the audio input channel with the audio input device of the mobile terminal can ensure that the user can listen to the audio in time after removing the earphone, improve the accuracy of the audio output, and thus improve the user experience.
  • the determining that both the first earphone and the second earphone are in a non-wearing state includes:
  • the first signaling is used to inform the The first earphone is in a non-wearing state
  • the second signaling is used to inform the second earphone in a non-wearing state
  • the first signaling is that the first earphone detects that the first earphone is in a non-wearing state
  • the second signaling is forwarded by the second earphone when the second earphone detects that the second earphone is in a non-wearing state.
  • the sending moments of the first signaling and the second signaling may be the same or different, which is not limited herein.
  • the mobile terminal is notified through signaling that the headset is in the non-wearing state, the process is simple, and the convenience of the mobile terminal in determining the wearing state of the headset is improved.
  • both the first earphone and the second earphone include an infrared proximity sensor, and when the infrared proximity sensor of the first earphone is in a remote state, the first earphone detects The first earphone is in a non-wearing state; when the infrared proximity sensor of the second earphone is in a away state, the second earphone detects that the second earphone is in a non-wearing state.
  • the infrared proximity sensor is provided on the housing of the earphone. When the earphone is worn, the infrared proximity sensor is blocked, so that the infrared proximity sensor is in a close state, and when the earphone is not worn, the infrared proximity sensor is not covered. Make the infrared proximity sensor far away.
  • the working principle of the infrared proximity sensor is to determine whether the infrared proximity sensor is in the proximity state or the distance state by the time when the infrared light is emitted and the time when the infrared light is reflected back.
  • the infrared proximity sensor is disposed on the housing of the earphone, when the earphone is worn by the user, the infrared proximity sensor is blocked.
  • the time for the infrared proximity sensor to emit infrared light is The time difference between receiving the infrared light is close to 0. At this time, the infrared proximity sensor is considered to be in a close state.
  • the infrared proximity sensor When the headset is not worn by the user, the infrared proximity sensor is not covered. In this case, the infrared proximity sensor emits infrared light at the time it receives The time difference of the infrared light is far greater than 0, and at this time, the infrared proximity sensor is considered to be in the away state.
  • the first earphone and the second earphone each include a plurality of pressure sensors, and the pressure values detected by the plurality of pressure sensors of the first earphone are all below 0,
  • the first earphone detects that the first earphone is in a non-wearing state; when the pressure values detected by the plurality of pressure sensors of the second earphone are all 0, the second earphone detects the first earphone 2.
  • the headset is in a non-wearing state.
  • the plurality of pressure sensors are disposed below the target surface of the earphone.
  • the target surface is in contact with the skin, so that the pressure values detected by at least two pressure sensors among the plurality of pressure sensors are not 0, when the earphone is worn, the target surface is not in contact with the skin, so that the pressure values detected by the plurality of pressure sensors are all 0.
  • At least two of the plurality of pressure sensors of the first earphone have a detected pressure value other than 0, the first earphone detects that the first earphone is in a wearing state; At least two of the plurality of pressure sensors of the second earphone have detected pressure values other than 0, and the second earphone detects that the second earphone is in a wearing state.
  • At least two pressure sensors have a pressure value other than 0, which includes at least one of the following: the pressure values detected by the at least two pressure sensors are all greater than or equal to the first threshold, the at least two The sum of the pressure values detected by the two sensors is greater than or equal to the second threshold.
  • the first threshold and the second threshold may be user-defined or earphone-defined, which is not limited herein.
  • the installation positions of multiple pressure sensors in the earphone are shown in FIG. 2C.
  • the above multiple pressure sensors may detect the following situations: 1. Some pressure sensors do not detect the value; 2. The values detected by some pressure sensors are not large; 3. The values detected by the multiple pressure sensors are all; 4. The values detected by the multiple pressure sensors are all greater than one value. Therefore, it can be judged whether the earphone is in the wearing state according to the conditions detected by the multiple pressure sensors.
  • multiple pressure sensors are used to determine whether the earphone is worn, which improves the accuracy of detection of the wearing state.
  • the method before the mobile terminal replaces the audio output channel with the audio output device of the mobile terminal, the method further includes: the mobile terminal determines that the first headset is disconnected from the Mobile terminal communication connection.
  • the disconnection of the first earphone from the communication connection with the mobile terminal may be actively triggered by the first earphone (eg, triggered when both the first earphone and the second earphone are in a non-wearing state), or may be the user ’s Triggered by a button (such as pressing the power button of the first headset, etc.).
  • the communication connection between the first headset and the mobile terminal includes, for example, a call voice connection, a hands-free protocol (Hands-free Profile, HFP) connection, a Bluetooth audio transmission model protocol (Advanced Audio Distribution Profile, A2DP) connection, and so on.
  • a call voice connection a hands-free protocol (Hands-free Profile, HFP) connection
  • a Bluetooth audio transmission model protocol Advanced Audio Distribution Profile, A2DP
  • the audio channel is switched only when the first earphone and the second earphone are both in a non-wearing state, and the first earphone is disconnected from the communication connection of the mobile terminal. Improve the accuracy of audio output.
  • the method before the mobile terminal replaces the audio output channel with the audio output device of the mobile terminal, the method further includes: the mobile terminal receives specific signaling from the first headset , The specific signaling is used to instruct to change the audio channel.
  • the specific signaling may be actively triggered by the first earphone (for example, triggered when both the first earphone and the second earphone are in a non-wearing state), or may be triggered by a user through a button of the first earphone (for example, pressing The power button of the first headset, etc.).
  • the audio channel is switched only when the first headset and the second headset are both in a non-wearing state and certain signaling is received, which further improves the accuracy of the audio output .
  • the method further includes:
  • the mobile terminal adjusts the output volume of the audio output device of the mobile terminal to the first volume.
  • the first volume is determined based on the current geographic location, specifically based on the first mapping relationship and the current geographic location.
  • the first mapping relationship is a mapping relationship between the volume of the audio output channel located under the mobile terminal and the geographic location.
  • the size of the output volume is reasonably adjusted to improve the audio listening effect.
  • the first earphone has an audio output and audio input function
  • the second earphone has an audio output function
  • the method further includes:
  • the mobile terminal When it is determined that the first earphone is in a worn state, or the first earphone and the second earphone are in a worn state, the mobile terminal replaces the audio output channel and the audio input channel with the wireless earphone;
  • the mobile terminal After determining that the second earphone is in a worn state, the mobile terminal replaces the audio output channel with the wireless earphone.
  • both the first earphone and the second earphone have audio output and audio input functions.
  • the method further includes:
  • the mobile terminal After determining that the first earphone and / or the second earphone are in a worn state, the mobile terminal replaces the audio output channel and the audio input channel with the wireless earphone.
  • the method further includes:
  • the mobile terminal When it is determined that the second earphone is in a worn state, or the first earphone and the second earphone are in a worn state, the mobile terminal replaces the audio output channel and the audio input channel with the wireless earphone;
  • the mobile terminal After determining that the first earphone is in a worn state, the mobile terminal replaces the audio output channel with the wireless earphone.
  • the mobile terminal when a change in the wearing state of the earphone is sent, the mobile terminal promptly switches the audio channel based on the wearing state of the earphone, thereby improving the accuracy of audio output and thereby improving the user experience.
  • the determining that both the first earphone and / or the second earphone are in a wearing state includes:
  • the third signaling is used to inform The first earphone is in a worn state
  • the fourth signaling is used to inform the second earphone in a worn state
  • the third signaling is when the first earphone detects that the first earphone is in a worn state
  • the fourth signaling is forwarded through the first earphone when the second earphone detects that the second earphone is in a wearing state.
  • the sending moments of the third signaling and the fourth signaling may be the same or different, which is not limited herein.
  • the mobile terminal is notified through signaling that the headset is in the wearing state, the process is simple, and the convenience of the mobile terminal in determining the wearing state of the headset is improved.
  • the method further includes:
  • the mobile terminal adjusts the output volume of the wireless headset to the second volume.
  • the second volume is determined based on the current geographic location, specifically based on the second mapping relationship and the current geographic location.
  • the second mapping relationship is a mapping relationship between the volume of the audio output channel under the wireless headset and the geographic location.
  • the size of the output volume is reasonably adjusted to improve the audio listening effect.
  • FIG. 3 is a schematic flowchart of an audio channel replacement method provided by an embodiment of the present application, which is applied to a mobile terminal, the mobile terminal and the wireless headset.
  • a first headset is communicatively connected, the first headset is communicatively connected to a second headset of the wireless headset, the first headset has audio output and audio input functions, and the second headset has audio output functions, as shown ,
  • This audio channel replacement method includes:
  • Step 301 The mobile terminal sets the audio output channel and the audio input channel as the wireless headset.
  • Step 302 The mobile terminal receives first signaling and second signaling from the first headset, where the first signaling is used to inform that the first headset is in a non-wearing state, and the second signaling is used to Inform that the second earphone is in a non-wearing state, the first signaling is sent when the first earphone detects that the first earphone is in a non-wearing state, and the second signaling is the second earphone Forwarded through the first earphone when it is detected that the second earphone is in a non-wearing state.
  • Step 303 When it is determined that both the first earphone and the second earphone are in a non-wearing state, the mobile terminal replaces the audio output channel with the audio output device of the mobile terminal.
  • Step 304 When switching the audio output channel to the audio output device of the mobile terminal, the mobile terminal replaces the audio input channel with the audio input device of the mobile terminal.
  • Step 305 After determining that the first earphone is in a worn state, or the first earphone and the second earphone are in a worn state, the mobile terminal replaces the audio output channel and the audio input channel with the wireless headset.
  • FIG. 4 is a schematic structural diagram of a mobile terminal provided by an embodiment of the present application.
  • the mobile terminal is in communication connection with a first headset of a wireless headset
  • the first headset is in communication connection with the second headset of the wireless headset.
  • the electronic device includes a processor, a memory, a communication interface, and one or more programs, wherein the one or more programs are Stored in the aforementioned memory and configured to be executed by the aforementioned processor, the aforementioned program includes instructions for performing the following steps:
  • the determining that both the first earphone and the second earphone are in a non-wearing state includes:
  • the first signaling is used to inform the The first earphone is in a non-wearing state
  • the second signaling is used to inform the second earphone in a non-wearing state
  • the first signaling is that the first earphone detects that the first earphone is in a non-wearing state Sent in the state
  • the second signaling is forwarded by the first earphone when the second earphone detects that the second earphone is in a non-wearing state.
  • both the first earphone and the second earphone include an infrared proximity sensor, and when the infrared proximity sensor of the first earphone is in a remote state, the first earphone detects The first earphone is in a non-wearing state; when the infrared proximity sensor of the second earphone is in a away state, the second earphone detects that the second earphone is in a non-wearing state.
  • the first earphone and the second earphone each include a plurality of pressure sensors, and the pressure values detected by the plurality of pressure sensors of the first earphone are all below 0,
  • the first earphone detects that the first earphone is in a non-wearing state; when the pressure values detected by the plurality of pressure sensors of the second earphone are all 0, the second earphone detects the first earphone 2.
  • the headset is in a non-wearing state.
  • the above program before replacing the audio output channel with the audio output device of the mobile terminal, includes instructions for performing the following steps:
  • the above program before replacing the audio output channel with the audio output device of the mobile terminal, includes instructions for performing the following steps:
  • the specific signaling is used to instruct to change the audio channel.
  • the first earphone has an audio output and audio input function
  • the second earphone has an audio output function, after replacing the audio input channel with the audio input device of the mobile terminal .
  • the audio output channel is replaced with the wireless earphone.
  • the electronic device includes a hardware structure and / or a software module corresponding to each function.
  • the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed by hardware or computer software driven hardware depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
  • the embodiment of the present application may divide the functional unit of the electronic device according to the method example, for example, each functional unit may be divided corresponding to each function, or two or more functions may be integrated into one processing unit.
  • the integrated unit may be implemented in the form of hardware or a software functional unit. It should be noted that the division of units in the embodiments of the present application is schematic, and is only a division of logical functions, and there may be other division manners in actual implementation.
  • FIG. 5 is an audio channel replacement device provided by an embodiment of the present application, which is applied to a mobile terminal.
  • the mobile terminal is in communication with a first headset of a wireless headset, and the first headset is connected to the wireless headset
  • the second headset communication connection, the audio channel replacement device includes:
  • the processing unit 501 is configured to set the audio output channel and the audio input channel to the wireless earphones; when it is determined that both the first earphone and the second earphone are in a non-wearing state, replace the audio output channel to The audio output device of the mobile terminal; when switching the audio output channel to the audio output device of the mobile terminal, replace the audio input channel with the audio input device of the mobile terminal.
  • the audio channel replacement device further includes a communication unit 502 and a storage unit 503, the processing unit 501 may be a processor, the communication unit 502 may be a communication interface, and the storage unit 503 may be a memory.
  • the determining that both the first headset and the second headset are in a non-wearing state includes: after receiving the first signaling from the first headset through the communication unit 502 and After the second signaling, it is determined that both the first headset and the second headset are in a non-wearing state, the first signaling is used to inform the first headset that it is in a non-wearing state, and the second signaling is used To inform that the second headset is in a non-wearing state, the first signaling is sent when the first headset detects that the first headset is in a non-wearing state, and the second signaling is the second When the earphone detects that the second earphone is in a non-wearing state, it is forwarded through the first earphone.
  • both the first earphone and the second earphone include an infrared proximity sensor, and when the infrared proximity sensor of the first earphone is in a remote state, the first earphone detects The first earphone is in a non-wearing state; when the infrared proximity sensor of the second earphone is in a away state, the second earphone detects that the second earphone is in a non-wearing state.
  • the first earphone and the second earphone each include a plurality of pressure sensors, and the pressure values detected by the plurality of pressure sensors of the first earphone are all below 0,
  • the first earphone detects that the first earphone is in a non-wearing state; when the pressure values detected by the plurality of pressure sensors of the second earphone are all 0, the second earphone detects the first earphone 2.
  • the headset is in a non-wearing state.
  • the processing unit 501 before the processing unit 501 replaces the audio output channel with the audio output device of the mobile terminal, the processing unit 501 is also used to determine that the first earphone is disconnected from the mobile Terminal communication connection.
  • the processing unit 501 before the processing unit 501 replaces the audio output channel with the audio output device of the mobile terminal, the processing unit 501 is further configured to receive the first headset through the communication unit 502. Specific signaling, which is used to instruct to change the audio channel.
  • the first earphone has an audio output and audio input function
  • the second earphone has an audio output function
  • the processing unit 501 replaces the audio input channel with the audio of the mobile terminal
  • the processing unit 501 is further configured to input the audio output channel and the audio when it is determined that the first earphone is in a worn state, or the first earphone and the second earphone are in a worn state
  • the channel is replaced with the wireless headset; when it is determined that the second headset is in a wearing state, the audio output channel is replaced with the wireless headset.
  • An embodiment of the present application further provides a computer storage medium, wherein the computer storage medium stores a computer program for electronic data exchange, which causes the computer to perform part or all of the steps of any method described in the above method embodiments ,
  • the aforementioned computer includes a mobile terminal.
  • Embodiments of the present application also provide a computer program product, where the computer program product includes a non-transitory computer-readable storage medium that stores the computer program, and the computer program is operable to cause the computer to perform any of the methods described in the foregoing method embodiments Some or all steps of the method.
  • the computer program product may be a software installation package.
  • the computer includes a mobile terminal.
  • the disclosed device may be implemented in other ways.
  • the device embodiments described above are only schematic.
  • the above-mentioned unit division is only a logical function division.
  • there may be other division modes for example, multiple units or components may be combined or integrated To another system, or some features can be ignored, or not implemented.
  • the displayed or discussed mutual coupling or direct coupling or communication connection may be indirect coupling or communication connection through some interfaces, devices or units, and may be in electrical or other forms.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
  • the above integrated unit can be implemented in the form of hardware or software function unit.
  • the above integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer readable memory.
  • the technical solution of the present application essentially or part of the contribution to the existing technology or all or part of the technical solution can be embodied in the form of a software product, the computer software product is stored in a memory, Several instructions are included to enable a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the above methods in various embodiments of the present application.
  • the aforementioned memory includes: U disk, Read-Only Memory (ROM, Read-Only Memory), Random Access Memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.
  • the program may be stored in a computer-readable memory, and the memory may include: a flash disk , Read-Only Memory (English: Read-Only Memory, abbreviation: ROM), Random Access Device (English: Random Access Memory, abbreviation: RAM), magnetic disk or optical disk, etc.
  • ROM Read-Only Memory
  • RAM Random Access Device
  • magnetic disk or optical disk etc.

Abstract

本申请公开了一种音频通道更换方法及相关设备,应用于移动终端,移动终端与无线耳机的第一耳机通信连接,第一耳机与无线耳机的第二耳机通信连接,方法包括:将音频输出通道和音频输入通道设置为无线耳机;在确定第一耳机和第二耳机均处于非佩戴状态时,将音频输出通道更换为移动终端的音频输出装置;在将音频输出通道切换至移动终端的音频输出装置时,将音频输入通道更换为移动终端的音频输入装置。采用本申请实施例可保证用户在摘下耳机后及时收听到音频,提升音频输出的准确性。

Description

音频通道更换方法及相关设备 技术领域
本申请涉及电子技术领域,尤其涉及一种音频通道更换方法及相关设备。
背景技术
随着无线技术的应用日益扩大,支持无线通信连接的无线设备种类也日益增多,无线设备例如有无线耳机、无线音箱等。移动终端(比如智能手机、平板电脑等)可以与无线设备通信连接,然后通过无线设备实现某些功能,比如输出音频等。
发明内容
本申请实施例提供一种音频通道更换方法及相关设备,以保证用户在摘下耳机后及时收听到音频,提升音频输出的准确性。
第一方面,本申请实施例提供一种音频通道更换方法,应用于移动终端,所述移动终端与无线耳机的第一耳机通信连接,所述第一耳机与所述无线耳机的第二耳机通信连接,所述方法包括:
将音频输出通道和音频输入通道设置为所述无线耳机;
在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,将所述音频输出通道更换为所述移动终端的音频输出装置;
在将所述音频输出通道切换至所述移动终端的音频输出装置时,将所述音频输入通道更换为所述移动终端的音频输入装置。
第二方面,本申请实施例提供一种音频通道更换装置,应用于移动终端,所述移动终端与无线耳机的第一耳机通信连接,所述第一耳机与所述无线耳机的第二耳机通信连接,所述装置包括:
处理单元,用于将音频输出通道和音频输入通道设置为所述无线耳机;在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,将所述音频输出通道更换为所述移动终端的音频输出装置;在将所述音频输出通道切换至所述移动终端的音频输出装置时,将所述音频输入通道更换为所述移动终端的音频输入 装置。
第三方面,本申请实施例提供一种移动终端,包括处理器、存储器、通信接口以及一个或多个程序,其中,上述一个或多个程序被存储在上述存储器中,并且被配置由上述处理器执行,上述程序包括用于执行本申请实施例第一方面所述的方法中的步骤的指令。
第四方面,本申请实施例提供了一种计算机可读存储介质,其中,上述计算机可读存储介质存储用于电子数据交换的计算机程序,其中,上述计算机程序使得计算机执行如本申请实施例第一方面所述的方法中所描述的部分或全部步骤。
第五方面,本申请实施例提供了一种计算机程序产品,其中,上述计算机程序产品包括存储了计算机程序的非瞬时性计算机可读存储介质,上述计算机程序可操作来使计算机执行如本申请实施例第一方面所述的方法中所描述的部分或全部步骤。该计算机程序产品可以为一个软件安装包。
可以看出,在本申请实施例中,移动终端先将音频输出通道和音频输入通道设置为无线耳机,在确定无线耳机的第一耳机和第二耳机均处于非佩戴状态时,直接将音频输出通道更换为移动终端的音频输出装置,以及将音频输入通道更换为移动终端的音频输入装置,这样可保证用户在摘下耳机后及时收听到音频,提升音频输出的准确性。
附图说明
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1A是一种智能手机的程序运行空间的示意图;
图1B是一种安卓系统的系统架构图;
图2A是本申请实施例提供的一种音频通道更换方法的流程示意图;
图2B是本申请实施例提供的一种红外接近传感器所在位置的示例的示意 图;
图2C是本申请实施例提供的一种压力接近传感器所在位置的示例的示意图;
图3是本申请实施例公开的另一种音频通道更换方法的流程示意图;
图4是本申请实施例公开的一种移动终端的结构示意图;
图5是本申请实施例公开的一种音频通道更换装置的功能单元组成框图。
具体实施方式
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分的实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本申请保护的范围。
以下分别进行详细说明。
本申请的说明书和权利要求书及所述附图中的术语“第一”、“第二”、“第三”和“第四”等是用于区别不同对象,而不是用于描述特定顺序。此外,术语“包括”和“具有”以及它们任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或单元的过程、方法、系统、产品或设备没有限定于已列出的步骤或单元,而是可选地还包括没有列出的步骤或单元,或可选地还包括对于这些过程、方法、产品或设备固有的其它步骤或单元。
在本文中提及“实施例”意味着,结合实施例描述的特定特征、结构或特性可以包含在本申请的至少一个实施例中。在说明书中的各个位置出现该短语并不一定均是指相同的实施例,也不是与其它实施例互斥的独立的或备选的实施例。本领域技术人员显式地和隐式地理解的是,本文所描述的实施例可以与其它实施例相结合。
如图1A所示,目前智能手机等移动终端一般设置有程序运行空间,该程序运行空间包括用户空间和操作系统空间,其中,用户空间运行有一个或多个应用程序,该一个或多个应用程序为移动终端安装的第三方应用程序,本申请 实施例所描述的音频输出控制方法的软件算法可以运行在用户空间,操作系统空间运行有移动终端的操作系统。
该移动终端具体可以运行安卓Android系统、苹果公司开发的移动操作系统iOS等,此处不做唯一限定。如图1B所示,以所述移动终端运行有Android系统为例,对应的用户空间包括该Android系统中的应用层(Applications),操作系统空间可以包括该Android系统中的应用程序框架层(Application Framework)、系统运行库层(包括系统运行库层Libraries和Android运行时Android Runtime)、Linux内核层(Linux Kernel)。其中,应用层上包括各类与用户直接交互的应用程序,或由Java语言编写的运行于后台的服务程序。例如,智能手机上实现的常见基本功能的程序,诸如短消息业务(Short Messaging Service,SMS)短信,电话拨号,图片浏览器,日历,游戏,地图,万维网(World Wide Web,Web)浏览器等程序,以及开发人员开发的其他应用程序。应用程序框架层提供开发Android应用程序所需的一系列类库,能够用于重用组件,也可以通过继承实现个性化的扩展。系统运行库层是应用程序框架的支撑,为Android系统中的各个组件提供服务。系统运行库层由系统类库和Android运行时构成。Android运行时包含核心库和Dalvik虚拟机两部分。Linux内核层用于实现硬件设备驱动,进程和内存管理,网络协议栈,电源管理,无线通信等核心功能。
移动终端可以包括各种具有无线通信功能的手持设备、车载设备、可穿戴设备(例如智能手表、智能手环、计步器等)、计算设备或通信连接到无线调制解调器的其他处理设备,以及各种形式的用户设备(User Equipment,UE),移动台(Mobile Station,MS),终端设备(terminal device)等等。为方便描述,上面提到的设备统称为移动终端。
下面对本申请实施例进行详细介绍。
请参阅图2A,图2A是本申请实施例提供了一种音频通道更换方法的流程示意图,应用于移动终端,所述移动终端与无线耳机的第一耳机通信连接,所述第一耳机与所述无线耳机的第二耳机通信连接,本音频通道更换方法包括:
步骤201:移动终端将音频输出通道和音频输入通道设置为所述无线耳 机。
进一步地,在移动终端与第一耳机建立通信连接时,执行步骤201;和/或在移动终端与第一耳机建立通信连接之后,若移动终端前台运行的应用为目标应用,执行步骤201,该目标应用为需要音频输入或音频输出的应用,例如有通话应用、即时通信应用、音频播放应用、视频播放应用、购物应用、新闻应用等等;和/或在确定第一耳机和/或第二耳机处于佩戴状态时,执行步骤201。
步骤202:在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,移动终端将所述音频输出通道更换为所述移动终端的音频输出装置。
其中,移动终端的音频输出装置例如有听筒、扬声器、麦克风等。
步骤203:在将所述音频输出通道切换至所述移动终端的音频输出装置时,移动终端将所述音频输入通道更换为所述移动终端的音频输入装置。
其中,移动终端的音频输入装置例如有听筒、扬声器、麦克风等。
进一步地,本音频通道更换方法适用于通话场景、多媒体播放场景、录音场景、能够发送语音或播放语音的即时通信聊天场景等等。
需要说明的是,第一耳机具有音频输出和音频输入功能,第二耳机也具有音频输出和音频输入功能;或者,第一耳机仅具有音频输出,而第二耳机具有音频输出和音频输入功能;或者,第一耳机具有音频输出和音频输入功能,而第二耳机仅具有音频输出。
可以看出,在本申请实施例中,移动终端先将音频输出通道和音频输入通道设置为无线耳机,在确定第一耳机和第二耳机均处于非佩戴状态时,直接将音频输出通道更换为移动终端的音频输出装置,以及将音频输入通道更换为移动终端的音频输入装置,这样可保证用户在摘下耳机后及时收听到音频,提升音频输出的准确性,进而提升用户体验。
在本申请的一实现方式中,所述确定所述第一耳机和所述第二耳机均处于非佩戴状态,包括:
在接收到来自所述第一耳机的第一信令和第二信令后,确定所述第一耳机和所述第二耳机均处于非佩戴状态,所述第一信令用于告知所述第一耳机处于非佩戴状态,所述第二信令用于告知所述第二耳机处于非佩戴状态,所述第一 信令是所述第一耳机检测到所述第一耳机处于非佩戴状态时发送的,所述第二信令是所述第二耳机检测到所述第二耳机处于非佩戴状态时通过所述第一耳机转发的。
其中,第一信令和第二信令发送时刻可以相同的,也可以是不相同的,在此不作限定。
可以看出,在本申请实施例中,通过信令告知移动终端耳机处于非佩戴状态,流程简单,提升移动终端确定耳机佩戴状态的便捷性。
在本申请的一实现方式中,所述第一耳机和所述第二耳机均包括红外接近传感器,在所述第一耳机的所述红外接近传感器处于远离状态下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述红外接近传感器处于远离状态下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
进一步地,红外接近传感器设于耳机的壳体上,在耳机被佩戴时,红外接近传感器被遮住,使得红外接近传感器处于接近状态,在耳机未被佩戴时,红外接近传感器未被遮住,使得红外接近传感器处于远离状态。
具体地,红外接近传感器的工作原理是通过发射红外光的时间与接收该红外光反射回来的时间确定红外接近传感器是处于接近状态还是处于远离状态。在本申请实施例中,如图2B所示,由于红外接近传感器设置在耳机的壳体上,在耳机被用户佩戴时,红外接近传感器被遮住,这样的话红外接近传感器发射红外光的时间与接收到该红外光的时间差接近于0,此时认为红外接近传感器处于接近状态,在耳机未被用户佩戴时,红外接近传感器未被遮住,这样的话红外接近传感器发射红外光的时间与接收到该红外光的时间差远远大于0,此时认为红外接近传感器处于远离状态。
可以看出,在本申请实施例中,通过红外接近传感器确定耳机是否处于佩戴状态,简单便捷,提升佩戴状态检测的便捷性。
在本申请的一实现方式中,所述第一耳机和所述第二耳机均包括多个压力传感器,在所述第一耳机的所述多个压力传感器检测到的压力值均为0下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述多个压力传感器检测到的压力值均为0下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
进一步地,该多个压力传感器设置于耳机的目标表面的下方,在耳机被佩戴时,该目标表面与皮肤接触,使得该多个压力传感器中存在至少两个压力传感器检测到的压力值不为0,在耳机被佩戴时,该目标表面未与皮肤接触,使得该多个压力传感器检测到的压力值均为0。
进一步地,在所述第一耳机的所述多个压力传感器中存在至少两个检测到的压力值不为0下,所述第一耳机检测到所述第一耳机处于佩戴状态;在所述第二耳机的所述多个压力传感器中存在至少两个检测到的压力值不为0下,所述第二耳机检测到所述第二耳机处于佩戴状态。
进一步地,多个压力传感器中存在至少两个压力传感器检测到的压力值不为0包括以下至少一种:该至少两个压力传感器检测到的压力值均大于或等于第一阈值,该至少两个传感器检测到的压力值的和大于或等于第二阈值。
其中,第一阈值和第二阈值可以是用户自定义的,也可以是耳机自定义的,在此不作限定。多个压力传感器在耳机中的设置位置如图2C所示。
具体地,用户佩戴耳机有些人喜欢搭在耳朵上,有些用户喜欢塞在耳朵里,这样的话上述多个压力传感器检测到的情况可能有以下几种:1、某些压力传感器没有检测到数值;2、有些压力传感器检测到的数值不大;3、这多个压力传感器均检测到数值;4、这多个压力传感器检测到的数值均大于一个值。因此可根据多个压力传感器检测到的情况判断耳机是否处于佩戴状态。
可以看出,在本申请实施例中,通过多个压力传感器共同确定耳机是否被佩戴,提升了佩戴状态的检测准确度。
在本申请的一实现方式中,所述移动终端将所述音频输出通道更换为所述移动终端的音频输出装置之前,所述方法还包括:移动终端确定所述第一耳机断开与所述移动终端的通信连接。
进一步地,第一耳机断开与移动终端的通信连接可以是第一耳机主动触发的(如在第一耳机和第二耳机均处于非佩戴状态下触发),也可以是用户通过第一耳机的按键触发的(如按压第一耳机的电源按键等)。
进一步地,第一耳机与移动终端的通信连接例如有:通话语音连接、免提协议(Hands-free Profile,HFP)连接、蓝牙音频传输模型协议(Advanced Audio Distribution Profile,A2DP)连接等。
可以看出,在本申请实施例中,在第一耳机与第二耳机均处于非佩戴状态,且第一耳机断开与移动终端的通信连接的情况下,才进行音频通道的切换,更进一步提升音频输出的准确性。
在本申请的一实现方式中,所述移动终端将所述音频输出通道更换为所述移动终端的音频输出装置之前,所述方法还包括:移动终端接收来自所述第一耳机的特定信令,所述特定信令用于指示更换音频通道。
进一步地,该特定信令是可以是第一耳机主动触发的(如在第一耳机和第二耳机均处于非佩戴状态下触发),也可以是用户通过第一耳机的按键触发的(如按压第一耳机的电源按键等)。
可以看出,在本申请实施例中,在第一耳机与第二耳机均处于非佩戴状态,且接收到特定信令的情况下,才进行音频通道的切换,更进一步提升音频输出的准确性。
在本申请的一实现方式中,所述移动终端将所述音频输出通道更换为所述移动终端的音频输出装置之后,所述方法还包括:
移动终端将所述移动终端的音频输出装置的输出音量调节至第一音量。
其中,第一音量是基于当前地理位置确定的,具体是基于第一映射关系和当前地理位置确定的,第一映射关系是在音频输出通道位于移动终端下的音量与地理位置的映射关系。
可以看出,在本申请实施例中,在切换音频输出通道之后,合理调节输出音量的大小,以提升音频收听效果。
在本申请的一实现方式中,在步骤203之后,所述第一耳机具有音频输出和音频输入功能,所述第二耳机具有音频输出功能,所述方法还包括:
在确定所述第一耳机处于佩戴状态,或所述第一耳机和所述第二耳机处于佩戴状态下,移动终端将所述音频输出通道和所述音频输入通道更换为所述无线耳机;
在确定所述第二耳机处于佩戴状态下,移动终端将所述音频输出通道更换为所述无线耳机。
在本申请的一实现方式中,在步骤203之后,所述第一耳机和所述第二耳机均具有音频输出和音频输入功能所述方法还包括:
在确定所述第一耳机和/或所述第二耳机处于佩戴状态下,移动终端将所述音频输出通道和所述音频输入通道更换为所述无线耳机。
在本申请的一实现方式中,在步骤203之后,所述第一耳机具有音频输出功能,所述第二耳机具有音频输出和音频输入功能,所述方法还包括:
在确定所述第二耳机处于佩戴状态,或所述第一耳机和所述第二耳机处于佩戴状态下,移动终端将所述音频输出通道和所述音频输入通道更换为所述无线耳机;
在确定所述第一耳机处于佩戴状态下,移动终端将所述音频输出通道更换为所述无线耳机。
可以看出,在本申请实施例中,在耳机的佩戴状态发送变化时,移动终端及时基于耳机的佩戴状态进行音频通道的切换,提升音频输出的准确性,进而提升用户体验。
进一步地,所述确定所述第一耳机和/或所述第二耳机均处于佩戴状态,包括:
在接收到来自所述第一耳机的第三信令和/或第三信令,确定所述第一耳机和/或所述第二耳机均处于佩戴状态,所述第三信令用于告知所述第一耳机处于佩戴状态,所述第四信令用于告知所述第二耳机处于佩戴状态,所述第三信令是所述第一耳机检测到所述第一耳机处于佩戴状态时发送的,所述第四信令是所述第二耳机检测到所述第二耳机处于佩戴状态时通过所述第一耳机转发的。
其中,第三信令和第四信令发送时刻可以相同的,也可以是不相同的,在此不作限定。
可以看出,在本申请实施例中,通过信令告知移动终端耳机处于佩戴状态,流程简单,提升移动终端确定耳机佩戴状态的便捷性。
在本申请的一实现方式中,所述移动终端将所述音频输出通道更换为所述无线耳机之后,所述方法还包括:
移动终端将所述无线耳机的输出音量调节至第二音量。
其中,第二音量是基于当前地理位置确定的,具体是基于第二映射关系和当前地理位置确定的,第二映射关系是在音频输出通道位于无线耳机下的音量 与地理位置的映射关系。
可以看出,在本申请实施例中,在切换音频输出通道之后,合理调节输出音量的大小,以提升音频收听效果。
与所述图2A所示的实施例一致的,请参阅图3,图3是本申请实施例提供的一种音频通道更换方法的流程示意图,应用于移动终端,所述移动终端与无线耳机的第一耳机通信连接,所述第一耳机与所述无线耳机的第二耳机通信连接,所述第一耳机具有音频输出和音频输入功能,所述第二耳机具有音频输出功能,如图所示,本音频通道更换方法包括:
步骤301:移动终端将音频输出通道和音频输入通道设置为所述无线耳机。
步骤302:移动终端接收来自所述第一耳机的第一信令和第二信令,所述第一信令用于告知所述第一耳机处于非佩戴状态,所述第二信令用于告知所述第二耳机处于非佩戴状态,所述第一信令是所述第一耳机检测到所述第一耳机处于非佩戴状态时发送的,所述第二信令是所述第二耳机检测到所述第二耳机处于非佩戴状态时通过所述第一耳机转发的。
步骤303:在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,移动终端将所述音频输出通道更换为所述移动终端的音频输出装置。
步骤304:在将所述音频输出通道切换至所述移动终端的音频输出装置时,移动终端将所述音频输入通道更换为所述移动终端的音频输入装置。
步骤305:在确定所述第一耳机处于佩戴状态,或所述第一耳机和所述第二耳机处于佩戴状态下,移动终端将所述音频输出通道和所述音频输入通道更换为所述无线耳机。
需要说明的是,本实施例的具体实现过程可参见上述方法实施例所述的具体实现过程,在此不再叙述。
与上述图2A和图3所示的实施例一致的,请参阅图4,图4是本申请实施例提供的一种移动终端的结构示意图,所述移动终端与无线耳机的第一耳机通信连接,所述第一耳机与所述无线耳机的第二耳机通信连接,如图所示,该 电子设备包括处理器、存储器、通信接口以及一个或多个程序,其中,上述一个或多个程序被存储在上述存储器中,并且被配置由上述处理器执行,上述程序包括用于执行以下步骤的指令:
将音频输出通道和音频输入通道设置为所述无线耳机;
在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,将所述音频输出通道更换为所述移动终端的音频输出装置;
在将所述音频输出通道切换至所述移动终端的音频输出装置时,将所述音频输入通道更换为所述移动终端的音频输入装置。
在本申请的一实现方式中,所述确定所述第一耳机和所述第二耳机均处于非佩戴状态,包括:
在接收来到自所述第一耳机的第一信令和第二信令后,确定所述第一耳机和所述第二耳机均处于非佩戴状态,所述第一信令用于告知所述第一耳机处于非佩戴状态,所述第二信令用于告知所述第二耳机处于非佩戴状态,所述第一信令是所述第一耳机检测到所述第一耳机处于非佩戴状态时发送的,所述第二信令是所述第二耳机检测到所述第二耳机处于非佩戴状态时通过所述第一耳机转发的。
在本申请的一实现方式中,所述第一耳机和所述第二耳机均包括红外接近传感器,在所述第一耳机的所述红外接近传感器处于远离状态下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述红外接近传感器处于远离状态下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
在本申请的一实现方式中,所述第一耳机和所述第二耳机均包括多个压力传感器,在所述第一耳机的所述多个压力传感器检测到的压力值均为0下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述多个压力传感器检测到的压力值均为0下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
在本申请的一实现方式中,在将所述音频输出通道更换为所述移动终端的音频输出装置之前,上述程序包括用于执行以下步骤的指令:
确定所述第一耳机断开与所述移动终端的通信连接。
在本申请的一实现方式中,在将所述音频输出通道更换为所述移动终端的 音频输出装置之前,上述程序包括用于执行以下步骤的指令:
接收来自所述第一耳机的特定信令,所述特定信令用于指示更换音频通道。
在本申请的一实现方式中,所述第一耳机具有音频输出和音频输入功能,所述第二耳机具有音频输出功能,在将所述音频输入通道更换为所述移动终端的音频输入装置之后,上述程序包括用于执行以下步骤的指令:
在确定所述第一耳机处于佩戴状态,或所述第一耳机和所述第二耳机处于佩戴状态下,将所述音频输出通道和所述音频输入通道更换为所述无线耳机;
在确定所述第二耳机处于佩戴状态下,将所述音频输出通道更换为所述无线耳机。
需要说明的是,本实施例的具体实现过程可参见上述方法实施例所述的具体实现过程,在此不再叙述。
上述实施例主要从方法侧执行过程的角度对本申请实施例的方案进行了介绍。可以理解的是,电子设备为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
本申请实施例可以根据所述方法示例对电子设备进行功能单元的划分,例如,可以对应各个功能划分各个功能单元,也可以将两个或两个以上的功能集成在一个处理单元中。所述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。需要说明的是,本申请实施例中对单元的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。
下面为本申请装置实施例,本申请装置实施例用于执行本申请方法实施例所实现的方法。请参阅图5,图5是本申请实施例提供的一种音频通道更换装置,应用于移动终端,所述移动终端与无线耳机的第一耳机通信连接,所述第 一耳机与所述无线耳机的第二耳机通信连接,所述音频通道更换装置包括:
处理单元501,用于将音频输出通道和音频输入通道设置为所述无线耳机;在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,将所述音频输出通道更换为所述移动终端的音频输出装置;在将所述音频输出通道切换至所述移动终端的音频输出装置时,将所述音频输入通道更换为所述移动终端的音频输入装置。
其中,所述音频通道更换装置还包括通信单元502和存储单元503,处理单元501可以是处理器、通信单元502可以是通信接口、存储单元503可以是存储器。
在本申请的一实现方式中,所述确定所述第一耳机和所述第二耳机均处于非佩戴状态,包括:在通过通信单元502接收到来自所述第一耳机的第一信令和第二信令后,确定所述第一耳机和所述第二耳机均处于非佩戴状态,所述第一信令用于告知所述第一耳机处于非佩戴状态,所述第二信令用于告知所述第二耳机处于非佩戴状态,所述第一信令是所述第一耳机检测到所述第一耳机处于非佩戴状态时发送的,所述第二信令是所述第二耳机检测到所述第二耳机处于非佩戴状态时通过所述第一耳机转发的。
在本申请的一实现方式中,所述第一耳机和所述第二耳机均包括红外接近传感器,在所述第一耳机的所述红外接近传感器处于远离状态下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述红外接近传感器处于远离状态下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
在本申请的一实现方式中,所述第一耳机和所述第二耳机均包括多个压力传感器,在所述第一耳机的所述多个压力传感器检测到的压力值均为0下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述多个压力传感器检测到的压力值均为0下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
在本申请的一实现方式中,在处理单元501将所述音频输出通道更换为所述移动终端的音频输出装置之前,处理单元501,还用于确定所述第一耳机断开与所述移动终端的通信连接。
在本申请的一实现方式中,在处理单元501将所述音频输出通道更换为所 述移动终端的音频输出装置之前,处理单元501,还用于通过通信单元502接收来自所述第一耳机的特定信令,所述特定信令用于指示更换音频通道。
在本申请的一实现方式中,所述第一耳机具有音频输出和音频输入功能,所述第二耳机具有音频输出功能,在处理单元501将所述音频输入通道更换为所述移动终端的音频输入装置之后,处理单元501,还用于在确定所述第一耳机处于佩戴状态,或所述第一耳机和所述第二耳机处于佩戴状态下,将所述音频输出通道和所述音频输入通道更换为所述无线耳机;在确定所述第二耳机处于佩戴状态下,将所述音频输出通道更换为所述无线耳机。
本申请实施例还提供一种计算机存储介质,其中,该计算机存储介质存储用于电子数据交换的计算机程序,该计算机程序使得计算机执行如上述方法实施例中记载的任一方法的部分或全部步骤,上述计算机包括移动终端。
本申请实施例还提供一种计算机程序产品,上述计算机程序产品包括存储了计算机程序的非瞬时性计算机可读存储介质,上述计算机程序可操作来使计算机执行如上述方法实施例中记载的任一方法的部分或全部步骤。该计算机程序产品可以为一个软件安装包,上述计算机包括移动终端。
需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请并不受所描述的动作顺序的限制,因为依据本申请,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本申请所必须的。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。
在本申请所提供的几个实施例中,应该理解到,所揭露的装置,可通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如上述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性或其它的形式。
上述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
上述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储器中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储器中,包括若干指令用以使得一台计算机设备(可为个人计算机、服务器或者网络设备等)执行本申请各个实施例上述方法的全部或部分步骤。而前述的存储器包括:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储器中,存储器可以包括:闪存盘、只读存储器(英文:Read-Only Memory,简称:ROM)、随机存取器(英文:Random Access Memory,简称:RAM)、磁盘或光盘等。
以上对本申请实施例进行了详细介绍,本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的一般技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。

Claims (10)

  1. 一种音频通道更换方法,其特征在于,应用于移动终端,所述移动终端与无线耳机的第一耳机通信连接,所述第一耳机与所述无线耳机的第二耳机通信连接,所述方法包括:
    将音频输出通道和音频输入通道设置为所述无线耳机;
    在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,将所述音频输出通道更换为所述移动终端的音频输出装置;
    在将所述音频输出通道切换至所述移动终端的音频输出装置时,将所述音频输入通道更换为所述移动终端的音频输入装置。
  2. 根据权利要求1所述的方法,其特征在于,所述确定所述第一耳机和所述第二耳机均处于非佩戴状态,包括:
    在接收到来自所述第一耳机的第一信令和第二信令后,确定所述第一耳机和所述第二耳机均处于非佩戴状态,所述第一信令用于告知所述第一耳机处于非佩戴状态,所述第二信令用于告知所述第二耳机处于非佩戴状态,所述第一信令是所述第一耳机检测到所述第一耳机处于非佩戴状态时发送的,所述第二信令是所述第二耳机检测到所述第二耳机处于非佩戴状态时通过所述第一耳机转发的。
  3. 根据权利要求2所述的方法,其特征在于,所述第一耳机和所述第二耳机均包括红外接近传感器,在所述第一耳机的所述红外接近传感器处于远离状态下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述红外接近传感器处于远离状态下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
  4. 根据权利要求2所述的方法,其特征在于,所述第一耳机和所述第二耳机均包括多个压力传感器,在所述第一耳机的所述多个压力传感器检测到的压力值均为0下,所述第一耳机检测到所述第一耳机处于非佩戴状态;在所述第二耳机的所述多个压力传感器检测到的压力值均为0下,所述第二耳机检测到所述第二耳机处于非佩戴状态。
  5. 根据权利要求1-4任一项所述的方法,其特征在于,所述将所述音频 输出通道更换为所述移动终端的音频输出装置之前,所述方法还包括:确定所述第一耳机断开与所述移动终端的通信连接。
  6. 根据权利要求1-4任一项所述的方法,其特征在于,所述将所述音频输出通道更换为所述移动终端的音频输出装置之前,所述方法还包括:接收来自所述第一耳机的特定信令,所述特定信令用于指示更换音频通道。
  7. 根据权利要求1-6任一项所述的方法,其特征在于,所述第一耳机具有音频输出和音频输入功能,所述第二耳机具有音频输出功能,所述将所述音频输入通道更换为所述移动终端的音频输入装置之后,所述方法还包括:
    在确定所述第一耳机处于佩戴状态,或所述第一耳机和所述第二耳机处于佩戴状态下,将所述音频输出通道和所述音频输入通道更换为所述无线耳机;
    在确定所述第二耳机处于佩戴状态下,将所述音频输出通道更换为所述无线耳机。
  8. 一种音频通道更换装置,其特征在于,应用于移动终端,所述移动终端与无线耳机的第一耳机通信连接,所述第一耳机与所述无线耳机的第二耳机通信连接,所述装置包括:
    处理单元,用于将音频输出通道和音频输入通道设置为所述无线耳机;在确定所述第一耳机和所述第二耳机均处于非佩戴状态时,将所述音频输出通道更换为所述移动终端的音频输出装置;在将所述音频输出通道切换至所述移动终端的音频输出装置时,将所述音频输入通道更换为所述移动终端的音频输入装置。
  9. 一种移动终端,其特征在于,包括处理器、存储器、通信接口,以及一个或多个程序,所述一个或多个程序被存储在所述存储器中,并且被配置由所述处理器执行,所述程序包括用于执行如权利要求1-7任一项所述的方法中的步骤的指令。
  10. 一种计算机可读存储介质,其特征在于,存储用于电子数据交换的计算机程序,其中,所述计算机程序使得计算机执行如权利要求1-7任一项所述的方法。
PCT/CN2018/112240 2018-10-27 2018-10-27 音频通道更换方法及相关设备 WO2020082387A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201880098189.9A CN112771889A (zh) 2018-10-27 2018-10-27 音频通道更换方法及相关设备
PCT/CN2018/112240 WO2020082387A1 (zh) 2018-10-27 2018-10-27 音频通道更换方法及相关设备

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/112240 WO2020082387A1 (zh) 2018-10-27 2018-10-27 音频通道更换方法及相关设备

Publications (1)

Publication Number Publication Date
WO2020082387A1 true WO2020082387A1 (zh) 2020-04-30

Family

ID=70332142

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/112240 WO2020082387A1 (zh) 2018-10-27 2018-10-27 音频通道更换方法及相关设备

Country Status (2)

Country Link
CN (1) CN112771889A (zh)
WO (1) WO2020082387A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113242493A (zh) * 2021-03-31 2021-08-10 联想(北京)有限公司 一种处理方法及电子设备
WO2022033176A1 (zh) * 2020-08-14 2022-02-17 Oppo广东移动通信有限公司 音频播放控制方法、装置、电子设备及存储介质

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104065832A (zh) * 2014-07-17 2014-09-24 广东欧珀移动通信有限公司 一种防止移动终端漏接电话的方法及装置
CN104113794A (zh) * 2013-04-22 2014-10-22 联想(北京)有限公司 一种信息处理方法、系统及一种耳机
CN105491469A (zh) * 2014-09-15 2016-04-13 Tcl集团股份有限公司 一种基于耳机佩戴状态控制音频输出模式的方法及系统
CN106453791A (zh) * 2016-10-27 2017-02-22 宇龙计算机通信科技(深圳)有限公司 声音信号的输出方法及装置、耳机状态的检测方法及装置
CN106528041A (zh) * 2016-11-07 2017-03-22 广东欧珀移动通信有限公司 声音输出方式的切换方法、装置及终端
CN107566604A (zh) * 2017-07-12 2018-01-09 广东小天才科技有限公司 一种消息提醒的控制方法及用户终端

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105072242B (zh) * 2015-07-30 2018-12-11 广东欧珀移动通信有限公司 一种语音提示的方法及移动终端
CN106375590A (zh) * 2016-09-28 2017-02-01 珠海格力电器股份有限公司 一种智能终端的音量调节方法及其装置
CN107959903A (zh) * 2016-10-18 2018-04-24 中兴通讯股份有限公司 音频输出切换方法、反馈耳机佩戴状态方法、装置及耳机
CN107302638A (zh) * 2017-08-18 2017-10-27 广东欧珀移动通信有限公司 一种音量调节方法、装置、存储介质及移动终端
CN111970597B (zh) * 2017-11-27 2022-10-28 深圳市汇顶科技股份有限公司 耳机、检测耳机的佩戴状态的方法和电子设备
CN107819958A (zh) * 2017-11-30 2018-03-20 河南浩德科技有限公司 音量调整方法、装置、移动终端及计算机存储介质

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104113794A (zh) * 2013-04-22 2014-10-22 联想(北京)有限公司 一种信息处理方法、系统及一种耳机
CN104065832A (zh) * 2014-07-17 2014-09-24 广东欧珀移动通信有限公司 一种防止移动终端漏接电话的方法及装置
CN105491469A (zh) * 2014-09-15 2016-04-13 Tcl集团股份有限公司 一种基于耳机佩戴状态控制音频输出模式的方法及系统
CN106453791A (zh) * 2016-10-27 2017-02-22 宇龙计算机通信科技(深圳)有限公司 声音信号的输出方法及装置、耳机状态的检测方法及装置
CN106528041A (zh) * 2016-11-07 2017-03-22 广东欧珀移动通信有限公司 声音输出方式的切换方法、装置及终端
CN107566604A (zh) * 2017-07-12 2018-01-09 广东小天才科技有限公司 一种消息提醒的控制方法及用户终端

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022033176A1 (zh) * 2020-08-14 2022-02-17 Oppo广东移动通信有限公司 音频播放控制方法、装置、电子设备及存储介质
CN113242493A (zh) * 2021-03-31 2021-08-10 联想(北京)有限公司 一种处理方法及电子设备

Also Published As

Publication number Publication date
CN112771889A (zh) 2021-05-07

Similar Documents

Publication Publication Date Title
EP3591987B1 (en) Method for controlling earphone switching, earphone, and earphone system
US11043980B2 (en) Method for controlling earphone switching, earphone, and earphone system
US11102697B2 (en) Method for controlling earphone switching and earphone
CN109104684B (zh) 麦克风堵孔检测方法及相关产品
EP3675520A2 (en) Audio data routing between multiple wirelessly connected devices
US10805708B2 (en) Headset sound channel control method and system, and related device
CN108777827B (zh) 无线耳机、音量调整方法及相关产品
US10993063B2 (en) Method for processing 3D audio effect and related products
US10827455B1 (en) Method and apparatus for sending a notification to a short-range wireless communication audio output device
WO2020007174A1 (zh) 通信连接建立方法及相关设备
WO2020019843A1 (zh) 麦克风堵孔检测方法及相关产品
WO2024055494A1 (zh) 基于蓝牙耳机的通话方法、装置及存储介质
WO2022033176A1 (zh) 音频播放控制方法、装置、电子设备及存储介质
WO2020007173A1 (zh) 通信连接建立方法及相关设备
KR20200106743A (ko) 블루투스 네트워크 환경에서 응답 메시지를 전송하기 위한 전자 장치 및 그에 관한 방법
WO2020082387A1 (zh) 音频通道更换方法及相关设备
WO2020007172A1 (zh) 通信连接建立方法及相关设备
CN112806023B (zh) 无线耳机的控制方法及相关产品
CN108377298B (zh) 一种切换接听模式的方法、装置、移动终端和计算机可读存储介质
WO2020118496A1 (zh) 音频通路切换方法和装置、可读存储介质、电子设备
CN115396408A (zh) 一种无线音频/视频装置和无线通信方法
US20210152965A1 (en) Method for detecting blocking of microphone and related products
CN109618062B (zh) 语音交互方法、装置、设备以及计算机可读存储介质
WO2020077493A1 (zh) 耳机断开连接的方法、相关设备及计算机可读存储介质
WO2020113525A1 (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: 18937739

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 07/09/2021)

122 Ep: pct application non-entry in european phase

Ref document number: 18937739

Country of ref document: EP

Kind code of ref document: A1