Audio processing apparatus, method and codec

By detecting the output signal of the audio interface through the codec to identify the device type, the problem of limiting the type of device to which the audio interface is inserted in the existing technology is solved, and the universality and convenience of the audio processing device are realized.

CN116382616BActive Publication Date: 2026-07-31BEIJING YOUZHUJU NETWORK TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
BEIJING YOUZHUJU NETWORK TECH CO LTD
Filing Date
2023-03-29
Publication Date
2026-07-31

AI Technical Summary

Technical Problem

Existing audio processing devices require fixed or toggle switches to limit the types of devices that can be inserted into the audio interface, making it inconvenient for users to insert devices freely.

Method used

The output signal of the audio interface is detected by the codec, the type of the inserted device is identified, and the audio input and output paths are matched according to the device type to realize audio processing.

Benefits of technology

It achieves universality in device type recognition and processing of audio interfaces, allowing users to freely plug in devices and conveniently use audio processing devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116382616B_ABST
    Figure CN116382616B_ABST
Patent Text Reader

Abstract

This disclosure relates to an audio processing apparatus, method, and codec. The apparatus includes: at least one audio interface, a codec, and a processor. Each audio interface is communicatively connected to the codec, and the codec is communicatively connected to the processor. Each audio interface is used to insert an electronic device. The codec is used to, for each audio interface, when detecting that an electronic device is inserted into the audio interface, acquire the output signal of the audio interface, determine the device type of the electronic device based on the output signal, and receive audio input from the electronic device according to an audio input path matching the device type, and send the audio to the processor. The processor is used to process the received audio to obtain target audio and send the target audio to the codec. The codec is also used to output the target audio to the electronic device according to an audio output path matching the device type. The audio interface of this apparatus can be inserted into any electronic device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of electronic technology, and more specifically, to an audio processing apparatus, method, and codec. Background Technology

[0002] With the popularity of live streaming and online audio and video conferencing, more and more devices capable of mixing audio or translating speech have appeared on the market. However, in related technologies, such devices need to be fixed or have their audio interface connected to be limited by means of switches, which prevents users from freely inserting devices into the audio interface and makes it inconvenient for users to use the device. Summary of the Invention

[0003] This section is provided to briefly introduce the concepts, which will be described in detail in the Detailed Description section later. This section is not intended to identify key or essential features of the claimed technical solution, nor is it intended to limit the scope of the claimed technical solution.

[0004] In a first aspect, this disclosure provides an audio processing apparatus, the apparatus comprising: at least one audio interface, a codec, and a processor, wherein each audio interface is communicatively connected to the codec, and the codec is communicatively connected to the processor;

[0005] Each of the aforementioned audio interfaces is used to insert an electronic device;

[0006] The codec is used to, for each of the audio interfaces, when it is detected that the electronic device is inserted into the audio interface, acquire the output signal of the audio interface, determine the device type of the electronic device based on the output signal, and receive the audio input from the electronic device based on the audio input path matching the device type, and send the audio to the processor;

[0007] The processor is used to process the received audio to obtain the target audio, and send the target audio to the codec. The codec is also used to output the target audio to the electronic device according to the audio output path that matches the device type.

[0008] Secondly, this disclosure provides an audio processing method applied to an audio processing apparatus, the method comprising:

[0009] For each audio interface, when an electronic device is detected to be plugged into the audio interface, the output signal of the audio interface is collected;

[0010] The device type of the electronic device is determined based on the output signal;

[0011] According to the audio input path matching the device type, the audio input from the electronic device is received and sent to the processor, which processes the received audio to obtain the target audio;

[0012] The processor receives the target audio and outputs it to the electronic device according to the audio output path that matches the device type.

[0013] Thirdly, this disclosure provides a codec for performing the audio processing method described above.

[0014] The above technical solution utilizes a codec for each audio interface. Upon detecting an electronic device inserted into the audio interface, the codec determines the device type based on the output signal of the audio interface. It then receives the audio input from the electronic device using the matching audio input path and outputs the target audio to the electronic device using the matching audio output path. This simple and universal method identifies the type of device inserted into the audio interface, enabling processing of the audio acquired through the interface based on the matching audio input and output paths. It eliminates the limitation on the type of device inserted into the audio interface, allowing users to freely insert devices and facilitating the use of audio processing devices.

[0015] Other features and advantages of this disclosure will be described in detail in the following detailed description section. Attached Figure Description

[0016] The above and other features, advantages, and aspects of the embodiments of this disclosure will become more apparent from the accompanying drawings and the following detailed description. Throughout the drawings, the same or similar reference numerals denote the same or similar elements. It should be understood that the drawings are schematic, and the originals and elements are not necessarily drawn to scale. In the drawings:

[0017] Figure 1 This is a block diagram illustrating an audio processing apparatus according to an exemplary embodiment of the present disclosure.

[0018] Figure 2 This is another block diagram illustrating an audio processing apparatus according to an exemplary embodiment of the present disclosure.

[0019] Figure 3 This is another block diagram illustrating an audio processing apparatus according to an exemplary embodiment of the present disclosure.

[0020] Figure 4 This is a schematic diagram of a second switching module according to an exemplary embodiment of the present disclosure.

[0021] Figure 5This is a flowchart illustrating an audio processing method according to an exemplary embodiment of the present disclosure. Detailed Implementation

[0022] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.

[0023] It should be understood that the steps described in the method embodiments of this disclosure may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this disclosure is not limited in this respect.

[0024] The term "comprising" and its variations as used herein are open-ended inclusions, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the description below.

[0025] It should be noted that the concepts of "first" and "second" mentioned in this disclosure are used only to distinguish different devices, modules or units, and are not used to limit the order of functions performed by these devices, modules or units or their interdependencies.

[0026] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".

[0027] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.

[0028] All actions involving the acquisition of signals, information, or data in this disclosure are carried out in accordance with the relevant data protection laws and policies of the country where the location is situated, and with the authorization granted by the owner of the relevant device.

[0029] It is understood that before using the technical solutions disclosed in the various embodiments of this disclosure, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in this disclosure in an appropriate manner in accordance with relevant laws and regulations, and user authorization should be obtained.

[0030] For example, upon receiving a user's active request, a prompt message is sent to the user to explicitly inform them that the requested operation will require the acquisition and use of the user's personal information. This allows the user to independently choose whether to provide personal information to the software or hardware, such as the electronic device, application, server, or storage medium performing the operations of this disclosed technical solution, based on the prompt message.

[0031] As an optional but non-limiting implementation, in response to a user's active request, sending a prompt message to the user can be done via a pop-up window, where the prompt message can be presented in text format. Furthermore, the pop-up window can also include a selection control allowing the user to choose "agree" or "disagree" to provide personal information to the electronic device.

[0032] It is understood that the above notification and user authorization process are merely illustrative and do not constitute a limitation on the implementation of this disclosure. Other methods that comply with relevant laws and regulations may also be applied to the implementation of this disclosure.

[0033] Meanwhile, it is understood that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and related provisions.

[0034] As mentioned in the background section, with the popularity of live streaming and online audio and video conferencing, more and more devices capable of mixing or translating audio have appeared on the market, such as mixing devices or translation devices.

[0035] For example, when a mixing device is used in a live streaming scenario, it can acquire the accompaniment and local user voice separately through an audio interface, mix the accompaniment and user voice, and then send them to live streaming devices such as mobile phones. When a translation device is used in an online audio and video conferencing scenario, it can acquire the voice to be translated from host devices such as mobile phones or external devices such as headphones through an audio interface, translate it, and return it to the corresponding host device or headphone device.

[0036] However, in related technologies, for such devices, such as mixing devices or translation devices, in order to realize audio input and output, it is necessary to fix or limit the types of devices that can be inserted into the audio interface of the device by means of a toggle switch, for example, limiting a certain audio interface to only insert host devices or only insert external devices of the corresponding type, which prevents users from inserting devices into the audio interface at will, thus making it inconvenient for users to use the device.

[0037] In view of this, this disclosure proposes an audio processing apparatus, method, and codec that can easily and universally identify the type of device inserted into the audio interface, thereby processing the audio acquired through the audio interface according to the audio input and audio output paths that match the device type, without limiting the type of device inserted into the audio interface, allowing users to freely insert devices into the audio interface and making it convenient for users to use the audio processing apparatus.

[0038] Figure 1 This is a block diagram illustrating an audio processing apparatus according to an exemplary embodiment of the present disclosure. Figure 1 As shown, the audio processing device may include at least one audio interface 110, a codec 120, and a processor 130. Each audio interface 110 is communicatively connected to the codec 120, and the codec 120 is communicatively connected to the processor 130.

[0039] Each audio interface 110 is used to insert an electronic device;

[0040] The codec 120 is used for each audio interface 110 to acquire the output signal of the audio interface 110 when an electronic device is detected to be inserted into the audio interface 110, and to determine the device type of the electronic device based on the output signal, and to receive the audio input from the electronic device based on the audio input path that matches the device type, and to send the audio to the processor 130.

[0041] The processor 130 is used to process the received audio to obtain the target audio and send the target audio to the codec 120. The codec 120 is also used to output the target audio to the electronic device according to the audio output path that matches the device type.

[0042] It is worth noting that, Figure 1 The audio interfaces shown include at least two, but the audio processing apparatus of this disclosure may include only one audio interface. For the sake of simplicity, this case is not shown in a separate figure.

[0043] The audio interface can be used for inputting and outputting audio. In some embodiments, the audio interface can be a 3.5mm jack, which refers to a coaxial audio jack with a diameter of 3.5mm. It is worth noting that the audio interface can also be a 2.5mm jack; this disclosure does not impose any limitation on the diameter of the interface. The audio interface can be any type of interface, such as an NC (Normally Closed) type interface, a NO (Normally Open) type interface, a single HPH_DET type interface, or a dual HPH_DET type interface, etc., where HPH_DET refers to the insertion detection pin.

[0044] In some embodiments, the electronic device may include a host device and an external device. The host device may include a mobile phone, computer, laptop, or tablet computer, etc. The external device may refer to hardware devices other than the host device. The external device may include a first external device with a microphone and a second external device without a microphone. The first external device may include a four-segment headset, and the second external device may include a three-segment headset and a speaker, etc.

[0045] In some embodiments, the codec 120 is further configured to detect whether an electronic device is inserted into the audio interface 110 based on the acquired signal of the insertion detection pin HPH_DET of the audio interface 110. For example, the codec can also detect that an electronic device is inserted into the audio interface 110 when the signal of the insertion detection pin changes from a high level to a low level. Depending on the type of audio interface, different methods can be used to detect whether an electronic device is inserted into the audio interface 110, which will not be elaborated here. The connection relationship between the insertion detection pin HPH_DET of the audio interface 110 and the codec 120 can be found below. Figure 4 ,like Figure 4 It can be seen that the detection pin HPH_DET is connected to the detection pin INSERT_DET of the codec 120.

[0046] In some embodiments, the output signal may include a first output signal and a second output signal for a first pin and a second pin of the audio interface, wherein the first pin is one of a ground pin and a microphone pin, and the second pin is the other of a ground pin and a microphone pin; the codec is also used to acquire the first output signal and the second output signal, and determine the device type based on the first output signal and the second output signal.

[0047] When an external device is plugged into the audio interface, different external devices may conform to different standards, resulting in different types of the first and second pins on the audio interface. Therefore, the first pin may be a ground pin or a microphone pin, and correspondingly, the second pin may be a microphone pin or a ground pin. This disclosure determines the device type of the electronic device by simultaneously acquiring the first output signal of the first pin and the second output signal of the second pin, and based on the first and second output signals, effectively identifying the corresponding device type regardless of the device plugged into the audio interface.

[0048] As mentioned above, electronic devices include host devices and external devices. Correspondingly, device types may include host devices and external devices. The codec is also used to determine that the device type is a host device when the first output value of each of the first output signal and the second output signal is less than a preset threshold, and to determine that the device type is an external device when the first output value of the first output signal or the second output signal is greater than or equal to the preset threshold.

[0049] In related technologies, the headphone circuit on the host device applies a voltage of 1.8V or 2.7V to the microphone pin of the audio interface through a pull-up resistor. Therefore, for the audio processing device of this disclosure, when the host device is plugged into the audio interface, the first output values ​​of both the first output signal and the second output signal are less than 0; when an external device is plugged into the audio interface, the first output value of either the first output signal or the second output signal is greater than 0.

[0050] The preset threshold disclosed herein can be a value greater than or equal to 0. For example, the preset threshold can be 0.5 or 0.8, etc. Here, 0 is an ideal value. Since voltage fluctuations and interference exist in actual situations, by setting the preset threshold to a value greater than 0, misjudgment of equipment type can be avoided, and the accuracy of equipment type judgment can be improved.

[0051] In some embodiments, the codec can detect whether the first output values ​​of the first output signal and the second output signal are both less than a preset threshold by means of a built-in microcontroller, comparator or gate circuit.

[0052] As mentioned above, the external device includes a first external device and a second external device; the codec is also used to apply a bias power supply to the first pin and the second pin respectively when the device type is indeed an external device, and to determine whether the device type is the first external device or the second external device based on the second output values ​​of the first output signal and the second output signal respectively acquired after applying the bias voltage.

[0053] In some embodiments, the codec is further configured to determine that the device type is a first external device when either the first output signal or the second output signal has a second output value greater than 0; and to determine that the device type is a second external device when both the first output signal and the second output signal have second output values ​​less than 0. When either second output value is greater than 0, it indicates that a microphone signal is detected at the microphone pin, the external device inserted into the audio interface has a microphone, and correspondingly, the external device inserted into the audio interface is the first external device. When both second output values ​​are less than 0, it indicates that no microphone signal is detected at the microphone pin, the external device inserted into the audio interface does not have a microphone, and correspondingly, the external device inserted into the audio interface is the second external device.

[0054] In some embodiments, the codec can directly apply bias power to the first pin and the second pin respectively, or it can apply bias power to the first pin and the second pin respectively through a first switching module connected to the audio interface.

[0055] like Figure 2As shown, in some embodiments, the audio processing device may further include a first switching module 140 connected to the audio interface 110, and the audio interface 110 is communicatively connected to the codec 120 through the first switching module 140; the first switching module 140 is used to turn on or off the connection between the bias power supply pin of the codec 120 and the first pin and the second pin; the codec 120 is also used to control the first switching module 140 to turn on the connection between the bias power supply pin and the first pin and the second pin respectively, so as to apply bias power to the first pin and the second pin respectively. Wherein, the bias power supply pin, the first pin, and the second pin are not in... Figure 2 As shown in the diagram, information regarding the first and second pins can be found in [reference needed]. Figure 4 .

[0056] This disclosure determines whether the device type is a first external device or a second external device by applying bias power to the first and second pins respectively when the device type is indeed an external device, that is, by determining the type of external device inserted into the audio interface. However, when the device type is determined to be a host device, there is no need to perform the process of determining whether it is a first external device or a second external device, which can improve the efficiency of determining the device type.

[0057] In some embodiments, the first switching module may be a switch and supporting circuit for switching between OMTP standard and CTIA standard headphones. Under the control of the codec, it can realize the sequential switching of the microphone pin and ground pin of the audio interface, i.e., signal switching.

[0058] In some embodiments, the first switching module is further configured to switch the order of the first pin and the second pin; the codec is further configured to identify the standard conforming to the first external device when the device type is determined to be a first external device, and to switch the actual order of the first pin and the second pin represented by the standard when the theoretical pin order does not match the actual pin order of the first pin and the second pin of the audio interface, wherein the standard includes the Open Mobile Platform Organization standard and the Mobile Communications Industry Association standard.

[0059] The first external device is a four-segment headset. For four-segment headsets, depending on the position of the microphone on the connector, they can be divided into the Open Mobile Terminal Platform (OMTP) standard and the Cellular Telecommunications Industry Association (CTIA) standard. The OMTP standard is also known as the national standard or European standard, and the CTIA standard is also known as the international standard or American standard.

[0060] For example, the pin order of a four-segment headphone conforming to the OMTP standard, starting from the head of the socket, is: left channel - right channel - microphone - ground; the pin order of a four-segment headphone conforming to the CTIA standard, starting from the head of the socket, is: left channel - right channel - ground - microphone. Therefore, it can be seen that when the first external device conforming to the OMTP standard and the CTIA standard comes into contact with the audio interface, the order of the microphone pin and the ground pin on the audio interface is different, that is, the pin order of the first pin and the second pin is different.

[0061] This disclosure identifies the standard conforming to the first external device through a codec, and when the theoretical pin order of the first and second pins represented by the standard does not match the actual pin order, it switches the actual pin order through a first switching module, automatically identifying OMTP standard four-segment headphones and CTIA standard four-segment headphones, and switching the order of the corresponding microphone pin and ground pin, thereby achieving compatibility between OMTP standard four-segment headphones and CTIA standard four-segment headphones, and ensuring the normal use of four-segment headphones of different standards.

[0062] In some embodiments, the processing performed by the processor 130 on the received audio can be specifically determined according to actual needs. For example, the processing may include mixing, noise reduction, audio equalization, and translation. Depending on the processing performed by the processor 130, the codec 120 can output the processed target audio to different electronic devices. The methods of outputting to different electronic devices are described in the following related descriptions and will not be repeated here.

[0063] In some embodiments, the processing performed by the processor 130 can be online or offline. When performing offline processing, the processor can perform offline processing locally, or it can send the data to a server for processing via wireless function and then return it to the processor.

[0064] like Figure 2 As shown, in some embodiments, the audio processing apparatus may further include a pickup device 150, which is communicatively connected to a codec 120. The pickup device 150 is used to input the acquired audio to the codec 120. The codec 120 is also used to activate the pickup device 150 and receive the audio input from the pickup device 150 when the audio interface 110 includes one device and the device type is a host device, and to send the audio to the processor 130; or when the audio interface 110 includes multiple devices and the device type includes a second external device, to activate the pickup device 150 and receive the audio input from the pickup device 150, and to send the audio to the processor 130. In some embodiments, the pickup device 150 may include at least one microphone and its peripheral circuitry, through which near-end audio, such as the audio of a local user, can be acquired.

[0065] It is worth noting that when the audio processing device disclosed herein is applied to live streaming mixing scenarios or audio and video conferencing translation scenarios, the processor in the audio processing device needs to acquire near-end audio and far-end audio, and perform mixing or translation processing on the near-end audio and far-end audio. Here, near-end audio can refer to audio from one's own side, also known as uplink audio, and far-end audio can refer to audio from the other party, also known as downlink audio.

[0066] When the audio interface 110 includes one device, and the device type of the electronic device connected to the audio interface 110 is a host device, the audio processing apparatus of this disclosure can be a mixing apparatus used to mix sounds from multiple sources. In this case, the processor 130 can only acquire audio from one source through the host device, for example, acquiring accompaniment music played by the host device, which is far-end audio; understandably, the host device is used to acquire far-end audio. At this time, the codec 120 can activate the pickup device 150, so that the processor 130 can acquire audio from another source through the pickup device 150, for example, acquiring local user speech captured by the pickup device 150, which is near-end audio; understandably, the pickup device 150 is used to acquire near-end audio. Furthermore, the processor 130 can perform mixing processing on the received near-end and far-end audio to obtain mixed audio, which the codec 120 can send to the host device, for example, to a live streaming application on the host device.

[0067] Understandably, when the audio interface 110 includes one and the audio processing device does not include the pickup device 150, the audio processing device can be used for processing other than mixing, such as the aforementioned noise reduction, audio equalization and translation, and returning the processed audio to the electronic device inserted in the audio interface.

[0068] When the audio interface 110 includes multiple devices and the device type includes a second external device, the audio processing apparatus of this disclosure may be a mixing apparatus, a translation apparatus, a noise reduction apparatus, or an audio equalization apparatus. In some embodiments, the second external device may be a device for acquiring near-end audio, and the codec 120 may also be used to activate the pickup device and receive the audio input from the pickup device and send the audio to the processor when the audio interface includes multiple devices, the device type of the electronic device for acquiring far-end audio is a host device, and the device type of the electronic device for acquiring near-end audio is a second external device.

[0069] For example, taking an audio processing device as a translation device for audio and video conferencing, with two audio interfaces 110 and a second external device being a three-segment headset, assuming one audio interface 110 is connected to the host device and the other audio interface 110 is connected to the three-segment headset, the processor 130 can acquire the voice of the remote user (i.e., remote audio) through the microphone of the host device. However, since the three-segment headset does not have a microphone, it cannot acquire near-end audio. At this point, the codec 120 can activate the pickup device 150, and the processor 130 can acquire the voice of the near-end user (or local user) through the pickup device 150 (i.e., near-end audio). Then, the codec 120 can send the first translated audio obtained by the processor 130 translating the near-end user's voice to the host device, enabling the remote user to acquire the first translated audio, and send the second translated audio obtained by the processor 130 translating the remote user's voice to the three-segment headset, enabling the near-end user to acquire the second translated audio, thus achieving real-time translation. Both the first and second translated audio are target audio.

[0070] This disclosure provides a pickup device on the audio processing device. Even if the audio processing device has only one audio interface and that audio interface is inserted into a host device for acquiring remote audio, or if the audio processing device includes multiple audio interfaces and the audio interface for acquiring near-end audio is inserted into a three-segment headphone, that is, in the case where the device cannot acquire near-end audio through the aforementioned audio interface, the pickup device can still acquire near-end audio, ensuring the transmission of local near-end audio and avoiding the phenomenon of silent transmission.

[0071] like Figure 3 As shown, in some embodiments, the audio processing device further includes a second switching module 160 connected to the audio interface 110 and the codec 120 respectively; the second switching module 160 is used to control the connection mode between the microphone signal terminal, the left channel pin, and the right channel pin and the analog-to-digital converter and digital-to-analog converter of the codec 120 respectively, according to the received control signal, so as to switch the audio input path and audio output path matched with the host device or external device. The microphone signal terminal includes a microphone pin and / or a pickup device 150 (the connection relationship between the pickup device 150 and the second switching module is not shown in the figure). Figure 3 As shown in the diagram, the control signal is sent by the codec 120 to the second switching module 160 according to the device type.

[0072] To more clearly explain the working principle of the second switching module 160, the following will combine... Figure 4 The switching process of the second switching module 160 is described below, such as... Figure 4As shown, the second switching module 160 includes a first switch K1, a second switch K2, and a third switch K3. The stationary contact s1 of the first switch K1 is connected to the microphone signal terminal, the first moving contact a1 of the first switch K1 is connected to the output terminal of the digital-to-analog converter (DAC), the second moving contact a2 of the first switch K1 is connected to the input terminal of the analog-to-digital converter (ADC), the stationary contact s2 of the second switch K2 is connected to the left channel pin HPH_L, the first moving contact b1 of the second switch K2 is connected to the input terminal of the ADC, the second moving contact b2 of the second switch K2 is connected to the output terminal of the DAC, the stationary contact s3 of the third switch K3 is connected to the right channel pin HPH_R, the first moving contact c1 of the third switch K3 is connected to the input terminal of the ADC, and the second moving contact c2 of the third switch K3 is connected to the output terminal of the DAC. The input terminal of the DAC is connected to the processor.

[0073] In some embodiments, the second switching module can be a three-input single-pole double-throw switch under joint control, or it can be a single-pole double-throw switch using three identical control signals.

[0074] It is worth noting that, Figure 4 The diagram only illustrates the second switching module connected to one audio interface. No diagram is provided for the second switching module connected to each audio interface. The working principle of the second switching module connected to each audio interface is the same.

[0075] As mentioned above, the microphone signal terminal includes microphone pins and / or a pickup device 150. In a possible implementation, the microphone signal terminal can be output through a first switching module 140, thereby enabling the second switching module 160 to receive the audio output from the microphone signal terminal through the connection between the first switching module 140 and the second switching module 160. Figure 4 As shown, the first switching module 140 may include a microphone signal terminal HPH_MIC, and the first switching module 140 is also used to connect the microphone pins and / or the pickup device 150 to the microphone signal terminal.

[0076] For example, combined Figure 4 For example, the aforementioned audio processing device is a translation device for audio and video conferencing, and the audio interface 110 includes two, one of which is inserted into the host device and the other is inserted into an external device.

[0077] If the external device is a four-segment headphone, and the codec 120 detects that the audio interface 110 of the host device is plugged in, the codec 120 can send a control signal SWA to the second switching module 160 connected to the audio interface. The second switching module 160, based on the received control signal SWA, controls the first switch K1, the second switch K2, and the third switch K3 to switch to their respective first moving contacts, i.e., switch to... Figure 4 The A-end of the codec 120, and the audio interface 110 for which the codec 120 detects that a four-segment headphone is inserted, control the first switch K1, the second switch K2, and the third switch K3 of the second switching module 160 connected to the audio interface to switch to their respective second moving contacts, i.e., switch to Figure 4 The B-end in the middle.

[0078] In this way, the left channel pin HPH_L and right channel pin HPH_R of the audio interface 110 inserted into the host device acquire the remote audio, and enter the analog-to-digital converter (ADC) of the codec 120 through the audio input paths corresponding to the left channel pin HPH_L and the right channel pin HPH_R. The ADC performs analog-to-digital conversion on the remote audio to obtain digital audio, and sends the digital audio to the processor 130 (not in the processor). Figure 4 As shown in the figure, after the processor 130 performs translation processing to obtain digital translated audio, it is returned to the digital-to-analog converter (DAC) of the codec 120. The DAC converts the digital translated audio into analog translated audio, and transmits the analog translated audio to the left channel pin HPH_L and the right channel pin HPH_R of the audio interface of the four-segment headphones through the audio output paths corresponding to the left channel pin HPH_L and the right channel pin HPH_R, so that the translated audio can be played in the four-segment headphones.

[0079] The microphone signal terminal HPH_MIC, which is plugged into the audio jack of a four-segment headphone, acquires near-end audio and inputs it to the analog-to-digital converter (ADC) of the codec 120 via the corresponding audio input path. The ADC performs analog-to-digital conversion on the near-end audio to obtain digital audio, which is then sent to the processor 130 (not in...). Figure 4 As shown in the diagram, after translation processing by processor 130, digital translated audio is obtained and returned to the digital-to-analog converter (DAC) of codec 120. The DAC converts the digital translated audio into analog translated audio and transmits the analog translated audio to the microphone signal terminal HPH_MIC inserted into the audio interface of the host device through the audio output path corresponding to the microphone signal terminal HPH_MIC. The first switching module 140 sends the translated audio transmitted by the microphone signal terminal HPH_MIC to the left channel pin HPH_L and the right channel pin HPH_R of the audio interface of the host device, so that the translated audio can be played in the host device.

[0080] If the external device is a three-segment headphone or speaker, the codec 120 can activate the pickup device 150. Upon detecting that the audio interface 110 of the three-segment headphone or speaker is inserted, the codec 120 controls the first switch K1, the second switch K2, and the third switch K3 of the second switching module 160 connected to that audio interface to switch to their respective first moving contacts, i.e., switch to... Figure 4 The A-end of the codec 120, and the audio interface 110 of the host device detected by the codec 120, send a control signal SWA to the second switching module 160 connected to the audio interface. The second switching module 160 controls the first switch K1, the second switch K2, and the third switch K3 to switch to their respective second moving contacts according to the received control signal SWA, that is, switch to Figure 4 The B-end in the middle.

[0081] In this way, the near-end audio captured by the pickup device 150 enters the analog-to-digital converter (ADC) of the codec 120 through the audio input path corresponding to the microphone signal terminal HPH_MIC. The ADC performs analog-to-digital conversion to obtain digital audio, which is then sent to the processor 130 (not in the processor). Figure 4 As shown in the diagram, the processor 130 performs translation processing to obtain digital translated audio, which is then returned to the digital-to-analog converter (DAC) of the codec 120. The DAC converts the digital translated audio into analog translated audio, which is then transmitted to the microphone signal terminal HPH_MIC of the audio interface plugged into the host device through the audio output path corresponding to the microphone signal terminal HPH_MIC. The analog translated audio is then sent to the left channel pin HPH_L and the right channel pin HPH_R of the audio interface of the host device through the first switching module 140, and the translated audio is played in the host device.

[0082] The left channel pin HPH_L and right channel pin HPH_R of the audio interface 110 of the host device are used to acquire remote audio, which is then fed into the analog-to-digital converter (ADC) of the codec 120 through the audio input paths corresponding to the left channel pin HPH_L and the right channel pin HPH_R. The ADC performs analog-to-digital conversion to obtain digital audio, which is then sent to the processor 130 (not in...). Figure 4 As shown in the figure, the processor 130 performs translation processing to obtain digital translated audio, which is then returned to the digital-to-analog converter (DAC) of the codec 120. The DAC converts the digital translated audio into analog translated audio, and transmits the analog translated audio to the left channel pin HPH_L and the right channel pin HPH_R through the audio output paths corresponding to the left channel pin HPH_L and the right channel pin HPH_R, so that the translated audio can be played in a three-segment headphone or speaker.

[0083] This disclosure can easily and universally identify whether the device type plugged into the audio interface is a host device, a 4-segment headphone, a 3-segment headphone, or an external speaker, and switch to the corresponding signal path, avoiding the limitations of previous external plug-in devices and bringing great convenience to users.

[0084] like Figure 4 As shown, in some embodiments, the first pin 1 of the audio interface 110 is connected to the first detection terminal DET1 of the codec 120 through the first switching module 140, and the second pin 2 of the audio interface 110 is connected to the second detection terminal DET2 of the codec 120 through the first switching module 140; the codec 120 is also used to acquire a first output signal and a second output signal based on the first detection terminal DET1 and the second detection terminal DET2.

[0085] In some embodiments, the codec is further configured to control the connection between the first switching module and the codec, and to acquire the first output signal and the second output signal based on the first detection terminal DET1 and the second detection terminal DET2.

[0086] This disclosure enables the first detection terminal DET1 and the second detection terminal DET2 of the codec to acquire the first output signal and the second output signal through the first switching module. Since the first switching module is a switch that can switch between CTIA and OMTP headphones, it enables the first switching module to perform multiple functions and reduces the complexity of the audio processing device.

[0087] like Figure 4 As shown, in some embodiments, the codec 120 may send a control signal SWB to the first switching module 140 to turn on or off the connection between the codec's bias power supply pin and the first and second pins, or to switch the order of the first and second pins.

[0088] Figure 5 This is a flowchart illustrating an audio processing method according to an exemplary embodiment of the present disclosure. Figure 5 As shown, the audio processing method includes the following steps.

[0089] Step 510: For each audio interface, if an electronic device is detected to be plugged into the audio interface, the output signal of the audio interface is acquired.

[0090] Step 520: Determine the device type of the electronic device based on the output signal.

[0091] In some embodiments, the output signal includes a first output signal and a second output signal for a first pin and a second pin of an audio interface, wherein the first pin is one of a ground pin and a microphone pin, and the second pin is the other of a ground pin and a microphone pin; determining the device type of an electronic device based on the output signal includes: determining the device type based on the first output signal and the second output signal.

[0092] In some embodiments, the device type includes a host device and an external device. Determining the device type based on the first output signal and the second output signal includes: determining the device type as a host device when the first output value of each of the first output signal and the second output signal is less than a preset threshold; and determining the device type as an external device when the first output value of the first output signal or the second output signal is greater than or equal to the preset threshold.

[0093] Step 530: Receive audio input from electronic device according to the audio input path matching the device type, and send the audio to processor. The processor processes the received audio to obtain the target audio.

[0094] Step 540: Receive the target audio returned by the processor, and output the target audio to the electronic device according to the audio output path that matches the device type.

[0095] Regarding the methods in the above embodiments, the specific manner in which each step is performed has been described in detail in the embodiments related to the device, and will not be elaborated here.

[0096] According to one or more embodiments of this disclosure, Example 1 provides an audio processing apparatus, the apparatus comprising: at least one audio interface, a codec, and a processor, wherein each audio interface is communicatively connected to the codec, and the codec is communicatively connected to the processor;

[0097] Each of the aforementioned audio interfaces is used to insert an electronic device;

[0098] The codec is used to, for each of the audio interfaces, when it is detected that the electronic device is inserted into the audio interface, acquire the output signal of the audio interface, determine the device type of the electronic device based on the output signal, and receive the audio input from the electronic device based on the audio input path matching the device type, and send the audio to the processor;

[0099] The processor is used to process the received audio to obtain the target audio, and send the target audio to the codec. The codec is also used to output the target audio to the electronic device according to the audio output path that matches the device type.

[0100] According to one or more embodiments of this disclosure, Example 2 provides an apparatus of Example 1, wherein the output signal includes a first output signal and a second output signal for a first pin and a second pin of the audio interface, wherein the first pin is one of a ground pin and a microphone pin, and the second pin is the other of the ground pin and the microphone pin;

[0101] The codec is also used to acquire the first output signal and the second output signal, and to determine the device type based on the first output signal and the second output signal.

[0102] According to one or more embodiments of this disclosure, Example 3 provides an apparatus of Example 2, wherein the device type includes a host device and an external device, and the codec is further configured to determine that the device type is the host device when the first output value of each of the first output signal and the second output signal is less than a preset threshold, and to determine that the device type is the external device when the first output value of the first output signal or the second output signal is greater than or equal to the preset threshold.

[0103] According to one or more embodiments of this disclosure, Example 4 provides the apparatus of Example 3, wherein the external device includes a first external device having a microphone and a second external device not having a microphone;

[0104] The codec is further configured to, when the device type is indeed the external device, apply a bias power supply to the first pin and the second pin respectively, and determine whether the device type is the first external device or the second external device based on the second output values ​​of the first output signal and the second output signal respectively acquired after applying the bias voltage.

[0105] According to one or more embodiments of this disclosure, Example 5 provides the apparatus of Example 4, the apparatus further comprising a pickup device communicatively connected to the codec;

[0106] The pickup device is used to input the acquired audio into the codec;

[0107] The codec is further configured to, when the audio interface includes one and the device type is the host device, activate the pickup device, receive the audio input from the pickup device, and send the audio to the processor; or

[0108] When the audio interface includes multiple devices and the device type includes the second external device, the pickup device is activated, and the audio input from the pickup device is received and sent to the processor.

[0109] According to one or more embodiments of this disclosure, Example 6 provides an apparatus of Example 4, the apparatus further comprising a first switching module connected to the audio interface, the audio interface being communicatively connected to the codec via the first switching module;

[0110] The first switching module is used to turn on or off the connection between the bias power supply pin of the codec and the first and second pins;

[0111] The codec is also used to control the first switching module to respectively connect the bias power supply pin to the first pin and the second pin, so as to apply the bias power supply to the first pin and the second pin respectively.

[0112] According to one or more embodiments of this disclosure, Example 7 provides the apparatus of Example 4, wherein the first switching module is further configured to switch the order of the first pin and the second pin;

[0113] The codec is further configured to, when determining that the device type is the first external device, identify the standard conforming to the first external device, and, when the theoretical pin order of the first and second pins characterized by the standard does not match the actual pin order of the first and second pins of the audio interface, switch the actual order through the first switching module, wherein the standard includes Open Mobile Platforms Organization standards and Mobile Communications Industry Association standards.

[0114] According to one or more embodiments of this disclosure, Example 8 provides the apparatus of Example 6, wherein the first pin of the audio interface is connected to the first detection terminal of the codec via the first switching module, and the second pin of the audio interface is connected to the second detection terminal of the codec via the first switching module;

[0115] The codec is also used to acquire the first output signal and the second output signal based on the first detection end and the second detection end.

[0116] According to one or more embodiments of this disclosure, Example 9 provides an apparatus of Example 6, the apparatus further comprising a second switching module connected to the audio interface and the codec, respectively;

[0117] The second switching module is used to control the connection mode between the microphone signal terminal, the left channel pin, and the right channel pin and the analog-to-digital converter and digital-to-analog converter of the codec, respectively, according to the received control signal, so as to switch the audio input path and audio output path that match the host device or the external device. The microphone signal terminal includes the microphone pin and / or the pickup device. The control signal is sent by the codec to the second switching module according to the device type.

[0118] According to one or more embodiments of this disclosure, Example 10 provides the apparatus of Example 9, wherein the second switching module includes a first switch, a second switch, and a third switch, wherein the stationary contact of the first switch is connected to the microphone signal terminal, the first moving contact of the first switch is connected to the output terminal of the digital-to-analog converter (DAC), the second moving contact of the first switch is connected to the input terminal of the DAC, the stationary contact of the second switch is connected to the left channel pin, the first moving contact of the second switch is connected to the input terminal of the DAC, the second moving contact of the second switch is connected to the output terminal of the DAC, the stationary contact of the third switch is connected to the right channel pin, the first moving contact of the third switch is connected to the input terminal of the DAC, and the second moving contact of the third switch is connected to the output terminal of the DAC, wherein the input terminal of the DAC is connected to the processor.

[0119] According to one or more embodiments of this disclosure, Example 11 provides an apparatus of Example 9 or 10, wherein the first switching module includes the microphone signal terminal, and the first switching module is further configured to connect the microphone pin and / or the pickup device to the microphone signal terminal.

[0120] According to one or more embodiments of this disclosure, Example 12 provides an audio processing method applied to the audio processing apparatus described in Example 1, the method comprising:

[0121] For each audio interface, when an electronic device is detected to be plugged into the audio interface, the output signal of the audio interface is collected;

[0122] The device type of the electronic device is determined based on the output signal;

[0123] According to the audio input path matching the device type, the audio input from the electronic device is received and sent to the processor, which processes the received audio to obtain the target audio;

[0124] The processor receives the target audio and outputs it to the electronic device according to the audio output path that matches the device type.

[0125] According to one or more embodiments of this disclosure, Example 13 provides the method of Example 12, wherein the output signal includes a first output signal and a second output signal for a first pin and a second pin of the audio interface, wherein the first pin is one of a ground pin and a microphone pin, and the second pin is the other of the ground pin and the microphone pin;

[0126] Determining the device type of the electronic device based on the output signal includes:

[0127] The device type is determined based on the first output signal and the second output signal.

[0128] According to one or more embodiments of this disclosure, Example 14 provides the method of Example 13, wherein the device type includes a host device and an external device, and the step of determining the device type based on the first output signal and the second output signal includes:

[0129] If the first output value of both the first output signal and the second output signal is less than a preset threshold, the device type is determined to be the host device.

[0130] If the first output value of the first output signal or the second output signal is greater than or equal to the preset threshold, the device type is determined to be the external device.

[0131] According to one or more embodiments of this disclosure, Example 15 provides a codec for performing an audio processing method as described in any one of Examples 12-14.

[0132] The above description is merely a preferred embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.

[0133] Furthermore, while the operations are described in a specific order, this should not be construed as requiring these operations to be performed in the specific order shown or in a sequential order. In certain environments, multitasking and parallel processing may be advantageous. Similarly, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of this disclosure. Certain features described in the context of individual embodiments may also be implemented in combination in a single embodiment. Conversely, various features described in the context of a single embodiment may also be implemented individually or in any suitable sub-combination in multiple embodiments.

[0134] Although the subject matter has been described using language specific to structural features and / or methodological logic, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. Rather, the specific features and actions described above are merely illustrative forms of implementing the claims. Regarding the apparatus in the above embodiments, the specific manner in which the various modules perform their operations has been described in detail in the embodiments relating to the method, and will not be elaborated upon here.

Claims

1. An audio processing device, characterized in that, The device includes: at least one audio interface, a codec, and a processor, wherein each audio interface is communicatively connected to the codec, and the codec is communicatively connected to the processor. Each of the aforementioned audio interfaces is used to insert an electronic device; The codec is used to, for each of the audio interfaces, when it is detected that the electronic device is inserted into the audio interface, acquire the output signal of the audio interface, determine the device type of the electronic device based on the output signal, and receive the audio input from the electronic device based on the audio input path matching the device type, and send the audio to the processor; The processor is used to process the received audio to obtain the target audio, and send the target audio to the codec. The codec is also used to output the target audio to the electronic device according to the audio output path that matches the device type. The output signal includes a first output signal and a second output signal for each of the first and second pins of the audio interface, wherein the first pin is one of a ground pin and a microphone pin, and the second pin is the other of the ground pin and the microphone pin; the codec is further configured to acquire the first output signal and the second output signal, and determine the device type based on the first output signal and the second output signal; The device type includes host devices and external devices. The codec is further configured to determine that the device type is the host device when the first output value of the first output signal and the second output signal are both less than a preset threshold, and to determine that the device type is the external device when the first output value of the first output signal or the second output signal is greater than or equal to the preset threshold.

2. The audio processing apparatus according to claim 1, characterized in that, The external device includes a first external device with a microphone and a second external device without a microphone; The codec is further configured to, when the device type is indeed the external device, apply a bias power supply to the first pin and the second pin respectively, and determine whether the device type is the first external device or the second external device based on the second output values ​​of the first output signal and the second output signal respectively acquired after applying the bias voltage.

3. The audio processing apparatus according to claim 2, characterized in that, The device also includes a microphone, which is communicatively connected to the codec. The pickup device is used to input the acquired audio into the codec; The codec is also used to, when the audio interface includes one and the device type is the host device, activate the pickup device, receive the audio input from the pickup device, and send the audio to the processor; or When the audio interface includes multiple devices and the device type includes the second external device, the pickup device is activated, and the audio input from the pickup device is received and sent to the processor.

4. The audio processing apparatus according to claim 2, characterized in that, The device further includes a first switching module connected to the audio interface, and the audio interface is communicatively connected to the codec through the first switching module. The first switching module is used to turn on or off the connection between the bias power supply pin of the codec and the first and second pins; The codec is also used to control the first switching module to respectively connect the bias power supply pin to the first pin and the second pin, so as to apply the bias power supply to the first pin and the second pin respectively.

5. The audio processing apparatus according to claim 4, characterized in that, The first switching module is also used to switch the order of the first pin and the second pin; The codec is further configured to, when determining that the device type is the first external device, identify the standard conforming to the first external device, and, when the theoretical pin order of the first and second pins characterized by the standard does not match the actual pin order of the first and second pins of the audio interface, switch the actual order through the first switching module, wherein the standard includes Open Mobile Platforms Organization standards and Mobile Communications Industry Association standards.

6. The audio processing apparatus according to claim 4, characterized in that, The first pin of the audio interface is connected to the first detection terminal of the codec through the first switching module, and the second pin of the audio interface is connected to the second detection terminal of the codec through the first switching module. The codec is also used to acquire the first output signal and the second output signal based on the first detection end and the second detection end.

7. The audio processing apparatus according to claim 4, characterized in that, The device further includes a second switching module connected to the audio interface and the codec respectively; The second switching module is used to control the connection mode between the microphone signal terminal, the left channel pin, and the right channel pin and the analog-to-digital converter and digital-to-analog converter of the codec, respectively, according to the received control signal, so as to switch the audio input path and audio output path that match the host device or the external device. The microphone signal terminal includes the microphone pin and / or the pickup device. The control signal is sent by the codec to the second switching module according to the device type.

8. The audio processing apparatus according to claim 7, characterized in that, The second switching module includes a first switch, a second switch, and a third switch. The stationary contact of the first switch is connected to the microphone signal terminal. The first moving contact of the first switch is connected to the output terminal of the digital-to-analog converter (DAC). The second moving contact of the first switch is connected to the input terminal of the DAC. The stationary contact of the second switch is connected to the left channel pin. The first moving contact of the second switch is connected to the input terminal of the DAC. The second moving contact of the second switch is connected to the output terminal of the DAC. The stationary contact of the third switch is connected to the right channel pin. The first moving contact of the third switch is connected to the input terminal of the DAC. The second moving contact of the third switch is connected to the output terminal of the DAC. The input terminal of the DAC is connected to the processor.

9. The audio processing apparatus according to claim 7 or 8, characterized in that, The first switching module includes the microphone signal terminal, and the first switching module is also used to connect the microphone pin and / or the pickup device to the microphone signal terminal.

10. An audio processing method, characterized in that, Applied to the audio processing apparatus of claim 1, the method comprises: For each audio interface, when an electronic device is detected to be plugged into the audio interface, the output signal of the audio interface is collected; The device type of the electronic device is determined based on the output signal; According to the audio input path matching the device type, the audio input from the electronic device is received and sent to the processor, which processes the received audio to obtain the target audio; The system receives the target audio returned by the processor and outputs the target audio to the electronic device according to the audio output path that matches the device type. The output signal includes a first output signal and a second output signal for each of the first and second pins of the audio interface, wherein the first pin is one of a ground pin and a microphone pin, and the second pin is the other of the ground pin and the microphone pin; determining the device type of the electronic device based on the output signal includes: determining the device type based on the first output signal and the second output signal; The device type includes host devices and external devices. Determining the device type based on the first output signal and the second output signal includes: determining that the device type is the host device when the first output value of each of the first output signal and the second output signal is less than a preset threshold; and determining that the device type is the external device when the first output value of either the first output signal or the second output signal is greater than or equal to the preset threshold.

11. A codec, characterized in that, include: Analog-to-digital converter and digital-to-analog converter; the codec is used to perform the audio processing method as described in claim 10; The analog-to-digital converter is used to perform analog-to-digital conversion on audio to obtain digital audio; the digital-to-analog converter is used to convert digital audio into analog audio.