Disclosure of Invention
In view of the above, the present invention provides an audio signal processor and an audio signal processing method, which sample a supply voltage by adding a correction circuit, and generate an analog output signal without an ac component of the supply voltage by controlling a power stage circuit through a feedforward loop, so as to solve the problem of audio quality degradation of an audio signal due to a ripple variation of the supply voltage in the prior art.
According to a first aspect of the present invention, there is provided an audio signal processor comprising:
a correction circuit that receives an audio input signal and a supply voltage of a power stage circuit of the processor; controlling the power stage circuit to produce an analog output signal free of an alternating current component of the supply voltage by a feed-forward loop including the correction circuit and a tone adjustment circuit.
Preferably, the correction circuit generates a correction signal comprising a dc component of the supply voltage and a digital supply voltage signal for controlling the power stage circuit to generate an analogue output signal free of an ac component of the supply voltage.
Preferably, the time delay generated by the feedforward loop is within a preset range to eliminate the influence of the ripple variation of the supply voltage on the analog output signal.
Preferably, the correction circuit includes:
a signal conversion circuit configured to receive the supply voltage and generate the digital supply voltage signal and the DC component of the supply voltage;
a ripple suppression circuit configured to signal process the direct current component of the supply voltage and the digital supply voltage signal to generate the correction signal.
Preferably, the ripple suppression circuit includes:
a multiplier that multiplies the audio input signal subjected to audio processing and the direct current component of the supply voltage;
a divider that divides the direct current component of the supply voltage and the digital supply voltage signal to generate the correction signal.
Preferably, the signal conversion circuit includes:
a first analog-to-digital converter configured to digitally process the supply voltage and generate the digital supply voltage signal;
a low pass filter configured to generate the DC component of the supply voltage based on the digital supply voltage signal.
Preferably, the number of bits of the first analog-to-digital converter is not lower than a first preset value, so as to eliminate the influence of the correction circuit on the analog output signal.
Preferably, a cut-off frequency of the low-pass filter is not higher than a preset frequency value to eliminate an influence of the correction circuit on the analog output signal.
Preferably, the signal conversion circuit includes:
a second analog-to-digital converter configured to digitally process the supply voltage and generate the DC component of the supply voltage;
a third analog-to-digital converter configured to digitally process the supply voltage and generate an alternating current component of the supply voltage;
an adder configured to add the direct current component of the supply voltage and the alternating current component of the supply voltage and obtain the digital supply voltage signal.
Preferably, the number of bits of the second analog-to-digital converter and the third analog-to-digital converter is not lower than a second preset value, so as to eliminate the influence of the correction circuit on the analog output signal.
According to a second aspect of the present invention, there is provided an audio signal processing method comprising:
receiving an audio input signal and a supply voltage of a power stage circuit to generate a correction signal;
the power stage circuit is controlled by a feed-forward loop to generate an analog output signal free of an alternating current component of the supply voltage.
Preferably, the correction signal comprises a dc component of the supply voltage and a digital supply voltage signal for controlling the power stage circuit to produce an analogue output signal free of an ac component of the supply voltage.
Preferably, the time delay generated by the feedforward loop is within a preset range to eliminate the influence of the ripple variation of the supply voltage on the analog output signal.
Preferably, the acquiring of the correction signal comprises the steps of:
receiving the supply voltage and generating the digital supply voltage signal and the dc component of the supply voltage;
signal processing the DC component of the supply voltage and the digital supply voltage signal to generate the correction signal
Preferably, the acquiring of the correction signal comprises the steps of:
multiplying the audio input signal that is audio processed by the DC component of the supply voltage;
dividing the direct current component of the supply voltage and the digital supply voltage signal to produce the correction signal.
Preferably, obtaining the digital supply voltage signal and the dc component of the supply voltage comprises the steps of:
digitally processing the supply voltage and generating the digital supply voltage signal;
generating the DC component of the supply voltage based on the digital supply voltage signal.
Preferably, obtaining the digital supply voltage signal and the dc component of the supply voltage comprises the steps of:
digitally processing the supply voltage and generating a direct current component of the supply voltage;
digitally processing the supply voltage and generating an alternating current component of the supply voltage;
adding the DC component of the supply voltage and the AC component of the supply voltage to obtain the digital supply voltage signal.
The audio signal processor of the invention samples the supply voltage by adding the correction circuit with simple structure to generate the correction signal, and effectively eliminates the influence of the ripple variation of the supply voltage on the analog output signal of the audio signal processor in time by the feedforward loop comprising the correction circuit, thereby improving the audio quality, avoiding the complexity of the design of the closed-loop control loop, saving the area of a circuit system and reducing the manufacturing cost of the circuit system.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 2 is a schematic block diagram of an audio signal processor according to an embodiment of the invention.
Referring to fig. 2, an audio signal processor according to an embodiment of the invention includes a calibration circuit 23. Audio processing circuit 20 is configured to receive an audio input signal Vin and digitally process it to generate an input signal D; the correction circuit 23 receives the supply voltage Vm of the power stage circuit 22 and the input signal D to generate a correction signal C, which includes a direct-current component of the supply voltage and a digital supply voltage signal; the audio adjusting circuit 21 quantizes, shapes and modulates the correction signal C and generates a pulse width modulated signal D, which is thus a function of the input signal D, the direct current component of the supply voltage and the digital supply voltage signal; the power stage circuit 22 receives the supply voltage Vm and generates an analog output signal Vo from the pulse width modulated signal d. Wherein the supply voltage Vm and the input signal D form a feed forward loop 2 via the correction circuit 23 and the tone adjusting circuit 21 to the pulse width modulation signal D, the supply voltage Vm forms a main path 1 via the power stage circuit 22 to the analog output signal Vo, and the feed forward loop 2 controls the main path 1 by open loop. The audio input signal Vin may be an information carrier with frequency and amplitude variations of regular sound waves of speech, music and sound effects, and the audio conditioning circuit 21, including circuit blocks such as a noise shaper, a pulse width modulation circuit, etc., are well known in the art and therefore will not be described in detail here.
As can be seen from fig. 2, the pulse width modulation signal D is a function of the input signal D, the dc component of the supply voltage and the digital supply voltage signal, wherein the input signal D is obtained by processing the audio input signal Vin by the audio processing circuit 20, while the supply voltage Vm is the input voltage of the power stage circuit 22, the power stage circuit 22 receives the pulse width modulation signal D and the supply voltage Vm and generates the analog output signal Vo, so the analog output signal Vo can be regarded as a function of the audio input signal Vin and the supply voltage Vm, if the ripple variation Δ Vm of the supply voltage Vm is regarded as a very small signal, the voltage gain a of the supply voltage Vm to the analog output signal Vo is multiplied by the variation Δ Vm of the supply voltage Vm, that is, the voltage gain a of the power stage circuit 22 is multiplied by the variation Δ Vm of the supply voltage Vm, the ripple variation Δ Vm of the supply voltage Vm therefore necessarily affects the analog output signal Vo, the magnitude of the effect depending on the Power Supply Rejection Ratio (PSRR), the greater the Power Supply Rejection Ratio (PSRR), the better the output audio quality of the audio signal processor.
When the supply voltage Vm changes, the correction circuit 23 generates a correction signal C according to the supply voltage Vm and the input signal D, and the correction signal C can timely compensate the influence of the correction signal C on the analog output signal Vo according to the variation quantity Δ Vm of the supply voltage Vm in advance, that is, the feedforward loop 2 controls the power stage circuit 22 to generate the analog output signal Vo without the alternating current component of the supply voltage Vm, so that the analog output signal Vo is prevented from fluctuating due to the variation of the supply voltage Vm, the influence on the analog output signal Vo of the audio processor when the supply voltage Vm changes is effectively compensated, and the audio quality of the analog output signal Vo is improved; compared with analog closed-loop control, the invention inhibits the ripple interference of the supply voltage Vm through the correction circuit 23 with simple structure, avoids the complexity of closed-loop control loop design, simplifies the design difficulty of the circuit, and can reduce the chip area.
The delay time of the feedforward loop 2 can be reduced by optimizing the circuit structure, so that the delay time of the feedforward loop 2 is in a preset range, the influence of the ripple change of the supply voltage Vm on the analog output signal Vo is eliminated, and the power supply rejection ratio can be better improved. For example, the delay time is reduced from 10 clock signal periods to less than 1 clock signal period according to the requirements of the application environment, so that the power supply rejection ratio is increased to meet the application requirements.
The audio adjusting circuit 21 of the present invention includes circuit modules such as a noise shaper, a pulse width modulator, an analog-to-digital converter, etc., and the audio processor of the present invention can have various implementation forms according to the function and the circuit connection mode of the audio processor, and the correcting circuit 23 can be applied to the audio signal processor of the present invention to eliminate the influence of the supply voltage Vm of the power stage circuit 22 on the analog output signal Vo.
Fig. 3 is a circuit schematic diagram of an alternative manner of the correction circuit 23 of the audio processor shown in fig. 2.
Referring to fig. 3, the calibration circuit 23 includes a signal conversion circuit 30 and a ripple suppression circuit 31, the signal conversion circuit 30 receives the supply voltage Vm and generates a dc component P of the supply voltage VmDCAnd a digital supply voltage signal P, the ripple suppression circuit 31 receiving the direct current component P of the supply voltage VmDCAnd a digital supply voltage signal P to generate a correction signal C.
The signal conversion circuit 30 includes a first analog-to-digital converter 301 and a low-pass filter 302, and the ripple suppression circuit 31 includes a multiplier 303 and a divider 304. The first analog-to-digital converter 301 receives the supply voltage Vm and digitizes it to generate a digital supply voltage signal P, which may be represented as a direct current component P of the supply voltage VmDCAnd an alternating current component PACSumming; the low-pass filter 302 receives the digital supply voltage signal P and filters it to obtain a dc component P of the supply voltage VmDCThe multiplier 303 multiplies the DC component PDCMultiplying the input signal D to obtain the input signal D and a DC component PDCThe divider 304 divides the product and the digital supply voltage signal P to obtain a ratio of the product and the digital supply voltage signal P, which is the correction signal C, and thus the correction signal C can be expressed as follows:
wherein D is an input signal generated after audio processing of the audio input signal Vin, PDCIs the dc component of the supply voltage Vm sampled by the first analog-to-digital converter 301, P being the digital supply voltage signal.
The number of bits of the first adc 301 is not lower than a first preset value, and the first preset value is set according to application requirements, so as to eliminate the influence of the correction circuit 23 on the analog output signal Vo. The correction signal C can eliminate the influence of the ripple variation Δ Vm of the supply voltage Vm on the analog output signal Vo through the feedforward loop 2 in time, thereby obtaining a stable analog output signal Vo.
Fig. 4 is a circuit schematic diagram of another alternative of the correction circuit 23 of the audio processor shown in fig. 2.
Referring to fig. 4, the signal conversion circuit 30 in the correction circuit 23 includes a second analog-to-digital converter 401, a third analog-to-digital converter 402 and an adder 403. The second adc 401 and the third adc 402 receive the supply voltage Vm and perform digital processing on the supply voltage Vm to generate a dc component P of the supply voltage Vm respectivelyDCAnd an alternating current component PACThe adder 403 adds the DC component PDCAnd an alternating current component PACThe addition operation is performed to obtain the digital supply voltage signal P, and therefore the digital supply voltage signal P can be expressed as: p ═ PDC+PAC. The operation principle of the ripple suppression circuit 31 is the same as that of fig. 3, and is not described herein again. The number of bits of the second adc 401 and the third adc 402 is not lower than a second preset value, which is set according to the application requirement to eliminate the influence of the correction circuit 23 on the analog output signal Vo, wherein the second preset value may be equal to the first preset value.
As can be seen from fig. 2, the power stage circuit 22 uses the supply voltage Vm and the pulse width modulation signal d as input signals, and uses the analog output signal Vo as output signals, and since the audio adjusting circuit 21 only quantizes, shapes and modulates the correction signal C, the digital representation of the correction signal C is not affected, and the influence of the audio adjusting circuit 21 on the correction signal C can be ignored for the convenience of mathematical analysis, so the relationship between the input signal and the output signal of the main channel 1 of the audio signal processor in the present invention can be simplified and expressed as follows:
where Vo is the analog output signal of the audio signal processor, d is the pulse width modulated signal, Vm is the supply voltage of the power stage circuit 22, and a is the gain of the power stage circuit 22. P is a digital supply voltage signal.
The supply voltage Vm may be represented as follows:
Vm=kp(P+ep)=Vm_DC+p(k) (3)
wherein k ispRepresenting the proportionality coefficient between the sampled value, obtained by sampling the supply voltage Vm by the correction circuit 23, and the true value, epRepresents a sampling error when the supply voltage Vm is sampled, p (k) kpep。
The actual DC component V of the supply voltage Vmm_DCCan be expressed as follows:
Vm_DC=kp(PDC+epDC) (4)
wherein epDCRepresenting the actual DC component V to the supply voltage Vmm_DCSampling error in sampling.
The pulse width modulation signal d can be expressed as follows:
d=(d(k-N)+ed) (5)
wherein d (k-N) represents the delay time generated by the audio input signal Vin through the feedforward path 2, i.e. the delay time generated from the correction circuit 23 to the power stage circuit 22, N represents the number of units of delay, which may be an integer or a decimal number, k represents the current time, edRepresenting the error of the audio input signal Vin after being digitized by the feed forward loop 2.
As can be seen from equation (3), the digital supply voltage signal P includes the following expression of the delay unit N at time k:
from the equation (4), the dc component P obtained by sampling the supply voltage VmDCThe expression containing the delay unit N at time k is as follows:
substituting equations (5) - (7) into equation (2) can obtain analog output signal VOThe specific expression for the error at time k is as follows:
VO(k)=(d(k-N)+ed)
(Vm_DC(k)+p(k))(A+ea) (8)
where A is the gain of the power stage circuit 22, eaAn error generated by the power stage circuit 22. By subjecting equation (8) to linearization processing according to the small signal analysis method, the following expression can be obtained:
Vo(k)≈(d(k-N)+ed){Vm_DC(k)-[p(k-N)-kpep]
+p(k)-kpepDC}(A+ea)
≈Vm_DC(k)d(k-N)
+Vm_DC(k)kped
+d(k-N)[p(k)-p(k-N)]+d(k-N)kpep
-d(k-N)kpepDC+Vm_DC(k)d(k-N)ea (9)
as can be seen from equation (9), the output V of the analog output signal Vo at time kO(k) The device comprises two parts: a part being a useful output V generated by the input signalm_DC(k) d (k-N), the remainder being the various errors added to the input signal after it has passed through the audio signal processor, which can interfere with the useful output, and therefore, it is desirable to reduce the various errors and improve the audio quality.
The influence of various errors can be expressed by calculating the signal-to-noise ratio of various errors in the formula (9), the signal-to-noise ratio can be generally expressed as the ratio of useful signals to noise in the analog output signal Vo, and the higher the signal-to-noise ratio is, the more useful signals in the analog output signal Vo are, the better the audio quality is, so that the audio signal processor can be better optimized and the influence of the errors on the performance of the system can be reduced by calculating the signal-to-noise ratio of various errors in the analog output signal Vo.
First error Vm_DC(k)kpedIs composed of soundGenerated by digital circuits integrated inside the frequency signal processor.
Second error d (k-N) [ p (k) -p (k-N)]Is the error caused by the ripple variation of the supply voltage Vm, and is also the error to be eliminated by the present invention by adding the correction circuit 23, the second signal-to-noise ratio SNR corresponding to the second error2The numerical values of (a) can be expressed as follows:
from this, the second SNR is2Related to the number of units of delay time N generated by the feedforward loop 2, the smaller N, the second SNR2The larger the second error is, the smaller the second error is, and the feedforward loop 2 controls the delay time to be within a preset range according to application requirements, so that the influence of the ripple variation of the supply voltage Vm on the analog output signal Vo is effectively inhibited. For example, if the power supply rejection ratio is guaranteed to be good in the high frequency (20kHz) phase according to the application requirements, the number of delay units N is less than 2 units.
Third error d (k-N) kpepAnd a fourth error-d (k-N) kpepDCIs the error introduced by the correction circuit 23, the third signal-to-noise ratio SNR corresponding to the third error3Can be expressed as follows:
wherein P isADCIs a fixed detection value, P, generated when the first, second and third analog-to-digital converters 301, 401, 402 sample the supply voltage VmbitNumber of bits representing an analog-to-digital converter, number of bits PbitCan be expressed as the ratio of the voltage represented by the Least Significant Bit (LSB) of the analog-to-digital converter and the supply voltage Vm.
Third signal-to-noise ratio SNR3Number of bits P associated with analog-to-digital converterbitIs increased, the first preset value and the second preset value are set according to the application environment, so that the third SNR is increased3Satisfy the requirement ofApplication requirements. For example, a third SNR is required in the application3Up to 0.1% (60dB), the fixed detection value produced by the analog-to-digital converter when sampling the supply voltage Vm is 12dB, and the number of bits of the analog-to-digital converter is at least 8 bits, i.e. the first preset value and the second preset value are 8.
Fourth error-d (k-N) kpepDCCorresponding fourth SNR4Can be expressed as follows:
wherein Vmax=max(|-d(k-N)kp|) represents the maximum value of the analog output signal Vo generated by the power stage circuit 22, eDCRepresenting a direct current component P to the supply voltage VmDCError after normalization. In fig. 3, a digital signal P of a supply voltage Vm is obtained by the supply voltage Vm passing through an analog-to-digital converter 301, and a dc component P of the supply voltage VmDCThe digital supply voltage signal P is filtered by the low pass filter 302, then eDCRepresenting the AC component P of the digital supply voltage signal P by the low-pass filter 302ACPerforming attenuation to obtain DC component PDCErrors in time. In fig. 4, the second analog-to-digital converter 401 samples the supply voltage Vm and obtains the dc component P of the supply voltage VmDCThen in this example eDCIndicating that the analog-to-digital converter 401 generates a dc component PDCErrors in time. By a fourth signal-to-noise ratio SNR4Is given by the expression ofDCThe smaller, the fourth signal-to-noise ratio SNR4The larger the fourth error, the smaller.
For the correction circuit 23 in fig. 3, the cut-off frequency of the low-pass filter 302 is set low enough to better filter out the alternating current component P in the digital supply voltage signal PACSo that the direct current component PDCDoes not contain an alternating current component PACThereby reducing the error eDC. The low-pass filter 302 receives the digital supply voltage signal P at its input and generates the dc component P of the supply voltage Vm at its outputDC Low pass filter 302 at time kThe relationship of input and output can be expressed as:
PDC(k)=(1-2-n)PDC(k-1)+2-nP(k)
where n is a delay time and is an integer, and the cutoff frequency of the low-pass filter 302 decreases with a decrease in the delay time n, so that the suitable delay time n is set so that the cutoff frequency is not higher than a preset frequency value, and the preset frequency value can be set according to a ripple variation of the supply voltage Vm in an application environment, so that the dc component P sampled by the low-pass filter 302DCA direct current component close to the actual supply voltage Vm, thereby reducing the error eDCTo improve the fourth signal-to-noise ratio SNR4。
For the correction circuit 23 in fig. 4, the sampled dc component P can be made by increasing the sampling precision of the second analog-to-digital converter 401DCApproximating the dc component of the actual supply voltage Vm to reduce the error eDC. In one implementation, a low-pass filter is added to the input of the second adc 401 to filter the supply voltage Vm, and then the second adc 401 samples the filtered supply voltage Vm to obtain a dc component P close to the actual supply voltage VmDCThereby reducing the error eDCTo improve the fourth signal-to-noise ratio SNR4. In another implementation, the second analog-to-digital converter 401 may be configured as an analog-to-digital converter with a smaller number of bits and a larger voltage value represented by the Least Significant Bit (LSB), for example, the supply voltage Vm is 12V, the number of bits of the second analog-to-digital converter 401 may be set to 4 bits, the voltage represented by the least significant bit may be 0.75V, and then the ripple variation of the supply voltage Vm smaller than 0.75V is not detected by the second analog-to-digital converter 401, so that the dc component P of the supply voltage Vm sampled by the second analog-to-digital converter 401 is not detectedDCApproaching the actual dc component of the supply voltage Vm, thereby reducing the error eDCTo improve the fourth signal-to-noise ratio SNR4。
Fifth error Vm_DC(k)d(k-N)eaIs generated by analog circuitry in the audio signal processor.
In summary, the analog output signal Vo of the audio signal processor generates a useful output portion while introducing various errors, wherein the errors caused by the ripple variation of the supply voltage Vm account for a large proportion, so the present invention suppresses the influence of the ripple variation of the supply voltage Vm on the analog output signal Vo by adding the correction circuit. As can be seen from equation (9), the first error and the fifth error are caused by errors of the digital circuit and the analog circuit themselves integrated inside the audio signal processor, such as non-ideal factors of devices, circuit layout, and the like, respectively, and therefore the first error and the fifth error have little influence on the circuitry while being avoided as much as possible, and are well known in various embodiments, and therefore, will not be described in detail herein; the second error is an error caused by the ripple variation of the supply voltage Vm, and is also an error that can be eliminated by the correction circuit 23 in the present invention, and the third error and the fourth error are errors caused by the correction circuit 23, but the third error and the fourth error can be eliminated by optimizing the correction circuit 23, so the audio signal processor in the present invention can effectively filter the error generated in the analog output signal Vo due to the ripple variation of the supply voltage Vm by adding the correction circuit 23, and the output audio quality of the audio signal processor is improved.
FIG. 5 is a flowchart illustrating an audio signal processing method according to an embodiment of the invention.
Referring to fig. 5, the audio signal processing method includes the following steps:
s501: receiving an audio input signal and a supply voltage of a power stage circuit to generate a correction signal;
s502: the power stage circuit is controlled by a feed-forward loop to generate an analog output signal free of an alternating current component of the supply voltage.
Wherein the correction signal comprises a direct current component of a supply voltage and a digital supply voltage signal; the time delay generated by the feedforward loop is within a preset range so as to eliminate the influence of the ripple change of the supply voltage on the analog output signal.
Acquiring the correction signal comprises the following steps:
receiving the supply voltage and generating a digital supply voltage signal and the DC component of the supply voltage;
signal processing the direct current component of the supply voltage and a digital supply voltage signal to produce the correction signal;
wherein the audio input signal subjected to audio processing and the direct current component of the supply voltage are multiplied, and the direct current component of the supply voltage and a digital supply voltage signal are divided to generate the correction signal.
In one implementation, obtaining a digital supply voltage signal and the dc component of the supply voltage includes the steps of:
digitally processing the supply voltage and generating a digital supply voltage signal;
the direct current component of the supply voltage is generated based on a digital supply voltage signal.
In another implementation, obtaining a digital supply voltage signal P and the dc component of the supply voltage comprises the steps of:
digitally processing the supply voltage and generating a direct current component of the supply voltage;
digitally processing the supply voltage and generating an alternating current component of the supply voltage;
adding the DC component of the supply voltage and the AC component of the supply voltage to obtain a digital supply voltage signal.
It should be noted that the devices with the same names in the embodiments of the present invention have the same functions, and the modified embodiments can be combined with the above embodiments, but the description is only exemplified on the basis of the above embodiment. Those skilled in the art may make modifications to the disclosed circuit based on the embodiments of the present invention, and such modifications are within the scope of the embodiments of the present invention.
Having described the audio processor and the audio signal processing method according to the preferred embodiment of the present invention in detail, it is understood by those skilled in the art that other techniques or structures and circuit layouts, components, etc. may be applied to the embodiments. The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.