Audio playing circuit, electronic equipment and chip
By generating negatively correlated adjustment signals through the selection module and the channel control module, the channel switching problem after the electronic device is rotated is solved, a stable stereo effect and cost-effective audio playback are achieved, and the user experience is improved.
Patent Information
- Application Number
- CN202510774108.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-10
- Publication Date
- 2025-09-12
AI Technical Summary
When an electronic device is rotated 90°, some audio amplifiers cannot switch channels with the device, resulting in the loss of the stereo effect. Existing external channel switching switches are difficult to control synchronously, which may cause popping sounds and increase costs and PCB layout complexity.
The selection module and the channel control module are used to control the amplitude of the audio signal by generating negatively correlated first channel adjustment signals and second channel adjustment signals, thereby realizing switch-free switching of the channels, ensuring the stability of the audio signal amplitude, and avoiding the feeling of fluctuating sound.
This enables plosive-free channel switching during electronic device rotation, reduces costs and PCB layout complexity, and improves the user's auditory experience.
Smart Images

Figure CN120640207A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of audio processing technology, and in particular to an audio playback circuit, electronic equipment, and chip. Background Art
[0002] Currently, many smart terminals can achieve stereo playback effects through dual-channel design. Figure 1 As shown, the electronic device 10 includes an audio amplifier 1, an audio amplifier 2, an audio amplifier 3, and an audio amplifier 4. When the electronic device 10 is in landscape mode, the audio amplifier 1 and the audio amplifier 4 are located on the left side of the electronic device 10, and the audio amplifier 2 and the audio amplifier 3 are located on the right side of the electronic device 10. The audio amplifier 1 and the audio amplifier 4 play the left channel audio signal, and the audio amplifier 2 and the audio amplifier 3 play the right channel audio signal, thereby achieving a stereo playback effect.
[0003] However, when the electronic device is rotated 90 degrees, some of the audio amplifiers of the electronic device cannot switch the sound channels as the electronic device rotates. Figure 1 When the electronic device 10 is rotated 90° to the right, as shown in FIG. Figure 2 As shown, the electronic device 10 is in portrait mode, the audio amplifier 3 is located on the left side of the electronic device 10 but plays the right channel audio signal, and the audio amplifier 1 is located on the right side of the electronic device 10 but plays the left channel audio signal, and the multi-channel stereo effect cannot be guaranteed. Summary of the Invention
[0004] In order to solve the problem that when the electronic device is rotated 90°, the audio amplifier of the electronic device cannot switch channels as the electronic device rotates, the embodiments of the present application provide an audio playback circuit, an electronic device and a chip.
[0005] In a first aspect, an embodiment of the present application provides an audio playback circuit, which includes a selection module, a channel control module and an audio output module, wherein the audio output module includes a pre-gain amplifier unit and an audio power amplifier unit, a first end of the selection module is connected to the first end of the channel control module, a second end of the channel control module is connected to the first end of the pre-gain amplifier unit, and a second end of the pre-gain amplifier unit is connected to the first end of the audio power amplifier unit, the selection module is used to obtain a control signal, and generate a first channel adjustment signal and a second channel adjustment signal based on the control signal, the first channel adjustment signal and the second channel adjustment signal being negatively correlated; the channel control module is used to receive the first channel audio signal and a second channel audio signal, processes the amplitude of the first channel audio signal based on the first channel adjustment signal, processes the amplitude of the second channel audio signal based on the second channel adjustment signal, and performs signal processing on the processed first channel audio signal and the second channel audio signal to obtain a synthesized audio signal, and outputs the synthesized audio signal to a pre-gain amplifier unit, the signal processing including synthesis processing and amplification processing; the pre-gain amplifier unit amplifies the received synthesized audio signal and outputs the amplified synthesized audio signal to the audio power amplifier unit; the audio power amplifier unit processes the received synthesized audio signal and outputs the processed synthesized audio signal.
[0006] It can be understood that the first channel adjustment signal and the second channel adjustment signal are negatively correlated. If the amplitude of the first channel adjustment signal gradually increases, the amplitude of the second channel adjustment signal gradually decreases; if the amplitude of the first channel adjustment signal gradually decreases, the amplitude of the second channel adjustment signal gradually increases.
[0007] In this way, the electronic device can control the amplitude of the first channel audio signal input to the pre-gain amplifier unit through the first channel adjustment signal, and control the amplitude of the second channel audio signal input to the pre-gain amplifier through the second channel adjustment signal, thereby realizing channel switching. There is no need to switch channels in the form of an external switch, which eliminates the operation of connecting the channel switching switch in series with the external circuit; and, during the channel switching process, the first channel adjustment signal and the second channel adjustment signal are negatively correlated, so that the sum of the amplitudes of the first channel audio signal and the second channel audio signal is relatively stable, ensuring that the sound will not fluctuate during the channel switching process, thereby improving the user's auditory experience.
[0008] In a possible implementation, the sum of the amplitudes of the first channel audio signal and the second channel audio signal after processing is equal to the sum of the amplitudes of the first channel audio signal and the second channel audio signal before processing.
[0009] In one possible implementation, the channel control module includes an audio input unit and an amplifying unit, the first end of the selection module is connected to the first end of the audio input unit, the second end of the audio input unit is connected to the first end of the amplifying unit, and the second end of the amplifying unit is connected to the audio output module, the audio input unit is used to receive a first channel audio signal and a second channel audio signal, process the amplitude of the first channel audio signal based on the first channel adjustment signal, and process the amplitude of the second channel audio signal based on the second channel adjustment signal; the amplifying unit is used to perform signal processing on the received first channel audio signal and the second channel audio signal to obtain a synthesized audio signal, and output the synthesized audio signal to the audio output module.
[0010] In one possible implementation, the audio input unit includes a first audio input unit, the first audio input unit includes at least one first adjustment unit, the first adjustment unit includes a first switch and a first resistor, the first end of the first switch is connected to the first end of the first resistor, and the second end of the first resistor is connected to the input end of the amplification unit.
[0011] In one possible implementation, the audio input unit includes a second audio input unit, the second audio input unit includes at least one second adjustment unit, the second adjustment unit includes a second switch and a second resistor, the first end of the second switch is connected to the first end of the second resistor, and the second end of the second resistor is connected to the input end of the amplification unit.
[0012] In one possible implementation, the amplification unit includes a third resistor, a first amplifier and a first capacitor, the first end of the third resistor and the negative input end of the first amplifier are both connected to the second end of the first audio input unit and the second end of the second audio input unit; the second end of the third resistor and the positive output end of the first amplifier are both connected to the first end of the first capacitor, and the second end of the first capacitor is connected to the input end of the audio output module.
[0013] In a possible implementation, the operating modes of the audio playback circuit include an operating state selection mode, a speaker mode, a left and right channel selection mode, a first channel mode, a second channel mode, and a channel rotation mode.
[0014] In one possible implementation, the selection module is also used to determine that the audio playback circuit is in a channel rotation mode based on a control signal, and generate a first channel adjustment signal and a second channel adjustment signal based on the control signal, wherein the amplitude of the first channel adjustment signal gradually decreases, and the amplitude of the second channel adjustment signal gradually increases, wherein the channel rotation mode characterizes that the electronic device where the audio playback circuit is located detects that the electronic device rotates from a first state to a second state.
[0015] In some embodiments, the first state is a horizontal screen state, and the second state is a vertical screen state. In other embodiments, the first state is a vertical screen state, and the second state is a horizontal screen state.
[0016] In one possible implementation, the selection module is further used to determine, based on the control signal, that the audio playback circuit is in a working state selection mode and enters the working state selection mode; the selection module is further used to, when in the working state selection mode, determine, based on the control signal, that the audio playback circuit is in a speaker mode and enters the speaker mode, and control the channel control module to enter the startup state; the selection module is further used to, when in the speaker mode, determine, based on the control signal, that the audio playback circuit is in a left and right channel selection mode and enters the left and right channel selection mode; the selection module is further used to, when in the left and right channel selection mode, determine, based on the control signal, that the audio playback circuit is in a first channel mode and generate, based on the control signal, a first channel adjustment signal in a third state, the first channel adjustment signal in the third state, so that the first audio input unit is turned on; the selection module is further used to, when in the left and right channel selection mode, determine, based on the control signal, that the audio playback circuit is in a second channel mode and generate, based on the control signal, a second channel adjustment signal in a first state, the second channel adjustment signal in the third state, so that the second audio input unit is turned on.
[0017] It is understood that the third state may be a high level state. In other embodiments, the third state may be a low level state.
[0018] In a second aspect, an embodiment of the present application provides an electronic device, comprising any one of the audio playback circuits and audio amplifiers provided by the first aspect and various possible implementations of the first aspect.
[0019] In a possible implementation, multiple audio playback circuits and audio power amplifiers are included, and the multiple audio playback circuits and the multiple audio power amplifiers are connected in a one-to-one correspondence.
[0020] In a third aspect, an embodiment of the present application provides a chip, in which is formed any audio playback circuit provided by the first aspect and various possible implementations of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 A schematic structural diagram of an electronic device 10 in a horizontal screen state is shown;
[0022] Figure 2 A schematic diagram of the structure of an electronic device 10 in a vertical screen state is shown;
[0023] Figure 3 According to an embodiment of the present application, a module schematic diagram of an audio playback circuit is shown;
[0024] Figure 4 According to an embodiment of the present application, a module schematic diagram of another audio playback circuit is shown;
[0025] Figure 5According to an embodiment of the present application, a module schematic diagram of another audio playback circuit is shown;
[0026] Figure 6 According to an embodiment of the present application, a module schematic diagram of another audio playback circuit is shown;
[0027] Figure 7 According to an embodiment of the present application, a schematic diagram of a change of a control signal is shown;
[0028] Figure 8 According to an embodiment of the present application, another schematic diagram of a change in a control signal is shown;
[0029] Figure 9 According to an embodiment of the present application, a circuit structure diagram of a channel control module 200 and a pre-gain amplifier unit 301 is shown;
[0030] Figure 10 According to an embodiment of the present application, a schematic structural diagram of an electronic device 10 in a landscape mode is shown;
[0031] Figure 11 According to an embodiment of the present application, a schematic structural diagram of an electronic device 10 in a portrait state is shown;
[0032] Figure 12 According to an embodiment of the present application, a flow chart of a channel switching method is shown;
[0033] Figure 13 According to an embodiment of the present application, a structural diagram of an electronic device 10 is shown. DETAILED DESCRIPTION
[0034] The illustrative embodiments of the present application include, but are not limited to, an audio playback circuit, an electronic device, and a chip.
[0035] As can be seen from the above, when the electronic device is rotated 90°, some audio amplifiers of the electronic device cannot switch channels as the electronic device rotates.
[0036] In some embodiments, to address the aforementioned issues, a channel switch can be connected in series with a hardware circuit connected to each audio amplifier of the electronic device. When the electronic device detects rotation, the channel switch can be used to switch the channel to which the audio amplifier is connected. This allows each audio amplifier to be connected to either the left channel to obtain a left-channel audio signal or the right channel to obtain a right-channel audio signal.
[0037] However, the channel switch is provided in an external hardware circuit, and it is difficult to synchronously control the channel switching process. In addition, a popping sound may occur during the switching process of the channel switch.
[0038] In addition, the channel switch is provided in an external hardware circuit, and the rotation process relies on the external hardware circuit connected in series with the channel switch, which greatly increases the cost and occupies more space during printed circuit board (PCB) layout or layout, which is not conducive to PCB routing.
[0039] To solve the above problems, the present invention provides an audio playback circuit. Figure 3 As shown, the audio playback circuit includes a selection module 100, a channel control module 200 and an audio output module 300, the audio output module 300 includes a pre-gain amplifier unit 301 and an audio power amplifier unit 302, a first end of the selection module 100 is connected to a first end of the channel control module 200, a second end of the channel control module 200 is connected to a first end of the pre-gain amplifier unit 301, and a second end of the pre-gain amplifier unit 301 is connected to a first end of the audio power amplifier unit 302, the selection module 100 is used to obtain a control signal, and generate a first channel adjustment signal and a second channel adjustment signal based on the control signal, the first channel adjustment signal and the second channel adjustment signal are negatively correlated; the channel control module 200 is used to receive a first The first channel audio signal and the second channel audio signal are processed based on the first channel adjustment signal for the amplitude of the first channel audio signal, and based on the second channel adjustment signal for the amplitude of the second channel audio signal, and the processed first channel audio signal and the second channel audio signal are processed to obtain a synthesized audio signal, and the synthesized audio signal is output to the pre-gain amplifier unit 301, and the signal processing includes synthesis processing and amplification processing; the pre-gain amplifier unit 301 amplifies the received synthesized audio signal and outputs the amplified synthesized audio signal to the audio power amplifier unit 302; the audio power amplifier unit 302 processes the received synthesized audio signal and outputs the processed synthesized audio signal.
[0040] It can be understood that the first channel adjustment signal and the second channel adjustment signal are negatively correlated. If the amplitude of the first channel adjustment signal gradually increases, the amplitude of the second channel adjustment signal gradually decreases; if the amplitude of the first channel adjustment signal gradually decreases, the amplitude of the second channel adjustment signal gradually increases.
[0041] In this way, the electronic device 10 can control the amplitude of the first channel audio signal and the amplitude of the second channel audio signal through the first channel adjustment signal and the second channel adjustment signal, thereby realizing channel switching, and there is no need to implement channel switching in the form of an external switch, eliminating the operation of connecting the channel switching switch in series with the external circuit; and, during the channel switching process, the first channel adjustment signal and the second channel adjustment signal are negatively correlated, so that the sum of the amplitudes of the first channel audio signal and the second channel audio signal is relatively stable, ensuring that there will be no auditory sensation of sudden changes in the sound during the channel switching process, thereby improving the user's auditory experience.
[0042] In the embodiments of this application, Figure 4 As shown, the channel control module 200 includes an audio input unit 201 and an amplifying unit 202. The first end of the selection module 100 is connected to the first end of the audio input unit 201, the second end of the audio input unit 201 is connected to the first end of the amplifying unit 202, and the second end of the amplifying unit 202 is connected to the first end of the pre-gain amplifying unit 301 in the audio output module 300. The audio input unit 201 is configured to receive a first channel audio signal and a second channel audio signal, process the amplitude of the first channel audio signal based on a first channel adjustment signal, and process the amplitude of the second channel audio signal based on a second channel adjustment signal. The amplifying unit 202 is configured to process the received first channel audio signal and the second channel audio signal to obtain a composite audio signal, and output the composite audio signal to the pre-gain amplifying unit 301 in the audio output module 300.
[0043] In the embodiments of this application, Figure 5 As shown, the audio input unit 201 includes a first audio input unit 2011 and a second audio input unit 2012. The first end of the selection module 100 is connected to the first end of the first audio input unit 2011 and the first end of the second audio input unit 2012, and the second end of the first audio input unit 2011 and the second end of the second audio input unit 2012 are both connected to the first end of the amplification unit 202; wherein the first audio input unit 2011 is used to obtain a first channel adjustment signal and a first channel audio signal, and adjust the amplitude of the first channel audio signal based on the first channel adjustment signal; the second audio input unit 2012 is used to obtain a second channel adjustment signal and a second channel audio signal, and adjust the amplitude of the second channel audio signal based on the second channel adjustment signal.
[0044] In an embodiment of the present application, the working modes of the audio playback circuit include a working state selection mode, a speaker mode, a left and right channel selection mode, a first channel mode, a second channel mode and a channel rotation mode.
[0045] In an embodiment of the present application, after obtaining a control signal, the selection module 100 determines that the audio playback circuit is in channel rotation mode based on the control signal, and generates a first channel adjustment signal and a second channel adjustment signal; the amplitude of the first channel adjustment signal gradually decreases, and the amplitude of the second channel adjustment signal gradually increases. The channel rotation mode indicates that the electronic device 10 where the audio playback circuit is located detects that the electronic device 10 rotates from the first state to the second state.
[0046] In some embodiments, the first state is a horizontal screen state, and the second state is a vertical screen state. In other embodiments, the first state is a vertical screen state, and the second state is a horizontal screen state.
[0047] In an embodiment of the present application, the first channel adjustment signal is a left channel adjustment signal, and the second channel adjustment signal is a right channel adjustment signal; in other embodiments, the first channel adjustment signal is a right channel adjustment signal, and the second channel adjustment signal is a left channel adjustment signal.
[0048] The following combination Figure 6 This paper introduces the structure of the audio playback circuit. Figure 6 As shown, the audio playback circuit includes a selection module 100, a channel control module 200, an audio output module 300, and a speaker 400. The channel control module 200 includes an audio input unit 201 and an amplifier unit 202. The audio input unit 201 includes a first audio input unit 2011 and a second audio input unit 2012. The audio output module 300 includes a pre-gain amplifier unit 301 and an audio power amplifier unit 302.
[0049] The second end of the selection module 100 is connected to the signal control pin, the first end of the selection module 100 is connected to the first end of the first audio input unit 2011 and the first end of the second audio input unit 2012 in the channel control module 200, the second end of the first audio input unit 2011 and the second end of the second audio input unit 2012 are both connected to the first end of the amplifier unit 202, the second end of the amplifier unit 202 is connected to the first end of the pre-gain amplifier unit 301, the second end of the pre-gain amplifier unit 301 is connected to the first end of the audio power amplifier unit 302, and the second end of the audio power amplifier unit 302 is connected to the first end of the speaker 400. The third end of the first audio input unit 2011 is connected to the pin of the audio source input 1 to obtain the audio signal of the left channel, and the third end of the second audio input unit 2012 is connected to the pin of the audio source input 2 to obtain the audio signal of the right channel.
[0050] In the embodiment of the present application, the signal control pin is used to obtain a control signal sent by the control unit of the electronic device 10. The selection module 100 can determine the operating mode of the audio playback circuit based on the control signal, wherein the operating modes of the audio playback circuit include an operating state selection mode, a speaker mode, a left and right channel selection mode, a first channel mode, a second channel mode, and a channel rotation mode.
[0051] It is understood that the electronic device 10 includes a speaker 400 and an earpiece. In the embodiment of the present application, the working mode of the audio playback circuit of the electronic device 10 can be preset to include a speaker mode and an earpiece mode.
[0052] The selection module 100 , the first audio input unit 2011 , the second audio input unit 2012 , the amplification unit 202 , the pre-gain amplification unit 301 , the audio power amplification unit 302 and the speaker 400 are introduced below respectively.
[0053] In an embodiment of the present application, the second end of the selection module 100 can be connected to multiple control pins. In other embodiments, the selection module 100 can obtain control signals based on an inter-integrated circuit (IIC) bus or a serial peripheral interface (SPI).
[0054] In the embodiment of the present application, the selection module 100 enters the working state selection mode when it is determined that the control signal meets the trigger flag of the working state selection mode; and enters the idle mode when it is determined that the control signal does not meet the trigger flag of the working state selection mode.
[0055] For example, the trigger mark of the working state selection mode is that the control signal is a high-level signal and the time for maintaining the high-level signal is greater than the first time; wherein the first time can be any positive number, for example, the first time is 100ms.
[0056] like Figure 7 As shown, Figure 7 The selection module 100 determines based on the control signal that the control signal maintains a high level within a time period t1, and the time period t1 is greater than the first time, and enters the working state selection mode.
[0057] It can be understood that the trigger flag of the working state selection mode can also be set based on the pulse edge, pulse period, etc.
[0058] When the selection module 100 is in the working state selection mode, when it is determined that the control signal meets the trigger mark of the speaker mode, that is, based on the control signal, the audio playback circuit is determined to be in speaker mode, the speaker mode is entered, and the channel control module 200 is controlled to enter the startup state; when it is determined that the control signal meets the trigger mark of the earpiece mode, that is, based on the control signal, the audio playback circuit is determined to be in earpiece mode, the earpiece mode is entered.
[0059] For example, the triggering flag for speaker mode is that the control signal is a pulse signal, and the number of pulses within the first preset time period is greater than the first value and less than or equal to the second value. The triggering flag for earpiece mode is that the control signal is a pulse signal, and the number of pulses within the first preset time period is greater than the second value. The first preset time period starts at the moment when the electronic device 10 enters the working state selection mode, and ends at the moment when the electronic device 10 enters the working state selection mode + time period t2. The first value can be any positive number less than the second value, and the second value can be any positive number greater than the first value.
[0060] for Figure 7 In the illustrated scenario, the selection module 100 determines based on the control signal that the number of pulses of the control signal in the first preset time is greater than a first value and less than or equal to a second value, and enters the speaker mode.
[0061] It is understandable that the trigger flag of the loudspeaker mode and the trigger flag of the earpiece mode can also be set based on a pulse edge, a pulse period, etc.
[0062] When the selection module 100 is in the speaker mode, it can enter the left and right channel selection mode when it is determined that the control signal meets the trigger mark of the left and right channel selection mode; when it is determined that the control signal does not meet the trigger mark of the left and right channel selection mode, it enters the idle mode.
[0063] For example, the triggering flag of the left and right channel selection mode is that the control signal is a high-level signal within a second preset time period. The start time of the second preset time period is the time when the electronic device 10 enters the speaker mode, and the end time of the second preset time period is the time when the electronic device 10 enters the speaker mode + time period t3.
[0064] for Figure 7 In the scenario shown, the selection module 100 determines based on the control signal that the control signal is a high-level signal within the second preset time period and enters the left and right channel selection mode.
[0065] It is understandable that the trigger flag of the left and right channel selection mode can also be set based on a pulse edge, a pulse period, etc.
[0066] When the selection module 100 is in the left and right channel selection mode, the selection module 100 can determine that the audio playback circuit is in the first channel mode when it is determined that the control signal meets the trigger mark of the first channel mode, and generate a first channel adjustment signal in the third state based on the control signal to control the speaker 400 to play the first channel audio signal; when the selection module 100 is in the left and right channel selection mode, the selection module 100 can determine that the audio playback circuit is in the second channel mode when it is determined that the control signal meets the trigger mark of the second channel mode, and generate a second channel adjustment signal in the third state based on the control signal to control the speaker 400 to play the second channel audio signal.
[0067] It is understood that the third state can be a high-level state. The first channel adjustment signal in the third state turns on the first audio input unit 2011, and the second channel adjustment signal in the third state turns on the second audio input unit 2012. The first audio input unit 2011 is used to obtain the first channel audio signal, and the second audio input unit 2012 is used to obtain the second channel audio signal. In other embodiments, the third state is a low-level state.
[0068] It can be understood that the trigger flag of the first channel mode and the trigger flag of the second channel mode can also be set based on the pulse edge, pulse period, etc.
[0069] In some embodiments, the first channel mode is triggered by the control signal being at a high level within a third preset time period, and the second channel mode is triggered by the control signal being at a low level within a third preset time period. The third preset time period starts at the moment the speaker 400 enters the left and right channel selection mode, and ends at the moment the speaker 400 enters the left and right channel selection mode plus time period t4.
[0070] for Figure 7 In the illustrated scenario, when the selection module 100 is in the left and right channel selection mode, the selection module 100 determines, based on the control signal, that the control signal is a low-level signal within a third preset time period, determines that the audio playback circuit is in the second channel mode, and generates a second channel adjustment signal in a third state. The second channel adjustment signal in the third state turns on the second audio input unit 2012. The channel control module 200 detects the second channel adjustment signal in the third state and turns on the second audio input unit 2012 to control the speaker 400 to play the second channel audio signal. It will be appreciated that the third state can be a high-level state, and in some other embodiments, the third state is a low-level state.
[0071] For another example, if the selection module 100 is in the left and right channel selection mode, the selection module 100 determines, based on the control signal, that the control signal is a high-level signal within a third preset time period, determines that the audio playback circuit is in the first channel mode, and generates a first channel adjustment signal in a third state. The first channel adjustment signal in the third state turns on the first audio input unit 2011. The channel control module 200 detects the first channel adjustment signal in the third state and turns on the first audio input unit 2011 to control the speaker 400 to play the first channel audio signal.
[0072] After the selection module 100 determines that the speaker 400 enters the first channel mode or the second channel mode, the selection module 100 may control the speaker 400 to switch the audio signal of the playing channel when determining that the control signal meets the trigger mark of the channel rotation mode.
[0073] For example, the channel rotation mode is triggered when the number of pulses of the control signal within a fourth preset time period is less than or equal to a third value. The fourth preset time period starts at the end time of the first pulse after the speaker 400 enters the first channel mode or the second channel mode, and the third preset time period ends at the end time of the first pulse after the speaker 400 enters the first channel mode or the second channel mode + t5.
[0074] In an embodiment of the present application, the first channel mode is a left channel mode, and the second channel mode is a right channel mode. In other embodiments, the first channel mode is a right channel mode, and the second channel mode is a left channel mode.
[0075] It is understandable that the trigger flag of the channel rotation mode can also be set based on the pulse edge, pulse period, etc.
[0076] It can be understood that the channel rotation mode indicates that the electronic device 10 where the speaker 400 is located detects that the electronic device 10 rotates from the first state to the second state.
[0077] In some embodiments, the first state is a horizontal screen state, and the second state is a vertical screen state. In other embodiments, the first state is a vertical screen state, and the second state is a horizontal screen state.
[0078] for Figure 8In the illustrated scenario, the selection module 100 determines, based on the control signal, that the number of pulses in the control signal within a fourth preset time period is less than or equal to a third value (for example, the third value may be 3), and generates a first channel adjustment signal with a gradually decreasing amplitude and a second channel adjustment signal with a gradually increasing amplitude. The channel control module 200 detects the first and second channel adjustment signals and, based on the first and second channel adjustment signals, controls the speaker 400 to switch the audio signal played in the channel. The method for controlling the speaker 400 to switch the audio signal played in the channel is described below.
[0079] In the embodiment of the present application, the sound channel control module 200 includes an audio input unit 201 and an amplification unit 202 . The audio input unit 201 includes a first audio input unit 2011 and a second audio input unit 2012 .
[0080] The first audio input unit 2011 is used to obtain the first channel adjustment signal and the first channel audio signal, and adjust the amplitude of the first channel audio signal based on the first channel adjustment signal; the second audio input unit 2012 is used to obtain the second channel adjustment signal and the second channel audio signal, and adjust the amplitude of the second channel audio signal based on the second channel adjustment signal; the amplification unit 202 is used to synthesize and amplify the adjusted first channel audio signal and the second channel audio signal to obtain a synthesized audio signal, and input the synthesized audio signal into the pre-gain amplification unit 301.
[0081] The method of adjusting the amplitude of the first channel audio signal based on the first channel adjustment signal and adjusting the amplitude of the second channel audio signal based on the second channel adjustment signal is described below.
[0082] In an embodiment of the present application, the first channel adjustment signal is a left channel adjustment signal, the first channel audio signal is a left channel audio signal, the second channel adjustment signal is a right channel adjustment signal, and the second channel audio signal is a right channel audio signal; in other embodiments, the first channel adjustment signal is a right channel adjustment signal, the first channel audio signal is a right channel audio signal, the second channel adjustment signal is a left channel adjustment signal, and the second channel audio signal is a left channel audio signal.
[0083] In an embodiment of the present application, the audio output module 300 includes a pre-gain amplifier unit 301 and an audio power amplifier unit 302; wherein the pre-gain amplifier unit 301 is used to obtain the synthesized audio signal output by the amplifier unit 202, amplify the synthesized audio signal, and input the amplified synthesized audio signal into the audio power amplifier unit 302.
[0084] The audio power amplification unit 302 is used to obtain the synthesized audio signal amplified by the pre-gain amplification unit 301, optimize the synthesized audio signal amplified by the pre-gain amplification unit 301, and input the optimized synthesized audio signal into the speaker 400 so that the speaker 400 plays the synthesized audio signal optimized by the audio power amplification unit 302.
[0085] In an embodiment of the present application, the audio power amplification unit 302 includes a class K audio power amplifier (CLASS-KAmplifier, CLASS-K); in other embodiments, the audio power amplification unit 302 includes any one of a class D audio power amplifier (CLASS-DAmplifier, CLASS-D), a class AB audio power amplifier (CLASS-AB Amplifier, CLASS-AB), a class G audio power amplifier (CLASS-GAmplifier, CLASS-G), and a class T audio power amplifier (CLASS-TAmplifier, CLASS-T).
[0086] It can be understood that Class-K is an audio amplifier that includes multiple technical advantages. Class-K integrates bootstrap boost circuit, multi-mode modulation, anti-crack function and other technologies, which can optimize the processing of input signals.
[0087] The loudspeaker 400 is used to obtain and play the synthesized audio signal optimized by the audio power amplification unit 302 .
[0088] In the following, the first channel audio signal is taken as the left channel audio signal, the second channel audio signal is taken as the right channel audio signal, the first channel adjustment signal is taken as the left channel adjustment signal, and the second channel adjustment signal is taken as the right channel adjustment signal. Figure 9 The circuit structure of the channel control module 200 and the pre-gain amplifier unit 301 in the audio playback circuit provided by the embodiment of the present application is introduced. Figure 9 As shown, the channel control module 200 includes a first audio input unit 2011, a second audio input unit 2012, and an amplifier unit 202. A first end of the first audio input unit 2011 is connected to the left channel circuit, a first end of the second audio input unit 2012 is connected to the right channel circuit, a second end of the first audio input unit 2011 and a second end of the second audio input unit 2012 are both connected to an input end of the amplifier unit 202, and an output end of the amplifier unit 202 is connected to a first end of the pre-gain amplifier unit 301.
[0089] The first audio input unit 2011 includes at least one first adjustment unit, each of which is composed of a resistor and a switch. For example, the first adjustment unit includes a first switch and a first resistor, the second end of the first switch is connected to the left channel circuit, the first end of the first switch is connected to the first end of the first resistor, and the second end of the first resistor is connected to the input end of the amplification unit 202.
[0090] It can be understood that in other embodiments, the second end of the first resistor is connected to the left channel circuit, the first end of the first resistor is connected to the first end of the first switch, and the second end of the first switch is connected to the input end of the amplification unit 202.
[0091] In the embodiment of the present application, the first switch includes any one of switch Sn1, switch Sn2, switch Sn3, ..., and switch Sni, and the first resistor includes any one of resistor Rn1, resistor Rn2, resistor Rn3, ..., and resistor Rni, and the switches and resistors have a one-to-one correspondence. That is, resistor Rn1 corresponds to switch Sn1, resistor Rn2 corresponds to switch Sn2, resistor Rn3 corresponds to switch Sn3, ..., and resistor Rni corresponds to switch Sni.
[0092] The second audio input unit 2012 includes at least one second adjustment unit, each of which is composed of a resistor and a switch. For example, the second adjustment unit includes a second switch and a second resistor, the second end of the second switch being connected to the right channel circuit, the first end of the second switch being connected to the first end of the second resistor, and the second end of the second resistor being connected to the input end of the amplification unit 202.
[0093] It can be understood that in other embodiments, the second end of the second resistor is connected to the right channel circuit, the first end of the second resistor is connected to the first end of the second switch, and the second end of the second switch is connected to the input end of the amplification unit 202.
[0094] In the embodiment of the present application, the second switch includes any one of switch Sm1, switch Sm2, switch Sm3, ..., and switch Smi, and the second resistor includes any one of resistor Rm1, resistor Rm2, resistor Rm3, ..., and resistor Rmi, and the switches and resistors have a one-to-one correspondence. That is, resistor Rm1 corresponds to switch Sm1, resistor Rm2 corresponds to switch Sm2, resistor Rm3 corresponds to switch Sm3, ..., and resistor Rmi corresponds to switch Smi.
[0095] In an embodiment of the present application, the channel control module 200 includes input pins for left-channel audio signals and right-channel audio signals, so that no matter how the electronic device where the channel control module 200 is located is rotated (such as 90°, 180°, or 270°), the audio amplifier connected to the channel control module 200 can play the left-channel audio signal and / or the right-channel audio signal.
[0096] Amplification unit 202 includes a third resistor Rf, a first amplifier A1, a first capacitor C1, and a fourth resistor R2. The first end of third resistor Rf and the negative input end of first amplifier A1 are both connected to the second end of first audio input unit 2011 and the second end of second audio input unit 2012. The second end of third resistor Rf and the positive output end of first amplifier A1 are both connected to the first end of first capacitor C1. The second end of first capacitor C1 is connected to the first end of pre-gain amplifier unit 301 in audio output module 300. The positive input end of first amplifier A1 is connected to the first end of fourth resistor R2, and the second end of fourth resistor R2 is grounded.
[0097] The first amplifier A1 is used to synthesize and amplify the left channel audio signal and the right channel audio signal inputted from the negative input terminal, the first capacitor C1 is used to filter the audio signal outputted by the first amplifier A1, and the fourth resistor R2 is used to provide a reference voltage.
[0098] It can be understood that, for the audio channel control module 200, the adjustment unit in the first audio input unit 2011, the adjustment unit in the second audio input unit 2012, and the third resistor Rf constitute the gain of the first amplifier A1. Here, the output signal of the first amplifier A1 = third resistor Rf / resistance of the first audio input unit 2011 × left-channel audio signal + third resistor Rf / second audio input unit 2012 × right-channel audio signal.
[0099] The resistance of the first audio input unit 2011 is determined based on the sum of the resistances of the resistors connected to the closed switches in the first audio input unit 2011 ; the resistance of the second audio input unit 2012 is determined based on the sum of the resistances of the resistors connected to the closed switches in the second audio input unit 2012 .
[0100] In an embodiment of the present application, the selection module 100 may generate a left channel adjustment signal and a right channel adjustment signal based on the control signal and a clock signal of the electronic device 10 when determining that the control signal meets the trigger flag of the channel rotation mode.
[0101] The left channel adjustment signal includes multiple adjustment signals for controlling the conduction state of the switches included in the adjustment unit in the first audio input unit 2011, thereby adjusting the resistance of the first audio input unit 2011 by controlling the conduction state of the switches included in the adjustment unit in the first audio input unit 2011. The right channel adjustment signal includes multiple adjustment signals for controlling the conduction state of the switches included in the adjustment unit in the second audio input unit 2012, thereby adjusting the resistance of the second audio input unit 2012 by controlling the conduction state of the switches included in the adjustment unit in the second audio input unit 2012. Thus, by adjusting the resistance of the first audio input unit 2011 and the resistance of the second audio input unit 101, the amplitudes of the left channel audio signal and the right channel audio signal are adjusted, thereby switching the audio signals of the channels played by the speaker 400.
[0102] In this embodiment of the present application, the left channel adjustment signal and the right channel adjustment signal are negatively correlated. That is, if the number of adjustment signals included in the left channel adjustment signal gradually increases, the number of adjustment signals included in the right channel adjustment signal gradually decreases; if the number of adjustment signals included in the left channel adjustment signal gradually decreases, the number of adjustment signals included in the right channel adjustment signal gradually increases.
[0103] For example, when the electronic device 10 Figure 10 The horizontal screen is rotated to Figure 11 In the vertical screen state shown, the speaker 400 (i.e., the audio amplifier 1) is rotated from the right side to the left side of the electronic device 10. Then, in the audio playback circuit connected to the speaker 400, the number of adjustment signals included in the left channel adjustment signal gradually decreases, and the number of adjustment signals included in the right channel adjustment signal gradually increases, that is, the amplitude of the left channel adjustment signal gradually decreases, and the amplitude of the right channel adjustment signal gradually increases, that is, the amplitude of the left channel audio signal gradually decreases, and the amplitude of the right channel audio signal gradually increases.
[0104] When the electronic device 10 Figure 11 The vertical screen is rotated to Figure 10 In the horizontal screen state shown, the speaker 400 (i.e., the audio amplifier 1) is rotated from the right side to the left side of the electronic device 10. Then, in the audio playback circuit connected to the speaker 400, the number of adjustment signals included in the left channel adjustment signal gradually increases, and the number of adjustment signals included in the right channel adjustment signal gradually decreases, that is, the amplitude of the left channel adjustment signal gradually increases, and the amplitude of the right channel adjustment signal gradually decreases, that is, the amplitude of the left channel audio signal gradually increases, and the amplitude of the right channel audio signal gradually decreases.
[0105] It can be understood that the adjustment signal included in the left channel adjustment signal and the adjustment signal included in the right channel adjustment signal can be generated by a digital logic circuit based on the control signal.
[0106] Figure 12 FIG. 1 shows a flow chart of switching between left and right channels of an audio amplifier in some embodiments. Figure 12 As shown, first obtain the left channel audio signal (also called dinL) and the right channel audio signal (also called dinR) of the input audio amplifier. Secondly, initialize (initialize) the calculation coefficients a, b, i, data length (also called FadeNum), and step (step); wherein a and b are the adjustment coefficients (or exchange ratios) of the left channel audio signal and the right channel audio signal, i represents the pointer of the current signal, FadeNum represents the number of bits occupied by each sampling value in the audio signal, that is, the sampling depth, step = 1 / FadeNum. Determine whether the Swap switch is triggered. If it is determined that the channel rotation mode is entered, that is, the left and right channel sound sources need to be switched, then determine that the Swap switch is triggered, and calculate the values of the coefficients a and b, wherein a = a-step, b = b+step. The exchange ratio of the left-channel audio signal and the right-channel audio signal is adjusted by a and b, so that doutL(i) = a*dinL(i) + b*dinR(i) and doutR(i) = a*dinR(i) + b*dinL(i), and i is updated so that i = i + 1. It is determined whether i is less than or equal to FadeNum, that is, whether the pointer i exceeds the set exchange data length FadeNum. If the current pointer is less than or equal to FadeNum, the above steps are repeated. If the current pointer is greater than FadeNum, the loop is exited, so that the output left-channel audio signal doutL = doutL(i) and the right-channel audio signal doutR = doutR(i).
[0107] It can be understood that if it is determined that the channel rotation mode has not been entered, that is, the left and right channel audio sources do not need to be switched, then it is determined that the Swap switch is not triggered, and the output left channel audio signal doutL=dinL(i) and the right channel audio signal doutR=dintR(i).
[0108] In this way, when it is determined to enter the channel rotation mode, the audio signal obtained by the audio amplifier includes a right channel audio signal and a left channel audio signal, and among the audio signals obtained by the audio amplifier, the left channel audio signal and the right channel audio signal are exchanged synchronously and linearly, thereby realizing channel switching.
[0109] An embodiment of the present application provides an electronic device, including the above-mentioned audio playback circuit and audio amplifier.
[0110] In some embodiments, the electronic device includes multiple audio playback circuits and multiple audio power amplifiers, and the multiple audio playback circuits and the multiple audio power amplifiers are connected in a one-to-one correspondence.
[0111] An embodiment of the present application provides a chip in which the above-mentioned audio playback circuit is formed.
[0112] According to the embodiments of the present application, Figure 13 FIG shows a block diagram of an electronic device 10 based on a system on chip (SOC). Figure 13 In FIG, similar components have the same reference numerals. In addition, the dashed boxes are optional features of more advanced SOCs. Figure 13 In the embodiment, electronic device 10 includes: an interconnect unit 1350 coupled to processor 1315; a system agent unit 1370; a bus controller unit 1380; an integrated memory controller unit 1340; a set or one or more coprocessors 1320, which may include integrated graphics logic, an image processor, an audio processor, and a video processor; a static random-access memory (SRAM) unit 1330; and a direct memory access (DMA) unit 1360. In one embodiment, coprocessor 1320 includes a special-purpose processor, such as, for example, a network or communication processor, a compression engine, or an embedded processor.
[0113] In some cases, the disclosed embodiments may be implemented in hardware, firmware, software, or any combination thereof. The disclosed embodiments may also be implemented as instructions carried or stored on one or more temporary or non-temporary machine-readable (e.g., computer-readable) storage media, which may be read and executed by one or more processors. For example, instructions may be distributed over a network or through other computer-readable media. Therefore, a machine-readable medium may include any mechanism for storing or transmitting information in a machine (e.g., computer) readable form, including but not limited to floppy disks, optical disks, optical discs, read-only memories (compact disc-read only memories, CD-ROMs), magneto-optical disks, read-only memories (ROMs), random access memories (RAMs), erasable programmable read-only memories (EPROMs), electrically erasable programmable read-only memories (EEPROMs), magnetic or optical cards, flash memory, or a tangible machine-readable memory for transmitting information (e.g., carrier waves, infrared signals, digital signals, etc.) using the Internet in electrical, optical, acoustic, or other forms of propagation signals. Accordingly, machine-readable media includes any type of machine-readable media suitable for storing or transmitting electronic instructions or information in a form readable by a machine (eg, a computer).
[0114] In the accompanying drawings, some structural or method features may be shown in a particular arrangement and / or order. However, it should be understood that such a particular arrangement and / or order may not be required. Rather, in some embodiments, these features may be arranged in a manner and / or order different from that shown in the illustrative drawings. In addition, the inclusion of a structural or method feature in a particular figure does not imply that such feature is required in all embodiments, and in some embodiments, such features may not be included or may be combined with other features.
[0115] It should be noted that the units / modules mentioned in the various device embodiments of the present application are all logical units / modules. Physically, a logical unit / module can be a physical unit / module, or a part of a physical unit / module, or can be implemented as a combination of multiple physical units / modules. The physical implementation of these logical units / modules themselves is not the most important. The combination of functions implemented by these logical units / modules is the key to solving the technical problems raised by this application. In addition, in order to highlight the innovative part of this application, the above-mentioned device embodiments of this application do not introduce units / modules that are not closely related to solving the technical problems raised by this application. This does not mean that other units / modules do not exist in the above-mentioned device embodiments.
[0116] It should be noted that in the examples and description of this patent, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or apparatus comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a" does not exclude the presence of other identical elements in the process, method, article or apparatus comprising the element.
[0117] Although the present application has been shown and described with reference to certain preferred embodiments thereof, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the application.
Claims
1. An audio playback circuit, characterized in that: The audio playback circuit includes a selection module, a channel control module and an audio output module, wherein the audio output module includes a pre-gain amplifier unit and an audio power amplifier unit, a first end of the selection module is connected to a first end of the channel control module, a second end of the channel control module is connected to a first end of the pre-gain amplifier unit, and a second end of the pre-gain amplifier unit is connected to a first end of the audio power amplifier unit. The selection module is configured to obtain a control signal, and generate a first channel adjustment signal and a second channel adjustment signal based on the control signal, wherein the first channel adjustment signal and the second channel adjustment signal are negatively correlated; The channel control module is configured to receive a first channel audio signal and a second channel audio signal, process the amplitude of the first channel audio signal based on the first channel adjustment signal, process the amplitude of the second channel audio signal based on the second channel adjustment signal, perform signal processing on the processed first channel audio signal and second channel audio signal to obtain a synthesized audio signal, and output the synthesized audio signal to the pre-gain amplification unit, wherein the signal processing includes synthesis processing and amplification processing; The pre-gain amplifier unit amplifies the received synthesized audio signal and outputs the amplified synthesized audio signal to the audio power amplifier unit; The audio power amplifying unit processes the received synthesized audio signal and outputs the processed synthesized audio signal.
2. The audio playback circuit according to claim 1, wherein: The sum of the amplitudes of the first channel audio signal and the second channel audio signal after processing is equal to the sum of the amplitudes of the first channel audio signal and the second channel audio signal before processing.
3. The audio playback circuit according to claim 1, wherein: The channel control module includes an audio input unit and an amplifying unit. The first end of the selection module is connected to the first end of the audio input unit, the second end of the audio input unit is connected to the first end of the amplifying unit, and the second end of the amplifying unit is connected to the audio output module. The audio input unit is configured to receive the first channel audio signal and the second channel audio signal, process the amplitude of the first channel audio signal based on the first channel adjustment signal, and process the amplitude of the second channel audio signal based on the second channel adjustment signal; The amplifying unit is configured to perform signal processing on the received first channel audio signal and the second channel audio signal to obtain the synthesized audio signal, and output the synthesized audio signal to the audio output module.
4. The audio playback circuit according to claim 3, characterized in that: The audio input unit includes a first audio input unit, the first audio input unit includes at least one first adjustment unit, the first adjustment unit includes a first switch and a first resistor, the first end of the first switch is connected to the first end of the first resistor, and the second end of the first resistor is connected to the input end of the amplification unit.
5. The audio playback circuit according to claim 3, characterized in that: The audio input unit includes a second audio input unit, the second audio input unit includes at least one second adjustment unit, the second adjustment unit includes a second switch and a second resistor, the first end of the second switch is connected to the first end of the second resistor, and the second end of the second resistor is connected to the input end of the amplification unit.
6. The audio playback circuit according to claim 3, characterized in that: The amplifying unit includes a third resistor, a first amplifier and a first capacitor, The first end of the third resistor and the negative input end of the first amplifier are both connected to the second end of the first audio input unit and the second end of the second audio input unit; The second end of the third resistor and the positive output end of the first amplifier are both connected to the first end of the first capacitor, and the second end of the first capacitor is connected to the input end of the audio output module.
7. The audio playback circuit according to claim 1, wherein: The working modes of the audio playback circuit include a working state selection mode, a speaker mode, a left and right channel selection mode, a first channel mode, a second channel mode and a channel rotation mode.
8. The audio playback circuit according to claim 7, characterized in that: The selection module is further configured to determine, based on the control signal, that the audio playback circuit is in a channel rotation mode, and generate, based on the control signal, the first channel adjustment signal and the second channel adjustment signal, wherein the amplitude of the first channel adjustment signal gradually decreases, and the amplitude of the second channel adjustment signal gradually increases. The channel rotation mode indicates that the electronic device where the audio playback circuit is located detects that the electronic device has rotated from a first state to a second state.
9. The audio playback circuit according to claim 7, characterized in that: The selection module is further configured to determine, based on the control signal, that the audio playback circuit is in a working state selection mode and enter the working state selection mode; The selection module is further configured to, when in the working state selection mode, determine based on the control signal that the audio playback circuit is in speaker mode, enter the speaker mode, and control the channel control module to enter a startup state; The selection module is further configured to, when in the speaker mode, determine based on the control signal that the audio playback circuit is in a left and right channel selection mode, and enter the left and right channel selection mode; The selection module is further configured to, when in the left and right channel selection mode, determine that the audio playback circuit is in the first channel mode based on the control signal, and generate a first channel adjustment signal in a third state based on the control signal, wherein the first channel adjustment signal in the third state turns on the first audio input unit; The selection module is further configured to, when in the left and right channel selection mode, determine that the audio playback circuit is in the second channel mode based on the control signal, generate the second channel adjustment signal in the first state based on the control signal, and the second channel adjustment signal in the third state turns on the second audio input unit.
10. An electronic device, characterized in that: The invention comprises the audio playback circuit and audio power amplifier according to any one of claims 1 to 9.
11. The electronic device according to claim 10, characterized in that It comprises a plurality of the audio playing circuits and a plurality of audio power amplifiers, and the plurality of the audio playing circuits and the plurality of the audio power amplifiers are connected in a one-to-one correspondence.
12. A chip, characterized in that: The chip includes the audio playback circuit according to any one of claims 1 to 9.
Citation Information
Patent Citations
Audio processor for orientation-dependent processing
CN105532018A
Mobile terminal and audio-left and right channels automatic switching method of mobile terminal
CN106028254A
Sound channel switching method and device and electronic equipment
CN113630695A
Audio data processing method and related device
CN116567489A