A dynamic balancing method and circuit

By calculating the maximum and minimum gain coefficients, the computational complexity and storage space of the dynamic equalizer are simplified, the problem of transient instability and noise caused by real-time adjustment of filter coefficients is solved, and stable dynamic signal adjustment is achieved.

CN116072128BActive Publication Date: 2026-06-26SHANGHAI AWINIC TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHANGHAI AWINIC TECH CO LTD
Filing Date
2021-10-29
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

In existing technologies, dynamic equalizers are prone to momentary instability and noise when adjusting filter coefficients in real time, and the computational load is large.

Method used

By calculating the maximum and minimum gain coefficients, multiplying the input signal by them, and then superimposing them, the output signal can be dynamically adjusted, avoiding real-time calculation of filter coefficients, simplifying the computation, and stabilizing the filter.

Benefits of technology

While achieving real-time dynamic adjustment of the output signal, it reduces the computational load and storage space requirements, and avoids noise problems caused by sudden changes in filter coefficients.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116072128B_ABST
    Figure CN116072128B_ABST
Patent Text Reader

Abstract

The application provides a dynamic equalization method and circuit, which comprises the following steps: calculating a maximum gain coefficient and a minimum gain coefficient according to an input signal and preset processing parameters; multiplying the filtered input signal and one of the maximum gain coefficient and the minimum gain coefficient to obtain a first output signal; multiplying the input signal directly or after filtering or delaying and the other of the maximum gain coefficient and the minimum gain coefficient to obtain a second output signal; and superimposing the first output signal and the second output signal to obtain a final output signal; and adjusting the proportional relationship between the two input signals to achieve the purpose of adjusting the final output signal in real time. This method simplifies the required calculation amount and storage space of the dynamic filter, avoids the problem of harmonic and noise caused by the sudden change of the filter coefficient, and is effective in optimizing the calculation amount.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of electronic circuit technology, and more specifically, relates to a dynamic equalization method and circuit. Background Technology

[0002] In today's world of increasingly demanding audio processing requirements, traditional static equalizers are no longer sufficient to achieve optimal sound quality at every moment of the music's flow. Therefore, in recent years, audio manufacturers have introduced dynamic filters to meet these needs. Dynamic filters combine frequency domain adjustment and time domain dynamic control to achieve dynamic adjustment of the signal's frequency domain. By detecting the loudness, noise level, and spectral characteristics of the input signal through a detection unit, and calculating the parameters of the equalization filter bank in real time, the input signal can be passed through this equalization filter bank to achieve dynamic adjustments in loudness equalization, noise control, gain level, and timbre.

[0003] Existing dynamic equalization implementations all calculate and modify the parameters of the EQ (Equilibrium) filter, such as the coefficients of the IIR filter, in real time based on the input audio content to perform loudness equalization and DRC (Dynamic Range Control). This method requires high processing power from the DSP (digital signal processing). Furthermore, real-time adjustment of the filter coefficients may cause momentary instability of the filter, resulting in noise. Summary of the Invention

[0004] In view of this, the purpose of the present invention is to provide a dynamic equalization method and circuit, which can effectively optimize the computational load by adjusting the ratio of the two input signals to achieve real-time adjustment of the output signal.

[0005] The first aspect of this invention discloses a dynamic equilibrium method, comprising:

[0006] Based on the input signal and preset processing parameters, calculate the maximum gain coefficient and the minimum gain coefficient; wherein the sum of the maximum gain coefficient and the minimum gain coefficient is 1;

[0007] The product of the filtered input signal and one of the maximum gain coefficient and the minimum gain coefficient is used as the first output signal; and the product of the input signal directly or after filtering and / or delay and the other of the maximum gain coefficient and the minimum gain coefficient is used as the second output signal.

[0008] The superposition of the first output signal and the second output signal is taken as the final output signal.

[0009] Optionally, calculating the maximum gain coefficient and minimum gain coefficient based on the input signal and preset processing parameters includes:

[0010] The input signal is filtered to remove preset frequency components, and the signal parameters of the filtered input signal are detected.

[0011] The target gain is obtained based on the signal parameters and the preset processing parameters;

[0012] The target gain is proportionally calculated to obtain the maximum gain coefficient and the minimum gain coefficient.

[0013] Optionally, before performing a scaling calculation on the target gain to obtain the maximum and minimum gain coefficients, the method further includes:

[0014] The target gain value is smoothed based on the jumps in the target gain and the preset start and release times.

[0015] Optionally, the detection method includes at least one of mean square value detection or peak value detection.

[0016] Optionally, the signal parameters include at least one of the amplitude, power, and loudness of the input signal;

[0017] The processing parameters include: processing threshold, processing ratio, and processing compensation gain.

[0018] Optionally, the formula used to calculate the maximum gain coefficient and the minimum gain coefficient by proportionally calculating the target gain is as follows:

[0019] RatioMax=(TarGain-GainMin) / (GainMax-GainMin); RatioMin=1-RatioMax;

[0020] or,

[0021] RatioMin=(GainMax-TarGain) / (GainMax-GainMin); RatioMax=1-RatioMin;

[0022] Wherein, TarGain is the target gain; GainMax is the maximum gain; GainMin is the minimum gain, and the maximum gain and the minimum gain are calculated through the preset processing parameters; RatioMax is the maximum gain coefficient; and RatioMin is the minimum gain coefficient.

[0023] Optionally, the product of the filtered input signal and one of the maximum gain coefficient and the minimum gain coefficient is used as a first output signal; and the product of the input signal, directly or after filtering and / or delay, and the other of the maximum gain coefficient and the minimum gain coefficient is used as a second output signal, including:

[0024] The product of the filtered input signal and the maximum gain coefficient is used as the first output signal, and the product of the filtered input signal and the minimum gain coefficient is used as the second output signal.

[0025] Optionally, before performing a scaling calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient, the method further includes:

[0026] Determine whether the target gain represents an improvement in the input signal;

[0027] If the target gain represents the boost of the input signal, then the formulas used for the maximum gain coefficient and the minimum gain coefficient are transformed as follows: RatioMax = (TarGain-1) / (GainMax-1), RatioMin = 1-RatioMax;

[0028] If the target gain characterizes the attenuation of the input signal, then the formulas used for the maximum gain coefficient and the minimum gain coefficient are transformed as follows: RatioMax=(TarGain-GainMin) / (1-GainMin), RatioMin=1-RatioMax.

[0029] Optionally, the step of multiplying the filtered input signal by one of the maximum gain coefficient and the minimum gain coefficient as a first output signal; and multiplying the input signal directly or after filtering and / or delay by the other of the minimum gain coefficient and the minimum gain coefficient as a second output signal, includes:

[0030] If the target gain represents an improvement in the input signal, then the product of the filtered input signal and the maximum gain coefficient is used as the first output signal; and the product of the delayed input signal and the minimum gain coefficient is used as the second output signal.

[0031] If the target gain characterizes the attenuation of the input signal, then the product of the delayed input signal and the maximum gain coefficient is used as the second output signal; and the product of the filtered input signal and the minimum gain coefficient is used as the first output signal.

[0032] Optionally, determining whether the target gain characterizes an improvement in the input signal includes:

[0033] Determine whether the target gain is greater than or equal to 1;

[0034] If the target gain is greater than or equal to 1, then the target gain is determined to represent the boost of the input signal;

[0035] If the target gain is less than 1, the target gain is determined to represent the attenuation of the input signal.

[0036] A second aspect of the present invention discloses a dynamic equalization circuit, comprising: a detection link, an output signal unit, and at least two input signal paths;

[0037] At least one of the input signal paths is equipped with a filter;

[0038] The other input signal path is a direct path, or it is equipped with a filter and / or a delay unit;

[0039] The detection link is used to calculate the maximum gain coefficient and the minimum gain coefficient based on the input signal and preset processing parameters; wherein the sum of the maximum gain coefficient and the minimum gain coefficient is 1;

[0040] An output signal unit is configured to take the product of the input signal after passing through the corresponding filter and one of the maximum gain coefficient and the minimum gain coefficient as a first output signal, and take the product of the input signal directly or after passing through the filter and / or the delay unit and one of the maximum gain coefficient and the minimum gain coefficient as a second output signal; and take the superposition result of the first output signal and the second output signal as the final output signal.

[0041] Optionally, the detection link includes: a third filter, a detection unit, a signal processing unit, and at least one gain scaling module;

[0042] The third filter is used to filter the input signal to remove preset frequency components;

[0043] The detection unit is used to detect the signal parameters of the input signal after filtering by the third filter;

[0044] The signal processing unit is used to obtain the target gain based on the signal parameters and preset processing parameters;

[0045] The gain scaling module is used to perform scaling calculations on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient.

[0046] Optionally, the detection link further includes: a smoothing unit;

[0047] The smoothing unit is disposed between the signal processing unit and the gain ratio module; it is used to smooth the target gain value based on the jump of the target gain and the preset start time and release time.

[0048] Optionally, the number of input signal paths is 2;

[0049] Each of the input signal paths is equipped with its own corresponding filter.

[0050] Optionally, the number of the gain ratio module is one;

[0051] The product of the maximum gain coefficient and the output signal of the first filter is used as the first output signal;

[0052] The product of the minimum gain coefficient and the output signal of the second filter is used as the second output signal.

[0053] Optionally, the detection link further includes: a judgment module set before the gain ratio module; the number of gain ratio modules is two, namely a first gain ratio module and a second gain ratio module;

[0054] The judgment module is used to determine whether the target gain represents a signal boost; if so, the first gain ratio module is triggered to perform a ratio calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient.

[0055] If the target gain represents the attenuation of the input signal, then the second gain scaling module is triggered to perform a scaling calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient.

[0056] Optionally, the calculation formula used by the first proportional gain module to calculate the target gain is: RatioMax=(TarGain-1) / (GainMax-1), RatioMin=1-RatioMax;

[0057] The calculation formula used by the second gain ratio module to calculate the target gain ratio is: RatioMax=(TarGain-GainMin) / (1-GainMin), RatioMin=1-RatioMax.

[0058] Optionally, the number of input signal paths is 3;

[0059] Each of the two input signal paths is equipped with its own corresponding filter;

[0060] Another input signal path is provided with a delay unit.

[0061] Optionally, the product of the maximum gain coefficient output by the first gain ratio module and the output signal of the first filter is used as the first output signal; the product of the minimum gain coefficient output by the first gain ratio module and the output signal of the delay unit is used as the second output signal.

[0062] The product of the maximum gain coefficient output by the second gain ratio module and the output signal of the delay unit is used as the second output signal; the product of the minimum gain coefficient output by the second gain ratio module and the output signal of the second filter is used as the first output signal.

[0063] Optionally, each of the filters is at least one of an IIR peak filter, an FIR filter, a low-profile filter, and a high-profile filter.

[0064] As can be seen from the above technical solution, the dynamic equalization method provided by the present invention includes: calculating the maximum gain coefficient and the minimum gain coefficient based on the input signal and pre-set processing parameters; multiplying the filtered input signal by one of the maximum gain coefficient and the minimum gain coefficient as a first output signal; and multiplying the input signal directly or after filtering and / or delay by the other of the maximum gain coefficient and the minimum gain coefficient as a second output signal; using the superposition result of the first output signal and the second output signal as the output signal; and then adjusting the ratio of the two input signals to achieve the purpose of adjusting the final output signal in real time. This method simplifies the computational load and storage space required for dynamic filters because it does not require real-time calculation of filter coefficients or lookup tables to obtain filter coefficients, which is very effective in optimizing the computational load. It also avoids the problem of harmonics caused by sudden changes in filter coefficients, which can lead to noise. Attached Figure Description

[0065] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0066] Figure 1 This is a flowchart of a dynamic equilibrium method provided in an embodiment of the present invention;

[0067] Figure 2 This is a flowchart of another dynamic equilibrium method provided in an embodiment of the present invention;

[0068] Figure 3 This is a schematic diagram of another dynamic equalization circuit provided in an embodiment of the present invention;

[0069] Figure 4 This is a schematic diagram of another dynamic equalization circuit provided in an embodiment of the present invention;

[0070] Figure 5 This is a timing diagram of the maximum and minimum gain coefficients in another dynamic equalization circuit provided in this embodiment of the invention. Detailed Implementation

[0071] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0072] In this application, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0073] This invention provides a dynamic equalization method to address the problem that real-time adjustment of filter coefficients in the prior art may cause instantaneous instability of the filter, thereby generating noise.

[0074] See Figure 1 The dynamic equilibrium method includes:

[0075] S101. Calculate the maximum gain coefficient and minimum gain coefficient based on the input signal and the preset processing parameters.

[0076] The sum of the maximum gain coefficient and the minimum gain coefficient is 1.

[0077] It should be noted that the input signal can be an audio signal, etc. The specific form of the input signal is not limited here, but can be determined according to the actual situation, and all are within the protection scope of this application.

[0078] The processing parameters can be: threshold, scale, and compensation gain.

[0079] It should be noted that by pre-setting the processing parameters, there is no need to calculate them in real time. That is, only the input signal is used as a variable, thus reducing the computational load for calculating the maximum and minimum gain coefficients. Simultaneously, it can improve calculation accuracy; specifically, because introducing the input signal is equivalent to introducing a signal with zero gain to participate in the proportional weighting, it is more accurate than directly using one positive-gain EQ and one negative-gain EQ to calculate the maximum and minimum gain coefficients; that is, the results near zero gain will be more accurate.

[0080] S102, The product of the filtered input signal and one of the maximum gain coefficient and the minimum gain coefficient is used as the first output signal; and the product of the input signal directly or after filtering and / or delay and the other of the maximum gain coefficient and the minimum gain coefficient is used as the second output signal.

[0081] Specifically, filtering the input signal can remove some unnecessary frequency bands or frequencies, reducing impurities such as noise.

[0082] Delaying one input signal is to ensure that the timing of the first and second output signals is the same, enabling subsequent superposition. However, for the filtered input signal, if its delay is small, only the other input signal needs to be delayed. Furthermore, the specific operating principle of the branch corresponding to the second output signal is not specifically limited here; it depends on the actual situation and is all within the scope of this application.

[0083] In other words, if both the first output signal and the second output signal are the product of the filtered input signal and the corresponding gain coefficient, then the two signals, which are the product of the filtered input signal and the corresponding gain coefficient, have the same timing, and there is no need to delay either branch separately.

[0084] Since one of the first output signal and the second output signal is the product of the filtered input signal and the corresponding gain coefficient, while the other is unfiltered, the input signal of this branch needs to be delayed accordingly so that the timing of the first output signal and the second output signal are the same, thereby enabling subsequent superposition.

[0085] S103. The superposition result of the first output signal and the second output signal is taken as the final output signal.

[0086] As can be seen from the above description, the first output signal and the second output signal are parameters that have already been adjusted. Therefore, superimposing the first output signal and the second output signal can achieve dynamic adjustment of the final output signal.

[0087] In this embodiment, the final output signal is adjusted in real time by adjusting the ratio of the two input signals. This method simplifies the computational load and storage space required for the dynamic filter because it does not require real-time calculation of the filter coefficients or looking up the filter coefficients in a table. It also avoids the problem of harmonics caused by sudden changes in the filter coefficients, which can lead to noise.

[0088] In practical applications, see Figure 2 The specific process of step S101 above includes:

[0089] S201. Filter the input signal to remove preset frequency components, and detect the signal parameters of the filtered input signal.

[0090] Specifically, the input signal is first filtered to remove preset frequency components, such as filtering out preset frequency bands or frequencies in the input signal; then the signal parameters of the filtered input signal are detected.

[0091] The aforementioned signal parameters may include at least one of the amplitude, power, and loudness of the input signal.

[0092] In practical applications, the detection methods include at least one of mean square value detection or peak value detection; other detection methods may also be used, which will not be elaborated here, and are all within the scope of protection of this application.

[0093] S202. Based on the signal parameters and the preset processing parameters, the target gain is obtained.

[0094] It should be noted that the signal parameter can be at least one of the amplitude, power, and loudness of the input signal; the processing parameter can be the processing threshold, processing ratio, and processing compensation gain. In other words, the target gain can be obtained by calculating based on the amplitude and loudness of the input signal, as well as the processing threshold, processing ratio, and processing compensation gain.

[0095] It should be noted that setting this processing threshold is mainly to use it as a baseline so that when the value of the corresponding signal parameter is higher than the processing threshold, the first processing action is triggered; when the value of the corresponding signal parameter is lower than the processing threshold, the second processing action is triggered; of course, it is not limited to this, and will not be elaborated here, all of which are within the protection scope of this application.

[0096] S203. Calculate the target gain proportionally to obtain the maximum gain coefficient and the minimum gain coefficient.

[0097] There are several methods for determining the maximum and minimum gain coefficients, and the two cases will be explained below.

[0098] (1) The formula used to calculate the maximum and minimum gain coefficients by proportionally calculating the target gain is as follows:

[0099]

[0100] or,

[0101]

[0102] Where TarGain is the target gain; GainMax is the maximum gain; GainMin is the minimum gain, and both the maximum and minimum gains are calculated using pre-set processing parameters; RatioMax is the maximum gain coefficient; and RatioMin is the minimum gain coefficient.

[0103] It should be noted that Formula 1 and Formula 2 are mutually convertible. The specific transformation process will not be elaborated here, and all are within the scope of protection of this application.

[0104] The specific process of step S102 above is as follows: the product of the filtered input signal and the maximum gain coefficient is used as the first output signal, and the product of the filtered input signal and the minimum gain coefficient is used as the second output signal.

[0105] In other words, both input signals are filtered, multiplied by their respective gain coefficients, and then superimposed to form the final output signal.

[0106] (2) Before step S203, it may also include: determining whether the target gain represents a signal boost.

[0107] If the target gain represents signal enhancement, then the formulas used for the maximum and minimum gain coefficients are transformed as follows:

[0108]

[0109] Otherwise, the formulas used for the maximum and minimum gain coefficients are transformed as follows:

[0110]

[0111] It should be noted that Formula 3 and Formula 4 are derived from Formula 1. Formulas derived from Formula 2 are similar to Formula 3 and Formula 4, and will not be elaborated on here. All of them are within the scope of protection of this application.

[0112] In practical applications, the specific process for determining whether the target gain represents an increase in the input signal is as follows: determine whether the target gain is greater than or equal to 1; if the target gain is greater than or equal to 1, then the target gain represents an increase in the signal; if the target gain is less than 1, then the target gain represents an attenuation of the input signal.

[0113] The specific process of step S102 above is as follows:

[0114] If the target gain represents an improvement in the input signal, then the product of the filtered input signal and the maximum gain coefficient is used as the first output signal; and the product of the delayed input signal and the minimum gain coefficient is used as the second output signal.

[0115] Meanwhile, the maximum gain coefficient and the minimum gain coefficient are calculated using Formula 3.

[0116] If the target gain characterizes the attenuation of the input signal, then the product of the delayed input signal and the maximum gain coefficient is used as the second output signal; and the product of the filtered input signal and the minimum gain coefficient is used as the first output signal.

[0117] Meanwhile, the maximum gain coefficient and the minimum gain coefficient are calculated using Formula 4.

[0118] In practical applications, before step S203, the following may also be included: S204, smoothing the target gain value based on the jump situation of the target gain and the preset start time and release time.

[0119] In other words, smoothing the target gain does not mean directly using the target gain calculated in step S202 to calculate the maximum and minimum gain coefficients. Instead, the target gain value is smoothed before being used to calculate the maximum and minimum gain coefficients, so that the smoothed gain coefficients can make the final output signal more stable.

[0120] Another embodiment of the present invention provides a steady-state equalization circuit, see [link to relevant documentation]. Figure 3 This includes: detection links (including such as Figure 3 The system includes a third filter, a detection unit, a signal processing unit, at least one gain ratio module, an output signal unit, and at least two input signal paths.

[0121] At least one input signal path has a filter (e.g.) Figure 3 (The first filter or the second filter shown); that is, the input signal path is used to filter the input signal, such as filtering out the content of the preset frequency band.

[0122] The other input signal path is a direct path, or it is equipped with a filter and / or delay unit; that is, the other input signal path does not process the input signal, or filters and / or delays the input signal.

[0123] In other words, as long as at least one input signal path is guaranteed to filter the input signal, the other paths can either not process the input signal or filter and / or delay it.

[0124] The detection link is used to calculate the maximum gain coefficient and the minimum gain coefficient based on the input signal and its own preset processing parameters; the sum of the maximum gain coefficient and the minimum gain coefficient is 1.

[0125] It should be noted that the signal multiplied by the maximum and minimum gain coefficients is calculated based on preset processing parameters, which fixes the coefficients of the two filter devices used to filter the input signal. Instead of calculating the coefficients of the filter devices in real time each time to achieve the target gain, the formula for calculating the coefficients of the filter devices is much more complicated than calculating the maximum and minimum gain coefficients, thus reducing the amount of computation.

[0126] The input signal can be an audio signal, etc. The specific form of the input signal is not limited here, but can be determined according to the actual situation, and all are within the protection scope of this application.

[0127] The processing parameters can be: processing threshold, processing ratio, and processing compensation gain.

[0128] It should be noted that the detection link has pre-set processing parameters, eliminating the need to calculate the coefficients of the corresponding filter devices in real time. The coefficients of the two filter devices used to filter the input signal can be fixed simply by using the preset processing parameters. Only the proportional coefficients of the two filter devices participating in the weighting need to be calculated in real time. In addition, calculating the filter coefficients in real time is much more complicated than calculating the maximum and minimum gain coefficients, thus reducing the amount of computation.

[0129] The output signal unit is used to take the product of the input signal after passing through the corresponding filter and one of the maximum gain coefficient and the minimum gain coefficient as the first output signal, and to take the product of the input signal after passing through the filter and / or delay unit and the other of the maximum gain coefficient and the minimum gain coefficient as the second output signal; and to take the superposition result of the first output signal and the second output signal as the final output signal.

[0130] In other words, the maximum and minimum gain coefficients of the detection link output are superimposed on the output of the corresponding input signal path to obtain the first output signal and the second output signal.

[0131] It should be noted that when there are two input signal paths, the two gain coefficients correspond one-to-one with the two corresponding input signal paths. When there are multiple input signal paths, based on the actual real-time situation, two suitable input signal paths are selected from the multiple input signal paths, and these two input signal paths are then matched one-to-one with the two gain coefficients.

[0132] When filters are provided on at least two input signal paths, the filter types and frequencies can be the same, thus ensuring that the delays on these input signal paths are consistent. When no filter is provided on at least one input signal path, a delay unit can be provided on that input signal path to ensure that the delay of that input signal path is consistent with the delays of other input signal paths.

[0133] Because certain frequency bands need to be boosted or attenuated, the filters are usually variable gain filters, such as IIR Peak, Lowshelf, and Highshelf filters. For each frequency band requiring adjustment, two pairs of filters are used: a first filter and a second filter. The first and second filters have the same type and frequency.

[0134] The gains are set to maximum and minimum, both dynamically adjusted based on the settings of the signal processing unit. Since the processing parameters of the signal processing unit are preset, the maximum and minimum gains are known before the algorithm runs. Therefore, simply adjusting the maximum and minimum gain coefficients is sufficient to dynamically adjust the final output signal.

[0135] As can be seen from the above description, the first output signal and the second output signal are parameters that have already been adjusted. Therefore, superimposing the first output signal and the second output signal can achieve dynamic adjustment of the final output signal.

[0136] In practical applications, the detection link includes: a third filter, a detection unit, a signal processing unit, and at least one gain scaling module.

[0137] The third filter is used to filter the input signal to remove preset frequency components.

[0138] The detection unit is used to detect the signal parameters of the input signal after filtering by the third filter; the signal parameters can be at least one of the amplitude and loudness of the input signal. The detection method used by the detection unit can be at least one of mean square value detection or peak value detection; of course, other detection methods can also be used, which will not be elaborated here, and are all within the protection scope of this application.

[0139] The signal processing unit is used to obtain the target gain based on the signal parameters and preset processing parameters.

[0140] The target gain is a linear value, and therefore the maximum and minimum gain coefficients can be calculated according to a linear proportional relationship.

[0141] It should be noted that this signal processing unit typically performs dynamic compression or boosting of the signal. By combining it with a filter, dynamic compression or boosting of a certain frequency band of the signal can be achieved.

[0142] It should be noted that the signal parameter can be at least one of the amplitude and loudness of the input signal; the processing parameters can be a threshold, a scaling factor, and a compensation gain. In other words, the target gain can be obtained by calculating based on the amplitude and loudness of the input signal, as well as the threshold, scaling factor, and compensation gain.

[0143] The gain scaling module is used to perform scaling calculations on the target gain to obtain the maximum and minimum gain coefficients.

[0144] At least one filter, as well as filter and / or delay units, are used to achieve dynamic adjustment of the final output signal.

[0145] The operation of this gain scaling module varies depending on the input signal path. Please refer to the following description for details:

[0146] (1) As Figure 3 As shown, there are 2 input signal paths.

[0147] Each input signal path is equipped with its own corresponding filter.

[0148] The number of gain ratio modules is 1.

[0149] The product of the maximum gain coefficient and the output signal of the first filter is used as the first output signal; the product of the minimum gain coefficient and the output signal of the second filter is used as the second output signal.

[0150] In other words, the input signal is passed through the corresponding filter, multiplied by the corresponding gain coefficient, and then superimposed to obtain the final output signal.

[0151] Each filter is at least one of IIR peak filters, FIR filters, low-profile filters, and high-profile filters; of course, the filter can also be other types of filters, which will not be described in detail here, and are all within the protection scope of this application.

[0152] At this point, the formula used by the gain ratio module to obtain the maximum and minimum gain coefficients is:

[0153]

[0154] or,

[0155]

[0156] In this embodiment, the maximum and minimum gain required by the filter are pre-calculated using the processing threshold, processing ratio, and processing compensation gain in the preset signal processing unit. The input signal is then simultaneously fed into both sets of filters. Based on the content of the current input signal, the target gain is converted into the weight values ​​of the two filters. By adjusting the proportional relationship between the two filters, the filter gain is adjusted in real time. This method is very effective in optimizing computational load when the required adjustment bandwidth of the dynamic filter is small, and it also avoids the instantaneous instability of the filter caused by real-time modification of the filter coefficients.

[0157] In existing technologies, the target gain is calculated by looking up a table. This approach wastes the storage space of the signal processing unit and generates harmonics that affect the purity of the signal due to the discontinuity of the gain. Real-time calculation of filter coefficients is computationally intensive and may cause instantaneous instability of the filter, resulting in noise.

[0158] In other words, it eliminates the need to recalculate the filter coefficients based on the target gain each time, or to look up the filter coefficients in a table based on the target gain each time. The dynamic changes of the filter are equivalently represented by the sum of the proportional products of the outputs of the two filters with fixed parameters. The calculation is simple, and it does not cause instantaneous instability of the filter, nor does it generate harmonics due to gain discontinuity.

[0159] To further improve the accuracy of gain variation and simplify the algorithm, the delayed signal of the input signal can be introduced as a signal and filter to participate in the ratio calculation. See (2) for details.

[0160] (2) Figure 4 The number of input signal paths shown is 3.

[0161] Each of the two input signal paths is equipped with its own corresponding filter; a delay unit is provided on the other input signal path.

[0162] The detection link also includes a judgment module set up before the gain ratio module.

[0163] There are two gain ratio modules, namely the first gain ratio module and the second gain ratio module.

[0164] The judgment module is used to determine whether the target gain represents a signal boost; if so, the first gain scaling module is triggered to perform a scaling calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient; otherwise, the second gain scaling module is triggered to perform a scaling calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient.

[0165] The product of the maximum gain coefficient output by the first gain ratio module and the output signal of the first filter is used as the first output signal; the product of the minimum gain coefficient output by the first gain ratio module and the output signal of the delay unit is used as the second output signal.

[0166] The product of the maximum gain coefficient output by the second gain ratio module and the output signal of the delay unit is used as the first output signal; the product of the minimum gain coefficient output by the second gain ratio module and the output signal of the second filter is used as the second output signal.

[0167] Each filter is one of the following: IIR peak filter, low-profile filter, and high-profile filter.

[0168] Specifically, the calculation formula used by the first proportional gain module to perform proportional calculation on the target gain is as follows; that is, if the target gain represents a signal boost, then the formulas used for the maximum gain coefficient and the minimum gain coefficient are transformed as follows:

[0169]

[0170] The second proportional gain module uses the following formula to calculate the target gain proportionally; that is, if the target gain represents signal attenuation, the formulas used for the maximum gain coefficient and the minimum gain coefficient are transformed as follows:

[0171]

[0172] It should be noted that Formula 3 and Formula 4 are derived from Formula 1. Formulas derived from Formula 2 are similar to Formula 3 and Formula 4, and will not be elaborated on here. All of them are within the scope of protection of this application.

[0173] If both the maximum and minimum gains are greater than 1, the second filter does not need to participate in the calculation, nor is it necessary to determine whether the target gain represents a signal improvement. Only the first filter and delay unit need to be used for proportional calculation and summation. Similarly, if both the maximum and minimum gains are less than 1, the first filter does not need to participate in extreme value calculations, and the target gain does not need to be determined. Only the second filter and delay unit need to be used for proportional calculation and summation, and the maximum and minimum gains can be determined when setting the processing parameters. If one of the maximum and minimum gains is greater than 1 and the other is less than 1, then the algorithm flowchart can be followed.

[0174] In practical applications, the specific process by which the judgment module determines whether the target gain represents signal enhancement is as follows: determine whether the target gain is greater than or equal to 1; if the target gain is greater than or equal to 1, then determine that the target gain represents signal enhancement; if the target gain is less than 1, then determine that the target gain represents attenuation of the input signal.

[0175] like Figure 4 As shown, the judgment module judges the target gain calculated by the smoothing unit. If the target gain is greater than or equal to 1, it means that the input signal is boosted. Then, the maximum gain and 1 are used to calculate the maximum gain coefficient RatioMax and minimum gain coefficient RatioMin of the first filter and the direct delay unit, where 0<=RatioMax<=1. Then, the output signal of the first filter and the output signal of the delay unit are multiplied by the corresponding gain coefficient and then added together for output.

[0176] If the target gain is less than 1, it indicates that the input signal is attenuated. Then, the maximum gain coefficient RatioMax and minimum gain coefficient RatioMin of the through delay unit and the second filter are calculated using 1 and the minimum gain. Then, the output signal of the second filter and the output signal of the delay unit are multiplied by the corresponding gain and then added together for output.

[0177] When the maximum gain GainMax is greater than 1 and the minimum gain GainMin is less than 1, the curve for calculating the gain coefficient in the gain scaling module changes. Figure 5 As shown. When the maximum gain GainMax and minimum gain GainMin are other than those values, the curves of the gain coefficients are similar to... Figure 5 Similarities will not be elaborated here, as they are all within the scope of protection of this application.

[0178] In practical applications, the detection link also includes: a smoothing unit.

[0179] The smoothing unit is located between the signal processing unit and the gain scaling module; it is used to smooth the target gain value based on the jumps in the target gain and the preset start and release times.

[0180] In other words, smoothing the target gain does not mean directly using the target gain calculated in step S202 to calculate the maximum and minimum gain coefficients, so that the gain coefficients calculated after smoothing can make the final output signal more stable.

[0181] The features described in the various embodiments of this specification can be substituted for or combined with each other. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, for system or system embodiments, since they are basically similar to method embodiments, the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments. The systems and system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without creative effort.

[0182] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.

[0183] The above description of the disclosed embodiments enables those skilled in the art to make or use the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the invention is not 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.

Claims

1. A dynamic equilibrium method, characterized in that, include: Based on the input signal and preset processing parameters, the maximum gain coefficient and the minimum gain coefficient are calculated; wherein the sum of the maximum gain coefficient and the minimum gain coefficient is 1; wherein the input signal is an audio signal; The product of the filtered input signal and one of the maximum gain coefficient and the minimum gain coefficient is used as the first output signal; and the product of the input signal directly or after filtering and / or delay and the other of the maximum gain coefficient and the minimum gain coefficient is used as the second output signal. The superposition result of the first output signal and the second output signal is taken as the final output signal; The step of calculating the maximum gain coefficient and the minimum gain coefficient based on the input signal and preset processing parameters includes: filtering the input signal to remove preset frequency components, and detecting the signal parameters of the filtered input signal; obtaining the target gain based on the signal parameters and preset processing parameters; and performing a proportional calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient.

2. The dynamic equilibrium method according to claim 1, characterized in that, Before performing a scaling calculation on the target gain to obtain the maximum and minimum gain coefficients, the process also includes: The target gain value is smoothed based on the jumps in the target gain and the preset start and release times.

3. The dynamic equilibrium method according to claim 1, characterized in that, The detection method includes at least one of mean square value detection or peak value detection.

4. The dynamic equilibrium method according to claim 1, characterized in that, The signal parameters include at least one of the amplitude, power, and loudness of the input signal; The processing parameters include: processing threshold, processing ratio, and processing compensation gain.

5. The dynamic equilibrium method according to any one of claims 1-4, characterized in that, The formula used to calculate the maximum and minimum gain coefficients by proportionally calculating the target gain is as follows: RatioMax=(TarGain-GainMin) / (GainMax-GainMin); RatioMin=1-RatioMax; or, RatioMin=(GainMax-TarGain) / (GainMax-GainMin); RatioMax=1-RatioMin; Wherein, TarGain is the target gain; GainMax is the maximum gain; GainMin is the minimum gain, and the maximum gain and the minimum gain are calculated through the preset processing parameters; RatioMax is the maximum gain coefficient; and RatioMin is the minimum gain coefficient.

6. The dynamic equilibrium method according to claim 5, characterized in that, The product of the filtered input signal and one of the maximum gain coefficient and the minimum gain coefficient is used as the first output signal; And, taking the input signal directly or after filtering and / or delay, and multiplying it by the other of the maximum gain coefficient and the minimum gain coefficient as the second output signal, includes: The product of the filtered input signal and the maximum gain coefficient is used as the first output signal, and the product of the filtered input signal and the minimum gain coefficient is used as the second output signal.

7. The dynamic equilibrium method according to claim 5, characterized in that, Before performing a proportional calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient, the method further includes: Determine whether the target gain represents an improvement in the input signal; If the target gain represents the boost of the input signal, then the formulas used for the maximum gain coefficient and the minimum gain coefficient are transformed as follows: RatioMax=(TarGain-1) / (GainMax-1), RatioMin=1-RatioMax; If the target gain characterizes the attenuation of the input signal, then the formulas used for the maximum gain coefficient and the minimum gain coefficient are transformed as follows: RatioMax=(TarGain-GainMin) / (1-GainMin), RatioMin=1-RatioMax.

8. The dynamic equilibrium method according to claim 7, characterized in that, The first output signal is obtained by multiplying the filtered input signal by one of the maximum gain coefficient and the minimum gain coefficient. And, multiplying the input signal directly or after filtering and / or delay by the product of the minimum gain coefficient and another of the minimum gain coefficients as the second output signal, includes: If the target gain represents an improvement in the input signal, then the product of the filtered input signal and the maximum gain coefficient is used as the first output signal; and the product of the delayed input signal and the minimum gain coefficient is used as the second output signal. If the target gain characterizes the attenuation of the input signal, then the product of the delayed input signal and the maximum gain coefficient is used as the second output signal; and the product of the filtered input signal and the minimum gain coefficient is used as the first output signal.

9. The dynamic equilibrium method according to claim 7, characterized in that, Determining whether the target gain characterizes the input signal boost includes: Determine whether the target gain is greater than or equal to 1; If the target gain is greater than or equal to 1, then the target gain is determined to represent the boost of the input signal; If the target gain is less than 1, the target gain is determined to represent the attenuation of the input signal.

10. A dynamic equalization circuit, characterized in that, include: The system includes a detection link, an output signal unit, and at least two input signal paths; wherein the input signals are audio signals. At least one of the input signal paths is equipped with a filter; The other input signal path is a direct path, or it is equipped with a filter and / or a delay unit; The detection link is used to calculate the maximum gain coefficient and the minimum gain coefficient based on the input signal and pre-set processing parameters; wherein the sum of the maximum gain coefficient and the minimum gain coefficient is 1; An output signal unit is configured to take the input signal after passing through the corresponding filter and multiply it by one of the maximum gain coefficient and the minimum gain coefficient as a first output signal; and take the input signal directly or after passing through the filter and / or the delay unit and multiply it by one of the maximum gain coefficient and the minimum gain coefficient as a second output signal; and use the superposition result of the first output signal and the second output signal as the final output signal. The detection link includes: a third filter, a detection unit, a signal processing unit, and at least one gain ratio module; The third filter is used to filter the input signal to remove preset frequency components; The detection unit is used to detect the signal parameters of the input signal after filtering by the third filter; The signal processing unit is used to obtain the target gain based on the signal parameters and preset processing parameters; The gain scaling module is used to perform scaling calculations on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient.

11. The dynamic equalization circuit according to claim 10, characterized in that, The detection link further includes: a smoothing unit; The smoothing unit is disposed between the signal processing unit and the gain ratio module; it is used to smooth the target gain value based on the jump of the target gain and the preset start time and release time.

12. The dynamic equalization circuit according to claim 10, characterized in that, The number of input signal paths is 2; Each of the input signal paths is equipped with its own corresponding filter.

13. The dynamic equalization circuit according to claim 10, characterized in that, The number of the gain ratio module is 1; The product of the maximum gain coefficient and the output signal of the first filter is used as the first output signal; The product of the minimum gain coefficient and the output signal of the second filter is used as the second output signal.

14. The dynamic equalization circuit according to claim 13, characterized in that, The detection link further includes: a judgment module set before the gain ratio module; the number of the gain ratio modules is two, namely a first gain ratio module and a second gain ratio module; The judgment module is used to determine whether the target gain represents a signal boost; if so, the first gain ratio module is triggered to perform a ratio calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient. If the target gain represents the attenuation of the input signal, then the second gain scaling module is triggered to perform a scaling calculation on the target gain to obtain the maximum gain coefficient and the minimum gain coefficient.

15. The dynamic equalization circuit according to claim 14, characterized in that, The calculation formula used by the first gain ratio module to calculate the target gain ratio is: RatioMax=(TarGain-1) / (GainMax-1), RatioMin=1-RatioMax; The calculation formula used by the second gain ratio module to calculate the target gain ratio is: RatioMax=(TarGain-GainMin) / (1-GainMin), RatioMin=1-RatioMax; Wherein, TarGain is the target gain; GainMax is the maximum gain; GainMin is the minimum gain, and the maximum gain and the minimum gain are calculated through the preset processing parameters; RatioMax is the maximum gain coefficient; and RatioMin is the minimum gain coefficient.

16. The dynamic equalization circuit according to claim 14, characterized in that, The number of input signal paths is 3; Each of the two input signal paths is equipped with its own corresponding filter; Another input signal path is provided with a delay unit.

17. The dynamic equalization circuit according to claim 14, characterized in that, If the target gain represents the boost of the input signal, then the product of the maximum gain coefficient output by the first gain scaling module and the output signal of the first filter is used as the first output signal; the product of the minimum gain coefficient output by the first gain scaling module and the output signal of the delay unit is used as the second output signal. If the target gain characterizes the attenuation of the input signal, then the product of the maximum gain coefficient output by the second gain scaling module and the output signal of the delay unit is used as the second output signal; the product of the minimum gain coefficient output by the second gain scaling module and the output signal of the second filter is used as the first output signal.

18. The dynamic equalization circuit according to any one of claims 10-17, characterized in that, Each of the filters is at least one of IIR peak filters, FIR filters, low-profile filters, and high-profile filters.