WO2023274180A1 - 一种提升扬声器的音质的方法及装置 - Google Patents

一种提升扬声器的音质的方法及装置 Download PDF

Info

Publication number
WO2023274180A1
WO2023274180A1 PCT/CN2022/101678 CN2022101678W WO2023274180A1 WO 2023274180 A1 WO2023274180 A1 WO 2023274180A1 CN 2022101678 W CN2022101678 W CN 2022101678W WO 2023274180 A1 WO2023274180 A1 WO 2023274180A1
Authority
WO
WIPO (PCT)
Prior art keywords
signal
frequency
input signal
low
frequency input
Prior art date
Application number
PCT/CN2022/101678
Other languages
English (en)
French (fr)
Inventor
秦鹏
寇毅伟
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP22831994.3A priority Critical patent/EP4344246A1/en
Publication of WO2023274180A1 publication Critical patent/WO2023274180A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L21/00Speech or voice signal processing techniques to produce another audible or non-audible signal, e.g. visual or tactile, in order to modify its quality or its intelligibility
    • G10L21/02Speech enhancement, e.g. noise reduction or echo cancellation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/60Substation equipment, e.g. for use by subscribers including speech amplifiers
    • H04M1/6016Substation equipment, e.g. for use by subscribers including speech amplifiers in the receiver circuit
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/725Cordless telephones
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R1/00Details of transducers, loudspeakers or microphones
    • H04R1/20Arrangements for obtaining desired frequency or directional characteristics
    • H04R1/22Arrangements for obtaining desired frequency or directional characteristics for obtaining desired frequency characteristic only 
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R3/00Circuits for transducers, loudspeakers or microphones
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R3/00Circuits for transducers, loudspeakers or microphones
    • H04R3/04Circuits for transducers, loudspeakers or microphones for correcting frequency response
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R9/00Transducers of moving-coil, moving-strip, or moving-wire type
    • H04R9/06Loudspeakers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R2430/00Signal processing covered by H04R, not provided for in its groups
    • H04R2430/01Aspects of volume control, not necessarily automatic, in sound systems

Definitions

  • the embodiments of the present application relate to the field of media technology, and in particular, to a method and device for improving sound quality of a speaker.
  • the mid-low frequency loudness of audio signals played by most speakers is insufficient, so that the sound quality of the audio signals played by the speakers is poor.
  • the middle and low frequency signals in the audio signal play an important role in the sense of hearing and directly affect the user's hearing experience. Therefore, how to improve the low frequency sound effect of the small speaker is an urgent problem to be solved.
  • Embodiments of the present application provide a method and device for improving the sound quality of a speaker, which can improve the low-frequency sound effect of the speaker and improve the sound quality of the speaker.
  • the embodiment of the present application provides a method for improving the sound quality of the speaker, which can be applied to an electronic device with an audio playback function, and the method includes: the electronic device divides the frequency of the input signal of the speaker to obtain the first low-frequency input signal and the first high-frequency input signal, the input signal of the speaker is a time-domain signal, the first low-frequency input signal includes signals lower than the first preset frequency point in the input signal, and the first high-frequency input signal includes signals higher than the first preset frequency point in the input signal The signal at the first preset frequency point; and the electronic device performs transient detection on the first low-frequency input signal to determine whether the first low-frequency input signal is a transient signal; if the first low-frequency input signal is a transient signal, then the second A low-frequency input signal is subjected to signal envelope modulation to obtain a second low-frequency input signal; and then the electronic device determines the output signal of the speaker according to the second low-frequency input signal and the first high-frequency input signal.
  • the transient detection is performed on the low-frequency signal in the input signal. If the input signal is a transient signal, envelope modulation is used to enhance the transient signal. Since the speaker plays a When the audio signal is played by the speaker, the sound quality of the low-frequency signal in the audio signal is related to the performance of the speaker, and the transient signal in the low-frequency signal usually reflects important information of the audio signal, so the transient signal in the low-frequency signal is modulated to improve The loudness of the low-frequency transient signal, and adjust the dynamic range of the low-frequency transient signal, so that when the speaker plays the processed audio signal, the low-frequency sound effect of the audio signal is better, that is, the sound quality of the speaker can be improved through the technical solution of the embodiment of the present application .
  • the method for improving the sound quality of the speaker further includes: the electronic device divides the frequency of the first high-frequency input signal of the speaker to obtain the first intermediate-frequency input signal and the second high-frequency input signal.
  • the first intermediate frequency input signal includes a signal lower than the second preset frequency point in the first high frequency input signal
  • the second high frequency input signal includes a signal higher than the second preset frequency point in the first high frequency input signal signal, the second preset frequency point is higher than the first preset frequency point
  • the electronic device performs transient detection on the first intermediate frequency input signal to determine whether the first intermediate frequency input signal is a transient signal; if the first intermediate frequency input signal is a transient signal, the signal envelope modulation is performed on the first intermediate frequency input signal to obtain a second intermediate frequency input signal, the starting voltage of the second intermediate frequency input signal is greater than the starting voltage of the first intermediate frequency input signal, and the second The loudness of the intermediate frequency input signal is greater than the loudness of the first intermediate frequency input signal.
  • the method for determining the output signal of the speaker according to the second low-frequency input signal and the first high-frequency input signal specifically includes: the electronic device obtains the output signal of the speaker according to the second low-frequency input signal, the second intermediate-frequency input signal, and the second high-frequency input signal. output signal.
  • transient detection is also performed on the intermediate frequency signal in the input signal
  • envelope modulation is performed on the transient signal to enhance the intermediate frequency signal, so as to generally improve the sound quality of the speaker.
  • the first low-frequency input signal is a transient signal
  • the method for improving the sound quality of the speaker further includes: generating a low-frequency auxiliary signal; and adding the low-frequency auxiliary signal to the first low-frequency input signal to obtain a first auxiliary enhanced signal.
  • the method for performing signal envelope modulation on the first low-frequency input signal to obtain the second low-frequency input signal specifically includes: performing signal envelope modulation on the first auxiliary enhanced signal to obtain the second low-frequency input signal.
  • the above-mentioned first low-frequency input signal is a transient signal
  • the speaker of the electronic device is a relatively small speaker with weak low-frequency playback capability
  • low-frequency auxiliary can be added to the first low-frequency input signal.
  • the function of the low-frequency auxiliary signal is to help enhance the loudness of the first low-frequency input signal, and optimize the dynamic range of the first low-frequency input signal.
  • the above method for generating a low-frequency auxiliary signal includes: generating a first auxiliary signal, and performing high-pass filtering on the first auxiliary signal to obtain a low-frequency auxiliary signal.
  • the value range of A can be 10-50, and the specific value can be estimated by the system or set by the user, for example, it can be 10, 25, or 50, etc.; the value range of f can be within the range of 50-150Hz
  • the specific value of the frequency can be estimated by the system or set by the user, for example, the value of f can be 50 Hz, 100 Hz, or 150 Hz and so on.
  • the first low-frequency input signal is a transient signal
  • the method for improving the sound quality of the speaker provided in the embodiment of the present application further includes: Phase compensation is performed on the first low-frequency input signal to obtain a first phase compensation signal.
  • the method for performing signal envelope modulation on the first low-frequency input signal to obtain the second low-frequency input signal includes: the electronic device performs signal envelope modulation on the first phase compensation signal to obtain the second low-frequency input signal.
  • the phase of the first low-frequency input signal may be affected, resulting in a deviation of the phase of the low-frequency input signal, which is no longer a linear phase. Therefore , performing necessary linear phase compensation on the first low-frequency input signal, and correcting the phase of the first low-frequency input signal to a linear phase, thereby ensuring low-frequency sound quality.
  • the above-mentioned method for performing transient detection on the first low-frequency input signal and determining whether the first low-frequency input signal is a transient signal specifically includes: the electronic device determines the transient power and steady state of the first low-frequency input signal power; and determine the instantaneous rate of the first low-frequency input signal according to the transient power and steady-state power of the first low-frequency input signal; if the transient rate of the input signal is greater than the preset transient rate threshold, then determine the first low-frequency input signal for transient signals.
  • T r represents the instantaneous rate of the first low-frequency input signal
  • R r represents the transient state of the first low-frequency input signal
  • W represents a weighting factor
  • the value of W is the same as the current power of the first low-frequency input signal.
  • the power of the first low-frequency input signal is the sum of the squares of the voltage values of all data points contained in the first low-frequency input signal and then averaged; the instantaneous power of the first low-frequency input signal can be the current
  • the average power of n1 consecutive signal frames before the frame, the steady-state power of the first low-frequency input signal may be the average power of n2 consecutive signal frames before the current frame.
  • some small signals can be masked.
  • the electronic device may perform low-pass filtering on the first low-frequency input signal, and then calculate the instantaneous power and steady state of the filtered first low-frequency input signal. state power to further determine whether the first low-frequency input signal is a transient signal or a steady-state signal.
  • low-pass filtering is performed on the first low-frequency input signal to obtain a low-frequency input signal in a lower frequency range, and the high-frequency signal that may exist in the first low-frequency input signal can be further reduced through low-pass filtering, here Basically, performing transient detection on the filtered first low-frequency input signal can reduce the false detection rate of transient detection.
  • the method for improving the sound quality of the speaker further includes: the electronic device performs equalization processing on the first signal to obtain a second signal; the first signal is the initial signal to be input to the speaker. playing the signal; and processing the second signal with a bass enhancement algorithm to obtain the input signal of the speaker.
  • the above-mentioned specific method for equalizing the first signal may be: using a biquard filter to equalize the first signal, which can improve the low-frequency frequency response of the loudspeaker.
  • the second signal is processed by using a bass enhancement algorithm, which can enhance the low-frequency loudness of the second signal.
  • the above-mentioned method of processing the second signal by using the bass enhancement algorithm to obtain the input signal of the loudspeaker specifically includes: the electronic device determines the power of the low-frequency shelving filter according to the energy of the low-frequency signal in the second signal. Gain, the low-frequency shelving filter is used to control the loudness of the low-frequency signal in the second signal; and the low-frequency shelving filter is used to filter the second signal to obtain the input signal of the loudspeaker.
  • the above-mentioned bass enhancement algorithm is adopted, and the electronic device differentiates the loudness of low-frequency signals with different energies according to the energy of the low-frequency signal in the second signal, that is, sets different gains for the low-frequency signal according to the energy of the low-frequency signal, that is, According to the characteristics of the energy of the low-frequency signal of the second signal, the loudness of the low-frequency signal in the second signal is dynamically and adaptively increased, so that the clarity of the low-frequency signal can be improved.
  • the method for improving the sound quality of the speaker further includes: the electronic device acquires a first displacement prediction model including one or more correction coefficients, and the first displacement prediction model is used to simulate the loudspeaker To predict the displacement of the diaphragm of the loudspeaker, the one or more correction coefficients are used to control the output of the first displacement prediction model; and adjust at least one correction coefficient in the first displacement prediction model to obtain a second displacement prediction model;
  • the absolute value of the difference between the predicted displacement output by the second displacement prediction model and the actual displacement of the diaphragm of the loudspeaker is less than the absolute value of the difference between the predicted displacement output by the first displacement prediction model and the actual displacement of the diaphragm of the loudspeaker;
  • the actual displacement of the loudspeaker is the actual measurement value of the moving distance of the diaphragm relative to the initial position; and the electronic device controls the gain of the output signal of the loudspeaker according to the displacement protection threshold of the loudspeaker and
  • the above-mentioned second displacement prediction model more truly reflects the characteristics of the loudspeaker, ensures that the predicted displacement of the output is more accurate, and then can carry out more accurate displacement protection, which also realizes the protection of the displacement of the speaker diaphragm. , to maximize the hardware potential of the speaker and increase the loudness of the speaker.
  • the method for improving the sound quality of the speaker provided in the embodiment of the present application further includes: the electronic device performs virtual bass processing on the output signal to obtain a virtual bass output signal, and the psychologically perceived low-frequency loudness of the virtual bass output signal is The psychologically perceived loudness of low frequencies greater than the loudspeaker's output signal.
  • virtual bass processing is a method based on psychoacoustics to improve bass sound effects. Measured from the perspective of psychoacoustics, the psychological The perceived low frequency loudness is greater than the psychologically perceived low frequency loudness of the original output signal. In one embodiment, the psycho-perceived low-frequency loudness may be determined according to a psycho-acoustic model.
  • the method for performing virtual bass processing on the output signal of the loudspeaker to obtain the virtual bass output signal specifically includes: the electronic device performs frequency division processing on the output signal to obtain the first low-frequency output signal and the first low-frequency output signal.
  • a high-frequency output signal the first low-frequency output signal includes a signal of the output signal lower than the third preset frequency point, and the first high-frequency output signal includes a signal of the output signal higher than the third preset frequency point; and electronically
  • the device generates a harmonic signal of the first low-frequency output signal according to the first low-frequency output signal; then, the electronic device mixes the harmonic signal and the first low-frequency output signal to obtain a first mixed signal; and the first mixed signal and the second A high-frequency output signal is subjected to phase synchronization processing to obtain a second mixed signal and a second high-frequency output signal, and the amount of change in the phase of the second mixed signal is equal to the amount of change in the phase of the second high-frequency output signal; and then the electronic device According to the second mixed signal and the second high-frequency output signal, a virtual bass output signal is obtained.
  • the method for improving the sound quality of the speaker further includes: the electronic device adjusts the nonlinear parameters of the first nonlinear compensation model pre-configured in the speaker according to the coil temperature of the speaker, so as to obtain A second nonlinear compensation model; then the electronic device uses the second nonlinear compensation model to perform signal compensation on the output signal of the loudspeaker.
  • the determined second nonlinear parameter of the loudspeaker is a nonlinear parameter corresponding to the current working state of the loudspeaker, that is, a real-time nonlinear parameter, its accuracy is relatively high, so, according to the second nonlinear parameter to The output signal of the loudspeaker is used for signal compensation, and the signal compensation effect is better, which can effectively reduce signal distortion and improve the sound quality of the loudspeaker.
  • the embodiment of the present application provides an electronic device, which includes: a first acquisition module, a first determination module, an envelope modulation module, and a second determination module.
  • the first obtaining module is used for dividing the frequency of the input signal of the loudspeaker to obtain the first low-frequency input signal and the first high-frequency input signal
  • the input signal of the loudspeaker is a time-domain signal
  • the first low-frequency input signal includes the input signal A signal lower than the first preset frequency point in the input signal
  • the first high-frequency input signal includes a signal higher than the first preset frequency point in the input signal
  • the first determination module is used to perform transient detection on the first low-frequency input signal, To determine whether the first low-frequency input signal is a transient signal
  • the envelope modulation module is used to perform signal envelope modulation on the first low-frequency input signal when the first low-frequency input signal is a transient signal, to obtain a second low-frequency input signal, the starting voltage of the second low-frequency input signal is greater than the
  • the above-mentioned first acquisition module is further configured to divide the frequency of the first high-frequency input signal of the speaker to obtain the first intermediate-frequency input signal and the second high-frequency input signal, and the first intermediate-frequency input signal
  • the first high-frequency input signal includes a signal lower than the second preset frequency point
  • the second high-frequency input signal includes a signal higher than the second preset frequency point in the first high-frequency input signal
  • the second preset frequency point is higher than At the first preset frequency point
  • the first determination module is also used for transient detection of the first intermediate frequency input signal to determine whether the first intermediate frequency input signal is a transient signal
  • the envelope modulation module is also used for the first intermediate frequency When the input signal is a transient signal, signal envelope modulation is performed on the first intermediate frequency input signal to obtain a second intermediate frequency input signal, the starting voltage of the second intermediate frequency input signal is greater than the starting voltage of the first intermediate frequency input signal , and the loudness of the second intermediate frequency input signal is greater than the loudness of the first intermediate frequency
  • the electronic device provided in the embodiment of the present application further includes a generation module and a second acquisition module.
  • the generation module is used to generate the low-frequency auxiliary signal;
  • the second acquisition module is used to add the low-frequency auxiliary signal to the first low-frequency input signal to obtain the first auxiliary enhanced signal;
  • the envelope modulation module is specifically used to perform the first auxiliary enhanced signal The signal envelope is modulated to obtain a second low frequency input signal.
  • the generating module is specifically configured to generate a first auxiliary signal, and perform high-pass filtering on the first auxiliary signal to obtain a low-frequency auxiliary signal.
  • the first auxiliary signal satisfies: Among them, signal_h represents the low-frequency auxiliary signal, A represents the signal amplitude influence factor, and f is the center frequency of the speaker.
  • the electronic device provided in the embodiment of the present application further includes a phase compensation module; the phase compensation module is used to perform phase compensation on the first low-frequency input signal to obtain a first phase compensation signal; the above envelope modulation The module is specifically used to perform signal envelope modulation on the first phase compensation signal to obtain a second low-frequency input signal.
  • the above-mentioned first determination module is specifically configured to determine the transient power and steady-state power of the first low-frequency input signal; and determine the first low-frequency input signal according to the transient power and steady-state power of the first low-frequency input signal the instantaneous rate of the input signal; and determining that the first low-frequency input signal is a transient signal when the transient rate of the input signal is greater than a preset transient rate threshold.
  • T r represents the instantaneous rate of the first low-frequency input signal
  • R r represents the instantaneous power of the first low-frequency input signal
  • W represents a weighting factor
  • the value of W is the same as the current power of the first low-frequency input signal.
  • the electronic device provided in the embodiment of the present application further includes an equalization processing module and a bass enhancement module; wherein, the equalization processing module is configured to perform equalization processing on the first signal to obtain a second signal, and the first signal The initial signal to be played is input to the speaker; the bass enhancement module is used to process the second signal with a bass enhancement algorithm to obtain the input signal of the speaker.
  • the above-mentioned bass enhancement module is specifically configured to determine the gain of the low-frequency shelving filter according to the energy of the low-frequency signal in the second signal, and the low-frequency shelving filter is used to control the low-frequency signal in the second signal. loudness; and use a low-frequency shelving filter to filter the second signal to obtain the input signal of the loudspeaker.
  • the electronic device provided in the embodiment of the present application further includes a third acquisition module, a first adjustment module, and a control module.
  • the third acquisition module is used to acquire the first displacement prediction model including one or more correction coefficients
  • the first displacement prediction model is used to simulate the performance of the loudspeaker to predict the displacement of the diaphragm of the loudspeaker, and the one or more correction coefficients
  • the coefficient is used to control the output of the first displacement prediction model
  • the first adjustment module is used to adjust at least one correction coefficient in the first displacement prediction model to obtain a second displacement prediction model, and the predicted displacement output by the second displacement prediction model is consistent with the loudspeaker
  • the absolute value of the difference between the actual displacement of the diaphragm diaphragm is less than the absolute value of the difference between the predicted displacement output by the first displacement prediction model and the actual displacement of the speaker's diaphragm
  • the actual displacement of the speaker is the diaphragm relative to The actual measurement value of the moving distance of the initial position
  • the electronic device provided in the embodiment of the present application further includes a virtual bass processing module: the virtual bass processing module is configured to perform virtual bass processing on the above output signal to obtain a virtual bass output signal; the virtual bass output The psychologically perceived low frequency loudness of the signal is greater than the psychologically perceived low frequency loudness of the output signal.
  • the above-mentioned virtual bass processing module is specifically configured to perform frequency division processing on the above-mentioned output signal to obtain a first low-frequency output signal and a first high-frequency output signal, and the first low-frequency output signal includes the output signal In the signal lower than the third preset frequency point, the first high-frequency output signal includes a signal higher than the third preset frequency point in the output signal; and a harmonic signal of the first low-frequency output signal is generated according to the first low-frequency output signal ; and mixing the harmonic signal and the first low-frequency output signal to obtain a first mixed signal; and performing phase synchronization processing on the first mixed signal and the first high-frequency output signal to obtain a second mixed signal and a second high-frequency output signal frequency output signal, the change in phase of the second mixed signal is equal to the change in phase of the second high frequency output signal; furthermore, according to the second mixed signal and the second high frequency output signal, a virtual bass output signal is obtained.
  • the electronic device provided by the embodiment of the present application further includes a second adjustment module and a signal compensation module: the second adjustment module is used to adjust the first nonlinear compensation pre-configured in the speaker according to the coil temperature of the speaker.
  • the nonlinear parameters of the model are used to obtain a second nonlinear compensation model; the signal compensation module is used to perform signal compensation on the output signal of the loudspeaker by using the second nonlinear compensation model.
  • an embodiment of the present application provides an electronic device, the electronic device includes a memory and at least one processor connected to the memory, the memory is used to store instructions, and after the instructions stored in the memory are read by at least one processor, the above-mentioned The method described in any one of the first aspect and its possible implementations.
  • the embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the method described in any one of the above-mentioned first aspect and its possible implementations .
  • the embodiments of the present application provide a computer program product containing instructions, which, when run on a computer, cause the computer to execute the method described in any one of the first aspect and its possible implementations.
  • the embodiment of the present application provides a chip, including a memory and a processor.
  • Memory is used to store computer instructions.
  • the processor is used to call and execute the computer instructions from the memory, so as to execute the method described in any one of the first aspect and possible implementations thereof.
  • FIG. 1 is a schematic diagram of a transient signal and a steady state signal provided by an embodiment of the present application
  • FIG. 2 is a block diagram of an audio processing system provided by an embodiment of the present application.
  • FIG. 3 is a schematic diagram of a hardware structure of a mobile phone provided by an embodiment of the present application.
  • FIG. 4 is a schematic diagram of a method for improving the sound quality of a speaker provided in an embodiment of the present application
  • FIG. 5 is a schematic diagram of another method for improving the sound quality of a speaker provided by an embodiment of the present application.
  • FIG. 6 is a schematic diagram of the principle of an envelope modulation provided by an embodiment of the present application.
  • FIG. 7 is a schematic framework diagram of a loudspeaker system provided by an embodiment of the present application.
  • FIG. 8 is a schematic diagram of another method for improving the sound quality of a speaker provided by an embodiment of the present application.
  • FIG. 9 is a schematic framework diagram of another speaker system provided by the embodiment of the present application.
  • FIG. 10 is a schematic diagram of another method for improving the sound quality of a speaker according to an embodiment of the present application.
  • Fig. 11 is a schematic framework diagram of another speaker system provided by the embodiment of the present application.
  • FIG. 12 is a schematic diagram of another method for improving the sound quality of a speaker provided by an embodiment of the present application.
  • Fig. 13 is a schematic framework diagram of another speaker system provided by the embodiment of the present application.
  • Fig. 14 is a schematic frame diagram of another speaker system provided by the embodiment of the present application.
  • FIG. 15 is a schematic flow chart of a low-frequency enhancement algorithm provided by an embodiment of the present application.
  • Fig. 16 is a schematic framework diagram of another speaker system provided by the embodiment of the present application.
  • FIG. 17 is a schematic diagram of another method for improving the sound quality of a speaker provided by an embodiment of the present application.
  • Fig. 18 is a schematic frame diagram of another speaker system provided by the embodiment of the present application.
  • FIG. 19 is a schematic diagram of another method for improving the sound quality of a speaker according to an embodiment of the present application.
  • FIG. 20 is a schematic framework diagram of another speaker system provided by the embodiment of the present application.
  • FIG. 21 is a schematic diagram of another method for improving the sound quality of a speaker according to an embodiment of the present application.
  • Fig. 22 is a schematic framework diagram of another speaker system provided by the embodiment of the present application.
  • FIG. 23 is a first structural schematic diagram of an electronic device provided by an embodiment of the present application.
  • FIG. 24 is a second structural schematic diagram of an electronic device provided by an embodiment of the present application.
  • first and second in the description and claims of the embodiments of the present application are used to distinguish different objects, rather than to describe a specific order of objects.
  • the first low-frequency input signal and the second low-frequency input signal are used to distinguish different input signals, rather than to describe the specific sequence of low-frequency input signals; for example, the first high-frequency input signal and the second high-frequency input signal
  • the signal is used to distinguish different high-frequency input signals, not to describe a specific sequence of high-frequency input signals; for another example, the first intermediate-frequency input signal and the second intermediate-frequency input signal are used to distinguish different intermediate-frequency input signals, and Not a specific order for describing IF input signals.
  • words such as “exemplary” or “for example” are used as examples, illustrations or illustrations. Any embodiment or design scheme described as “exemplary” or “for example” in the embodiments of the present application shall not be interpreted as being more preferred or more advantageous than other embodiments or design schemes. Rather, the use of words such as “exemplary” or “such as” is intended to present related concepts in a concrete manner.
  • plural means two or more.
  • a plurality of correction coefficients refers to two or more correction coefficients.
  • Loudness is a measure of how strong or weak a sound is perceived by humans. Generally speaking, when the frequency of a sound is constant, the stronger the sound intensity, the louder it will be. However, the loudness is related to the frequency, the sound intensity is the same, but the frequency is different, the loudness may also be different. The loudness can be the sound pressure level of the audio signal, and simply, the loudness can also be understood as the volume of the audio signal.
  • the purpose of the technical solution provided by the embodiments of the present application is to increase the loudness of the low-frequency signal in the audio signal to be played by the speaker, so as to improve the sound quality of the speaker.
  • Low-frequency dynamic change refers to the change process of the signal from small to large and then to small.
  • the subtle dynamic changes of the low-frequency signal in the audio signal affect the user's sense of hearing.
  • Better bass dynamics refers to: fast low-frequency vibration, high peak loudness, fast decay, and better low-frequency dynamics.
  • the low-frequency details in the audio signals can be displayed, so that users have a lot of experience. Good subjective sense of hearing.
  • the input signal of the loudspeaker can also be called the input voltage signal.
  • the audio signal is processed frame by frame. Therefore, in the process of processing the signal frame, the input signal corresponding to the loudspeaker is a signal frame.
  • the input signal of the loudspeaker includes M (M is an integer greater than or equal to 1) digital signals, corresponding to n voltage values (also referred to as n points).
  • the input signal U in [U in (1) , U in (2), ..., U in (n), ..., U in (M)].
  • processing the input signal refers to sequentially processing each digital signal in the input signal.
  • t n the time when the nth digital signal is input is marked as t n
  • the input signal corresponding to the time t n is marked as U in (n) or U in (t n ).
  • the above-mentioned loudness and dynamic changes can be used to measure the sound quality of audio signals played by speakers, especially for small speakers, low-frequency loudness and dynamic changes are the main goals of audio signal processing.
  • Transient signal and steady-state signal The signal with short maintenance time and obvious start and end is called transient signal; the signal that changes within a small range for a long period of time is called steady-state signal.
  • Fig. 1 shows a transient signal and a steady state signal of an audio signal.
  • the displacement of the speaker refers to the moving distance of the diaphragm during the working process of the speaker.
  • the displacement of the speaker has an impact on the sound quality of the speaker.
  • the displacement of the diaphragm of the speaker may cause the diaphragm of the speaker to top or rub against the ring, resulting in noise and even mechanical damage to the speaker.
  • the displacement of the speaker may be controlled to improve the sound quality of the speaker.
  • Nonlinear parameters of speakers may include but not limited to the following parameters:
  • Force factor BL(x) refers to the force factor of the magnetic circuit system of the loudspeaker.
  • Kms(x) refers to the stiffness of the suspension system of the loudspeaker.
  • Kms(x) can include different coefficients such as first order, second order, and third order.
  • Inductance Le(x) refers to the inductance of the coil of the speaker.
  • Damping Rm(v) It is the damping coefficient of the loudspeaker, and Rm(v) can include different coefficients such as first order, second order and third order.
  • x refers to the displacement of the diaphragm of the loudspeaker
  • v refers to the moving speed of the diaphragm of the loudspeaker
  • nonlinear parameters of the speaker may change due to different working conditions of the speaker. For example, when the coil of the speaker is at different temperatures, the above Kms(x) will change, and Rm(v) may also change, that is Kms(x) is different at different temperatures, and Rm(v) is different at different temperatures.
  • Nonlinearity of the speaker is a phenomenon in which the output sound quality of the speaker is distorted due to the hardware structure of the speaker (such as the small size of the speaker, large displacement and other structural characteristics), which can be called nonlinear distortion, especially the speaker When there is a large signal input, the nonlinearity of the speaker is more obvious, and the output signal may produce excessive distortion, which affects the hearing experience.
  • the nonlinear distortion caused by hardware of the speaker may be compensated by using the nonlinear parameters of the speaker, so as to improve the sound quality of the speaker.
  • the loudness of the audio signal played by most speakers is insufficient, and the dynamic change performance is not good, so that the sound quality of the audio signal played by the speaker is poor.
  • the middle and low frequency signals in the audio signal play an important role in the sense of hearing and directly affect the user's hearing experience. Therefore, how to improve the low frequency sound effect of the small speaker is an urgent problem to be solved.
  • Some existing methods for improving the sound quality of speakers involve processing audio signals from the perspective of speaker displacement protection and nonlinear compensation, maximizing the hardware potential of the speaker, and improving the loudness of the speaker. The effect of improving the sound quality of the speaker still needs to be improved.
  • Embodiments of the present application provide a method and device for improving the sound quality of speakers, which can be applied to electronic equipment with speakers.
  • the electronic equipment processes the audio signal to be reproduced (the following embodiments are referred to as the input signal of the speaker) to improve The sound quality of the speakers.
  • the electronic device divides the frequency of the input signal of the speaker to obtain the first low-frequency input signal and the first high-frequency input signal; then the electronic device performs transient detection on the first low-frequency input signal of the speaker to determine the first low-frequency Whether the input signal is a transient signal; if the first low-frequency input signal is a transient signal, the signal envelope modulation is performed on the first low-frequency input signal to obtain a second low-frequency input signal, and the starting voltage of the second low-frequency input signal is greater than The starting voltage of the first low-frequency input signal, and the loudness of the second low-frequency input signal is greater than the loudness of the first low-frequency input signal; finally, the electronic device determines the output signal of the speaker according to the second low-frequency input signal and the above-mentioned first high-frequency input signal .
  • the method for improving the sound quality of speakers provided in the embodiments of the present application can be applied to electronic devices with audio playback function (that is, with speakers), such as mobile phones, tablet computers, notebook computers, smart speakers, TVs and other electronic devices equipped with speakers.
  • the method provided by the embodiment of the present application can be used in the scene where the speaker of the electronic device is used to produce sound.
  • the method for improving the sound quality of the speaker provided by the embodiment of the present application can be applied in the following scene: playing music and movies ( Including monophonic, dual-channel and quadruple-channel playback), hands-free calls (including operator calls, Internet calls, etc.), mobile phone ringtones (including external playback mode, earphone plug-in mode) and external playback of games, etc., to maximize the play
  • the hardware potential of the speaker can improve the low-frequency sound effect of the speaker and the sound quality of the speaker, thereby improving the user's subjective experience.
  • the audio processing system mainly includes a digital signal processing (digital signal processing, DSP) device and a power amplifier ( power amplifier, PA), wherein, DSP is used to process the input audio signal, and the processed signal is amplified by PA, and finally output to the speaker for playback.
  • DSP digital signal processing
  • PA power amplifier
  • FIG. 3 shows a schematic structural diagram of a mobile phone 300 .
  • the mobile phone 300 may include a processor 310, an external memory interface 320, an internal memory 321, a universal serial bus (universal serial bus, USB) interface 330, a charging management module 340, a power management module 341, a battery 342, an antenna 1, and an antenna 2 , mobile communication module 350, wireless communication module 360, audio module 370, speaker 370A, receiver 370B, microphone 370C, earphone jack 370D, sensor module 380, button 390, motor 391, indicator 392, camera 393, display screen 394, and A subscriber identification module (subscriber identification module, SIM) card interface 395 and the like.
  • SIM subscriber identification module
  • the sensor module 380 may include a pressure sensor 380A, a gyroscope sensor 380B, an air pressure sensor 380C, a magnetic sensor 380D, an acceleration sensor 380E, a distance sensor 380F, a proximity light sensor 380G, a fingerprint sensor 380H, a temperature sensor 380J, a touch sensor 380K, and an ambient light sensor.
  • the structure shown in the embodiment of the present application does not constitute a specific limitation on the mobile phone 300 .
  • the mobile phone 300 may include more or fewer components than shown in the figure, or combine some components, or separate some components, or arrange different components.
  • the illustrated components can be realized in hardware, software or a combination of software and hardware.
  • the processor 310 may include one or more processing units, for example: the processor 310 may include an application processor (application processor, AP), a modem processor, a graphics processing unit (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, memory, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural network processor (neural-network processing unit, NPU) Wait. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
  • application processor application processor, AP
  • modem processor graphics processing unit
  • graphics processing unit graphics processing unit
  • ISP image signal processor
  • controller memory
  • video codec digital signal processor
  • DSP digital signal processor
  • baseband processor baseband processor
  • neural network processor neural-network processing unit, NPU
  • the controller may be the nerve center and command center of the mobile phone 300 .
  • the controller can generate an operation control signal according to the instruction opcode and timing signal, and complete the control of fetching and executing the instruction.
  • a memory may also be provided in the processor 310 for storing instructions and data.
  • the memory in processor 310 is a cache memory.
  • the memory may hold instructions or data that the processor 310 has just used or recycled. If the processor 310 needs to use the instruction or data again, it can be directly recalled from the memory. Repeated access is avoided, and the waiting time of the processor 310 is reduced, thereby improving the efficiency of the system.
  • processor 310 may include one or more interfaces.
  • the interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous transmitter (universal asynchronous receiver/transmitter, UART) interface, mobile industry processor interface (mobile industry processor interface, MIPI), general-purpose input and output (general-purpose input/output, GPIO) interface, subscriber identity module (subscriber identity module, SIM) interface, and /or universal serial bus (universal serial bus, USB) interface, etc.
  • I2C integrated circuit
  • I2S integrated circuit built-in audio
  • PCM pulse code modulation
  • PCM pulse code modulation
  • UART universal asynchronous transmitter
  • MIPI mobile industry processor interface
  • GPIO general-purpose input and output
  • subscriber identity module subscriber identity module
  • SIM subscriber identity module
  • USB universal serial bus
  • the I2C interface is a bidirectional synchronous serial bus, including a serial data line (serial data line, SDA) and a serial clock line (derail clock line, SCL).
  • processor 310 may include multiple sets of I2C buses.
  • the processor 310 can be respectively coupled to the touch sensor 380K, the charger, the flashlight, the camera 393 and so on through different I2C bus interfaces.
  • the processor 310 may be coupled to the touch sensor 380K through an I2C interface, so that the processor 310 and the touch sensor 380K communicate through the I2C bus interface to realize the touch function of the mobile phone 300 .
  • the I2S interface can be used for audio communication.
  • processor 310 may include multiple sets of I2S buses.
  • the processor 310 may be coupled to the audio module 370 through an I2S bus to implement communication between the processor 310 and the audio module 370 .
  • the audio module 370 can transmit audio signals to the wireless communication module 360 through the I2S interface, so as to realize the function of answering calls through the Bluetooth headset.
  • the PCM interface can also be used for audio communication, sampling, quantizing and encoding the analog signal.
  • the audio module 370 and the wireless communication module 360 may be coupled through a PCM bus interface.
  • the audio module 370 can also transmit audio signals to the wireless communication module 360 through the PCM interface, so as to realize the function of answering calls through the Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.
  • the UART interface is a universal serial data bus used for asynchronous communication.
  • the bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication.
  • a UART interface is generally used to connect the processor 310 and the wireless communication module 360 .
  • the processor 310 communicates with the Bluetooth module in the wireless communication module 360 through the UART interface to realize the Bluetooth function.
  • the audio module 370 can transmit audio signals to the wireless communication module 360 through the UART interface, so as to realize the function of playing music through the Bluetooth headset.
  • the MIPI interface can be used to connect the processor 310 with peripheral devices such as the display screen 394 and the camera 393 .
  • MIPI interface includes camera serial interface (camera serial interface, CSI), display serial interface (display serial interface, DSI), etc.
  • the processor 310 communicates with the camera 393 through the CSI interface to realize the shooting function of the mobile phone 300 .
  • the processor 310 communicates with the display screen 394 through the DSI interface to realize the display function of the mobile phone 300 .
  • the GPIO interface can be configured by software.
  • the GPIO interface can be configured as a control signal or as a data signal.
  • the GPIO interface can be used to connect the processor 310 with the camera 393 , the display screen 394 , the wireless communication module 360 , the audio module 370 , the sensor module 380 and so on.
  • the GPIO interface can also be configured as an I2C interface, I2S interface, UART interface, MIPI interface, etc.
  • the USB interface 330 is an interface conforming to the USB standard specification, specifically, it may be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like.
  • the USB interface 330 can be used to connect a charger to charge the mobile phone 300, and can also be used to transmit data between the mobile phone 300 and peripheral devices. It can also be used to connect headphones and play audio through them. This interface can also be used to connect other electronic devices, such as AR devices.
  • the interface connection relationship between modules shown in the embodiment of the present application is only a schematic illustration, and does not constitute a structural limitation of the mobile phone 300 .
  • the mobile phone 300 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.
  • the charging management module 340 is configured to receive charging input from the charger.
  • the charger may be a wireless charger or a wired charger.
  • the charging management module 340 can receive charging input from a wired charger through the USB interface 330 .
  • the charging management module 340 can receive wireless charging input through the wireless charging coil of the mobile phone 300 . While the charging management module 340 is charging the battery 342 , it can also supply power to the electronic device through the power management module 341 .
  • the power management module 341 is used for connecting the battery 342 , the charging management module 340 and the processor 310 .
  • the power management module 341 receives the input of the battery 342 and/or the charging management module 340, and supplies power for the processor 310, the internal memory 321, the external memory, the display screen 394, the camera 393, and the wireless communication module 360, etc.
  • the power management module 341 can also be used to monitor parameters such as battery capacity, battery cycle times, and battery health status (leakage, impedance).
  • the power management module 341 may also be disposed in the processor 310 .
  • the power management module 341 and the charging management module 340 may also be set in the same device.
  • the wireless communication function of the mobile phone 300 can be realized by the antenna 1, the antenna 2, the mobile communication module 350, the wireless communication module 360, the modem processor and the baseband processor.
  • Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals.
  • Each antenna in handset 300 can be used to cover single or multiple communication frequency bands. Different antennas can also be multiplexed to improve the utilization of the antennas.
  • Antenna 1 can be multiplexed as a diversity antenna of a wireless local area network.
  • the antenna may be used in conjunction with a tuning switch.
  • the mobile communication module 350 can provide wireless communication solutions including 2G/3G/4G/5G applied on the mobile phone 300 .
  • the mobile communication module 350 may include at least one filter, switch, power amplifier, low noise amplifier (low noise amplifier, LNA) and the like.
  • the mobile communication module 350 can receive electromagnetic waves through the antenna 1, filter and amplify the received electromagnetic waves, and send them to the modem processor for demodulation.
  • the mobile communication module 350 can also amplify the signal modulated by the modem processor, convert it into electromagnetic wave and radiate it through the antenna 1 .
  • at least part of the functional modules of the mobile communication module 350 may be set in the processor 310 .
  • at least part of the functional modules of the mobile communication module 350 and at least part of the modules of the processor 310 may be set in the same device.
  • a modem processor may include a modulator and a demodulator.
  • the modulator is used for modulating the low-frequency baseband signal to be transmitted into a medium-high frequency signal.
  • the demodulator is used to demodulate the received electromagnetic wave signal into a low frequency baseband signal. Then the demodulator sends the demodulated low-frequency baseband signal to the baseband processor for processing.
  • the low-frequency baseband signal is passed to the application processor after being processed by the baseband processor.
  • the application processor outputs sound signals through audio equipment (not limited to speaker 370A, receiver 370B, etc.), or displays images or videos through display screen 394 .
  • the modem processor may be a stand-alone device.
  • the modem processor may be independent from the processor 310, and be set in the same device as the mobile communication module 350 or other functional modules.
  • the wireless communication module 360 can provide wireless local area networks (wireless local area networks, WLAN) (such as wireless fidelity (Wireless Fidelity, Wi-Fi) network), bluetooth (bluetooth, BT), global navigation satellite system, etc. applied on the mobile phone 300. (global navigation satellite system, GNSS), frequency modulation (frequency modulation, FM), near field communication technology (near field communication, NFC), infrared technology (infrared, IR) and other wireless communication solutions.
  • the wireless communication module 360 may be one or more devices integrating at least one communication processing module.
  • the wireless communication module 360 receives electromagnetic waves via the antenna 2 , frequency-modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 310 .
  • the wireless communication module 360 can also receive the signal to be sent from the processor 310 , frequency-modulate it, amplify it, and convert it into electromagnetic waves through the antenna 2 for radiation.
  • the antenna 1 of the mobile phone 300 is coupled to the mobile communication module 350, and the antenna 2 is coupled to the wireless communication module 360, so that the mobile phone 300 can communicate with the network and other devices through wireless communication technology.
  • the wireless communication technology may include global system for mobile communications (GSM), general packet radio service (general packet radio service, GPRS), code division multiple access (code division multiple access, CDMA), broadband Code division multiple access (wideband code division multiple access, WCDMA), time division code division multiple access (time-division code division multiple access, TD-SCDMA), long term evolution (long term evolution, LTE), BT, GNSS, WLAN, NFC , FM, and/or IR techniques, etc.
  • GSM global system for mobile communications
  • GPRS general packet radio service
  • code division multiple access code division multiple access
  • CDMA broadband Code division multiple access
  • WCDMA wideband code division multiple access
  • time division code division multiple access time-division code division multiple access
  • LTE long term evolution
  • BT GNSS
  • WLAN NFC
  • the GNSS may include a global positioning system (global positioning system, GPS), a global navigation satellite system (global navigation satellite system, GLONASS), a Beidou navigation satellite system (beidou navigation satellite system, BDS), a quasi-zenith satellite system (quasi -zenith satellite system (QZSS) and/or satellite based augmentation systems (SBAS).
  • GPS global positioning system
  • GLONASS global navigation satellite system
  • Beidou navigation satellite system beidou navigation satellite system
  • BDS Beidou navigation satellite system
  • QZSS quasi-zenith satellite system
  • SBAS satellite based augmentation systems
  • the mobile phone 300 realizes the display function through the GPU, the display screen 394, and the application processor.
  • the GPU is a microprocessor for image processing, connected to the display screen 394 and the application processor. GPUs are used to perform mathematical and geometric calculations for graphics rendering.
  • Processor 310 may include one or more GPUs that execute program instructions to generate or alter display information.
  • the display screen 394 is used to display images, videos and the like.
  • Display 394 includes a display panel.
  • the display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active matrix organic light emitting diode or an active matrix organic light emitting diode (active-matrix organic light emitting diode, AMOLED), flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-oLed, quantum dot light emitting diodes (quantum dot light emitting diodes, QLED), etc.
  • the mobile phone 300 may include 1 or N display screens 394, where N is a positive integer greater than 1.
  • the mobile phone 300 can realize the shooting function through ISP, camera 393 , video codec, GPU, display screen 394 and application processor.
  • the ISP is used for processing the data fed back by the camera 393 .
  • the light is transmitted to the photosensitive element of the camera through the lens, and the light signal is converted into an electrical signal, and the photosensitive element of the camera transmits the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye.
  • ISP can also perform algorithm optimization on image noise, brightness, and skin color.
  • ISP can also optimize the exposure, color temperature and other parameters of the shooting scene.
  • the ISP may be located in the camera 393 .
  • Camera 393 is used to capture still images or video.
  • the object generates an optical image through the lens and projects it to the photosensitive element.
  • the photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor.
  • CMOS complementary metal-oxide-semiconductor
  • the photosensitive element converts the light signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal.
  • the ISP outputs the digital image signal to the DSP for processing.
  • DSP converts digital image signals into standard RGB, YUV and other image signals.
  • the mobile phone 300 may include 1 or N cameras 393, where N is a positive integer greater than 1.
  • a digital signal processor is used to process digital signals, in addition to processing digital image signals, it can also process other digital signals (such as audio signals, etc.). For example, when the mobile phone 300 selects a frequency point, the digital signal processor is used to perform Fourier transform on the energy of the frequency point.
  • Video codecs are used to compress or decompress digital video.
  • the handset 300 may support one or more video codecs.
  • the mobile phone 300 can play or record videos in various encoding formats, for example: moving picture experts group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4 and so on.
  • MPEG moving picture experts group
  • the NPU is a neural-network (NN) computing processor.
  • NN neural-network
  • Applications such as intelligent cognition of the mobile phone 300 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
  • the external memory interface 320 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the mobile phone 300.
  • the external memory card communicates with the processor 310 through the external memory interface 320 to implement a data storage function. Such as saving music, video and other files in the external memory card.
  • the internal memory 321 may be used to store computer-executable program code, which includes instructions.
  • the processor 310 executes various functional applications and data processing of the mobile phone 300 by executing instructions stored in the internal memory 321 .
  • the internal memory 321 may include an area for storing programs and an area for storing data.
  • the stored program area can store an operating system, at least one application program required by a function (such as a sound playing function, an image playing function, etc.) and the like.
  • the storage data area can store data (such as audio data, phone book, etc.) created during the use of the mobile phone 300 .
  • the internal memory 321 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (universal flash storage, UFS) and the like.
  • the mobile phone 300 can realize the audio function through the audio module 370, the speaker 370A, the receiver 370B, the microphone 370C, the earphone interface 370D, and the application processor. Such as music playback, recording, etc.
  • the audio module 370 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signal.
  • the audio module 370 may also be used to encode and decode audio signals.
  • the audio module 370 can be set in the processor 310 , or some functional modules of the audio module 370 can be set in the processor 310 .
  • Speaker 370A also called “horn” is used to convert audio electrical signals into sound signals.
  • Cell phone 300 can listen to music through speaker 370A, or listen to hands-free calls.
  • Receiver 370B also called “earpiece” is used to convert audio electrical signals into audio signals.
  • the receiver 370B can be placed close to the human ear to receive the voice.
  • the microphone 370C also called “microphone” or “microphone”, is used to convert sound signals into electrical signals.
  • the user can put his mouth close to the microphone 370C to make a sound, and input the sound signal to the microphone 370C.
  • the mobile phone 300 can be provided with at least one microphone 370C.
  • the mobile phone 300 can be provided with two microphones 370C, which can also implement a noise reduction function in addition to collecting sound signals.
  • the mobile phone 300 can also be provided with three, four or more microphones 370C to realize the collection of sound signals, noise reduction, identification of sound sources, and realization of directional recording functions, etc.
  • the earphone interface 370D is used to connect wired earphones.
  • the earphone interface 370D may be a USB interface 330, or a 3.5mm open mobile terminal platform (open mobile terminal platform, OMTP) standard interface, or a cellular telecommunications industry association of the USA (CTIA) standard interface.
  • OMTP open mobile terminal platform
  • CTIA cellular telecommunications industry association of the USA
  • the pressure sensor 380A is used to sense the pressure signal and convert the pressure signal into an electrical signal.
  • pressure sensor 380A may be located on display screen 394.
  • pressure sensors 380A such as resistive pressure sensors, inductive pressure sensors, and capacitive pressure sensors.
  • a capacitive pressure sensor may be comprised of at least two parallel plates with conductive material.
  • the mobile phone 300 may also calculate the touched position according to the detection signal of the pressure sensor 380A.
  • touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold acts on the short message application icon, an instruction to view short messages is executed. When a touch operation whose intensity is greater than or equal to the first pressure threshold acts on the icon of the short message application, the instruction of creating a new short message is executed.
  • the gyroscope sensor 380B can be used to determine the motion posture of the mobile phone 300 .
  • the angular velocity of the mobile phone 300 about three axes ie, x, y and z axes
  • the gyro sensor 380B can be used for image stabilization.
  • the gyro sensor 380B detects the shaking angle of the mobile phone 300, and calculates the distance that the lens module needs to compensate according to the angle, so that the lens can counteract the shaking of the mobile phone 300 through reverse motion to achieve anti-shake.
  • the gyroscope sensor 380B can also be used for navigation and somatosensory game scenes.
  • the air pressure sensor 380C is used to measure air pressure. In some embodiments, the mobile phone 300 calculates the altitude based on the air pressure value measured by the air pressure sensor 380C to assist positioning and navigation.
  • the magnetic sensor 380D includes a Hall sensor.
  • the mobile phone 300 can use the magnetic sensor 380D to detect the opening and closing of the flip holster.
  • the mobile phone 300 can detect the opening and closing of the flip according to the magnetic sensor 380D.
  • features such as automatic unlocking of the flip cover are set.
  • the acceleration sensor 380E can detect the acceleration of the mobile phone 300 in various directions (generally three axes). When the mobile phone 300 is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
  • the distance sensor 380F is used to measure the distance.
  • the mobile phone 300 can measure the distance by infrared or laser. In some embodiments, when shooting a scene, the mobile phone 300 can use the distance sensor 380F for distance measurement to achieve fast focusing.
  • Proximity light sensor 380G may include, for example, light emitting diodes (LEDs) and light detectors, such as photodiodes.
  • the light emitting diodes may be infrared light emitting diodes.
  • the mobile phone 300 emits infrared light through the light emitting diode.
  • Cell phone 300 uses photodiodes to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the mobile phone 300 . When insufficient reflected light is detected, the mobile phone 300 can determine that there is no object near the mobile phone 300 .
  • the mobile phone 300 can use the proximity light sensor 380G to detect that the user is holding the mobile phone 300 close to the ear to talk, so that the screen can be automatically turned off to save power.
  • the proximity light sensor 380G can also be used in leather case mode, automatic unlock and lock screen in pocket mode.
  • the ambient light sensor 380L is used for sensing ambient light brightness.
  • the mobile phone 300 can adaptively adjust the brightness of the display screen 394 according to the perceived ambient light brightness.
  • the ambient light sensor 380L can also be used to automatically adjust the white balance when taking pictures.
  • the ambient light sensor 380L can also cooperate with the proximity light sensor 380G to detect whether the mobile phone 300 is in the pocket, so as to prevent accidental touch.
  • the fingerprint sensor 380H is used to collect fingerprints.
  • the mobile phone 300 can utilize the collected fingerprint features to realize fingerprint unlocking, access to application locks, fingerprint taking pictures, fingerprint answering incoming calls, etc.
  • the temperature sensor 380J is used to detect temperature.
  • the mobile phone 300 uses the temperature detected by the temperature sensor 380J to implement a temperature processing strategy. For example, when the temperature reported by the temperature sensor 380J exceeds the threshold, the mobile phone 300 may reduce the performance of the processor located near the temperature sensor 380J, so as to reduce power consumption and implement thermal protection.
  • the mobile phone 300 when the temperature is lower than another threshold, the mobile phone 300 heats the battery 342 to avoid abnormal shutdown of the mobile phone 300 due to low temperature.
  • the mobile phone 300 boosts the output voltage of the battery 342 to avoid abnormal shutdown caused by low temperature.
  • Touch sensor 380K also known as "touch panel”.
  • the touch sensor 380K can be arranged on the display screen 394, and the touch sensor 380K and the display screen 394 form a touch screen, also called “touch screen”.
  • the touch sensor 380K is used to detect a touch operation on or near it.
  • the touch sensor can pass the detected touch operation to the application processor to determine the type of touch event.
  • Visual output related to touch operations can be provided through the display screen 394 .
  • the touch sensor 380K may also be disposed on the surface of the mobile phone 300 , which is different from the position of the display screen 394 .
  • the bone conduction sensor 380M can acquire vibration signals. In some embodiments, the bone conduction sensor 380M can acquire the vibration signal of the vibrating bone mass of the human voice. The bone conduction sensor 380M can also contact the human pulse and receive the blood pressure beating signal. In some embodiments, the bone conduction sensor 380M can also be disposed in the earphone, combined into a bone conduction earphone.
  • the audio module 370 can analyze the voice signal based on the vibration signal of the vibrating bone mass of the vocal part acquired by the bone conduction sensor 380M, so as to realize the voice function.
  • the application processor can analyze the heart rate information based on the blood pressure beating signal acquired by the bone conduction sensor 380M, so as to realize the heart rate detection function.
  • the keys 390 include a power key, a volume key and the like.
  • the key 390 may be a mechanical key. It can also be a touch button.
  • the mobile phone 300 can receive key input and generate key signal input related to user settings and function control of the mobile phone 300 .
  • the motor 391 can generate a vibrating reminder.
  • the motor 391 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback.
  • touch operations applied to different applications may correspond to different vibration feedback effects.
  • the motor 391 can also correspond to different vibration feedback effects for touch operations acting on different areas of the display screen 394 .
  • Different application scenarios for example: time reminder, receiving information, alarm clock, games, etc.
  • the touch vibration feedback effect can also support customization.
  • the indicator 392 can be an indicator light, which can be used to indicate the charging status, the change of the battery capacity, and can also be used to indicate messages, missed calls, notifications and the like.
  • the SIM card interface 395 is used for connecting a SIM card.
  • the SIM card can be connected and separated from the mobile phone 300 by inserting it into the SIM card interface 395 or pulling it out from the SIM card interface 395 .
  • the mobile phone 300 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1.
  • SIM card interface 395 can support Nano SIM card, Micro SIM card, SIM card etc. Multiple cards can be inserted into the same SIM card interface 395 at the same time. The types of the multiple cards may be the same or different.
  • the SIM card interface 395 is also compatible with different types of SIM cards.
  • the SIM card interface 395 is also compatible with external memory cards.
  • the mobile phone 300 interacts with the network through the SIM card to implement functions such as calling and data communication.
  • the mobile phone 300 adopts eSIM, that is, an embedded SIM card.
  • the eSIM card can be embedded in the mobile phone 300 and cannot be separated from the mobile phone 300 .
  • FIG. 3 only uses a mobile phone as an example for illustration, and does not specifically limit the structure of the electronic device.
  • the electronic device may include more components in FIG. 3 , or may include fewer components than those shown in FIG. 3 , which is not limited in this embodiment of the present application.
  • the processor of the electronic device can perform some or all of the steps in the embodiment of the present application. These steps or operations are only examples, and the embodiment of the present application can also Perform other operations or variations of various operations. In addition, each step may be performed in a different order presented in the embodiment of the present application, and it may not be necessary to perform all operations in the embodiment of the present application.
  • Each embodiment of the present application may be implemented independently or in any combination, which is not limited in the present application.
  • an embodiment of the present application provides a method for improving sound quality of a speaker, and the method includes steps 401 to 404 .
  • Step 401 the electronic device divides the frequency of the input signal of the speaker to obtain a first low-frequency input signal and a first high-frequency input signal.
  • the input signal of the loudspeaker processed by the electronic device is a time-domain signal.
  • the first low-frequency input signal includes a signal of the input signal lower than a first preset frequency point
  • the first high-frequency input signal includes a signal of the input signal higher than a second preset frequency point.
  • the first preset frequency point may be a frequency point in the range of 100-400 Hz, for example, the first preset frequency point may be 100, 200, 250, 300 or 400 Hz and so on.
  • the signal at the first preset frequency point may be included in the first low-frequency input signal, or may be included in the first high-frequency input signal, or may be included in both the first low-frequency input signal and the first high-frequency input signal.
  • the frequency input signal is not limited in this embodiment of the present application.
  • the electronic device may divide the input data by a frequency divider.
  • the frequency divider is essentially a filter for filtering the input signal to obtain a low-frequency signal in the input signal (referred to as the first low-frequency input signal) and A high-frequency signal (referred to as a first high-frequency input signal).
  • Step 402 the electronic device performs transient detection on the first low-frequency input signal of the speaker, so as to determine whether the first low-frequency input signal is a transient signal.
  • transient signals are some signals with large signal amplitude changes.
  • transient signals usually transient signals contain important information of a piece of audio. Therefore, the transient signals in audio signals can be signal, to process the transient signal and improve the sound quality.
  • the method for an electronic device to perform transient detection on a first low-frequency input signal specifically includes steps 4021 to 4023 .
  • Step 4021 the electronic device determines the transient power and steady-state power of the first low-frequency input signal.
  • the process for the electronic device to determine the transient power and steady-state power of the first low-frequency input signal (corresponding to one signal frame) includes:
  • the electronic device calculates the power of the first low-frequency input signal. It should be understood that the power of the first low-frequency input signal is the sum of the squares of the voltage values of all data points included in the first low-frequency input signal and then averaged.
  • the transient power of the first low-frequency input signal may be the average power of n1 consecutive signal frames before the current frame
  • the steady-state power of the first low-frequency input signal may be the average power of n2 consecutive signal frames before the current frame
  • n1 is much smaller than n2, for example, the value of n1 is 5, and the value of n2 is 50.
  • Step 4022 the electronic device determines the instantaneous rate of the first low-frequency input signal according to the instantaneous power and steady-state power of the first low-frequency input signal.
  • the instantaneous rate of the above-mentioned first low-frequency input signal satisfies:
  • T r represents the instantaneous rate of the first low-frequency input signal
  • R r represents the ratio of the transient power of the first low-frequency input signal to the steady-state power of the first low-frequency input signal
  • W represents the weighting factor
  • P s represents the transient power of the current frame
  • P w is the steady-state power of the current frame.
  • the value of the weighting factor may be the same as the current power of the first low-frequency input signal.
  • some small signals can be masked.
  • Step 4023 If the transient rate of the input signal is greater than the preset transient rate threshold, the electronic device determines that the input signal is a transient signal; otherwise, the input signal is a steady state signal.
  • the first low-frequency input signal is a transient signal, mark the first low-frequency input signal, and perform the following step 403 to process the first low-frequency input signal; if the first low-frequency input signal is a steady-state signal, the first low-frequency input signal is not processed.
  • the electronic device may perform low-pass filtering on the first low-frequency input signal, and then calculate the instantaneous power and steady state of the filtered first low-frequency input signal. state power to further determine whether the first low-frequency input signal is a transient signal or a steady-state signal.
  • low-pass filtering is performed on the first low-frequency input signal to obtain a low-frequency input signal in a lower frequency range, and the high-frequency signal that may exist in the first low-frequency input signal can be further reduced through low-pass filtering, here Basically, performing transient detection on the filtered first low-frequency input signal can reduce the false detection rate of transient detection.
  • Step 403 If the first low-frequency input signal is a transient signal, the electronic device performs signal envelope modulation on the first low-frequency input signal to obtain a second low-frequency input signal.
  • the envelope modulation of the audio signal is to adjust the oscillation voltage, loudness and decay speed of the signal, so that the sound quality of the audio signal after envelope modulation is better than that of the audio signal before envelope modulation.
  • the start-up voltage refers to the voltage that can make the speaker diaphragm start to vibrate quickly, that is, the start-up voltage determines the start-up speed of the diaphragm.
  • the start-up voltage of the second low-frequency input signal obtained by performing envelope modulation on the first low-frequency input signal is greater than the start-up voltage of the first low-frequency input signal, and the loudness of the second low-frequency input signal is greater than that of the first low-frequency input signal.
  • the transient signal waveform change usually includes four stages, namely: the attack phase (attack, denoted as A), the decay phase (decay, denoted as D), and the continuous phase ( sustain, denoted as S) and the release phase (release, denoted as R).
  • each stage has a certain duration, and each stage corresponds to adjustment parameters, for example, the adjustment parameters in the start-up phase are start-up time and start-up voltage (target Ratio A), and the adjustment parameters in the decay phase are decay time and decay Speed (target Radio DR), the adjustment parameters of the sustain stage are duration and volume (ie amplitude, sustain level), and the adjustment parameters of the release stage are release time and release speed.
  • the decay rate and the release rate can be equal.
  • performing envelope modulation on the first low-frequency input signal includes: adjusting the parameters of the four stages of the first low-frequency input signal, such as adjusting the duration of the above four stages, adjusting the oscillation voltage, volume, and release speed. At least one item of , so that the start-up voltage of the second low-frequency input signal is greater than the start-up voltage of the first low-frequency input signal, and the loudness of the second low-frequency input signal is greater than the loudness of the first low-frequency input signal.
  • Step 404 the electronic device determines the output signal of the speaker according to the second low-frequency input signal and the first high-frequency input signal.
  • the electronic device begins to divide the input signal into the first low-frequency input signal and the first high-frequency input signal, and then processes the first low-frequency input signal, and the first high-frequency input signal No processing, finally, sum the processed low-frequency input data (that is, the second low-frequency input data) and the first high-frequency input data (it is the inverse process of frequency division), so as to complete the processing of the input signal and obtain the output signal , and then send the output signal to the speaker for playback.
  • Fig. 7 shows a framework of a loudspeaker system provided by an embodiment of the present application.
  • the speaker system includes a frequency division unit, a transient detection unit, an envelope modulation unit, and an output unit, wherein the frequency division unit is used to divide the input signal to obtain a low-frequency input signal and a high-frequency input signal ;
  • the transient detection unit is used for transient detection of the low-frequency input signal
  • the envelope modulation unit is used for performing envelope modulation on the low-frequency input signal when the low-frequency input signal is a transient signal
  • the output unit is used for converting the high-frequency
  • the input signal and the low-frequency input signal after envelope modulation are mixed to obtain the input and output signals, and then input to the speaker for playback.
  • the transient detection is performed on the low-frequency signal in the input signal. If the input signal is a transient signal, envelope modulation is used to enhance the transient signal. Since the speaker plays a When the audio signal is played by the speaker, the sound quality of the low-frequency signal in the audio signal is related to the performance of the speaker, and the transient signal in the low-frequency signal usually reflects important information of the audio signal, so the transient signal in the low-frequency signal is modulated to improve The loudness of the low-frequency transient signal, and adjust the dynamic range of the low-frequency transient signal, so that when the speaker plays the processed audio signal, the low-frequency sound effect of the audio signal is better, that is, the sound quality of the speaker can be improved through the technical solution of the embodiment of the present application .
  • the method for improving the sound quality of a speaker provided in the embodiment of the present application further includes steps 405 to 407 .
  • Step 405 the electronic device divides the frequency of the first high-frequency input signal of the speaker to obtain the first intermediate-frequency input signal and the second high-frequency input signal.
  • the above-mentioned first intermediate frequency input signal includes a signal lower than a second preset frequency point in the first high frequency input signal
  • the second high frequency input signal includes a signal higher than a second preset frequency point in the first high frequency input signal
  • the second preset frequency point is higher than the first preset frequency point
  • the second preset frequency point may be a frequency point in the range of 1500-2500 Hz, for example, the second preset frequency point may be 1500, 1750, 2000, 2250, or 2500 Hz and so on.
  • the signal at the second preset frequency point may be included in the first intermediate frequency input signal, or may be included in the second high frequency input signal, or may be included in both the first intermediate frequency input signal and the second high frequency input signal.
  • the frequency input signal is not limited in this embodiment of the present application.
  • the electronic device can divide the input signal into signals of two frequency bands, that is, the above-mentioned low-frequency input signal and high-frequency input signal, and further divide the high-frequency input signal into an intermediate-frequency input signal and new high-frequency input signals.
  • the electronic device may also directly divide the frequency of the input signal into signals of three frequency bands, that is, a low-frequency signal, an intermediate-frequency signal, and a high-frequency signal. That is to say, when the electronic device starts to process the input signal, the electronic device directly divides the frequency of the input signal, and divides the input signal into the above-mentioned first low-frequency input signal, first intermediate-frequency input signal and second high-frequency input signal.
  • Step 406 the electronic device performs transient detection on the first intermediate frequency input signal, so as to determine whether the first intermediate frequency input signal is a transient signal.
  • Step 407 If the first intermediate frequency input signal is a transient signal, perform signal envelope modulation on the first intermediate frequency input signal to obtain a second intermediate frequency input signal.
  • the starting voltage of the second intermediate frequency input signal is greater than the starting voltage of the first intermediate frequency input signal
  • the loudness of the second intermediate frequency input signal is greater than the loudness of the first intermediate frequency input signal
  • step 406 and step 407 The method of performing transient detection and envelope modulation on the first intermediate frequency input signal in the above step 406 and step 407 is similar to the method of performing transient detection and envelope modulation on the first low frequency input signal in the above embodiment, therefore, for the step For related descriptions of step 406 and step 407, reference may be made to the detailed description of step 402 and step 403 in the foregoing embodiments, and details are not repeated here. It should be noted that the difference between the two is that some parameters set during transient detection and envelope modulation may be different.
  • the method for the electronic device to determine the output signal of the speaker specifically includes step 408, that is, the above step 404 is replaced with step 408.
  • Step 408 the pair of electronic devices determines the output signal of the speaker according to the second low-frequency input signal, the second intermediate-frequency input signal, and the second high-frequency input signal.
  • the electronic device may sum the second low-frequency input signal, the second intermediate-frequency input signal, and the second high-frequency input signal to obtain the output signal of the speaker.
  • Fig. 9 shows a framework of another loudspeaker system provided by an embodiment of the present application.
  • the speaker system includes a frequency division unit, a first transient detection unit, a first envelope modulation unit, a second transient detection unit, a second envelope modulation unit and an output unit, wherein the frequency division unit It is used to divide the frequency of the input signal to obtain the low frequency input signal, the intermediate frequency input signal and the high frequency input signal; the first transient detection unit is used for transient detection of the low frequency input signal, and the first envelope modulation unit is used for When the low-frequency input signal is a transient signal, envelope modulation is carried out to the low-frequency input signal; the second transient detection unit is used to perform transient detection (such as step 406) to the intermediate frequency input signal, and the second envelope modulation unit uses In the case that the intermediate frequency input signal is a transient signal, envelope modulation is performed on the intermediate frequency input signal (for example, step 407); the output unit is used to convert the high frequency input signal, the
  • transient detection is also performed on the intermediate frequency signal in the input signal
  • envelope modulation is performed on the transient signal to enhance the intermediate frequency signal, so as to generally improve the sound quality of the speaker.
  • the above-mentioned first low-frequency input signal is a transient signal
  • the speaker of the electronic device is a smaller speaker whose low-frequency replay capability is weak.
  • the method for improving the sound quality of the loudspeaker provided by the embodiment of the present application further includes steps 409 and 410 .
  • Step 409 the electronic device generates a low-frequency auxiliary signal.
  • the function of the low-frequency auxiliary signal is to help enhance the loudness of the first low-frequency input signal and optimize the dynamic range of the first low-frequency input signal.
  • the specific method for generating the low-frequency auxiliary signal includes:
  • the first auxiliary signal is generated. There are multiple methods for generating the first auxiliary signal.
  • the first auxiliary signal satisfies:
  • signal_h represents the first auxiliary signal
  • A represents the signal amplitude influence factor
  • f is the center frequency of the loudspeaker.
  • the value range of A can be 10 ⁇ 50, and the specific value of A can be estimated by the system or set by the user, for example, it can be 10, 25, or 50, etc.; the value range of f can be 50 ⁇ 150Hz, the specific value
  • the value of can be estimated by the system or set by the user, for example, it can be 50Hz, 100Hz, or 150Hz and so on.
  • high-pass filtering is performed on the first auxiliary signal to obtain a low-frequency auxiliary signal.
  • the electronic device performs high-pass filtering on the first auxiliary signal to filter out some signals with too low frequencies in the first auxiliary signal to obtain a low-frequency auxiliary signal.
  • the high-pass filter The filtering frequency may be about 1.5 times the above-mentioned central frequency f.
  • Step 410 the electronic device adds a low-frequency auxiliary signal to the first low-frequency input signal, so as to obtain a first auxiliary enhanced signal.
  • adding the low-frequency auxiliary signal to the first low-frequency input signal refers to summing the first low-frequency input signal and the low-frequency auxiliary signal.
  • the electronic device may add a certain proportion of low-frequency auxiliary signals to the first low-frequency input signal according to the energy of the first low-frequency input signal. For example, if the energy of the first low-frequency input signal is low, the first low-frequency Add a times the low-frequency auxiliary signal to the input signal, 0 ⁇ a ⁇ 1.
  • step 403 the above-mentioned signal envelope adjustment is performed on the first low-frequency input signal to obtain the second low-frequency input signal (that is, step 403) is specifically implemented through step 4031:
  • Step 4031 Perform signal envelope modulation on the first auxiliary enhanced signal to obtain a second low-frequency input signal.
  • FIG. 11 is a schematic diagram of another loudspeaker system frame provided by an embodiment of the present application.
  • the loudspeaker system further includes an auxiliary enhancement unit on the basis of the loudspeaker system shown in FIG. 9 .
  • the auxiliary enhancement unit executes the process from step 409 to step 410 to perform auxiliary enhancement on the first low-frequency input signal.
  • the above-mentioned first low-frequency input signal is a transient signal.
  • the method may also include step 411 .
  • Step 411 the electronic device performs phase compensation on the first low-frequency input signal to obtain a first phase compensation signal.
  • the first phase compensation signal is the first low-frequency input signal after phase compensation.
  • the phase of the first low-frequency input signal may be affected, resulting in low-frequency
  • the phase of the input signal deviates and is no longer a linear phase. Therefore, necessary linear phase compensation is performed on the first low-frequency input signal to correct the phase of the first low-frequency input signal to a linear phase, thereby ensuring low-frequency sound quality.
  • the electronic device calculates the signal (which may be an electrical signal or an acoustic signal) after the test signal is processed by the speaker system, and then generates a phase compensation filter according to the calculation result of the test signal and the preset standard signal (specifically, generates the phase compensation filter coefficient), and then use the phase compensation filter to process the first low-frequency input signal to realize phase compensation for the first low-frequency input signal.
  • the signal which may be an electrical signal or an acoustic signal
  • the preset standard signal specifically, generates the phase compensation filter coefficient
  • step 403 the above-mentioned signal envelope adjustment is performed on the first low-frequency input signal to obtain the second low-frequency input signal (that is, step 403) is specifically implemented through step 4032:
  • Step 4032 Perform signal envelope modulation on the first phase compensation signal to obtain a second low-frequency input signal.
  • FIG. 13 is a schematic diagram of another loudspeaker system frame provided by an embodiment of the present application.
  • the loudspeaker system further includes a phase compensation unit on the basis of the loudspeaker system shown in FIG. 11 .
  • the phase compensation unit executes the process of step 411 to perform linear phase compensation on the first low-frequency input signal.
  • the electronic device may perform the above-mentioned step 411 before performing envelope modulation on the first low-frequency input signal (step 403), that is, the electronic device performs auxiliary enhanced first low-frequency input signal phase compensation.
  • the electronic device may execute Step 410 is specifically determined according to the actual situation, which is not limited in this embodiment of the present application.
  • the electronic device has completed the transient enhancement processing of the input signal of the speaker, which can improve the low-frequency loudness of the speaker, adjust the dynamic change of the speaker, and improve the sound quality of the speaker.
  • the electronic device may also process the initial signal to be played by the speaker to obtain an input signal for transient enhancement processing.
  • the method for improving the sound quality of a speaker provided by the embodiment of the present application further includes steps 1401 to 1402 .
  • Step 1401. The electronic device equalizes the first signal to obtain a second signal.
  • the first signal is an initial signal to be played input to the speaker.
  • the initial signal to be played by the speaker may be an audio signal collected by the electronic device, or may be an audio signal received by the electronic device from other devices, which is not specifically limited in this embodiment of the present application.
  • the above specific method of equalizing the first signal may be: using a biquard filter to equalize the first signal, which can improve the low-frequency frequency response of the speaker.
  • a biquard filter to equalize the first signal, which can improve the low-frequency frequency response of the speaker.
  • Step 1402 the electronic device processes the second signal by using a bass enhancement algorithm to obtain an input signal of the loudspeaker.
  • using the bass enhancement algorithm to process the second signal specifically uses a low-frequency shelving filter to filter the second signal to enhance the low-frequency loudness of the second signal (also called low-frequency sense of volume).
  • the above step 1402 includes step 1402a to step 1402b.
  • Step 1402a the electronic device determines the gain of the low-frequency shelving filter according to the energy of the low-frequency signal in the second signal.
  • the low frequency shelving filter is used to control the loudness of low frequency signals in the second signal.
  • the electronic device performs low-pass filtering on the second signal to obtain the low-frequency signal in the second signal; then, the electronic device calculates the The ratio of the energy of each point (value) to the total energy of the second signal is to calculate the energy ratio of the low-frequency signal.
  • the gain of the low-frequency shelf filter is determined according to the energy proportion of the low-frequency signal. Specifically, the basic gain of the low-frequency shelving filter is determined first, and then the basic gain is smoothed to obtain the gain of the low-frequency shelving filter.
  • the smoothing formula for the gain of the low frequency shelving filter is:
  • G_current G s *a+(1-a)*G_before
  • G_current represents the gain of the low-frequency shelf filter corresponding to the current frame
  • a is the smoothing coefficient of the filter gain
  • G_before is the filter gain of the previous frame of the current frame
  • G s represents the basic gain of the low-frequency shelf filter.
  • the method for determining the basic gain of the above-mentioned low-frequency shelf filter includes:
  • G s target
  • targetG is a preset gain
  • G s targetG-S*(ratio-rth1), where S is the gain smoothing coefficient, ratio is the energy proportion of the low-frequency signal, and rth1 is first threshold.
  • G s gth*targetG, where gth is a gain coefficient.
  • Step 1402b the electronic device uses a low-frequency shelving filter to filter the second signal to obtain an input signal of the speaker.
  • FIG. 16 is a schematic framework diagram of another speaker system provided by an embodiment of the present application.
  • the speaker system includes a determination unit, a gain update unit, and a filter unit, and the determination unit is used to determine the energy of the low-frequency signal in the second signal.
  • the gain update unit is used to determine the gain of the low-frequency shelf filter according to the energy ratio of the low-frequency signal in the second signal
  • the filter unit is used to filter the second signal
  • the filtered signal is used as a transient enhancement process
  • the input signal of that is, the input signal of the loudspeaker in step 401 above).
  • the loudness of the low-frequency signal with different energies is differentiated to different degrees, that is, different gains are set for the low-frequency signal according to the energy of the low-frequency signal.
  • step 1402 according to the characteristics of the energy of the low-frequency signal of the second signal, dynamically and adaptively increase the loudness of the low-frequency signal in the second signal, so that the clarity of the low-frequency signal can be improved.
  • the electronic device may further process the output signal to further improve the bass sound quality of the small speaker.
  • the output signal obtained after the processing in step 404 is collectively referred to as the first output signal.
  • the method for improving the sound quality of the speaker may further include: performing virtual bass processing on the first output signal to obtain a virtual bass output signal.
  • virtual bass processing is a method based on psychoacoustics to improve bass sound effects. Measured from the perspective of psychoacoustics, the psychologically perceived low-frequency loudness of the output signal (ie, the virtual bass output signal) processed by the virtual bass is Greater than the psychologically perceived low frequency loudness of the first output signal.
  • the psycho-perceived low-frequency loudness may be determined according to a psycho-acoustic model.
  • the method for performing virtual bass processing on the first output signal to obtain virtual bass output may include steps 1701 to 1705 .
  • Step 1701. The electronic device performs frequency division processing on the first output signal to obtain a first low-frequency output signal and a first high-frequency output signal.
  • the first low-frequency output signal includes a signal of the first output signal lower than the third preset frequency point
  • the first high-frequency output signal includes a signal of the first output signal higher than the third preset frequency point
  • the third preset frequency point may be a frequency point in the range of 100-400 Hz, for example, the third preset frequency point may be 100, 150, 250, 300 or 400 Hz and so on.
  • the signal at the third preset frequency point can be included in the first low-frequency output signal, can also be included in the first high-frequency output signal, or can also be included in both the first low-frequency output signal and the first
  • the high-frequency output signal is not limited in this embodiment of the present application.
  • Step 1702 the electronic device generates a harmonic signal of the first low-frequency output signal according to the first low-frequency output signal.
  • Signal_out cos(Coeff d ⁇ Signal_in)-b f ⁇ Signal_in
  • Coeff d a f ⁇ (0.5 ⁇ -0.8)+0.8
  • a f and b f are input coefficients, 0 ⁇ a f ⁇ 1, 0 ⁇ b f ⁇ 1, and Signal_in is the first low-frequency output signal.
  • a f is used to adjust the ratio of the amplitude of the harmonic signal of different frequencies
  • b f is used to adjust the total energy of the harmonic signal and the first low-frequency output signal (the first low-frequency output signal can also be called the fundamental wave signal) The ratio between the total energy.
  • the number of harmonic signals generating the first low-frequency output signal and the frequency of the harmonics can be determined according to actual needs, for example, three harmonics of the first low-frequency output signal can be generated, and the frequencies of the harmonics are 3f, 5f, 7f, f are the original frequencies of the first low-frequency output signal.
  • Step 1703. The electronic device mixes the harmonic signal of the first low-frequency output signal with the first low-frequency output signal to obtain a first mixed signal.
  • the harmonic signal of the first low-frequency output signal and the first low-frequency output signal may be mixed according to a certain ratio.
  • the electronic device can generate a harmonic signal according to the normalized first low-frequency output signal, and then combine the generated harmonic signal with the normalized first The low frequency output signal is mixed.
  • Step 1704 the electronic device performs phase synchronization processing on the first mixed signal and the first high-frequency output signal to obtain the second mixed signal and the second high-frequency output signal, and the phase change of the second mixed signal is the same as the second highest The amount of change in the phase of the frequency output signal is equal.
  • Step 1705 the electronic device obtains a virtual bass output signal according to the second mixed signal and the second high frequency output signal.
  • the electronic device may perform band-pass filtering on the first mixed signal to filter out possible high-frequency signals and low-frequency signals in the first mixed signal. clutter components, and detect the maximum amplitude of the filtered first mixed signal, and then restore the first mixed signal according to the maximum amplitude (that is, the inverse process of the above-mentioned normalization), and obtain the restored first mixed signal. Further, the electronic device performs low-pass filtering on the restored first mixed signal to filter high-frequency noise to obtain the denoised first mixed signal, and finally uses an all-pass filter to filter the denoised first mixed signal and the first mixed signal.
  • the high-frequency output signal is phase-synchronized to obtain a virtual bass output signal.
  • Fig. 18 shows a frame of a loudspeaker system provided by an embodiment of the present application.
  • the speaker system includes a frequency division unit, a harmonic generation unit, a signal mixing unit, and a phase synchronization unit.
  • the frequency division unit divides the frequency of the first output signal
  • the harmonic generation unit generates the frequency-divided first
  • the signal mixing unit mixes the harmonic signal with the first low-frequency output signal to obtain a first mixed signal
  • the phase synchronization unit performs phase synchronization on the first mixed signal and the first high-frequency signal to obtain A second mixed signal and a second high frequency output signal are obtained, and a virtual bass output signal is obtained according to the second mixed signal and the second high frequency output signal.
  • the electronic device may continue to process the virtual bass output signal (displacement control), so as to protect the diaphragm displacement of the speaker from exceeding The displacement protection threshold of the speaker.
  • the virtual bass output signal is collectively referred to as the second output signal.
  • the method for improving the sound quality of the speaker provided by the embodiment of the present application may further include steps 1901 to 1903 .
  • Step 1901 the electronic device acquires a first displacement prediction model including one or more correction coefficients, where the correction coefficients are used to control the output of the first displacement prediction model.
  • the first displacement prediction model is used to simulate the performance of the speaker to predict the displacement of the diaphragm of the speaker, and the one or more correction coefficients are used to control the output of the first displacement prediction model.
  • the first displacement prediction model may satisfy the following expression:
  • f s is the sampling rate
  • ⁇ , ⁇ , ⁇ , and ⁇ are correction coefficients
  • can be used to adjust the low-frequency output of the displacement prediction model
  • is used to adjust the output of the frequency range of the displacement prediction model including the resonance frequency of the loudspeaker
  • It is used to adjust the intermediate frequency output of the displacement prediction model
  • is used to adjust the full frequency band output of the displacement prediction model.
  • spk.Bl is the magnetic force coefficient of the speaker in the initial parameters
  • spk.Kms is the stiffness coefficient of the speaker in the initial parameters
  • spk.Rms is the power of the speaker in the initial parameters.
  • ax, bx are the coefficients of the generated IIR filter.
  • the expression of the first displacement prediction model, the number of correction coefficients included in the first displacement prediction model, and the content controlled by each correction coefficient can be configured according to actual needs. be specifically limited.
  • the content of the first displacement prediction model is different, which may include but not limited to the following situations:
  • the correction factor in the initial model can be 1.
  • the displacement prediction model may also include initial parameters, which are parameters related to loudspeaker hardware characteristics in the displacement prediction model.
  • initial parameters are parameters related to loudspeaker hardware characteristics in the displacement prediction model.
  • it may further include: acquiring an impedance curve of the loudspeaker, and determining initial parameters of the shift prediction model according to the impedance curve.
  • the initial parameters are parameters related to the speaker hardware characteristics in the displacement prediction model.
  • the initial parameters may be the magnetic coefficient spk.Bl of the loudspeaker, the stiffness coefficient spk.Kms of the loudspeaker, and the power spk.Rms of the loudspeaker.
  • the impedance curve of the loudspeaker is obtained, and the initial parameters of the shift prediction model are determined according to the impedance curve, including: inputting a preset input signal into the loudspeaker, and collecting the voltage and current of the loudspeaker; determining the impedance curve of the loudspeaker according to the voltage and current; The impedance curve is determined by curve fitting or parameter identification to determine the initial parameters of the shift prediction model.
  • the preset input signal may be a specific noise signal or other signals, which is not limited.
  • the voltage and the corresponding current signal of the loudspeaker within a period of time may be collected, Fourier transform is performed, and the impedance curve is obtained by dividing the voltage spectrum by the current spectrum.
  • the first displacement prediction model may be the displacement prediction model stored in the electronic device for predicting the displacement of the speaker diaphragm when step 1901 is performed.
  • the first displacement prediction model configured in the electronic device may be a displacement prediction model obtained after correction in case 1 or case 2.
  • Step 1902 the electronic device adjusts at least one correction coefficient in the first displacement prediction model to obtain a second displacement prediction model, the absolute value of the difference between the predicted displacement output by the second displacement prediction model and the actual displacement of the diaphragm of the loudspeaker, less than the absolute value of the difference between the predicted displacement output by the first displacement prediction model and the actual displacement of the diaphragm of the loudspeaker.
  • the actual displacement of the diaphragm of the speaker is an actual measured value of the moving distance of the diaphragm of the speaker relative to the initial position.
  • the second displacement prediction model is obtained by adjusting the correction coefficient of the first displacement prediction model, and the expression of the second displacement prediction model is the same as the expression of the first displacement prediction model.
  • the actual displacement of the loudspeaker can be obtained through measurement, and then the correction coefficient in the first displacement prediction model is repeatedly adjusted according to the correction coefficient adjustment rule to obtain the second displacement prediction model.
  • a laser may be used to measure the actual displacement of the diaphragm of the speaker, or other methods may be used to measure the actual displacement of the diaphragm of the speaker, which is not limited in this embodiment of the present application.
  • correction coefficient adjustment rule may be configured according to actual requirements, which is not specifically limited in this embodiment of the present application.
  • the correction coefficient adjustment rule may be: configure an adjustment step for each correction coefficient, adjust each correction coefficient according to the adjustment step in turn according to the preset correction coefficient adjustment order, until the second displacement prediction model is obtained.
  • the correction coefficient adjustment rule may be: compare the predicted displacement output by the first displacement prediction model with the actual displacement of the diaphragm when the speaker plays the input signal input to the first displacement prediction model, and find the predicted displacement according to the size relationship between the two. A corresponding relationship is established, and the content of the adjusted correction coefficient and the adjusted value are obtained.
  • the predicted corresponding relationship stores different size relationships between predicted displacements and actual displacements, and correction coefficients and adjustment values that need to be adjusted corresponding to different size relationships.
  • Step 1903 the electronic device controls the gain of the second output signal according to the protection threshold of the speaker's displacement and the predicted displacement output by the second displacement prediction model, so that the displacement of the diaphragm when the speaker plays the second output signal is less than or equal to the protection threshold of displacement.
  • the displacement protection threshold of the speaker is the maximum displacement of the diaphragm of the speaker.
  • the electronic device when the predicted displacement is greater than or equal to the displacement protection threshold, the electronic device attenuates the second output signal as a whole, so that the diaphragm displacement of the speaker playing the second output signal is less than or equal to the displacement protection threshold of the speaker. threshold.
  • the displacement of the loudspeaker when the predicted displacement is greater than or equal to the displacement protection threshold, the low-frequency signal in the second output signal can be suppressed by means of a high-pass filter.
  • the middle and high frequency signals are used to control the gain of the second output signal of the loudspeaker to reduce the displacement of the loudspeaker while ensuring the loudness of the loudspeaker.
  • the electronic device determines the frequency parameter of the high-pass filter according to the predicted displacement output by the second displacement prediction model, and then uses the high-pass filter to filter the above-mentioned second output signal, so that the displacement of the diaphragm of the speaker playing the second output signal is less than or Equal to the displacement protection threshold of the loudspeaker.
  • the specific method for the electronic device to determine the frequency parameter of the high-pass filter according to the predicted displacement output by the second displacement prediction model is: the electronic device uses n sets of frequency parameters to filter the predicted displacement output by the second displacement prediction model; Select two groups of frequency parameters whose filter output value is located on both sides of the displacement protection threshold and whose absolute value of the difference with the displacement protection threshold is the smallest; in the frequency parameter interval including the two groups of frequency parameters, select the first frequency parameter as the high-pass filter The frequency parameter of the device.
  • the pass bands of n groups of frequency parameters are different; n is greater than 2.
  • the specific values of the n groups of frequency parameters may be configured according to actual application experience, which will not be repeated in this embodiment of the present application.
  • the first frequency parameter is selected, which may be the passband of the high-pass filter indicated by the first frequency parameter, and the high-pass filter indicated by the frequency parameters of the two groups of frequency parameters. between the channels of the device.
  • selecting the first frequency parameter in the frequency parameter interval including the two groups of frequency parameters may be implemented as: selecting the two groups of frequency parameters in the frequency parameter interval including the two groups of frequency parameters The intermediate value of is used as the first frequency parameter.
  • the middle value of the two groups of frequency parameters is selected as the first frequency parameter, which can be specifically implemented as: selecting the average value of the center frequencies of the two groups of frequency parameters , as the center frequency of the first frequency parameter, the first frequency parameter is obtained.
  • the average value of the starting frequencies of the two groups of frequency parameters is selected as the starting frequency of the first frequency parameter to obtain the first frequency parameter.
  • the average value of the cutoff frequency of the two groups of frequency parameters is selected as the cutoff frequency of the first frequency parameter to obtain the first frequency parameter.
  • selecting the first frequency parameter within the frequency parameter interval including the two groups of frequency parameters can be implemented as: performing interpolation between the two groups of frequency parameters to obtain multiple groups of frequency parameters to be selected ; Select the candidate frequency parameter with the smallest absolute value of the difference between the filter output value of the predicted displacement output by the second displacement prediction model and the displacement protection threshold among multiple groups of frequency parameters to be selected as the first frequency parameter.
  • the interpolation between the two groups of frequency parameters may be implemented as: interpolating the center frequencies of the two groups of frequency parameters, or, interpolating the starting frequencies of the two groups of frequency parameters, or, interpolating the two groups of frequency parameters The cutoff frequency for parameter interpolation.
  • a preset number of values may be interpolated, or interpolated according to a preset frequency interval, or may be interpolated in other ways. This is not specifically limited.
  • the interpolation when performing interpolation between the two groups of frequency parameters, can be repeated until the difference between the filtered output value of the predicted displacement output by the second displacement prediction model and the displacement protection threshold is equal to The candidate frequency parameter of is used as the first frequency parameter.
  • the above-mentioned second displacement prediction model more truly reflects the characteristics of the loudspeaker, ensures that the predicted displacement of the output is more accurate, and then can carry out more accurate displacement protection, which also realizes the protection of the displacement of the speaker diaphragm. , to maximize the hardware potential of the speaker and increase the loudness of the speaker.
  • the electronic device can also correct the above-mentioned high-pass filter for filtering the second output signal according to the temperature.
  • the frequency parameter ensures that the control of the second output signal conforms to the current characteristics of the speaker, thereby ensuring the improvement of the loudness of the speaker.
  • the electronic device determines the real-time temperature of the speaker according to the impedance of the speaker.
  • the real-time temperature T of the speaker can satisfy the following expression: ⁇ is the temperature rise coefficient, Re is the impedance of the speaker, Re 0 is the impedance of the speaker at room temperature, and T 0 is the preset room temperature. ⁇ and Re are the inherent parameters of the speaker.
  • the electronic device determines the frequency correction coefficient according to the real-time temperature of the speaker.
  • the frequency correction coefficient Coeff satisfies the following expression:
  • the frequency correction coefficient Coeff satisfies the following expression.
  • the parameters in the expression are preset values.
  • T hot is the temperature threshold of the hot state
  • T cold is the temperature threshold of the cold state
  • Coeff 0 is the initial frequency correction coefficient.
  • the embodiment of the present application does not limit the specific value of the preset value.
  • the frequency correction coefficient Coeff is a frequency offset, or a passband offset.
  • the electronic device corrects the filtered frequency parameter according to the frequency correction coefficient, and filters the second output signal with the corrected frequency parameter.
  • Correcting the filtered frequency parameter according to the frequency correction coefficient refers to shifting the value of the frequency correction coefficient to the channel of the high-pass filter indicated by the filtered frequency parameter to obtain the corrected frequency parameter.
  • Fig. 20 shows a framework of a loudspeaker system provided by an embodiment of the present application.
  • the loudspeaker system includes a displacement prediction model (the second displacement prediction model after adjusting the correction parameters), a gain control unit, a determination unit, a power amplifier unit (amplifier), a temperature calculation unit and a temperature correction unit.
  • the second output signal is input to the displacement prediction model, and the predicted displacement is output.
  • the determination unit determines the frequency parameter of the high-pass filter, and the gain control unit controls the gain of the second output signal and then inputs it into the power amplifier unit; after the power amplifier unit converts the digital signal into an analog signal, input The speaker plays.
  • the temperature calculation unit calculates the real-time temperature of the loudspeaker, the temperature correction unit determines the frequency correction coefficient and inputs it into the gain control unit, and the gain control unit corrects the filtered frequency parameters, and the corrected frequency parameters are used to control the gain of the second output signal.
  • the electronic device performs gain control on the second output signal of the speaker by performing the above steps 1901 to 1903 to protect the displacement of the speaker.
  • the signal continues to be processed to reduce signal distortion, thereby further improving the sound quality of the speaker.
  • the output signal obtained after the processing in step 1903 is collectively referred to as the third output signal.
  • the method for improving the sound quality of a speaker may further include steps 2101 to 2102 .
  • Step 2101 the electronic device adjusts the nonlinear parameters of the first nonlinear compensation model pre-configured in the speaker according to the coil temperature of the speaker, so as to obtain the second nonlinear compensation model.
  • the nonlinear compensation model of the loudspeaker corresponds to multiple nonlinear parameters, and determining the nonlinear compensation model of the loudspeaker means obtaining the nonlinear parameters of the loudspeaker.
  • the speaker's nonlinear parameter includes at least one of the speaker's force factor BL, mechanical stiffness Kms, inductance Le, and damping Rm.
  • the nonlinear parameters of the nonlinear compensation model preconfigured in the loudspeaker are called first nonlinear parameters, and the obtained nonlinear parameters of the second nonlinear compensation model of the loudspeaker are called second nonlinear parameters.
  • the coil temperature of the speaker can be determined according to the DC resistance of the speaker, and the relationship between the coil temperature of the speaker (also referred to as the voice coil temperature) and the DC resistance of the coil of the speaker is as follows:
  • T is the coil temperature of the speaker (same as the real-time temperature of the above-mentioned speaker)
  • R is the DC resistance of the speaker coil
  • is the temperature rise coefficient
  • R0 is the DC resistance of the coil corresponding to the calibration temperature, usually at 25 degrees Celsius Calibrate for voice coil temperature.
  • the method for the electronic device to adjust the nonlinear parameters of the pre-configured nonlinear compensation model in the speaker according to the coil temperature of the speaker specifically includes: adjusting the pre-configured nonlinear parameters (that is, the first nonlinear parameter) according to the coil temperature of the speaker. parameter) to interpolate to obtain the second nonlinear parameter of the loudspeaker.
  • the characteristic curve of the Kms is a curve reflecting the relationship between the stiffness coefficient of the loudspeaker and the displacement of the loudspeaker, for example, at 5 degrees Celsius
  • 10 characteristic curves of the Kms from 10 degrees Celsius to 55 degrees Celsius are obtained, and the data of the 10 characteristic curves are stored.
  • the characteristic curve of the nonlinear parameter Kms(x) is linearly interpolated to obtain the target characteristic curve (the target characteristic curve can be understood as the third nonlinear parameter Estimated result of the characteristic curve).
  • the temperature threshold 2 is greater than the temperature threshold 1, and the third nonlinear parameter can be understood as a nonlinear parameter corresponding to the current coil temperature of the loudspeaker.
  • the temperature of the coil of the loudspeaker is marked as T
  • the temperature threshold 1 is marked as T min
  • the temperature threshold 2 is marked as T max , then:
  • T ⁇ T min take the characteristic curve corresponding to T min as the target characteristic curve.
  • T min ⁇ T ⁇ T max perform linear interpolation on the characteristic curve corresponding to T min and the characteristic curve corresponding to T max according to the coil temperature of the loudspeaker to generate the target characteristic curve.
  • the coefficient a 1 corresponds to the first-order coefficient of the nonlinear parameter Kms
  • the coefficient a 2 corresponds to the second-order coefficient of the nonlinear parameter Kms
  • the coefficient a 2 corresponds to the third-order coefficient of the nonlinear parameter Kms
  • the coefficient a 4 corresponds to the nonlinear parameter Kms fourth-order coefficients.
  • the characteristic curve of the nonlinear parameter may be data in tabular form, or data or files in other forms, which is not limited in this embodiment of the present application.
  • the nonlinear parameters of the speaker may change in real time.
  • the nonlinear parameters change with the change of the voice coil temperature of the speaker.
  • the first nonlinear parameter of the speaker according to the current temperature of the speaker, the first nonlinear parameter of the speaker By interpolating the parameters, the nonlinear parameters of the loudspeaker can be adjusted in real time to obtain the second nonlinear parameters, and the accuracy of the second nonlinear parameters is relatively high.
  • nonlinear parameters of the speaker may also change with the change of the displacement of the speaker.
  • a similar linear interpolation method can be used to determine the displacement of the speaker according to the DC resistance of the speaker, and then according to the displacement of the speaker Displacement, the first nonlinear parameter of the speaker is interpolated to obtain the second nonlinear parameter of the speaker, so as to obtain the nonlinear model of the speaker.
  • Step 2102 the electronic device uses the second nonlinear model to perform signal compensation on the output signal.
  • the method for improving the sound quality of the speaker provided in the embodiment of the present application further includes: filtering the compensated third output signal.
  • the notch filter can be used to filter the compensated third output signal, and the velocity of the speaker diaphragm near the resonance frequency can be adjusted, thereby reducing the distortion of the output signal and effectively improving the sound quality of the speaker.
  • a series of processing can be performed on the audio signal to be played by the speaker, such as equalization processing, bass enhancement, transient enhancement, virtual bass processing, displacement control, and nonlinear compensation in sequence.
  • equalization processing bass enhancement, transient enhancement, virtual bass processing, displacement control, and nonlinear compensation in sequence.
  • bass enhancement transient enhancement
  • virtual bass processing displacement control
  • nonlinear compensation nonlinear compensation
  • FIG. 22 shows a schematic framework diagram of a speaker system provided by an embodiment of the present application.
  • the speaker system may include an equalization processing module, a bass enhancement module, a transient enhancement module, a virtual bass module, The displacement control module and the nonlinear compensation module, the equalization processing module is used to perform the above step 1401, the bass enhancement module is used to perform the above step 1402, the transient enhancement module is used to perform the above steps 401 to 404, and the virtual bass module is used to perform the above steps From step 1701 to step 1705, the displacement control module is used to execute steps 1901 to 1903, and the nonlinear compensation module is used to execute steps 2101 to 2102 above.
  • the embodiment of the present application provides an electronic device, which can divide the electronic device into functional modules according to the above method example, for example, each functional module can be divided corresponding to each function, or two or more functions can be integrated in a processing module.
  • the above-mentioned integrated modules can be implemented in the form of hardware or in the form of software function modules. It should be noted that the division of modules in the embodiment of the present invention is schematic, and is only a logical function division, and there may be another division manner in actual implementation.
  • FIG. 23 shows a possible structural schematic diagram of the electronic device involved in the above embodiment.
  • the electronic device includes a first acquisition module 2301 , a first determination module 2302 , an envelope modulation module 2303 and a second determination module 2304 .
  • the first acquisition module 2301 is configured to divide the frequency of the input signal of the speaker to obtain the first low-frequency input signal and the first high-frequency input signal, the input signal of the speaker is a time-domain signal, and the first low-frequency input signal includes the input signal For signals lower than the first preset frequency point, the first high-frequency input signal includes a signal higher than the first preset frequency point in the input signal, for example, perform step 401 in the above method embodiment.
  • the first determining module 2032 is configured to perform transient detection on the first low-frequency input signal to determine whether the first low-frequency input signal is a transient signal, for example, perform step 402 (including step 4021 to step 4023) in the above method embodiment .
  • the envelope modulation module 2303 is used to perform signal envelope modulation on the first low-frequency input signal when the first low-frequency input signal is a transient signal, so as to obtain a second low-frequency input signal; start-up of the second low-frequency input signal
  • the voltage is greater than the start-up voltage of the first low-frequency input signal, and the loudness of the second low-frequency input signal is greater than the loudness of the first low-frequency input signal.
  • step 403 in the above method embodiment is performed.
  • the second determining module 2304 is configured to determine the output signal of the loudspeaker according to the second low-frequency input signal and the first high-frequency input signal, for example, execute step 404 in the above method embodiment.
  • the above-mentioned first obtaining module 2301 is further configured to divide the frequency of the first high-frequency input signal of the speaker to obtain the first intermediate-frequency input signal and the second high-frequency input signal, where the first intermediate-frequency input signal includes the first Signals in the high-frequency input signal that are lower than the second preset frequency point, the second high-frequency input signal includes signals that are higher than the second preset frequency point in the first high-frequency input signal, and the second preset frequency point is higher than the second preset frequency point A preset frequency point, for example, execute step 405 in the above method embodiment.
  • the first determining module 2302 is further configured to perform transient detection on the first intermediate frequency input signal to determine whether the first intermediate frequency input signal is a transient signal, for example, execute step 406 in the above method embodiment.
  • the envelope modulation module 2303 is also used to perform signal envelope modulation on the first intermediate frequency input signal when the first intermediate frequency input signal is a transient signal, so as to obtain the second intermediate frequency input signal; the start-up of the second intermediate frequency input signal
  • the voltage is greater than the start-up voltage of the first IF input signal, and the loudness of the second IF input signal is greater than the loudness of the first IF input signal.
  • step 407 in the above method embodiment is performed.
  • the second determining module 2304 is specifically configured to obtain the output signal of the speaker according to the second low-frequency input signal, the second intermediate-frequency input signal and the second high-frequency input signal, for example, perform step 408 in the above method embodiment.
  • the electronic device provided in this embodiment of the present application further includes a generation module 2305 and a second acquisition module 2306 .
  • the generating module 2305 is configured to generate a low-frequency auxiliary signal, for example, execute step 409 in the above method embodiment.
  • the second obtaining module 2306 is configured to add a low-frequency auxiliary signal to the first low-frequency input signal to obtain a first auxiliary enhanced signal, for example, perform step 410 in the above method embodiment.
  • the envelope modulation module 2303 is specifically configured to perform signal envelope modulation on the first auxiliary enhanced signal to obtain the second low-frequency input signal, for example, perform step 4031 in the above method embodiment.
  • the electronic device provided in this embodiment of the present application further includes a phase compensation module 2307, which is configured to perform phase compensation on the first low-frequency input signal to obtain a first phase compensation signal, for example, to execute the above method embodiment Step 411 in .
  • the envelope modulation module 2303 is specifically configured to perform signal envelope modulation on the first phase compensation signal to obtain a second low-frequency input signal, for example, perform step 4032 in the above method embodiment.
  • the electronic device provided in this embodiment of the present application further includes an equalization processing module 2308 and a bass enhancement module 2309 .
  • the equalization processing module 2308 is configured to perform equalization processing on the first signal to obtain a second signal.
  • the first signal is an initial signal to be played input to the speaker, for example, performing step 1401 in the above method embodiment.
  • the bass enhancement module 2309 is configured to process the second signal with a bass enhancement algorithm to obtain the input signal of the speaker, for example, execute step 1402 (including step 1402a to step 1402b) in the above method embodiment.
  • the electronic device provided in the embodiment of the present application further includes a third acquisition module 2310 , a first adjustment module 2311 and a control module 2312 .
  • the third acquisition module 2310 is used to acquire a first displacement prediction model including one or more correction coefficients
  • the first displacement prediction model is used to simulate the performance of the speaker to predict the displacement of the diaphragm of the speaker
  • the one or more correction coefficients are used for Control the output of the first displacement prediction model, for example, execute step 1901 in the above method embodiment.
  • the first adjustment module 2311 is used to adjust at least one correction coefficient in the first displacement prediction model to obtain a second displacement prediction model; the absolute value of the difference between the predicted displacement output by the second displacement prediction model and the actual displacement of the diaphragm is less than The absolute value of the difference between the predicted displacement output by the first displacement prediction model and the actual displacement of the diaphragm of the loudspeaker; the actual displacement of the diaphragm of the loudspeaker is the actual measured value of the moving distance of the diaphragm of the loudspeaker relative to the initial position, such as performing the above method Step 1902 in an embodiment.
  • the control module 2312 is used to control the gain of the output signal according to the displacement protection threshold of the loudspeaker and the predicted displacement output by the second displacement prediction model, so that the diaphragm displacement when the loudspeaker plays the output signal is less than or equal to the displacement protection threshold;
  • the displacement protection threshold is For the maximum displacement of the diaphragm of the loudspeaker, for example, perform step 1903 in the above method embodiment.
  • the electronic device provided in the embodiment of the present application further includes a virtual bass processing module 2313, and the virtual bass processing module 2313 is configured to perform virtual bass processing on the output signal of the speaker to obtain a virtual bass output signal, and the virtual bass output signal
  • the psychologically perceived low-frequency loudness of the loudspeaker is greater than the psychologically perceived low-frequency loudness of the output signal of the speaker, for example, performing steps 1701 to 1705 in the above method embodiment.
  • the electronic device provided in this embodiment of the present application further includes a second adjustment module 2314 and a signal compensation module 2315 .
  • the second adjustment module 2314 is used to adjust the nonlinear parameters of the first nonlinear compensation model pre-configured in the speaker according to the coil temperature of the speaker to obtain the second nonlinear compensation model, for example, perform step 2101 in the above method embodiment.
  • the signal compensation module 2315 is configured to use the second nonlinear compensation model to perform signal compensation on the output signal, for example, perform step 2102 in the above method embodiment.
  • Each module of the above-mentioned electronic device can also be used to perform other actions in the above-mentioned method embodiment, and all relevant content of each step involved in the above-mentioned method embodiment can be referred to the function description of the corresponding functional module, and will not be repeated here.
  • FIG. 24 shows another possible structural diagram of the electronic device involved in the above embodiment.
  • the electronic device provided in this embodiment of the present application may include: a processing module 2401 and a communication module 2402 .
  • the processing module 2401 can be used to control and manage the actions of the electronic device.
  • the processing module 2401 can be used to support the electronic device to execute steps 401 to 411, steps 1701 to 1705, and steps 1901 to 1901 in the above method embodiments. Step 1903, Step 2101 - Step 2102, and/or other processes for the techniques described herein.
  • the communication module 2402 may be used to support communication between the electronic device and other network entities.
  • the electronic device may further include a storage module 2403, configured to store program codes and data of the device.
  • the processing module 2001 may be a processor or a controller (such as the above-mentioned processor 310 shown in FIG. 3 ), such as a central processing unit (central processing unit, CPU), a general purpose processor, a digital signal processor (digital signal processor, DSP), application-specific integrated circuit (ASIC), field programmable gate array (field programmable gate array, FPGA) or other programmable logic devices, transistor logic devices, hardware components or any of them combination. It can implement or execute various exemplary logical blocks, modules and circuits described in conjunction with the disclosure of the embodiments of the present invention.
  • the above-mentioned processors may also be a combination of computing functions, for example, a combination of one or more microprocessors, a combination of DSP and a microprocessor, and so on.
  • the communication module 2402 may be a transceiver, a transceiver circuit, or a communication interface (for example, it may be the mobile communication module 350 or the wireless communication module 360 shown in FIG. 3 ).
  • the storage module 2403 may be a memory (for example, it may be the aforementioned internal memory 321 shown in FIG. 1 ).
  • the processing module 2401 is a processor
  • the communication module 2402 is a transceiver
  • the storage module 2403 is a memory
  • the processor, the transceiver, and the memory may be connected through a bus.
  • the bus may be a peripheral component interconnect standard (peripheral component interconnect, PCI) bus or an extended industry standard architecture (extended Industry standard architecture, EISA) bus or the like.
  • PCI peripheral component interconnect
  • EISA Extended Industry standard architecture
  • all or part of them may be implemented by software, hardware, firmware or any combination thereof.
  • a software program it may be implemented in whole or in part in the form of a computer program product.
  • the computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on the computer, all or part of the processes or functions according to the embodiments of the present application will be generated.
  • the computer can be a general purpose computer, special purpose computer, computer network, or other programmable device.
  • the computer instructions may be stored in or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transferred from a website, computer, server, or data center by wire (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, microwave, etc.) to another website site, computer, server or data center.
  • the computer-readable storage medium may be any available medium that can be accessed by a computer or may be a data storage device such as a server, a data center, etc. integrated with one or more available media.
  • the available medium may be a magnetic medium (for example, a floppy disk, a magnetic disk, a magnetic tape), an optical medium (for example, a digital video disc (digital video disc, DVD)), or a semiconductor medium (for example, a solid state drive (solid state drives, SSD)), etc. .
  • a magnetic medium for example, a floppy disk, a magnetic disk, a magnetic tape
  • an optical medium for example, a digital video disc (digital video disc, DVD)
  • a semiconductor medium for example, a solid state drive (solid state drives, SSD)
  • the disclosed system, device and method can be implemented in other ways.
  • the device embodiments described above are only illustrative.
  • the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods.
  • multiple units or components can be Incorporation may either be integrated into another system, or some features may be omitted, or not implemented.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit.
  • the above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.
  • the integrated unit is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a computer-readable storage medium.
  • the technical solution of the present application is essentially or part of the contribution to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium , including several instructions to make a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor execute all or part of the steps of the method described in each embodiment of the present application.
  • the aforementioned storage medium includes: flash memory, mobile hard disk, read-only memory, random access memory, magnetic disk or optical disk, and other various media capable of storing program codes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Acoustics & Sound (AREA)
  • Health & Medical Sciences (AREA)
  • Otolaryngology (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Computational Linguistics (AREA)
  • Quality & Reliability (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Human Computer Interaction (AREA)
  • Multimedia (AREA)
  • Tone Control, Compression And Expansion, Limiting Amplitude (AREA)
  • Circuit For Audible Band Transducer (AREA)

Abstract

本申请实施例提供一种提升扬声器的音质的方法及装置,涉及媒体技术领域,能够改善扬声器的低频音效,提升扬声器的音质。该方法包括:对扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号,该输入信号为时域信号;并且对第一低频输入信号进行瞬态检测,以确定第一低频输入信号是否为瞬态信号;若第一低频输入信号为瞬态信号,则对第一低频输入信号进行信号包络调制,以得到第二低频输入信号;进而根据第二低频输入信号和第一高频输入信号,确定扬声器的输出信号。其中,第二低频输入信号的起振电压大于第一低频输入信号的起振电压,且第二低频输入信号的响度大于第一低频输入信号的响度。

Description

一种提升扬声器的音质的方法及装置
本申请要求于2021年6月30日提交国家知识产权局、申请号为202110745517.3、发明名称为“一种提升扬声器的音质的方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请实施例涉及媒体技术领域,尤其涉及一种提升扬声器的音质的方法及装置。
背景技术
随着多媒体设备的小型化、轻便化发展,嵌入在这些多媒体设备中的扬声器的体积受到严格的限制,很多多媒体设备中的扬声器是小型扬声器,而小型扬声器的低频重放能力较差。
目前,多数扬声器播放的音频信号的中低频响度不足,使得扬声器播放音频信号时的音质较差。对于用户而言,音频信号中的中低频信号对听感起着重要的作用,直接影响用户的听觉感受,因此,如何改善小型扬声器的低频音效是急需解决的问题。
发明内容
本申请实施例提供一种提升扬声器的音质的方法及装置,能够改善扬声器的低频音效,提升扬声器的音质。
为达到上述目的,本申请实施例采用如下技术方案:
第一方面,本申请实施例提供一种提升扬声器的音质的方法,可以应用于具有音频播放功能的电子设备,该方法包括:电子设备对扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号,该扬声器的输入信号为时域信号,第一低频输入信号包括输入信号中低于第一预设频点的信号,第一高频输入信号包括输入信号中高于第一预设频点的信号;并且电子设备对第一低频输入信号进行瞬态检测,以确定第一低频输入信号是否为瞬态信号;若第一低频输入信号为瞬态信号,则对第一低频输入信号进行信号包络调制,以得到第二低频输入信号;进而电子设备根据第二低频输入信号和第一高频输入信号,确定扬声器的输出信号其中,第二低频输入信号的起振电压大于第一低频输入信号的起振电压,且第二低频输入信号的响度大于第一低频输入信号的响度。
本申请实施例提供的提升扬声器的音质的方法中,对输入信号中的低频信号进行瞬态检测,若输入信号是瞬态信号,则采用包络调制对瞬态信号进行增强,由于扬声器播放一段音频信号时,扬声器播放音频信号中的低频信号的音质关系扬声器的性能好坏,而低频信号中的瞬态信号通常反映音频信号的重要信息,因此对低频信号中的瞬态信号进行调制,提升低频瞬态信号的响度,并调节低频瞬态信号的动态范围,从而扬声器播放该处理后的音频信号时,音频信号的低频音效较好,即通过本申请实施例的技术方案能够提升扬声器的音质。
一种可能的实现方式中,本申请实施例提供的提升扬声器的音质的方法还包括:电子设备对扬声器的第一高频输入信号进行分频,以获取第一中频输入信号和第二高 频输入信号,该第一中频输入信号包括第一高频输入信号中低于第二预设频点的信号,第二高频输入信号包括第一高频输入信号中高于第二预设频点的信号,第二预设频点高于第一预设频点;并且电子设备对第一中频输入信号进行瞬态检测,以确定第一中频输入信号是否为瞬态信号;若第一中频输入信号为瞬态信号,则对第一中频输入信号进行信号包络调制,以得到第二中频输入信号,该第二中频输入信号的起振电压大于第一中频输入信号的起振电压,且第二中频输入信号的响度大于第一中频输入信号的响度。
上述根据第二低频输入信号和第一高频输入信号,确定扬声器的输出信号的方法具体包括:电子设备根据第二低频输入信号、第二中频输入信号以及第二高频输入信号,得到扬声器的输出信号。
本申请实施例中,对输入信号中的中频信号也进行瞬态检测,并对瞬态信号进行包络调制,对中频信号进行增强,总体上提升扬声器的音质。
一种可能的实现方式中,第一低频输入信号为瞬态信号,在对第一低频输入信号进行信号包络调制之前,本申请实施例提供的提升扬声器的音质的方法还包括:电子设备生成低频辅助信号;并且在第一低频输入信号中添加低频辅助信号,以获得第一辅助增强信号。
基于此,上述对第一低频输入信号进行信号包络调制,以得到第二低频输入信号的方法具体包括:对第一辅助增强信号进行信号包络调制,以得到第二低频输入信号。
本申请实施例中,上述第一低频输入信号为瞬态信号,且电子设备的扬声器是较小型的扬声器,其低频重放能力较弱的情况下,可以在第一低频输入信号中增加低频辅助信号,该低频辅助信号的作用是辅助增强上述第一低频输入信号的响度,优化第一低频输入信号的动态范围。
一种可能的实现方式中,上述生成低频辅助信号的方法包括:生成第一辅助信号,并且对第一辅助信号进行高通滤波,以得到低频辅助信号。第一辅助信号满足:signal_h=e -A×sin(2πf),其中,signal_h表示低频辅助信号,A表示信号幅度影响因子,f为扬声器的中心频率。其中,A的取值范围可以是10~50,具体的取值可以由系统推定或者由用户设置,例如可以是10,25,或50等等;f的取值范围可以是50~150Hz范围内的频率值,具体的取值可以由系统推定或者由用户设置,例如f的取值可以是50Hz,100Hz,或150Hz等等。
一种可能的实现方式中,第一低频输入信号为瞬态信号,在对第一低频输入信号进行信号包络调制之前,本申请实施例提供的提升扬声器的音质的方法还包括:电子设备对第一低频输入信号进行相位补偿,以获得第一相位补偿信号。
基于此,上述对第一低频输入信号进行信号包络调制,以得到第二低频输入信号的方法包括:电子设备对第一相位补偿信号进行信号包络调制,以得到第二低频输入信号。
本申请实施例中,在电子设备对输入信号进行分频以及辅助增强的过程中,可能对第一低频输入信号的相位造成影响,导致低频输入信号的相位产生偏差,不再是线 性相位,因此,对第一低频输入信号进行必要的线性相位补偿,将第一低频输入信号的相位校正为线性相位,从而保证低频音质。
一种可能的实现方式中,上述对第一低频输入信号进行瞬态检测,确定第一低频输入信号是否瞬态信号的方法具体包括:电子设备确定第一低频输入信号的瞬态功率和稳态功率;并且根据第一低频输入信号的瞬态功率和稳态功率确定第一低频输入信号的瞬时率;若输入信号的瞬态率大于预设的瞬态率阈值,则确定第一低频输入信号为瞬态信号。其中,第一低频输入信号的瞬时率满足:T r=(R r-1) 2×W,其中,T r表示第一低频输入信号的瞬时率,R r表示第一低频输入信号的瞬态功率与第一低频输入信号的稳态功率的比值,W表示计权因子,W的取值与第一低频输入信号的当前功率相同。
本申请实施例中,该第一低频输入信号的功率是该第一低频输入信号所包含的所有数据点的电压值的平方和再求平均值;第一低频输入信号的瞬态功率可以为当前帧之前的连续n1个信号帧的平均功率,第一低频输入信号的稳态功率可以是当前帧之前的连续n2个信号帧的平均功率。
在一些实现方式中,为了避免小信号误检,可以对一些小信号进行掩蔽,具体的,设置一个掩蔽阈值,当第一低频输入信号的功率小于掩蔽阈值时,取掩蔽阈值作为第一低频输入信号的功率。即,P d=max(P d,P th),其中,P d表示第一低频输入信号的功率,P th表示掩蔽阈值。同理,上述第一低频输入信号的瞬态功率与第一低频输入信号的稳态功率的比值也可以进行优化,具体是R r=max(R r,1)。
在一种实现方式中,在电子设备获取到第一低频输入信号之后,电子设备可以对第一低频输入信号进行低通滤波,然后再计算滤波后的第一低频输入信号的瞬态功率和稳态功率,以进一步确定第一低频输入信号是瞬态信号还是稳态信号。本申请实施例中,对第一低频输入信号进行低通滤波,得到更低频率范围的低频输入信号,并且通过低通滤波可以进一步降低第一低频输入信号中可能存在的高频信号,在此基础上,对滤波后的第一低频输入信号进行瞬态检测,能够降低瞬态检测的误检率。
一种可能的实现方式中,本申请实施例提供的提升扬声器的音质的方法还包括:电子设备对第一信号进行均衡处理,得到第二信号;该第一信号为输入至扬声器的初始的待播放信号;并且采用低音增强算法对第二信号进行处理,以得到扬声器的输入信号。
本申请实施例中,上述对第一信号进行均衡处理的具体方法可以是:采用biquard滤波器对第一信号进行均衡处理,能够改善扬声器的低频频率响应。采用低音增强算法对第二信号进行处理,能够提升第二信号的低频响度。
一种可能的实现方式中,上述采用低音增强算法对第二信号进行处理,得到扬声器的输入信号的方法具体包括:电子设备根据第二信号中的低频信号的能量,确定低频搁架滤波器的增益,该低频搁架滤波器用于控制第二信号中的低频信号的响度;并且使用低频搁架滤波器对第二信号进行滤波,得到扬声器的输入信号。
上述采用低音增强算法,电子设备根据第二信号中的低频信号的能量,有区分地对不同能量的低频信号进行不同程度的响度提升,即按照低频信号的能量为低频信号 设置不同的增益,即根据第二信号的低频信号的能量的特点,动态地、自适应地提升第二信号中的低频信号的响度的,如此,能够提高低频信号的清晰度。
一种可能的实现方式中,本申请实施例提供的提升扬声器的音质的方法还包括:电子设备获取包括一个或多个校正系数的第一位移预测模型,该第一位移预测模型用于模拟扬声器的性能以预测扬声器的振膜的位移,该一个或多个校正系数用于控制第一位移预测模型的输出;并且调整第一位移预测模型中的至少一个校正系数,得到第二位移预测模型;第二位移预测模型输出的预测位移与扬声器的振膜的实际位移的差值的绝对值,小于第一位移预测模型输出的预测位移与扬声器的振膜的实际位移的差值的绝对值;该扬声器的实际位移为振膜相对于初始位置的移动距离实际测量值;以及电子设备根据扬声器的位移保护阈值及第二位移预测模型输出的预测位移,控制扬声器的输出信号的增益,使得扬声器播放输出信号时的振膜位移小于或等于位移保护阈值;该位移保护阈值为扬声器的振膜的最大位移。
本申请实施例中,上述第二位移预测模型更真实的反映扬声器的特点,保证输出的预测位移更准确,进而可以更精确的进行位移保护,也就实现了在保护扬声器振膜位移的前提下,最大化发挥扬声器的硬件潜力,提升扬声器的外放响度。
一种可能的实现方式中,本申请实施例提供的提升扬声器的音质的方法还包括:电子设备对输出信号进行虚拟低音处理,以得到虚拟低音输出信号,该虚拟低音输出信号的心理感知低频响度大于扬声器的输出信号的心理感知低频响度。
本申请实施例中,虚拟低音处理是一种基于心理声学的一种提升低音音效的方法,从心理声学的角度来衡量,上述通过虚拟低音处理后的输出信号(即虚拟低音输出信号)的心理感知低频响度大于原输出信号的心理感知低频响度。在一种实施方式中,心理感知低频响度可以根据心理声学模型来确定。
一种可能的实现方式中,上述对扬声器的输出信号进行虚拟低音处理,以得到虚拟低音输出信号的方法具体包括:电子设备对输出信号进行分频处理,以获取第一低频输出信号和第一高频输出信号,该第一低频输出信号包括该输出信号中低于第三预设频点的信号,第一高频输出信号包括该输出信号中高于第三预设频点的信号;并且电子设备根据第一低频输出信号生成第一低频输出信号的谐波信号;然后,电子设备将谐波信号和第一低频输出信号进行混合,以得到第一混合信号;以及对第一混合信号和第一高频输出信号进行相位同步处理,以得到第二混合信号和第二高频输出信号,第二混合信号的相位的变化量与第二高频输出信号的相位的变化量相等;进而电子设备根据第二混合信号和第二高频输出信号,获得虚拟低音输出信号。
一种可能的实现方式中,本申请实施例提供的提升扬声器的音质的方法还包括:电子设备根据扬声器的线圈温度,调整扬声器中预先配置的第一非线性补偿模型的非线性参数,以得到第二非线性补偿模型;然后电子设备采用第二非线性补偿模型对扬声器的输出信号进行信号补偿。
本申请实施例中,由于确定的扬声器的第二非线性参数是扬声器当前工作状态对应的非线性参数,即实时的非线性参数,其准确性较高,如此,根据该第二非线性参数对扬声器的输出信号做信号补偿,信号补偿效果较好,能够有效地减小信号失真,提升扬声器的音质。
第二方面,本申请实施例提供一种电子设备,该电子设备包括:第一获取模块、第一确定模块、包络调制模块以及第二确定模块。其中,第一获取模块用于对扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号,该扬声器的输入信号为时域信号,第一低频输入信号包括输入信号中低于第一预设频点的信号,该第一高频输入信号包括输入信号中高于第一预设频点的信号;第一确定模块用于对第一低频输入信号进行瞬态检测,以确定第一低频输入信号是否为瞬态信号;包络调制模块用于在第一低频输入信号为瞬态信号的情况下,对第一低频输入信号进行信号包络调制,以得到第二低频输入信号,该第二低频输入信号的起振电压大于第一低频输入信号的起振电压,且第二低频输入信号的响度大于第一低频输入信号的响度;第二确定模块用于根据第二低频输入信号和第一高频输入信号,确定扬声器的输出信号。
一种可能的实现方式中,上述第一获取模块还用于对扬声器的第一高频输入信号进行分频,以获取第一中频输入信号和第二高频输入信号,该第一中频输入信号包括第一高频输入信号中低于第二预设频点的信号,第二高频输入信号包括第一高频输入信号中高于第二预设频点的信号,第二预设频点高于第一预设频点;第一确定模块还用于对第一中频输入信号进行瞬态检测,以确定第一中频输入信号是否为瞬态信号;包络调制模块还用于在第一中频输入信号为瞬态信号的情况下,对第一中频输入信号进行信号包络调制,以得到第二中频输入信号,该第二中频输入信号的起振电压大于第一中频输入信号的起振电压,且第二中频输入信号的响度大于第一中频输入信号的响度;第二确定模块具体用于根据第二低频输入信号、第二中频输入信号以及第二高频输入信号,得到扬声器的输出信号。
一种可能的实现方式中,本申请实施例提供的电子设备还包括生成模块和第二获取模块。生成模块用于生成低频辅助信号;第二获取模块用于在第一低频输入信号中添加低频辅助信号,以获得第一辅助增强信号;上述包络调制模块具体用于对第一辅助增强信号进行信号包络调制,以得到第二低频输入信号。
一种可能的实现方式中,上述生成模块具体用于生成第一辅助信号,对第一辅助信号进行高通滤波,以得到低频辅助信号。第一辅助信号满足:
Figure PCTCN2022101678-appb-000001
其中,signal_h表示低频辅助信号,A表示信号幅度影响因子,f为扬声器的中心频率。
一种可能的实现方式中,本申请实施例提供的电子设备还包括相位补偿模块;该相位补偿模块用于对第一低频输入信号进行相位补偿,以获得第一相位补偿信号;上述包络调制模块具体用于对第一相位补偿信号进行信号包络调制,以得到第二低频输入信号。
一种可能的实现方式中,上述第一确定模块具体用于确定第一低频输入信号的瞬态功率和稳态功率;并且根据第一低频输入信号的瞬态功率和稳态功率确定第一低频输入信号的瞬时率;以及在输入信号的瞬态率大于预设的瞬态率阈值的情况下,确定第一低频输入信号为瞬态信号。该第一低频输入信号的瞬时率满足:T r=(R r-1) 2×W,其中,T r表示第一低频输入信号的瞬时率,R r表示第一低频输入信号的瞬态功率与第一低频输入信号的稳态功率的比值,W表示计权因子,W的取值与第一低频输入信号的当前功率相同。
一种可能的实现方式中,本申请实施例提供的电子设备还包括均衡处理模块和低音增强模块;其中,均衡处理模块用于对第一信号进行均衡处理,得到第二信号,该第一信号为输入至扬声器的初始的待播放信号;低音增强模块用于采用低音增强算法对第二信号进行处理,以得到扬声器的输入信号。
一种可能的实现方式中,上述低音增强模块具体用于根据第二信号中的低频信号的能量,确定低频搁架滤波器的增益,该低频搁架滤波器用于控制第二信号中的低频信号的响度;并且使用低频搁架滤波器对第二信号进行滤波,得到扬声器的输入信号。
一种可能的实现方式中,本申请实施例提供的电子设备还包括第三获取模块、第一调整模块以及控制模块。其中,第三获取模块用于获取包括一个或多个校正系数的第一位移预测模型,该第一位移预测模型用于模拟扬声器的性能以预测扬声器的振膜的位移,该一个或多个校正系数用于控制第一位移预测模型的输出;第一调整模块用于调整第一位移预测模型中的至少一个校正系数,得到第二位移预测模型,该第二位移预测模型输出的预测位移与扬声器的振膜振膜的实际位移的差值的绝对值,小于第一位移预测模型输出的预测位移与扬声器的振膜的实际位移的差值的绝对值;该扬声器的实际位移为振膜相对于初始位置的移动距离实际测量值;控制模块用于根据扬声器的位移保护阈值及第二位移预测模型输出的预测位移,控制扬声器的输出信号的增益,使得扬声器播放输出信号时的振膜位移小于或等于位移保护阈值,位移保护阈值为扬声器的振膜的最大位移。
一种可能的实现方式中,本申请实施例提供的电子设备还包括虚拟低音处理模块:该虚拟低音处理模块用于对上述输出信号进行虚拟低音处理,以得到虚拟低音输出信号;该虚拟低音输出信号的心理感知低频响度大于输出信号的心理感知低频响度。
一种可能的实现方式中,上述虚拟低音处理模块具体用于对上述输出信号进行分频处理,以获取第一低频输出信号和第一高频输出信号,该第一低频输出信号包括该输出信号中低于第三预设频点的信号,第一高频输出信号包括该输出信号中高于第三预设频点的信号;并根据第一低频输出信号生成第一低频输出信号的谐波信号;且将谐波信号和第一低频输出信号进行混合,以得到第一混合信号;以及对第一混合信号和第一高频输出信号进行相位同步处理,以得到第二混合信号和第二高频输出信号,该第二混合信号的相位的变化量与第二高频输出信号的相位的变化量相等;进而根据第二混合信号和第二高频输出信号,获得虚拟低音输出信号。
一种可能的实现方式中,本申请实施例提供的电子设备还包括第二调整模块和信号补偿模块:第二调整模块用于根据扬声器的线圈温度,调整扬声器中预先配置的第一非线性补偿模型的非线性参数,以得到第二非线性补偿模型;信号补偿模块用于采用第二非线性补偿模型对扬声器的输出信号进行信号补偿。
第三方面,本申请实施例提供一种电子设备,该电子设备包括存储器和与存储器连接的至少一个处理器,存储器用于存储指令,存储器存储的指令被至少一个处理器读取后,执行上述第一方面及其可能的实现方式中任意之一所述的方法。
第四方面,本申请实施例提供一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时上述第一方面及其可能的实现方式中任意之一所述的方法。
第五方面,本申请实施例提供一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行第一方面及其可能的实现方式中任意之一所述的方法。
第六方面,本申请实施例提供一种芯片,包括存储器和处理器。存储器用于存储计算机指令。处理器用于从存储器中调用并运行该计算机指令,以执行第一方面及其可能的实现方式中任意之一所述的方法。
应当理解的是,本申请实施例的第二方面至第六方面技术方案及对应的可能的实施方式所取得的有益效果可以参见上述对第一方面及其对应的可能的实施方式的技术效果,此处不再赘述。
附图说明
图1为本申请实施例提供的一种瞬态信号和稳态信号的示意图;
图2为本申请实施例提供的一种音频处理系统的框图;
图3为本申请实施例提供的一种手机的硬件结构示意图;
图4为本申请实施例提供的一种提升扬声器的音质的方法示意图;
图5为本申请实施例提供的另一种提升扬声器的音质的方法示意图;
图6为本申请实施例提供的一种包络调制的原理示意图;
图7为本申请实施例提供的一种扬声器系统的框架示意图;
图8为本申请实施例提供的另一种提升扬声器的音质的方法示意图;
图9为本申请实施例提供的另一种一种扬声器系统的框架示意图;
图10为本申请实施例提供的另一种提升扬声器的音质的方法示意图;
图11为本申请实施例提供的另一种一种扬声器系统的框架示意图;
图12为本申请实施例提供的另一种提升扬声器的音质的方法示意图;
图13为本申请实施例提供的另一种一种扬声器系统的框架示意图;
图14为本申请实施例提供的另一种一种扬声器系统的框架示意图;
图15为本申请实施例提供的一种低频增强算法的流程示意图;
图16为本申请实施例提供的另一种一种扬声器系统的框架示意图;
图17为本申请实施例提供的另一种提升扬声器的音质的方法示意图;
图18为本申请实施例提供的另一种一种扬声器系统的框架示意图;
图19为本申请实施例提供的另一种提升扬声器的音质的方法示意图;
图20为本申请实施例提供的另一种一种扬声器系统的框架示意图;
图21为本申请实施例提供的又一种提升扬声器的音质的方法示意图;
图22为本申请实施例提供的又一种一种扬声器系统的框架示意图;
图23为本申请实施例提供的一种电子设备的结构示意图一;
图24为本申请实施例提供的一种电子设备的结构示意图二。
具体实施方式
本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。
本申请实施例的说明书和权利要求书中的术语“第一”和“第二”等是用于区别不同的对象,而不是用于描述对象的特定顺序。例如,第一低频输入信号和第二低频输入 信号等是用于区别不同的输入信号,而不是用于描述低频输入信号的特定顺序;又例如,第一高频输入信号和第二高频输入信号是用于区别不同的高频输入信号,而不是用于描述高频输入信号的特定顺序;又例如,第一中频输入信号和第二中频输入信号是用于区别不同的中频输入信号,而不是用于描述中频输入信号的特定顺序。
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。
在本申请实施例的描述中,除非另有说明,“多个”的含义是指两个或两个以上。例如,多个校正系数是指两个或两个以上的校正系数。
首先对本申请实施例提供的一种提升扬声器的音质的方法及装置中涉及的一些概念做解释说明。
响度:响度用于衡量人类主观感觉到的声音强弱程度。一般而言,声音的频率一定的情况下,声强越强,响度也越大。但是,响度与频率有关,声强相同,频率不同,响度也可能不同。响度可以为音频信号的声压级,简单地,响度也可以理解为音频信号的音量。
应理解,本申请实施例提供的技术方案的目的是提升扬声器待播放的音频信号中的低频信号的响度,以提升扬声器的音质。
低频动态变化:指信号从小到大再到小的变化过程,音频信号中的低频信号的细微动态变化影响用户听感。低音动态变化比较好指指的是:低频起振速度快,峰值响度大,衰减速度快,低频动态越好,在播放音频信号时,音频信号中的低频细节部分能够表现出来,使得用户具有很好的主观听感。
扬声器的输入信号:也可以称为输入电压信号,本申请实施例中,对音频信号进行逐帧进行处理,因此,在处理以信号帧的过程中,扬声器所对应的输入信号是一个信号帧。
扬声器的输入信号包含M个(M为大于或者等于1的整数)数字信号,对应n个电压值(也可以称为n个点),示例性的,输入信号U in=[U in(1),U in(2),…,U in(n),…,U in(M)]。本申请实施例中,对输入信号进行处理指的是对输入信号中的每个数字信号依次进行处理。为了便于描述,输入第n个数字信号的时刻记为t n,t n时刻对应的输入信号记为U in(n)或U in(t n)。
上述响度和动态变化可以用于衡量扬声器播放的音频信号的音质,特别是对于小型扬声器,低频响度和动态变化是音频信号处理的主要目标。
瞬态信号和稳态信号:将维持时间短,有明显的开始和结束的信号称为瞬态信号;将较长的时间段内维持在较小的范围内变化的信号称为稳态信号。示例性的,图1示出了一段音频信号的瞬态信号和稳态信号。
扬声器的位移,是指扬声器工作过程中其振膜的移动距离。
扬声器的位移对扬声器的音质具有影响,当扬声器的振膜位移过大时,可能导致扬声器的振膜打顶或者擦圈,从而产生杂音,甚至导致扬声器发生机械损坏。本申请实施例中,可以对扬声器的位移进行控制,以提升扬声器的音质。
扬声器的非线性参数:扬声器的非线性参数可以包括但不限于如下参数:
力因数BL(x):指的是扬声器的磁路系统的力因数。
力学劲度Kms(x):指的是扬声器的悬挂系统的劲度,Kms(x)可以包括一阶、二阶、三阶等不同的系数。
电感Le(x):指的是扬声器的线圈的电感。
阻尼Rm(v):是扬声器的阻尼系数,Rm(v)可以包括一阶、二阶、三阶等不同的系数。
其中,上述x指的是扬声器的振膜的位移,v指的是扬声器的振膜移动的速度。
需要说明的是,扬声器的工作状态不同,扬声器的非线性参数可能发生变化,例如,扬声器的线圈处于不同的温度时,上述Kms(x)会发生变化,Rm(v)也可能发生变化,即不同温度下的Kms(x)不同,不同温度下的Rm(v)不同。
扬声器的非线性:扬声器的非线性是由于扬声器的硬件结构(例如扬声器的小尺寸、大位移等结构特点)而导致其输出音质产生失真的一种现象,可以称为非线性失真,特别是扬声器有大信号输入时,扬声器的非线性更加明显,输出信号可能产生过量的失真,影响听觉感受。
本申请实施例中,可以利用扬声器的非线性参数对扬声器的硬件带来的非线性失真进行补偿,以提升扬声器的音质。
目前,多数扬声器播放的音频信号的响度不足,动态变化表现不好,使得扬声器播放音频信号时的音质较差。对于用户而言,音频信号中的中低频信号对听感起着重要的作用,直接影响用户的听觉感受,因此,如何改善小型扬声器的低频音效是急需解决的问题。现有的一些提升扬声器的音质的方法涉及从扬声器的位移保护的角度、非线性补偿的角度等对音频信号进行处理,最大化发挥扬声器的硬件潜力,提升扬声器的外放响度,但这些方法对扬声器的音质的提升效果仍然有待提升。
本申请实施例提供一种提升扬声器的音质的方法及装置,可以应用于具有扬声器的电子设备,该电子设备通过对待重现的音频信号(以下实施例称为扬声器的输入信号)进行处理以提升扬声器的音质。具体的,电子设备对扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号;然后电子设备对扬声器的第一低频输入信号进行瞬态检测,以确定第一低频输入信号是否为瞬态信号;若第一低频输入信号为瞬态信号,则对第一低频输入信号进行信号包络调制,得到第二低频输入信号,该第二低频输入信号的起振电压大于第一低频输入信号的起振电压,且第二低频输入信号的响度大于第一低频输入信号的响度;最后电子设备根据第二低频输入信号和上述第一高频输入信号,确定扬声器的输出信号。通过本申请实施例提供的技术方案,能够改善扬声器的低频音效,改善扬声器的音质。
本申请实施例提供的提升扬声器的音质的方法可以应用于具有音频外放功能(即具有扬声器)的电子设备,例如手机、平板电脑、笔记本电脑、智能音箱、电视等安装有扬声器的电子设备。
使用电子设备的扬声器进行发声的场景中均可以采用本申请实施例提供的方法,示例性的,本申请实施例提供的提升扬声器的音质的方法可以应用在以下场景中:音乐和电影外放(包括单声道、双声道以及四声道播放)、免提通话(包括运营商电话、 网络电话等)、手机铃声(包括外放模式、插耳机模式)以及游戏外放等,最大化发挥扬声器的硬件潜力,改善扬声器的低频音效,提升扬声器的音质,从而可以提升用户的主观体验。
应理解,本申请实施例提供的提升扬声器的音质的方法主要由电子设备中的音频处理系统完成,参考图2,音频处理系统主要包括数字信号处理(digital signal processing,DSP)器和功率放大器(power amplifier,PA),其中,DSP用于对输入的音频信号进行处理,处理之后的信号再经PA放大,最终输出至扬声器播放。
以上述电子设备为手机为例,下面详细介绍可以应用本申请实施例提供的提升扬声器的音质的方法的手机的详细结构,图3示出了手机300的结构示意图。该手机300可以包括处理器310,外部存储器接口320,内部存储器321,通用串行总线(universal serial bus,USB)接口330,充电管理模块340,电源管理模块341,电池342,天线1,天线2,移动通信模块350,无线通信模块360,音频模块370,扬声器370A,受话器370B,麦克风370C,耳机接口370D,传感器模块380,按键390,马达391,指示器392,摄像头393,显示屏394,以及用户标识模块(subscriber identification module,SIM)卡接口395等。其中传感器模块380可以包括压力传感器380A,陀螺仪传感器380B,气压传感器380C,磁传感器380D,加速度传感器380E,距离传感器380F,接近光传感器380G,指纹传感器380H,温度传感器380J,触摸传感器380K,环境光传感器380L,骨传导传感器380M等。
可以理解的是,本申请实施例示意的结构并不构成对手机300的具体限定。在本申请另一些实施例中,手机300可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。
处理器310可以包括一个或多个处理单元,例如:处理器310可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processing unit,GPU),图像信号处理器(image signal processor,ISP),控制器,存储器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。
其中,控制器可以是手机300的神经中枢和指挥中心。控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。
处理器310中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器310中的存储器为高速缓冲存储器。该存储器可以保存处理器310刚用过或循环使用的指令或数据。如果处理器310需要再次使用该指令或数据,可从存储器中直接调用。避免了重复存取,减少了处理器310的等待时间,因而提高了系统的效率。
在一些实施例中,处理器310可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuit sound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purpose input/output,GPIO)接口, 用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。
I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器310可以包含多组I2C总线。处理器310可以通过不同的I2C总线接口分别耦合触摸传感器380K,充电器,闪光灯,摄像头393等。例如:处理器310可以通过I2C接口耦合触摸传感器380K,使处理器310与触摸传感器380K通过I2C总线接口通信,实现手机300的触摸功能。
I2S接口可以用于音频通信。在一些实施例中,处理器310可以包含多组I2S总线。处理器310可以通过I2S总线与音频模块370耦合,实现处理器310与音频模块370之间的通信。在一些实施例中,音频模块370可以通过I2S接口向无线通信模块360传递音频信号,实现通过蓝牙耳机接听电话的功能。
PCM接口也可以用于音频通信,将模拟信号抽样,量化和编码。在一些实施例中,音频模块370与无线通信模块360可以通过PCM总线接口耦合。在一些实施例中,音频模块370也可以通过PCM接口向无线通信模块360传递音频信号,实现通过蓝牙耳机接听电话的功能。所述I2S接口和所述PCM接口都可以用于音频通信。
UART接口是一种通用串行数据总线,用于异步通信。该总线可以为双向通信总线。它将要传输的数据在串行通信与并行通信之间转换。在一些实施例中,UART接口通常被用于连接处理器310与无线通信模块360。例如:处理器310通过UART接口与无线通信模块360中的蓝牙模块通信,实现蓝牙功能。在一些实施例中,音频模块370可以通过UART接口向无线通信模块360传递音频信号,实现通过蓝牙耳机播放音乐的功能。
MIPI接口可以被用于连接处理器310与显示屏394,摄像头393等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(display serial interface,DSI)等。在一些实施例中,处理器310和摄像头393通过CSI接口通信,实现手机300的拍摄功能。处理器310和显示屏394通过DSI接口通信,实现手机300的显示功能。
GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器310与摄像头393,显示屏394,无线通信模块360,音频模块370,传感器模块380等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。
USB接口330是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB接口,USB Type C接口等。USB接口330可以用于连接充电器为手机300充电,也可以用于手机300与外围设备之间传输数据。也可以用于连接耳机,通过耳机播放音频。该接口还可以用于连接其他电子设备,例如AR设备等。
可以理解的是,本申请实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对手机300的结构限定。在本申请另一些实施例中,手机300也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。
充电管理模块340用于从充电器接收充电输入。其中,充电器可以是无线充电器, 也可以是有线充电器。在一些有线充电的实施例中,充电管理模块340可以通过USB接口330接收有线充电器的充电输入。在一些无线充电的实施例中,充电管理模块340可以通过手机300的无线充电线圈接收无线充电输入。充电管理模块340为电池342充电的同时,还可以通过电源管理模块341为电子设备供电。
电源管理模块341用于连接电池342,充电管理模块340与处理器310。电源管理模块341接收电池342和/或充电管理模块340的输入,为处理器310,内部存储器321,外部存储器,显示屏394,摄像头393,和无线通信模块360等供电。电源管理模块341还可以用于监测电池容量,电池循环次数,电池健康状态(漏电,阻抗)等参数。在其他一些实施例中,电源管理模块341也可以设置于处理器310中。在另一些实施例中,电源管理模块341和充电管理模块340也可以设置于同一个器件中。
手机300的无线通信功能可以通过天线1,天线2,移动通信模块350,无线通信模块360,调制解调处理器以及基带处理器等实现。
天线1和天线2用于发射和接收电磁波信号。手机300中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。
移动通信模块350可以提供应用在手机300上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块350可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块350可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块350还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块350的至少部分功能模块可以被设置于处理器310中。在一些实施例中,移动通信模块350的至少部分功能模块可以与处理器310的至少部分模块被设置在同一个器件中。
调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过音频设备(不限于扬声器370A,受话器370B等)输出声音信号,或通过显示屏394显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器310,与移动通信模块350或其他功能模块设置在同一个器件中。
无线通信模块360可以提供应用在手机300上的包括无线局域网(wireless local area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块360可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块360经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器310。无线通信模块360还可以从处理器310接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。
在一些实施例中,手机300的天线1和移动通信模块350耦合,天线2和无线通信模块360耦合,使得手机300可以通过无线通信技术与网络以及其他设备通信。所述无线通信技术可以包括全球移动通讯系统(global system for mobile communications,GSM),通用分组无线服务(general packet radio service,GPRS),码分多址接入(code division multiple access,CDMA),宽带码分多址(wideband code division multiple access,WCDMA),时分码分多址(time-division code division multiple access,TD-SCDMA),长期演进(long term evolution,LTE),BT,GNSS,WLAN,NFC,FM,和/或IR技术等。所述GNSS可以包括全球卫星定位系统(global positioning system,GPS),全球导航卫星系统(global navigation satellite system,GLONASS),北斗卫星导航系统(beidou navigation satellite system,BDS),准天顶卫星系统(quasi-zenith satellite system,QZSS)和/或星基增强系统(satellite based augmentation systems,SBAS)。
手机300通过GPU,显示屏394,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏394和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器310可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。
显示屏394用于显示图像,视频等。显示屏394包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emitting diode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organic light emitting diode的,AMOLED),柔性发光二极管(flex light-emitting diode,FLED),Miniled,MicroLed,Micro-oLed,量子点发光二极管(quantum dot light emitting diodes,QLED)等。在一些实施例中,手机300可以包括1个或N个显示屏394,N为大于1的正整数。
手机300可以通过ISP,摄像头393,视频编解码器,GPU,显示屏394以及应用处理器等实现拍摄功能。
ISP用于处理摄像头393反馈的数据。例如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将所述电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头393中。
摄像头393用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,手机300可以包括1个或N个摄像头393,N为大于1的正整数。
数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号(如音频信号等)。例如,当手机300在频点选择时,数字信号处理器用于对频点能量进行傅里叶变换等。
视频编解码器用于对数字视频压缩或解压缩。手机300可以支持一种或多种视频编解码器。这样,手机300可以播放或录制多种编码格式的视频,例如:动态图像专家组(moving picture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。
NPU为神经网络(neural-network,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现手机300的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。
外部存储器接口320可以用于连接外部存储卡,例如Micro SD卡,实现扩展手机300的存储能力。外部存储卡通过外部存储器接口320与处理器310通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。
内部存储器321可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。处理器310通过运行存储在内部存储器321的指令,从而执行手机300的各种功能应用以及数据处理。内部存储器321可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储手机300使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器321可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。
手机300可以通过音频模块370,扬声器370A,受话器370B,麦克风370C,耳机接口370D,以及应用处理器等实现音频功能。例如音乐播放,录音等。
音频模块370用于将数字音频信息转换成模拟音频信号输出,也用于将模拟音频输入转换为数字音频信号。音频模块370还可以用于对音频信号编码和解码。在一些实施例中,音频模块370可以设置于处理器310中,或将音频模块370的部分功能模块设置于处理器310中。
扬声器370A,也称“喇叭”,用于将音频电信号转换为声音信号。手机300可以通过扬声器370A收听音乐,或收听免提通话。
受话器370B,也称“听筒”,用于将音频电信号转换成声音信号。当手机300接听电话或语音信息时,可以通过将受话器370B靠近人耳接听语音。
麦克风370C,也称“话筒”,“传声器”,用于将声音信号转换为电信号。当拨打电话或发送语音信息时,用户可以通过人嘴靠近麦克风370C发声,将声音信号输入到麦克风370C。手机300可以设置至少一个麦克风370C。在另一些实施例中,手机300可以设置两个麦克风370C,除了采集声音信号,还可以实现降噪功能。在另一些实施例中,手机300还可以设置三个,四个或更多麦克风370C,实现采集声音信号,降噪,还可以识别声音来源,实现定向录音功能等。
耳机接口370D用于连接有线耳机。耳机接口370D可以是USB接口330,也可以是3.5mm的开放移动电子设备平台(open mobile terminal platform,OMTP)标准接口,美国蜂窝电信工业协会(cellular telecommunications industry association of the USA,CTIA)标准接口。
压力传感器380A用于感受压力信号,可以将压力信号转换成电信号。在一些实 施例中,压力传感器380A可以设置于显示屏394。压力传感器380A的种类很多,如电阻式压力传感器,电感式压力传感器,电容式压力传感器等。电容式压力传感器可以是包括至少两个具有导电材料的平行板。当有力作用于压力传感器380A,电极之间的电容改变。手机300根据电容的变化确定压力的强度。当有触摸操作作用于显示屏394,手机300根据压力传感器380A检测所述触摸操作强度。手机300也可以根据压力传感器380A的检测信号计算触摸的位置。在一些实施例中,作用于相同触摸位置,但不同触摸操作强度的触摸操作,可以对应不同的操作指令。例如:当有触摸操作强度小于第一压力阈值的触摸操作作用于短消息应用图标时,执行查看短消息的指令。当有触摸操作强度大于或等于第一压力阈值的触摸操作作用于短消息应用图标时,执行新建短消息的指令。
陀螺仪传感器380B可以用于确定手机300的运动姿态。在一些实施例中,可以通过陀螺仪传感器380B确定手机300围绕三个轴(即,x,y和z轴)的角速度。陀螺仪传感器380B可以用于拍摄防抖。示例性的,当按下快门,陀螺仪传感器380B检测手机300抖动的角度,根据角度计算出镜头模组需要补偿的距离,让镜头通过反向运动抵消手机300的抖动,实现防抖。陀螺仪传感器380B还可以用于导航,体感游戏场景。
气压传感器380C用于测量气压。在一些实施例中,手机300通过气压传感器380C测得的气压值计算海拔高度,辅助定位和导航。
磁传感器380D包括霍尔传感器。手机300可以利用磁传感器380D检测翻盖皮套的开合。在一些实施例中,当手机300是翻盖机时,手机300可以根据磁传感器380D检测翻盖的开合。进而根据检测到的皮套的开合状态或翻盖的开合状态,设置翻盖自动解锁等特性。
加速度传感器380E可检测手机300在各个方向上(一般为三轴)加速度的大小。当手机300静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。
距离传感器380F,用于测量距离。手机300可以通过红外或激光测量距离。在一些实施例中,拍摄场景,手机300可以利用距离传感器380F测距以实现快速对焦。
接近光传感器380G可以包括例如发光二极管(LED)和光检测器,例如光电二极管。发光二极管可以是红外发光二极管。手机300通过发光二极管向外发射红外光。手机300使用光电二极管检测来自附近物体的红外反射光。当检测到充分的反射光时,可以确定手机300附近有物体。当检测到不充分的反射光时,手机300可以确定手机300附近没有物体。手机300可以利用接近光传感器380G检测用户手持手机300贴近耳朵通话,以便自动熄灭屏幕达到省电的目的。接近光传感器380G也可用于皮套模式,口袋模式自动解锁与锁屏。
环境光传感器380L用于感知环境光亮度。手机300可以根据感知的环境光亮度自适应调节显示屏394亮度。环境光传感器380L也可用于拍照时自动调节白平衡。环境光传感器380L还可以与接近光传感器380G配合,检测手机300是否在口袋里,以防误触。
指纹传感器380H用于采集指纹。手机300可以利用采集的指纹特性实现指纹解 锁,访问应用锁,指纹拍照,指纹接听来电等。
温度传感器380J用于检测温度。在一些实施例中,手机300利用温度传感器380J检测的温度,执行温度处理策略。例如,当温度传感器380J上报的温度超过阈值,手机300执行降低位于温度传感器380J附近的处理器的性能,以便降低功耗实施热保护。在另一些实施例中,当温度低于另一阈值时,手机300对电池342加热,以避免低温导致手机300异常关机。在其他一些实施例中,当温度低于又一阈值时,手机300对电池342的输出电压执行升压,以避免低温导致的异常关机。
触摸传感器380K,也称“触控面板”。触摸传感器380K可以设置于显示屏394,由触摸传感器380K与显示屏394组成触摸屏,也称“触控屏”。触摸传感器380K用于检测作用于其上或附近的触摸操作。触摸传感器可以将检测到的触摸操作传递给应用处理器,以确定触摸事件类型。可以通过显示屏394提供与触摸操作相关的视觉输出。在另一些实施例中,触摸传感器380K也可以设置于手机300的表面,与显示屏394所处的位置不同。
骨传导传感器380M可以获取振动信号。在一些实施例中,骨传导传感器380M可以获取人体声部振动骨块的振动信号。骨传导传感器380M也可以接触人体脉搏,接收血压跳动信号。在一些实施例中,骨传导传感器380M也可以设置于耳机中,结合成骨传导耳机。音频模块370可以基于所述骨传导传感器380M获取的声部振动骨块的振动信号,解析出语音信号,实现语音功能。应用处理器可以基于所述骨传导传感器380M获取的血压跳动信号解析心率信息,实现心率检测功能。
按键390包括开机键,音量键等。按键390可以是机械按键。也可以是触摸式按键。手机300可以接收按键输入,产生与手机300的用户设置以及功能控制有关的键信号输入。
马达391可以产生振动提示。马达391可以用于来电振动提示,也可以用于触摸振动反馈。例如,作用于不同应用(例如拍照,音频播放等)的触摸操作,可以对应不同的振动反馈效果。作用于显示屏394不同区域的触摸操作,马达391也可对应不同的振动反馈效果。不同的应用场景(例如:时间提醒,接收信息,闹钟,游戏等)也可以对应不同的振动反馈效果。触摸振动反馈效果还可以支持自定义。
指示器392可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。
SIM卡接口395用于连接SIM卡。SIM卡可以通过插入SIM卡接口395,或从SIM卡接口395拔出,实现和手机300的接触和分离。手机300可以支持1个或N个SIM卡接口,N为大于1的正整数。SIM卡接口395可以支持Nano SIM卡,Micro SIM卡,SIM卡等。同一个SIM卡接口395可以同时插入多张卡。所述多张卡的类型可以相同,也可以不同。SIM卡接口395也可以兼容不同类型的SIM卡。SIM卡接口395也可以兼容外部存储卡。手机300通过SIM卡和网络交互,实现通话以及数据通信等功能。在一些实施例中,手机300采用eSIM,即:嵌入式SIM卡。eSIM卡可以嵌在手机300中,不能和手机300分离。
可以理解的,图3仅以手机为例进行说明,并不是对电子设备的结构的具体限定。在实际应用中,电子设备可以包括图3中更多的部件,也可以比图3示意的部件更少, 本申请实施例对此不予限定。
可以理解的,本申请实施例中,电子设备(例如上述手机)的处理器,例如DSP可以执行本申请实施例中的部分或全部步骤,这些步骤或操作仅是示例,本申请实施例还可以执行其它操作或者各种操作的变形。此外,各个步骤可以按照本申请实施例呈现的不同的顺序来执行,并且有可能并非要执行本申请实施例中的全部操作。本申请各实施例可以单独实施,也可以任意组合实施,本申请对此不作限定。
如图4所示,本申请实施例提供一种提升扬声器的音质的方法,该方法包括步骤401至步骤404。
步骤401、电子设备对扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号。
应理解,本申请实施例中,电子设备处理的扬声器的输入信号是时域信号。第一低频输入信号包括输入信号中低于第一预设频点的信号,第一高频输入信号包括输入信号中高于第二预设频点的信号。
示例性的,第一预设频点可以是100~400Hz范围内的频点,例如第一预设频点可以是100,200,250,300或400Hz等等。
需要说明的是,第一预设频点处的信号可以包含在第一低频输入信号中,也可以包含在第一高频输入信号,或者还可以同时包含在第一低频输入信号和第一高频输入信号中,本申请实施例不作限定。
可选地,电子设备可以通过分频器对输入数据进行分频,分频器实质上是滤波器,对输入信号进行滤波,得到输入信号中的低频信号(称为第一低频输入信号)和高频信号(称为第一高频输入信号)。
步骤402、电子设备对扬声器的第一低频输入信号进行瞬态检测,以确定第一低频输入信号是否为瞬态信号。
本申请实施例中,结合图1可知,瞬态信号是信号幅度变化量较大的一些信号,在音频信号中,通常瞬态信号包含一段音频的重要信息,因此,可以针对音频信号中瞬态信号,对瞬态信号进行处理,提升音质。
可选地,结合图4,如图5所示,本申请实施例中,电子设备对第一低频输入信号进行瞬态检测的方法具体包括步骤4021至步骤4023。
步骤4021、电子设备确定第一低频输入信号的瞬态功率和稳态功率。
本申请实施例中,电子设备确定第一低频输入信号(对应一个信号帧)的瞬态功率和稳态功率的过程包括:
首先,电子设备计算第一低频输入信号的功率,应理解,该第一低频输入信号的功率是该第一低频输入信号所包含的所有数据点的电压值的平方和再求平均值。
其次,根据当前帧的功率和电子设备中缓存的多个帧(该多个帧是一些历史帧)的功率确定第一低频输入信号的瞬态功率和稳态功率。其中,第一低频输入信号的瞬态功率可以为当前帧之前的连续n1个信号帧的平均功率,第一低频输入信号的稳态功率可以是当前帧之前的连续n2个信号帧的平均功率,n1远小于n2,例如,n1取值为5,n2取值为50。
步骤4022、电子设备根据第一低频输入信号的瞬态功率和稳态功率,确定第一低 频输入信号的瞬时率。
本申请实施例中,上述第一低频输入信号的瞬时率满足:
T r=(R r-1) 2×W
其中,T r表示第一低频输入信号的瞬时率,R r表示第一低频输入信号的瞬态功率与第一低频输入信号的稳态功率的比值,W表示计权因子。
可选地,上述
Figure PCTCN2022101678-appb-000002
其中,P s表示当前帧的瞬态功率,P w当前帧的稳态功率。计权因子的取值可以与第一低频输入信号的当前功率相同。
在一些实现方式中,为了避免小信号误检,可以对一些小信号进行掩蔽,具体的,设置一个掩蔽阈值,当第一低频输入信号的功率小于掩蔽阈值时,取掩蔽阈值作为第一低频输入信号的功率。即,P d=max(P d,P th),其中,P d表示第一低频输入信号的功率,P th表示掩蔽阈值。同理,上述第一低频输入信号的瞬态功率与第一低频输入信号的稳态功率的比值也可以进行优化,具体是R r=max(R r,1)。
步骤4023、若输入信号的瞬态率大于预设的瞬态率阈值,则电子设备确定输入信号为瞬态信号,否则,该输入信号为稳态信号。
本申请实施例中,若第一低频输入信号为瞬态信号,则对该第一低频输入信号进行标记,并执行下述步骤403,对第一低频输入信号进行处理;若第一低频输入信号为稳态信号,则不对该第一低频输入信号做处理。
在一种实现方式中,在电子设备获取到第一低频输入信号之后,电子设备可以对第一低频输入信号进行低通滤波,然后再计算滤波后的第一低频输入信号的瞬态功率和稳态功率,以进一步确定第一低频输入信号是瞬态信号还是稳态信号。本申请实施例中,对第一低频输入信号进行低通滤波,得到更低频率范围的低频输入信号,并且通过低通滤波可以进一步降低第一低频输入信号中可能存在的高频信号,在此基础上,对滤波后的第一低频输入信号进行瞬态检测,能够降低瞬态检测的误检率。
步骤403、若第一低频输入信号为瞬态信号,则电子设备对第一低频输入信号进行信号包络调制,以得到第二低频输入信号。
本申请实施例中,对音频信号进行包络调制是调节信号的起振电压、响度以及衰减速度,使得包络调制后的音频信号的音质优于包络调制前的音频信号的音质。应理解,起振电压指的是可以使得扬声器振膜快速起振的电压,即起振电压决定振膜的起振速度。上述对第一低频输入信号进行包络调制得到的第二低频输入信号的起振电压大于第一低频输入信号的起振电压,且第二低频输入信号的响度大于第一低频输入信号的响度。
参考图6所示的包络调制的原理示意图,瞬态信号波形变化通常包括四个阶段,分别是:启动阶段(attack,记为A)、衰减阶段(decay,记为D)、持续阶段(sustain,记为S)以及释放阶段(release,记为R)。其中,每个阶段具有一定的持续时长,并且每个阶段对应有调节参数,例如,启动阶段的调节参数是启动时间和起振电压(target Ratio A),衰减阶段的调节参数是衰减时间和衰减速度(target Radio DR),持续阶段的调节参数是持续时间和音量(即幅度,sustain level),释放阶段的调节参数是释放时间和释放速度。可选地,衰减速度与释放速度可以相等。
应理解,对第一低频输入信号进行包络调制包括:对第一低频输入信号的四个阶段的参数进行调整,例如调整上述四个阶段的持续时长,调整起振电压、音量、释放速度中的至少一项,使得第二低频输入信号的起振电压大于第一低频输入信号的起振电压,并且第二低频输入信号的响度大于第一低频输入信号的响度。
步骤404、电子设备根据第二低频输入信号和第一高频输入信号,确定扬声器的输出信号。
本申请实施例中,电子设备开始将输入信号进行分频,分为第一低频输入信号和第一高频输入信号,然后对其中的第一低频输入信号进行处理,对第一高频输入信号不做处理,最后,将处理后的低频输入数据(即第二低频输入数据)与第一高频输入数据求和(是分频的逆过程),从而完成对输入信号的处理,得到输出信号,进而将输出信号送至扬声器进行播放。
示例性的,图7示意了本申请实施例提供的一种扬声器系统的框架。如图7所示,该扬声器系统包括分频单元、瞬态检测单元、包络调制单元以及输出单元,其中,分频单元用于对输入信号进行分频,得到低频输入信号和高频输入信号;瞬态检测单元用于对低频输入信号进行瞬态检测,包络调制单元用于在低频输入信号为瞬态信号的情况下,对低频输入信号进行包络调制,输出单元用于将高频输入信号和包络调制后的低频输入信号进行混合,得到输入出信号,再输入至扬声器播放,结合图7可以图4以及图5中的步骤进行理解。
本申请实施例提供的提升扬声器的音质的方法中,对输入信号中的低频信号进行瞬态检测,若输入信号是瞬态信号,则采用包络调制对瞬态信号进行增强,由于扬声器播放一段音频信号时,扬声器播放音频信号中的低频信号的音质关系扬声器的性能好坏,而低频信号中的瞬态信号通常反映音频信号的重要信息,因此对低频信号中的瞬态信号进行调制,提升低频瞬态信号的响度,并调节低频瞬态信号的动态范围,从而扬声器播放该处理后的音频信号时,音频信号的低频音效较好,即通过本申请实施例的技术方案能够提升扬声器的音质。
可选地,结合图4,如图8所示,本申请实施例提供的提升扬声器的音质的方法还包括步骤405至步骤407。
步骤405、电子设备对扬声器的第一高频输入信号进行分频,以获取第一中频输入信号和第二高频输入信号。
上述第一中频输入信号包括第一高频输入信号中低于第二预设频点的信号,第二高频输入信号包括第一高频输入信号中高于第二预设频点的信号,且第二预设频点高于第一预设频点。
示例性的,第二预设频点可以为1500~2500Hz范围内的频点,例如第二预设频点可以是1500,1750,2000,2250,或2500Hz等等。
需要说明的是,第二预设频点处的信号可以包含在第一中频输入信号中,也可以包含在第二高频输入信号,或者还可以同时包含在第一中频输入信号和第二高频输入信号中,本申请实施例不作限定。
本申请实施例中,电子设备可以将输入信号分频为两种频段的信号,即上述低频 输入信号和高频输入信号,进一步地,在对高频输入信号进行分频,分为中频输入信号和新的高频输入信号。
可选地,电子设备也可以直接将输入信号分频为三种频段的信号,即低频信号、中频信号以及高频信号。也就是说,当电子设备开始处理输入信号时,电子设备直接对输入信号分频,将输入信号分为上述的第一低频输入信号、第一中频输入信号和第二高频输入信号。
步骤406、电子设备对第一中频输入信号进行瞬态检测,以确定第一中频输入信号是否为瞬态信号。
步骤407、若第一中频输入信号为瞬态信号,则对第一中频输入信号进行信号包络调制,以得到第二中频输入信号。
其中,第二中频输入信号的起振电压大于第一中频输入信号的起振电压,且第二中频输入信号的响度大于第一中频输入信号的响度。
上述步骤406和步骤407中对于第一中频输入信号进行瞬态检测和包络调制的方法与上述实施例中对第一低频输入信号进行瞬态检测和包络调制的方法类似,因此,对于步骤406和步骤407的相关描述可以参考上述实施例中对于步骤402和步骤403的详细描述,此处不再赘述。应注意,二者的区别是进行瞬态检测和包络调制时设置的一些参数可能不同。
基于上述步骤405至步骤407,本申请实施例中,电子设备确定扬声器的输出信号的方法具体包括步骤408,即上述的步骤404被替换为步骤408。
步骤408、电子设备对根据第二低频输入信号、第二中频输入信号以及第二高频输入信号,确定扬声器的输出信号。
可选的,电子设备可以对第二低频输入信号、第二中频输入信号以及第二高频输入信号求和,得到扬声器的输出信号。
示例性的,图9示意了本申请实施例提供的另一种扬声器系统的框架。如图9所示,该扬声器系统包括分频单元、第一瞬态检测单元、第一包络调制单元、第二瞬态检测单元、第二包络调制单元以及输出单元,其中,分频单元用于对输入信号进行分频,以得到低频输入信号、中频输入信号以及高频输入信号;第一瞬态检测单元用于对低频输入信号进行瞬态检测,第一包络调制单元用于在低频输入信号为瞬态信号的情况下,对该低频输入信号进行包络调制;第二瞬态检测单元用于对中频输入信号进行瞬态检测(例如步骤406),第二包络调制单元用于在中频输入信号为瞬态信号的情况下,对该中频输入信号进行包络调制(例如步骤407);输出单元用于将高频输入信号、包络调制后的低频输入信号以及包络调制后的中频输入信号进行混合,得到输入出信号,再输入至扬声器播放(例如步骤408)。
本申请实施例中,对输入信号中的中频信号也进行瞬态检测,并对瞬态信号进行包络调制,对中频信号进行增强,总体上提升扬声器的音质。
可选地,结合图8,如图10所示,上述第一低频输入信号为瞬态信号,且电子设备的扬声器是较小型的扬声器,其低频重放能力较弱的情况下,在对第一低频输入信号进行信号包络调制之前(即步骤403之前),本申请实施例提供的提升扬声器的音质的方法还包括步骤409和步骤410。
步骤409、电子设备生成低频辅助信号。
本申请实施例中,低频辅助信号的作用是辅助增强上述第一低频输入信号的响度,优化第一低频输入信号的动态范围。
本申请实施例中,生成低频辅助信号的具体方法包括:
首先,生成第一辅助信号,生成第一辅助信号的方法可以包括多种,在一种实现方式中,第一辅助信号满足:
signal_h=e -A×sin(2πf)
其中,signal_h表示第一辅助信号,A表示信号幅度影响因子,f为扬声器的中心频率。A的取值范围可以是10~50,A的具体的取值可以由系统推定或者由用户设置,例如可以是10,25,或50等等;f的取值范围可以是50~150Hz,具体的取值可以由系统推定或者由用户设置,例如可以是50Hz,100Hz,或150Hz等等。
其次,对第一辅助信号进行高通滤波,得到低频辅助信号。
本申请实施例中,电子设备对该第一辅助信号进行高通滤波,滤除第一辅助信号中的频率过低的一些信号滤除,得到低频辅助信号,在一种实现方式中,高通滤波的滤波频率可以为上述中心频率f的1.5倍左右。
步骤410、电子设备在第一低频输入信号中添加低频辅助信号,以获得第一辅助增强信号。
本申请实施例中,在第一低频输入信号中添加低频辅助信号指的是第一低频输入信号与低频辅助信号求和。
一种实现方式中,电子设备可以根据第一低频输入信号的能量,在第一低频输入信号中添加一定比例的低频辅助信号,例如,第一低频输入信号的能量较低,则在第一低频输入信号中添加a倍的低频辅助信号,0<a<1。
基于此,上述对第一低频输入信号进行信号包络调整,以得到第二低频输入信号(即步骤403)具体通过步骤4031实现:
步骤4031、对第一辅助增强信号进行信号包络调制,以得到第二低频输入信号。
示例性的,图11是本申请实施例提供的另一种扬声器系统框架的示意图,该扬声器系统在图9示意的扬声器系统的基础上还包括辅助增强单元。该辅助增强单元执行步骤409至步骤410的过程对第一低频输入信号进行辅助增强。
可选地,结合图10,如图12所示,上述第一低频输入信号为瞬态信号,在对第一低频输入信号进行信号包络调制之前,本申请实施例提供的提升扬声器的音质的方法还可以包括步骤411。
步骤411、电子设备对第一低频输入信号进行相位补偿,以获得第一相位补偿信号。
应理解,第一相位补偿信号是相位补偿之后的第一低频输入信号,在上述电子设备对输入信号进行分频以及辅助增强的过程中,可能对第一低频输入信号的相位造成影响,导致低频输入信号的相位产生偏差,不再是线性相位,因此,对第一低频输入信号进行必要的线性相位补偿,将第一低频输入信号的相位校正为线性相位,从而保 证低频音质。
具体的,电子设备计算测试信号经该扬声器系统处理后的信号(可以为电信号或声信号),然后根据测试信号的计算结果与预设的标准信号生成相位补偿滤波器(具体是生成该相位补偿滤波器的系数),然后采用该相位补偿滤波器对第一低频输入信号进行处理,实现对第一低频输入信号的相位补偿。
基于此,上述对第一低频输入信号进行信号包络调整,以得到第二低频输入信号(即步骤403)具体通过步骤4032实现:
步骤4032、对第一相位补偿信号进行信号包络调制,以得到第二低频输入信号。
示例性的,图13是本申请实施例提供的又一种扬声器系统框架的示意图,该扬声器系统在图11示意的扬声器系统的基础上还包括相位补偿单元。该相位补偿单元执行步骤411的过程对第一低频输入信号进行线性相位补偿。
可选地,电子设备可以在执行完步骤410之后,在对第一低频输入信号进行包络调制(步骤403)之前,执行上述步骤411,即电子设备对辅助增强后的第一低频输入信号进行相位补偿。当然,当电子设备不执行上述步骤409至步骤410时,电子设备在检测第一低频输入信号(即步骤402)之后,在对第一低频输入信号进行包络调制(步骤403)之前,可以执行步骤410,具体根据实际情况确定,本申请实施例不作限定。
至此,电子设备完成对扬声器的输入信号的瞬态增强处理,能够改善扬声器的低频响度、调节扬声器的动态变化,提升扬声器的音质。
需要说明的是,在上述步骤401至步骤404之前,电子设备还可以对扬声器初始的待播放信号进行处理,得到用于瞬态增强处理的输入信号。如图14所示,在上述步骤401至步骤404之前,本申请实施例提供的提升扬声器的音质的方法还包括步骤1401至步骤1402。
步骤1401、电子设备对第一信号进行均衡处理,得到第二信号,该第一信号为输入至扬声器的初始的待播放信号。
上述扬声器的初始的待播放信号可以是电子设备采集的音频信号,也可以是电子设备从其他设备接收的音频信号,本申请实施例不作具体限定。
可选地,本申请实施例中,上述对第一信号进行均衡处理的具体方法可以是:采用biquard滤波器对第一信号进行均衡处理,能够改善扬声器的低频频率响应。关于采用biquard滤波器对第一信号进行处理的过程可以参考现有的biquard滤波器的工作原理,此处不再详述。
步骤1402、电子设备采用低音增强算法对第二信号进行处理,以得到扬声器的输入信号。
本申请实施例中,采用低音增强算法对第二信号进行处理具体是采用低频搁架滤波器对第二信号进行滤波处理,增强第二信号的低频响度(也可以称为低频量感)。具体的,上述步骤1402包括步骤1402a至步骤1402b。
步骤1402a、电子设备根据第二信号中的低频信号的能量,确定低频搁架滤波器的增益。
该低频搁架滤波器用于控制第二信号中的低频信号的响度。
本申请实施例中,参考图15所示的低频增强算法的流程示意图,首先,电子设备对第二信号进行低通滤波,得到第二信号中的低频信号;然后,电子设备计算低频信号中的每一个点(值)的能量与第二信号的总能量的比值,即计算低频信号的能量占比。
进一步的,根据低频信号的能量占比,确定低频搁架滤波器的增益。具体的,首先确定低频搁架滤波器的基础增益,然后对基础增益进行平滑,得到低频搁架滤波器的增益。
可选地,低频搁架滤波器的增益的平滑公式为:
G_current=G s*a+(1-a)*G_before
其中,G_current表示当前帧对应的低频搁架滤波器的增益,a为滤波增益的平滑系数,G_before为当前帧的前一帧的滤波增益,G s表示低频搁架滤波器的基础增益。
上述低频搁架滤波器的基础增益的确定方法包括:
对于能量占比小于或等于第一阈值的低频信号,G s=target,targetG为预设增益。
对于能量占比大于第一阈值,并且小于第二阈值的低频信号,G s=targetG-S*(ratio-rth1),其中,S为增益平滑系数,ratio为低频信号的能量占比,rth1为第一阈值。
对于能量占比大于第一阈值,并且能量占比大于或等于第二阈值的低频信号,G s=gth*targetG,其中,gth为增益系数。
步骤1402b、电子设备使用低频搁架滤波器对第二信号进行滤波,得到扬声器的输入信号。
示例性的,图16是本申请实施例提供的又一种扬声器系统的框架示意图,该扬声器系统包括确定单元、增益更新单元以及滤波单元,确定单元用于确定第二信号中的低频信号的能量占比,增益更新单元用于根据第二信号中的低频信号的能量占比确定低频搁架滤波器的增益,滤波单元用于对第二信号进行滤波,滤波后的信号作为瞬态增强处理过程的输入信号(即上述步骤401中的扬声器的输入信号)。
本申请实施例中,根据第二信号中的低频信号的能量,有区分地对不同能量的低频信号进行不同程度的响度提升,即按照低频信号的能量为低频信号设置不同的增益,综上可知,在步骤1402中根据第二信号的低频信号的能量的特点,动态地、自适应地提升第二信号中的低频信号的响度的,如此,能够提高低频信号的清晰度。
可选地,在本申请实施例中,对扬声器的输入信号进行瞬态增强处理得到扬声器的输出信号之后,电子设备还可以对该输出信号继续进行处理,进一步提升小型扬声器的低音音质。需要说明的是,为了便于描述,在以下实施例中,将步骤404处理完成之后得到的输出信号统一称为第一输出信号。
在步骤404之后,本申请实施例提供的提升扬声器的音质的方法还可以包括:对第一输出信号进行虚拟低音处理,以得到虚拟低音输出信号。
应理解,虚拟低音处理是一种基于心理声学的一种提升低音音效的方法,从心理声学的角度来衡量,上述通过虚拟低音处理后的输出信号(即虚拟低音输出信号)的心理感知低频响度大于第一输出信号的心理感知低频响度。在一种实施方式中,心理感知低频响度可以根据心理声学模型来确定。
具体的,如图17所示,对第一输出信号进行虚拟低音处理,以得到虚拟低音输出的方法可以包括步骤1701至步骤1705。
步骤1701、电子设备对第一输出信号进行分频处理,以获取第一低频输出信号和第一高频输出信号。
其中,第一低频输出信号包括第一输出信号中低于第三预设频点的信号,第一高频输出信号包括第一输出信号中高于第三预设频点的信号。
示例性的,第三预设频点可以是100~400Hz范围内的频点,例如第三预设频点可以是100,150,250,300或400Hz等等。
需要说明的是,第三预设频点处的信号可以包含在第一低频输出信号中,也可以包含在第一高频输出信号中,或者还可以同时包含在第一低频输出信号和第一高频输出信号中,本申请实施例不作限定。
步骤1702、电子设备根据第一低频输出信号生成第一低频输出信号的谐波信号。
示例性的,可以采用下述公式生成第一低频输出信号的谐波信号:
Signal_out=cos(Coeff d×Signal_in)-b f×Signal_in
Coeff d=a f×(0.5π-0.8)+0.8
其中,a f和b f为输入的系数,0<a f<1,0<b f<1,Signal_in是第一低频输出信号。其中,a f用于调整不同频率的谐波信号的幅度的比例,b f用于调整谐波信号的总能量与第一低频输出信号(第一低频输出信号也可以称为基波信号)的总能量之间的比例。
可选地,生成第一低频输出信号的谐波信号的数量以及谐波的频率可以根据实际需求确定,例如,可以生成第一低频输出信号的3个谐波,谐波的频率依次是3f、5f、7f,f为第一低频输出信号原本的频率。
步骤1703、电子设备将第一低频输出信号的谐波信号和第一低频输出信号进行混合,以得到第一混合信号。
可选地,本申请实施例中,按照信号的能量,第一低频输出信号的谐波信号和第一低频输出信号可以按照一定的比例进行混合。
可选地,电子设备可以对第一低频输出信号进行归一化之后,根据归一化的第一低频输出信号生成谐波信号,然后再将生成的谐波信号与归一化后的第一低频输出信号进行混合。
步骤1704、电子设备对第一混合信号和第一高频输出信号进行相位同步处理,以得到第二混合信号和第二高频输出信号,该第二混合信号的相位的变化量与第二高频输出信号的相位的变化量相等。
步骤1705、电子设备根据第二混合信号和第二高频输出信号,获得虚拟低音输出信号。
可选地,本申请实施例中,电子设备获得第一混合信号之后,可以先对该第一混合信号进行带通滤波,滤除该第一混合信号中的可能存在的高频信号和低频信号的杂波成分,并检测滤波后的第一混合信号的最大幅度,然后根据该最大幅度还原第一混合信号(即上述归一化的逆过程),得到还原的第一混合信号。进一步的,电子设备再对还原的第一混合信号进行低通滤波,滤波高频噪声,得到去噪的第一混合信号,最后,采用全通滤波器对去噪的第一混合信号与第一高频输出信号进行相位同步,进 而得到虚拟低音输出信号。
示例性的,图18示意了本申请实施例提供的一种扬声器系统的框架。如图18所示,该扬声器系统包括分频单元、谐波生成单元、信号混合单元以及相位同步单元,分频单元对第一输出信号进行分频,谐波生成单元生成分频后的第一低频输出信号的谐波信号,信号混合单元将谐波信号与第一低频输出信号进行混合,以得到第一混合信号,相位同步单元对第一混合信号与第一高频信号进行相位同步,以得到第二混合信号和第二高频输出信号,并且对根据第二混合信号和第二高频输出信号获得虚拟低音输出信号。
可选地,在本申请实施例中,对扬声器的第一输出信号进行虚拟低音处之后,电子设备还可以对虚拟低音输出信号继续进行处理(位移控制),以保护扬声器的振膜位移不超过扬声器的位移保护阈值。需要说明的是,为了便于描述,在以下实施例中,将虚拟低音输出信号统一称为第二输出信号。
如图19所示,在上述步骤404之后,本申请实施例提供的提升扬声器的音质的方法还可以包括步骤1901至步骤1903。
步骤1901、电子设备获取包括一个或多个校正系数的第一位移预测模型,该校正系数用于控制第一位移预测模型的输出。
第一位移预测模型用于模拟扬声器的性能以预测扬声器的振膜的位移,一个或多个校正系数用于控制第一位移预测模型的输出。
示例性的,第一位移预测模型可以满足如下表达式:
Figure PCTCN2022101678-appb-000003
其中,ax 0=1,
Figure PCTCN2022101678-appb-000004
Figure PCTCN2022101678-appb-000005
d 0=α*spk.Kms*spk.Re,
Figure PCTCN2022101678-appb-000006
Figure PCTCN2022101678-appb-000007
b j=d 0+d 1+d 2
Figure PCTCN2022101678-appb-000008
bx 2=bx 3=-bx 0
其中,f s为采样率,α、β、γ、Ω为校正系数,α可以用于调整位移预测模型的低频输出,β用于调整位移预测模型的包含扬声器共振频率的频率区间的输出,γ用于调整位移预测模型的中频输出,Ω用于调整位移预测模型的全频段输出。spk.Bl为初始参数中扬声器的磁力系数,spk.Kms为初始参数中扬声器的劲度系数,spk.Rms为初始参数中扬声器的功率。ax、bx是生成的IIR滤波器的系数。
需要说明的是,可以根据实际需求配置第一位移预测模型的表达式,以及第一位移预测模型中包括的校正系数的个数,以及每个校正系数控制的内容,本申请实施例对此不予具体限定。
具体的,根据应用场景的不同,第一位移预测模型的内容不同,可以包括但不限于下述几种情况:
情况1、应用于电子设备开发或生产调试阶段保护扬声器振膜位移的场景中,电子设备中还未配置位移预测模型,电子设备在步骤1901中则配置初始模型作为第一位 移预测模型。
在情况1中,初始模型中的校正系数可以为1。
进一步的,位移预测模型中还可以包括初始参数,初始参数为位移预测模型中与扬声器硬件特性相关的参数。相应的,在情况1中,还可以包括:获取扬声器的阻抗曲线,根据阻抗曲线确定移预测模型的初始参数。其中,初始参数为位移预测模型中与扬声器硬件特性相关的参数。
例如,初始参数可以为扬声器的磁力系数spk.Bl,扬声器的劲度系数spk.Kms,扬声器的功率spk.Rms。
示例性的,获取扬声器的阻抗曲线,根据阻抗曲线确定移预测模型的初始参数,包括:将预设输入信号输入扬声器,采集扬声器的电压及电流;根据电压及电流,确定扬声器的阻抗曲线;根据阻抗曲线通过曲线拟合或者参数辨识,确定移预测模型的初始参数。
其中,预设输入信号可以为特定的噪音信号或者其他信号,不予限定。示例性的,可以采集一段时长内扬声器的电压及对应的电流信号,进行傅里叶变换,并用电压频谱除以电流频谱得到阻抗曲线。
情况2、应用于电子设备开发或生产调试阶段保护扬声器振膜位移的场景中,电子设备中配置了初始模型但还未调整校正系数,电子设备在步骤1901中则获取配置的初始模型作为第一位移预测模型。
情况3、应用于电子设备出厂后使用阶段保护扬声器振膜位移的场景中,第一位移预测模型可以为执行步骤1901时,电子设备中存储的用于预测扬声器振膜位移的位移预测模型。电子设备中配置的第一位移预测模型可以为情况1或情况2中,通过校正后得到的位移预测模型。
步骤1902、电子设备调整第一位移预测模型中的至少一个校正系数,得到第二位移预测模型,该第二位移预测模型输出的预测位移与扬声器的振膜的实际位移的差值的绝对值,小于第一位移预测模型输出的预测位移与扬声器的振膜的实际位移的差值的绝对值。
该扬声器的振膜的实际位移为扬声器的振膜相对于初始位置的移动距离实际测量值。
可以理解的是,第二位移预测模型是由第一位移预测模型调整校正系数后得到,第二位移预测模型的表达式与第一位移预测模型的表达式相同。
具体的,扬声器的实际位移可以通过测量得到,然后按照校正系数调整规则,反复调整第一位移预测模型中的校正系数,得到第二位移预测模型。
例如,可以采用激光测量扬声器的振膜的实际位移,或者,也可以采用其他方法测量扬声器的振膜的实际位移,本申请实施例对此不予限定。
应理解,可以根据实际需求配置校正系数调整规则的内容,本申请实施例对此并不进行具体限定。
示例性的,校正系数调整规则可以为:为每个校正系数配置调整步长,按照预设的校正系数调整顺序,依次按照调整步长调整每个校正系数,直到得到第二位移预测模型。
示例性的,校正系数调整规则可以为:比较第一位移预测模型输出的预测位移,与扬声器播放输入第一位移预测模型的输入信号时振膜的实际位移,根据两者的大小关系,查找预设对应关系,获取调整的校正系数的内容以及调整值。其中,该预测对应关系中存储了不同的预测位移与实际位移的大小关系,以及不同大小关系对应的需调整的校正系数以及调整值。
步骤1903、电子设备根据扬声器的位移保护阈值及第二位移预测模型输出的预测位移,控制第二输出信号的增益,使得扬声器播放第二输出信号时的振膜位移小于或等于位移保护阈值。
可选地,上述扬声器的位移保护阈值为扬声器的振膜的最大位移。
一种可能的实现方式中,在预测位移大于或等于位移保护阈值的情况下,电子设备将第二输出信号整体进行衰减,使得扬声器播放第二输出信号的振膜位移小于或等于扬声器的位移保护阈值。
另一种可能的实现方式中,基于扬声器的位移主要由低频信号产生的原理,当预测位移大于或等于位移保护阈值时,可以通过高通滤波器的方式抑制第二输出信号中的低频信号,通过中高频信号,以控制扬声器的第二输出信号的增益,降低扬声器的位移的同时,保证扬声器的响度。具体的,电子设备根据第二位移预测模型输出的预测位移确定高通滤波器的频率参数,进而使用高通滤波器对上述第二输出信号滤波,使得扬声器播放第二输出信号的振膜的位移小于或等于扬声器的位移保护阈值。
本申请实施例中,电子设备根据第二位移预测模型输出的预测位移确定高通滤波器的频率参数的具体方法是:电子设备采用n组频率参数对第二位移预测模型输出的预测位移进行滤波;选取滤波输出值位于位移保护阈值两侧,且与位移保护阈值的差值的绝对值最小的两组频率参数;在包括该两组频率参数的频率参数区间内,选取第一频率参数作为高通滤波器的频率参数。其中,n组频率参数的通带不同;n大于2。
其中,可以根据实际应用经验配置n组频率参数的具体取值,本申请实施例不再赘述。
应理解,在包括该两组频率参数的频率参数区间内,选取第一频率参数,可以是第一频率参数指示的高通滤波器的通带,位于该两组频率参数的频率参数指示的高通滤波器的通道之间。
一种可能的实现方式中,在包括该两组频率参数的频率参数区间内,选取第一频率参数,可以实现为:在包括该两组频率参数的频率参数区间内,选取该两组频率参数的中间值,作为第一频率参数。
示例性的,在包括该两组频率参数的频率参数区间内,选取该两组频率参数的中间值,作为第一频率参数,具体可以实现为:选取该两组频率参数的中心频率的平均值,作为第一频率参数的中心频率,得到第一频率参数。或者,选取该两组频率参数的起始频率的平均值,作为第一频率参数的起始频率,得到第一频率参数。或者,选取该两组频率参数的截止频率的平均值,作为第一频率参数的截止频率,得到第一频率参数。
另一种可能的实现方式中,在包括该两组频率参数的频率参数区间内,选取第一频率参数,可以实现为:在该两组频率参数之间进行插值,得到多组待选频率参数; 选取多组待选频率参数中,对第二位移预测模型输出的预测位移的滤波输出值与位移保护阈值的差值的绝对值最小的待选频率参数,作为第一频率参数。
可选地,在该两组频率参数之间进行插值可以实现为:对该两组频率参数的中心频率插值,或者,对该两组频率参数的起始频率插值,或者,对该两组频率参数的截止频率插值。
一种可能的实现方式中,在该两组频率参数之间进行插值时,可以插预设数量的值,也可以按照预设频率间距插值,或者也可以按照其他方式插值,本申请实施例对此不进行具体限定。
另一种可能的实现方式中,在该两组频率参数之间进行插值时,可以反复插值,直至获取到对第二位移预测模型输出的预测位移的滤波输出值与位移保护阈值的差值相等的待选频率参数,作为第一频率参数。
本申请实施例中,上述第二位移预测模型更真实的反映扬声器的特点,保证输出的预测位移更准确,进而可以更精确的进行位移保护,也就实现了在保护扬声器振膜位移的前提下,最大化发挥扬声器的硬件潜力,提升扬声器的外放响度。
可选地,本申请实施例中,电子设备还可以采集扬声器电流及电压,获取阻抗曲线,然后提取扬声器的共振频率f 0,并根据共振频率f 0和振动质量Mms,计算出扬声器的实时力学劲度Kms,Mms为扬声器的固有硬件参数;进而电子设备将当前使用的位移预测模型(即上述第二位移预测模型)中的Kms更新为实时Kms,Kms=(2*π*f 0) 2*Mms。
进一步的,随着扬声器的温度升高,对于同一信号扬声器的振膜的位移也会增大,本申请实施例中,电子设备还可以根据温度修正上述对第二输出信号进行滤波的高通滤波器的频率参数,保证对于第二输出信号的控制符合扬声器当前的特性,进而保证扬声器外放响度的提升。
具体的,首先电子设备根据扬声器的阻抗,确定扬声器的实时温度。
可选地,扬声器的实时温度T可以满足如下表达式:
Figure PCTCN2022101678-appb-000009
σ为温升系数,Re为扬声器的阻抗,Re 0为扬声器在室温的阻抗,T 0为预设室温。σ、Re为该扬声器的固有参数。
其次,电子设备根据扬声器的实时温度,确定频率修正系数。
其中,频率修正系数Coeff满足如下表达式:
Figure PCTCN2022101678-appb-000010
频率修正系数Coeff满足如下表达式满足的表达式中的参数均为预先设定值,例如,T hot为热状态温度门限,T cold为冷状态温度门限,Coeff 0为初始频率修正系数。本申请实施例对预先设定值的具体取值不予限定。频率修正系数Coeff为频率偏移量,或者通带偏移量。
最后,电子设备根据频率修正系数,修正滤波的频率参数,以修正后的频率参数对第二输出信号滤波。根据频率修正系数,修正滤波的频率参数,是指将滤波的频率参数指示的高通滤波器的通道,偏移频率修正系数的值,得到修正后的频率参数。
示例性的,图20示意了本申请实施例提供的一种扬声器系统的框架。如图20所 示,该扬声器系统包括位移预测模型(调整校正参数后的第二位移预测模型)、增益控制单元、确定单元、功放单元(放大器)、温度计算单元和温度修正单元。第二输出信号输入位移预测模型,输出预测位移,确定单元确定高通滤波器的频率参数,增益控制单元控制第二输出信号的增益后输入功放单元;功放单元将数字信号转换为模拟信号后,输入扬声器播放。温度计算单元计算扬声器的实时温度,温度修正单元确定频率修正系数输入增益控制单元,由增益控制单元修正滤波的频率参数,修正后的频率参数用于控制第二输出信号的增益。
可选地,在本申请实施例中,电子设备通过执行上述步骤1901至步骤1903对扬声器的第二输出信号进行增益控制以保护扬声器的位移,在步骤1901至步骤1903,电子设备还可以对输出信号继续进行处理,减小信号失真,从而进一步提升扬声器的音质。需要说明的是,为了便于描述,在以下实施例中,将步骤1903处理完成之后得到的输出信号统一称为第三输出信号。
如图21所示,在步骤1902之后,本申请实施例提供的提升扬声器的音质的方法还可以包括步骤2101至步骤2102。
步骤2101、电子设备根据扬声器的线圈温度,调整扬声器中预先配置的第一非线性补偿模型的非线性参数,以得到第二非线性补偿模型。
应理解,扬声器的非线性补偿模型对应多个非线性参数,确定扬声器的非线性补偿模型即获取扬声器的非线性参数。本申请实施例中,扬声器的非线性参数)包括扬声器的力因数BL、力学劲度Kms、电感Le以及阻尼Rm中的至少一个。
将扬声器中预先配置的非线性补偿模型的非线性参数称为第一非线性参数,将得到的扬声器的第二非线性补偿模型的非线性参数称为第二非线性参数。
本申请实施例中,扬声器的线圈温度可以根据扬声器的直流电阻确定,扬声器的线圈温度(也可以称为音圈温度)与扬声器的线圈的直流电阻之间的关系如下:
Figure PCTCN2022101678-appb-000011
其中,T为扬声器的线圈温度(与上述扬声器的实时温度含义相同),R为扬声器的线圈的直流电阻,η为温升系数,R 0为校准温度对应的线圈的直流电阻,通常在25摄氏度对音圈温度进行校准。
可选地,电子设备根据扬声器的线圈温度,调整扬声器中预先配置的非线性补偿模型的非线性参数的方法具体包括:根据扬声器的线圈的温度对预配置的非线性参数(即第一非线性参数)进行插值,得到扬声器的第二非线性参数。
以非线性参数中的力学劲度Kms为例,描述对第一非线性参数进行插值的过程。
首先,获取扬声器的线圈的温度为不同的温度值时非线性参数Kms的特性曲线,该Kms的特性曲线是反映扬声器的劲度系数与扬声器的位移之间的关系的曲线,例如,以5摄氏度为间隔,获取从10摄氏度至55摄氏度该Kms的10条特性曲线,并将该10条特性曲线的数据进行存储。
其次,根据扬声器的线圈的温度、温度阈值1以及温度阈值2,对非线性参数Kms(x)的特性曲线进行线性插值,得到目标特性曲线(该目标特性曲线可以理解为第三非线性参数的特性曲线的估计结果)。其中,温度阈值2大于温度阈值1,该第三非 线性参数可以理解为当前扬声器的线圈的温度所对应的非线性参数。
示例性的,将扬声器的线圈的温度记为T,温度阈值1记为T min,温度阈值2记为T max,那么:
若T<T min,将T min对应的特性曲线作为目标特性曲线。
若T>T max,将T max对应的特性曲线作为目标特性曲线。
若T min≤T≤T max,根据扬声器的线圈的温度,对T min对应的特性曲线和T max对应的特性曲线进行线性插值,生成目标特性曲线。
最后,对目标特性曲线进行多项式拟合,得到该目标特性曲线对应的多项式的各项系数,该各项系数与非线性参数具有一一对应的关系,如此,可以根据多项式的各项系数确定扬声器的第二非线性参数。
示例性的,对于非线性参数Kms,假设上述拟合的二项式为:
f(x)=a 0+a 1x+a 2x 2+a 3x 3+a 4x 4
其中,系数a 1对应非线性参数Kms的一阶系数,系数a 2对应非线性参数Kms的二阶系数,系数a 2对应非线性参数Kms的三阶系数,系数a 4对应非线性参数Kms的四阶系数。
对于非线性参数中的其他类的参数,例如Rm(v),也可以采用上述类似的线性插值的方法得到,本申请实施例不再详述。
可选地,非线性参数的特性曲线可以为表格形式的数据,也可以为其他形式的数据或文件,本申请实施例不作限定。
应理解,扬声器的非线性参数可能是实时变化的,例如非线性参数随着扬声器的音圈温度的变化而发生变化,本申请实施例中,根据扬声器当前的温度,对扬声器的第一非线性参数进行插值,可以实时地调整扬声器的非线性参数,得到第二非线性参数,第二非线性参数的准确性较高。
应理解,扬声器的非线性参数还可能随着扬声器位移的变化而发生变化,本申请实施例中,可以采用类似的线性插值的方法,根据扬声器的直流电阻,确定扬声器的位移,然后根据扬声器的位移,对扬声器的第一非线性参数进行插值,得到扬声器的第二非线性参数,从而得到扬声器的非线性模型。
步骤2102、电子设备采用第二非线性模型对输出信号进行信号补偿。
本申请实施例中,由于确定的扬声器的第二非线性参数的准确定较高,如此,根据该第二非线性参数对第三输出信号做信号补偿,信号补偿效果较好,能够有效地减小信号失真,提升扬声器的音质。
可选地,本申请实施例提供的提升扬声器的音质的方法还包括:对补偿后的第三输出信号滤波。
本申请实施例中,可以采用陷波器对补偿后的第三输出信号滤波,可以调整共振频率附近扬声器振膜的速度,进而降低输出信号的失真,可以有效地提升扬声器的音质。
综上所述可知,本申请实施例中,可以对扬声器待播放的音频信号进行一系列的处理,例如依次为均衡处理、低音增强、瞬态增强、虚拟低音处理、位移控制、非线 性补偿。可选地,对于一些大尺寸、低频能力较强的扬声器可以不执行上述虚拟低音处理和/或非线性补偿的过程。
示例性的,图22示出了本申请实施例提供的一种扬声器系统的框架示意图,如图22所示,扬声器系统可以包括均衡处理模块、低音增强模块、瞬态增强模块、虚拟低音模块、位移控制模块以及非线性补偿模块,均衡处理模块用于执行上述步骤1401,低音增强模块用于执行上述步骤1402,瞬态增强模块用于执行上述步骤401至步骤404、虚拟低音模块用于执行上述步骤1701至步骤1705,位移控制模块用于执行步骤1901至步骤1903,非线性补偿模块用于执行上述步骤2101至步骤2102。
相应地,本申请实施例提供一种电子设备,可以根据上述方法示例对电子设备进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本发明实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。
在采用对应各个功能划分各个功能模块的情况下,图23示出上述实施例中所涉及的电子设备的一种可能的结构示意图。如图23所示,该电子设备包括第一获取模块2301、第一确定模块2302、包络调制模块2303以及第二确定模块2304。
第一获取模块2301,用于对扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号,扬声器的输入信号为时域信号,第一低频输入信号包括输入信号中低于第一预设频点的信号,第一高频输入信号包括输入信号中高于第一预设频点的信号,例如执行上述方法实施例中的步骤401。
第一确定模块2032,用于对第一低频输入信号进行瞬态检测,以确定第一低频输入信号是否为瞬态信号,例如执行上述方法实施例中的步骤402(包括步骤4021至步骤4023)。
包络调制模块2303,用于在第一低频输入信号为瞬态信号的情况下,对第一低频输入信号进行信号包络调制,以得到第二低频输入信号;第二低频输入信号的起振电压大于第一低频输入信号的起振电压,且第二低频输入信号的响度大于第一低频输入信号的响度,例如执行上述方法实施例中的步骤403。
第二确定模块2304,用于根据第二低频输入信号和第一高频输入信号,确定扬声器的输出信号,例如执行上述方法实施例中的步骤404。
可选地,上述第一获取模块2301还用于对扬声器的第一高频输入信号进行分频,以获取第一中频输入信号和第二高频输入信号,该第一中频输入信号包括第一高频输入信号中低于第二预设频点的信号,第二高频输入信号包括第一高频输入信号中高于第二预设频点的信号,且第二预设频点高于第一预设频点,例如执行上述方法实施例中的步骤405。
第一确定模块2302还用于对第一中频输入信号进行瞬态检测,以确定第一中频输入信号是否为瞬态信号,例如执行上述方法实施例中的步骤406。
包络调制模块2303还用于在第一中频输入信号为瞬态信号的情况下,对第一中频输入信号进行信号包络调制,以得到第二中频输入信号;第二中频输入信号的起振电压大于第一中频输入信号的起振电压,且第二中频输入信号的响度大于第一中频输入 信号的响度,例如执行上述方法实施例中的步骤407。
第二确定模块2304具体用于根据第二低频输入信号、第二中频输入信号以及第二高频输入信号,得到扬声器的输出信号,例如执行上述方法实施例中的步骤408。
可选地,本申请实施例提供的电子设备还包括生成模块2305和第二获取模块2306。生成模块2305用于生成低频辅助信号,例如执行上述方法实施例中的步骤409。第二获取模块2306用于在第一低频输入信号中添加低频辅助信号,以获得第一辅助增强信号,例如执行上述方法实施例中的步骤410。包络调制模块2303具体用于对第一辅助增强信号进行信号包络调制,以得到第二低频输入信号,例如执行上述方法实施例中的步骤4031。
可选地,本申请实施例提供的电子设备还包括相位补偿模块2307,该相位补偿模块2307用于对第一低频输入信号进行相位补偿,以获得第一相位补偿信号,例如执行上述方法实施例中的步骤411。包络调制模块2303具体用于对第一相位补偿信号进行信号包络调制,以得到第二低频输入信号,例如执行上述方法实施例中的步骤4032。
可选地,本申请实施例提供的电子设备还包括均衡处理模块2308和低音增强模块2309。均衡处理模块2308用于对第一信号进行均衡处理,得到第二信号,第一信号为输入至扬声器的初始的待播放信号,例如执行上述方法实施例中的步骤1401。低音增强模块2309用于采用低音增强算法对第二信号进行处理,以得到扬声器的输入信号,例如执行上述方法实施例中的步骤1402(包括步骤1402a至步骤1402b)。
可选地,本申请实施例提供的电子设备还包括第三获取模块2310、第一调整模块2311以及控制模块2312。第三获取模块2310用于获取包括一个或多个校正系数的第一位移预测模型,第一位移预测模型用于模拟扬声器的性能以预测扬声器的振膜的位移,一个或多个校正系数用于控制第一位移预测模型的输出,例如执行上述方法实施例中的步骤1901。第一调整模块2311用于调整第一位移预测模型中的至少一个校正系数,得到第二位移预测模型;第二位移预测模型输出的预测位移与振膜的实际位移的差值的绝对值,小于第一位移预测模型输出的预测位移与扬声器的振膜实际位移的差值的绝对值;该扬声器的振膜实际位移为扬声器的振膜相对于初始位置的移动距离实际测量值,例如执行上述方法实施例中的步骤1902。控制模块2312用于根据扬声器的位移保护阈值及第二位移预测模型输出的预测位移,控制输出信号的增益,使得扬声器播放输出信号时的振膜位移小于或等于位移保护阈值;该位移保护阈值为扬声器的振膜的最大位移,例如执行上述方法实施例中的步骤1903。
可选地,本申请实施例提供的电子设备还包括虚拟低音处理模块2313,该虚拟低音处理模块2313用于对扬声器的输出信号进行虚拟低音处理,以得到虚拟低音输出信号,该虚拟低音输出信号的心理感知低频响度大于扬声器的输出信号的心理感知低频响度,例如执行上述方法实施例中的步骤1701至步骤1705。
可选地,本申请实施例提供的电子设备还包括第二调整模块2314和信号补偿模块2315。第二调整模块2314用于根据扬声器的线圈温度,调整扬声器中预先配置的第一非线性补偿模型的非线性参数,以得到第二非线性补偿模型,例如执行上述方法实施例中的步骤2101。信号补偿模块2315用于采用第二非线性补偿模型对输出信号进行信号补偿,例如执行上述方法实施例中的步骤2102。
上述电子设备的各个模块还可以用于执行上述方法实施例中的其他动作,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。
在采用集成的单元的情况下,图24示出了上述实施例中所涉及的电子设备的另一种可能的结构示意图。如图24所示,本申请实施例提供的电子设备可以包括:处理模块2401和通信模块2402。处理模块2401可以用于对该电子设备的动作进行控制管理,例如,处理模块2401可以用于支持该电子设备执行上述方法实施例中的步骤401至步骤411、步骤1701至步骤1705、步骤1901至步骤1903、步骤2101至步骤2102,和/或用于本文所描述的技术的其它过程。通信模块2402可以用于支持该电子设备与其他网络实体的通信。可选地,如图24所示,该电子设备还可以包括存储模块2403,用于存储该装置的程序代码和数据。
其中,处理模块2001可以是处理器或控制器(例如可以是上述如图3所示的处理器310),例如可以是中央处理器(central processing unit,CPU)、通用处理器、数字信号处理器(digital signal processor,DSP)、专用集成电路(application-specific integrated circuit,ASIC)、现场可编程门阵列(field programmable gate array,FPGA)或者其他可编程逻辑器件、晶体管逻辑器件、硬件部件或者其任意组合。其可以实现或执行结合本发明实施例公开内容所描述的各种示例性的逻辑方框、模块和电路。上述处理器也可以是实现计算功能的组合,例如包含一个或多个微处理器组合,DSP和微处理器的组合等等。通信模块2402可以是收发器、收发电路或通信接口等(例如可以是上述如图3所示的移动通信模块350或无线通信模块360)。存储模块2403可以是存储器(例如可以是上述如图1所示的内部存储器321)。
当处理模块2401为处理器,通信模块2402为收发器,存储模块2403为存储器时,处理器、收发器和存储器可以通过总线连接。总线可以是外设部件互连标准(peripheral component interconnect,PCI)总线或扩展工业标准结构(extended Industry standard architecture,EISA)总线等。总线可以分为地址总线、数据总线、控制总线等。
上述电子设备包含的模块实现上述功能的更多细节请参考前面各个方法实施例中的描述,在这里不再重复。
本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件程序实现时,可以全部或部分地以计算机程序产品的形式实现。该计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行该计算机指令时,全部或部分地产生按照本申请实施例中的流程或功能。该计算机可以是通用计算机、专用计算机、计算机网络或者其他可编程装置。该计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,该计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(digital subscriber line,DSL))方式或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心传输。该计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包括一个或多个可用 介质集成的服务器、数据中心等数据存储设备。该可用介质可以是磁性介质(例如,软盘、磁盘、磁带)、光介质(例如,数字视频光盘(digital video disc,DVD))、或者半导体介质(例如固态硬盘(solid state drives,SSD))等。
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)或处理器执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:快闪存储器、移动硬盘、只读存储器、随机存取存储器、磁碟或者光盘等各种可以存储程序代码的介质。
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何在本申请揭露的技术范围内的变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。

Claims (26)

  1. 一种提升扬声器的音质的方法,其特征在于,包括:
    对所述扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号,所述扬声器的输入信号为时域信号,所述第一低频输入信号包括所述输入信号中低于第一预设频点的信号,所述第一高频输入信号包括所述输入信号中高于所述第一预设频点的信号;
    对所述第一低频输入信号进行瞬态检测,以确定所述第一低频输入信号是否为瞬态信号;
    若所述第一低频输入信号为瞬态信号,则对所述第一低频输入信号进行信号包络调制,以得到第二低频输入信号;所述第二低频输入信号的起振电压大于所述第一低频输入信号的起振电压,且所述第二低频输入信号的响度大于所述第一低频输入信号的响度;
    根据所述第二低频输入信号和所述第一高频输入信号,确定所述扬声器的输出信号。
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:
    对所述扬声器的第一高频输入信号进行分频,以获取第一中频输入信号和第二高频输入信号,所述第一中频输入信号包括所述第一高频输入信号中低于第二预设频点的信号,所述第二高频输入信号包括所述第一高频输入信号中高于所述第二预设频点的信号,所述第二预设频点高于所述第一预设频点;
    对所述第一中频输入信号进行瞬态检测,以确定所述第一中频输入信号是否为瞬态信号;
    若所述第一中频输入信号为瞬态信号,则对所述第一中频输入信号进行信号包络调制,以得到第二中频输入信号;所述第二中频输入信号的起振电压大于所述第一中频输入信号的起振电压,且所述第二中频输入信号的响度大于所述第一中频输入信号的响度;
    所述根据所述第二低频输入信号和所述第一高频输入信号,确定所述扬声器的输出信号,包括:
    根据所述第二低频输入信号、所述第二中频输入信号以及所述第二高频输入信号,得到所述扬声器的输出信号。
  3. 根据权利要求1或2所述的方法,其特征在于,所述第一低频输入信号为瞬态信号,在对所述第一低频输入信号进行信号包络调制之前,所述方法还包括:
    生成低频辅助信号;
    在所述第一低频输入信号中添加所述低频辅助信号,以获得第一辅助增强信号;
    所述对所述第一低频输入信号进行信号包络调制,以得到第二低频输入信号包括:
    对所述第一辅助增强信号进行信号包络调制,以得到所述第二低频输入信号。
  4. 根据权利要求3所述的方法,其特征在于,所述生成低频辅助信号,包括:
    生成第一辅助信号,所述第一辅助信号满足:
    signal_h=e -A×sin(2πf)
    其中,signal_h表示所述低频辅助信号,A表示信号幅度影响因子,f为所述扬声器的中心频率;
    对所述第一辅助信号进行高通滤波,以得到所述低频辅助信号。
  5. 根据权利要求1-4中任一项所述的方法,其特征在于,所述第一低频输入信号为瞬态信号,在对所述第一低频输入信号进行信号包络调制之前,所述方法还包括:
    对所述第一低频输入信号进行相位补偿,以获得第一相位补偿信号;
    所述对所述第一低频输入信号进行信号包络调制,以得到第二低频输入信号包括:
    对所述第一相位补偿信号进行信号包络调制,以得到所述第二低频输入信号。
  6. 根据权利要求1-5中任一项所述的方法,其特征在于,对所述第一低频输入信号进行瞬态检测,确定所述第一低频输入信号是否瞬态信号,包括:
    确定所述第一低频输入信号的瞬态功率和稳态功率;
    根据所述第一低频输入信号的瞬态功率和稳态功率确定所述第一低频输入信号的瞬时率;所述第一低频输入信号的瞬时率满足:T r=(R r-1) 2×W,其中,T r表示所述第一低频输入信号的瞬时率,R r表示所述第一低频输入信号的瞬态功率与所述第一低频输入信号的稳态功率的比值,W表示计权因子,W的取值与所述第一低频输入信号的当前功率相同;
    若所述输入信号的瞬态率大于预设的瞬态率阈值,则确定所述第一低频输入信号为瞬态信号。
  7. 根据权利要求1-6中任一项所述的方法,其特征在于,所述方法还包括:
    对第一信号进行均衡处理,得到第二信号;所述第一信号为输入至所述扬声器的初始的待播放信号;
    采用低音增强算法对所述第二信号进行处理,以得到所述扬声器的输入信号。
  8. 根据权利要求7述的方法,其特征在于,所述采用低音增强算法对所述第二信号进行处理,得到所述扬声器的输入信号,包括:
    根据所述第二信号中的低频信号的能量,确定低频搁架滤波器的增益,所述低频搁架滤波器用于控制所述第二信号中的低频信号的响度;
    使用低频搁架滤波器对所述第二信号进行滤波,得到所述扬声器的输入信号。
  9. 根据权利要求1-8中任一项所述的方法,其特征在于,所述方法还包括:
    获取包括一个或多个校正系数的第一位移预测模型,所述第一位移预测模型用于模拟所述扬声器的性能以预测所述扬声器的振膜的位移,所述一个或多个校正系数用于控制所述第一位移预测模型的输出;
    调整所述第一位移预测模型中的至少一个校正系数,得到第二位移预测模型;所述第二位移预测模型输出的预测位移与所述振膜的实际位移的差值的绝对值,小于所 述第一位移预测模型输出的预测位移与所述实际位移的差值的绝对值;所述实际位移为所述振膜相对于初始位置的移动距离实际测量值;
    根据所述扬声器的位移保护阈值及所述第二位移预测模型输出的预测位移,控制所述输出信号的增益,使得所述扬声器播放所述输出信号时的振膜位移小于或等于所述位移保护阈值;所述位移保护阈值为所述振膜的最大位移。
  10. 根据权利要求1-9中任一项所述的方法,其特征在于,所述方法还包括:
    对所述输出信号进行虚拟低音处理,以得到虚拟低音输出信号;所述虚拟低音输出信号的心理感知低频响度大于所述输出信号的心理感知低频响度。
  11. 根据权利要求10所述的方法,其特征在于,所述对所述输出信号进行虚拟低音处理,以得到虚拟低音输出信号包括:
    对所述输出信号进行分频处理,以获取第一低频输出信号和第一高频输出信号,所述第一低频输出信号包括所述输出信号中低于第三预设频点的信号,所述第一高频输出信号包括所述输出信号中高于所述第三预设频点的信号;
    根据所述第一低频输出信号生成所述第一低频输出信号的谐波信号;
    将所述谐波信号和所述第一低频输出信号进行混合,以得到第一混合信号;
    对所述第一混合信号和所述第一高频输出信号进行相位同步处理,以得到第二混合信号和第二高频输出信号,所述第二混合信号的相位的变化量与所述第二高频输出信号的相位的变化量相等;
    根据所述第二混合信号和所述第二高频输出信号,获得所述虚拟低音输出信号。
  12. 根据权利要求1-11中任一项所述的方法,其特征在于,所述方法还包括:
    根据所述扬声器的线圈温度,调整所述扬声器中预先配置的第一非线性补偿模型的非线性参数,以得到第二非线性补偿模型;
    采用所述第二非线性补偿模型对所述输出信号进行信号补偿。
  13. 一种电子设备,其特征在于,包括:第一获取模块、第一确定模块、包络调制模块以及第二确定模块;
    所述第一获取模块,用于对所述扬声器的输入信号进行分频,以获取第一低频输入信号和第一高频输入信号,所述扬声器的输入信号为时域信号,所述第一低频输入信号包括所述输入信号中低于第一预设频点的信号,所述第一高频输入信号包括所述输入信号中高于所述第一预设频点的信号;
    所述第一确定模块,用于对所述第一低频输入信号进行瞬态检测,以确定所述第一低频输入信号是否为瞬态信号;
    所述包络调制模块,用于在所述第一低频输入信号为瞬态信号的情况下,对所述第一低频输入信号进行信号包络调制,以得到第二低频输入信号;所述第二低频输入信号的起振电压大于所述第一低频输入信号的起振电压,且所述第二低频输入信号的响度大于所述第一低频输入信号的响度;
    所述第二确定模块,用于根据所述第二低频输入信号和所述第一高频输入信号,确定所述扬声器的输出信号。
  14. 根据权利要求13所述的电子设备,其特征在于,
    所述第一获取模块,还用于对所述扬声器的第一高频输入信号进行分频,以获取 第一中频输入信号和第二高频输入信号;所述第一中频输入信号包括所述第一高频输入信号中低于第二预设频点的信号,所述第二高频输入信号包括所述第一高频输入信号中高于所述第二预设频点的信号,所述第二预设频点高于所述第一预设频点;
    所述第一确定模块,还用于对所述第一中频输入信号进行瞬态检测,以确定所述第一中频输入信号是否为瞬态信号;
    所述包络调制模块,还用于在所述第一中频输入信号为瞬态信号的情况下,对所述第一中频输入信号进行信号包络调制,以得到第二中频输入信号;所述第二中频输入信号的起振电压大于所述第一中频输入信号的起振电压,且所述第二中频输入信号的响度大于所述第一中频输入信号的响度;
    所述第二确定模块,具体用于根据所述第二低频输入信号、所述第二中频输入信号以及所述第二高频输入信号,得到所述扬声器的输出信号。
  15. 根据权利要求13或14所述的电子设备,其特征在于,所述电子设备还包括生成模块和第二获取模块;
    所述生成模块,用于生成低频辅助信号;
    所述第二获取模块,用于在所述第一低频输入信号中添加所述低频辅助信号,以获得第一辅助增强信号;
    所述包络调制模块,具体用于对所述第一辅助增强信号进行信号包络调制,以得到所述第二低频输入信号。
  16. 根据权利要求15所述的电子设备,其特征在于,
    所述生成模块,具体用于生成第一辅助信号,对所述第一辅助信号进行高通滤波,以得到所述低频辅助信号;
    所述第一辅助信号满足:
    signal_h=e -A×sin(2πf)
    其中,signal_h表示所述低频辅助信号,A表示信号幅度影响因子,f为所述扬声器的中心频率。
  17. 根据权利要求13-16中任一项所述的电子设备,其特征在于,所述电子设备还包括相位补偿模块;
    所述相位补偿模块,用于对所述第一低频输入信号进行相位补偿,以获得第一相位补偿信号;
    所述包络调制模块,具体用于对所述第一相位补偿信号进行信号包络调制,以得到所述第二低频输入信号。
  18. 根据权利要求13-17中任一项所述的电子设备,其特征在于,
    所述第一确定模块,具体用于确定所述第一低频输入信号的瞬态功率和稳态功率;并且根据所述第一低频输入信号的瞬态功率和稳态功率确定所述第一低频输入信号的 瞬时率;以及在所述输入信号的瞬态率大于预设的瞬态率阈值的情况下,确定所述第一低频输入信号为瞬态信号;
    所述第一低频输入信号的瞬时率满足:T r=(R r-1) 2×W,其中,T r表示所述第一低频输入信号的瞬时率,R r表示所述第一低频输入信号的瞬态功率与所述第一低频输入信号的稳态功率的比值,W表示计权因子,W的取值与所述第一低频输入信号的当前功率相同。
  19. 根据权利要求13-18中任一项所述的电子设备,其特征在于,所述电子设备还包括均衡处理模块和低音增强模块;
    所述均衡处理模块,用于对第一信号进行均衡处理,得到第二信号;所述第一信号为输入至所述扬声器的初始的待播放信号;
    所述低音增强模块,用于采用低音增强算法对所述第二信号进行处理,以得到所述扬声器的输入信号。
  20. 根据权利要求19所述的电子设备,其特征在于,
    所述低音增强模块,具体用于根据所述第二信号中的低频信号的能量,确定低频搁架滤波器的增益,所述低频搁架滤波器用于控制所述第二信号中的低频信号的响度;并且使用低频搁架滤波器对所述第二信号进行滤波,得到所述扬声器的输入信号。
  21. 根据权利要求13-20中任一项所述的电子设备,其特征在于,所述电子设备还包括第三获取模块、第一调整模块以及控制模块;
    所述第三获取模块,用于获取包括一个或多个校正系数的第一位移预测模型,所述第一位移预测模型用于模拟所述扬声器的性能以预测所述扬声器的振膜的位移,所述一个或多个校正系数用于控制所述第一位移预测模型的输出;
    所述第一调整模块,用于调整所述第一位移预测模型中的至少一个校正系数,得到第二位移预测模型;所述第二位移预测模型输出的预测位移与所述振膜的实际位移的差值的绝对值,小于所述第一位移预测模型输出的预测位移与所述实际位移的差值的绝对值;所述实际位移为所述振膜相对于初始位置的移动距离实际测量值;
    所述控制模块,用于根据所述扬声器的位移保护阈值及所述第二位移预测模型输出的预测位移,控制所述输出信号的增益,使得所述扬声器播放所述输出信号时的振膜位移小于或等于所述位移保护阈值;所述位移保护阈值为所述振膜的最大位移。
  22. 根据权利要求13-21中任一项所述的电子设备,其特征在于,所述电子设备还包括虚拟低音处理模块:
    虚拟低音处理模块,用于对所述输出信号进行虚拟低音处理,以得到虚拟低音输出信号;所述虚拟低音输出信号的心理感知低频响度大于所述输出信号的心理感知低频响度。
  23. 根据权利要求22所述的电子设备,其特征在于,
    所述虚拟低音处理模块,具体用于对所述输出信号进行分频处理,以获取第一低频输出信号和第一高频输出信号,所述第一低频输出信号包括所述输出信号中低于第三设频点的信号,所述第一高频输出信号包括所述输出信号中高于所述第三预设频点的信号;并根据所述第一低频输出信号生成所述第一低频输出信号的谐波信号;且将所述谐波信号和所述第一低频输出信号进行混合,以得到第一混合信号;以及对所述 第一混合信号和所述第一高频输出信号进行相位同步处理,以得到第二混合信号和第二高频输出信号,所述第二混合信号的相位的变化量与所述第二高频输出信号的相位的变化量相等;进而根据所述第二混合信号和所述第二高频输出信号,获得所述虚拟低音输出信号。
  24. 根据权利要求13-23中任一项所述的电子设备,其特征在于,所述电子设备还包括第二调整模块和信号补偿模块:
    所述第二调整模块,用于根据所述扬声器的线圈温度,调整所述扬声器中预先配置的第一非线性补偿模型的非线性参数,以得到第二非线性补偿模型;
    所述信号补偿模块,用于采用所述第二非线性补偿模型对所述输出信号进行信号补偿。
  25. 一种电子设备,其特征在于,包括存储器和与所述存储器连接的至少一个处理器,所述存储器用于存储指令,所述指令被至少一个处理器读取后,执行如权利要求1至12任一项所述的方法。
  26. 一种计算机可读存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至12任一项所述的方法。
PCT/CN2022/101678 2021-06-30 2022-06-27 一种提升扬声器的音质的方法及装置 WO2023274180A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
EP22831994.3A EP4344246A1 (en) 2021-06-30 2022-06-27 Method and apparatus for improving sound quality of speaker

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110745517.3A CN115567831A (zh) 2021-06-30 2021-06-30 一种提升扬声器的音质的方法及装置
CN202110745517.3 2021-06-30

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/390,769 Continuation US20240135946A1 (en) 2021-06-30 2023-12-20 Method and apparatus for improving sound quality of speaker

Publications (1)

Publication Number Publication Date
WO2023274180A1 true WO2023274180A1 (zh) 2023-01-05

Family

ID=84690092

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/101678 WO2023274180A1 (zh) 2021-06-30 2022-06-27 一种提升扬声器的音质的方法及装置

Country Status (3)

Country Link
EP (1) EP4344246A1 (zh)
CN (1) CN115567831A (zh)
WO (1) WO2023274180A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117135538A (zh) * 2023-02-21 2023-11-28 荣耀终端有限公司 扬声器驱动电路及电子设备

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101964190A (zh) * 2009-07-24 2011-02-02 敦泰科技(深圳)有限公司 扬声器截止频率以下信号还原原声的方法和装置
CN104936088A (zh) * 2015-04-21 2015-09-23 上海大学 一种混合虚拟低音增强处理方法
US20160180858A1 (en) * 2013-07-29 2016-06-23 Dolby Laboratories Licensing Corporation System and method for reducing temporal artifacts for transient signals in a decorrelator circuit
CN106953608A (zh) * 2016-01-06 2017-07-14 昱盛电子股份有限公司 功率放大装置
CN109151667A (zh) * 2018-09-21 2019-01-04 上海艾为电子技术股份有限公司 一种信号处理方法、装置及扬声器
CN111796791A (zh) * 2020-06-12 2020-10-20 瑞声科技(新加坡)有限公司 一种低音增强方法、系统、电子设备和存储介质

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101964190A (zh) * 2009-07-24 2011-02-02 敦泰科技(深圳)有限公司 扬声器截止频率以下信号还原原声的方法和装置
US20160180858A1 (en) * 2013-07-29 2016-06-23 Dolby Laboratories Licensing Corporation System and method for reducing temporal artifacts for transient signals in a decorrelator circuit
CN104936088A (zh) * 2015-04-21 2015-09-23 上海大学 一种混合虚拟低音增强处理方法
CN106953608A (zh) * 2016-01-06 2017-07-14 昱盛电子股份有限公司 功率放大装置
CN109151667A (zh) * 2018-09-21 2019-01-04 上海艾为电子技术股份有限公司 一种信号处理方法、装置及扬声器
CN111796791A (zh) * 2020-06-12 2020-10-20 瑞声科技(新加坡)有限公司 一种低音增强方法、系统、电子设备和存储介质

Also Published As

Publication number Publication date
EP4344246A1 (en) 2024-03-27
CN115567831A (zh) 2023-01-03

Similar Documents

Publication Publication Date Title
CN110138937B (zh) 一种通话方法、设备及系统
WO2020249062A1 (zh) 一种语音通信方法及相关装置
WO2022100610A1 (zh) 投屏方法、装置、电子设备及计算机可读存储介质
US11956607B2 (en) Method and apparatus for improving sound quality of speaker
WO2021083128A1 (zh) 一种声音处理方法及其装置
CN114466097A (zh) 防漏音的移动终端及移动终端的声音输出方法
CN114422340A (zh) 日志上报方法、电子设备及存储介质
CN113225661A (zh) 扬声器识别方法、装置和电子设备
CN114339429A (zh) 音视频播放控制方法、电子设备和存储介质
WO2023274180A1 (zh) 一种提升扬声器的音质的方法及装置
CN115714890A (zh) 供电电路和电子设备
CN115145527A (zh) 一种调节音量的方法、系统及电子设备
CN115412678B (zh) 曝光处理方法、装置及电子设备
CN114390406B (zh) 一种控制扬声器振膜位移的方法及装置
CN113467747B (zh) 音量调节方法、电子设备及存储介质
CN114449393B (zh) 一种声音增强方法、耳机控制方法、装置及耳机
US20240135946A1 (en) Method and apparatus for improving sound quality of speaker
CN114844542A (zh) 天线选择方法、装置、电子设备及可读存储介质
CN115459643A (zh) 线性马达的振动波形调整方法及装置
CN114915359A (zh) 选择信道的方法、装置、电子设备和可读存储介质
CN111885768A (zh) 调节光源的方法、电子设备和系统
US20240178771A1 (en) Method and apparatus for adjusting vibration waveform of linear motor
CN114050962B (zh) 一种通信故障检测方法、装置及计算机可读存储介质
CN116744187B (zh) 扬声器控制方法及设备
WO2023020420A1 (zh) 音量显示方法、电子设备及存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22831994

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2022831994

Country of ref document: EP

ENP Entry into the national phase

Ref document number: 2023580702

Country of ref document: JP

Kind code of ref document: A

REG Reference to national code

Ref country code: BR

Ref legal event code: B01A

Ref document number: 112023027599

Country of ref document: BR

ENP Entry into the national phase

Ref document number: 2022831994

Country of ref document: EP

Effective date: 20231221

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 112023027599

Country of ref document: BR

Kind code of ref document: A2

Effective date: 20231227