Calibration methods and electronic equipment for frequency response consistency

By introducing an equalizer calibration module and multiple sub-band filters into electronic devices, the frequency response of the screen sound-emitting device is adjusted, solving the problem of inconsistent frequency response of the screen sound-emitting device and improving user experience and device stability.

CN116320905BActive Publication Date: 2026-07-10BEIJING HONOR DEVICE CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
BEIJING HONOR DEVICE CO LTD
Filing Date
2021-12-10
Publication Date
2026-07-10

AI Technical Summary

Technical Problem

When the screen sound device in electronic devices plays sound signals, the frequency response curve fluctuates greatly, resulting in inconsistent hearing for users and affecting user experience.

Method used

By introducing an equalizer calibration module into the electronic device, the frequency response of the audio signal is acquired and calibrated. Multiple sub-band filters are used to adjust the frequency response curve to ensure that it is consistent with the standard frequency response.

Benefits of technology

It improves the quality of audio signals in electronic devices, enhances the user's listening experience, reduces differences in frequency response curves, and strengthens the reliability and stability of the devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116320905B_ABST
    Figure CN116320905B_ABST
Patent Text Reader

Abstract

This application provides a calibration method and electronic device for frequency response consistency, addressing the problem of significant fluctuations in the frequency response curve of an audio signal when played by the screen sound device of an electronic device. The calibration method includes: the electronic device playing a test audio signal; the electronic device storing calibration parameters; the calibration parameters being the operating parameters of an equalizer calibration module; the calibration parameters being determined by the frequency response of a first audio signal and the standard frequency response of the test audio signal; the first audio signal being obtained by a calibration device acquiring the test audio signal played by the electronic device; and the calibration parameters being used to adjust the frequency response of a second audio signal played by the electronic device through the equalizer calibration module when the electronic device plays a second audio signal.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of audio technology, and in particular to a calibration method and electronic device for frequency response consistency. Background Technology

[0002] Currently, many electronic devices, such as mobile phones and tablets, have voice communication or audio playback functions. To achieve these functions, a sound-generating device is needed to allow the user to hear the other party's voice during a call or the audio played by the device. With increasing demands for higher screen-to-body ratios in electronic devices, the number of openings on the front panel (screen) needs to be reduced. Therefore, electronic devices typically incorporate screen-generating devices (such as piezoelectric ceramic capacitive devices) as speakers or earpieces.

[0003] However, for electronic devices that use screen-based sound generators, the assembly process requires bonding the sound generator to the screen of the electronic device. This bonding process introduces inherent errors. Furthermore, differences in screen size and quality between manufacturers result in variations in screen dimensions. These issues cause significant fluctuations in the frequency response curve of the sound signal when played back, deviating considerably from the standard frequency response curve. This leads to inconsistent sound perception for the user and negatively impacts the user experience. Summary of the Invention

[0004] This application provides a calibration method and electronic device for frequency response consistency, which solves the problem that the frequency response curve of the sound signal will fluctuate greatly when the screen sound device of the electronic device plays the sound signal.

[0005] To achieve the above objectives, the embodiments of this application adopt the following technical solutions:

[0006] Firstly, a calibration method for frequency response consistency is provided. This method is applied to an electronic device. The electronic device includes an equalizer calibration module. The electronic device is communicatively connected to a calibration device. The method includes: the electronic device playing a test audio signal; the electronic device storing calibration parameters; and the calibration parameters being the operating parameters of the equalizer calibration module. The calibration parameters are determined by the frequency response of a first audio signal and the standard frequency response of the test audio signal. The first audio signal is obtained by the calibration device acquiring the test audio signal played by the electronic device. The calibration parameters are used to adjust the frequency response of the second audio signal played by the electronic device through the equalizer calibration module when the electronic device plays a second audio signal.

[0007] Based on the above method, a first audio signal is obtained by acquiring the sound signal played by the electronic device before calibration. The calibration parameters of the equalizer calibration module are then determined based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. These calibration parameters are used to adjust the smoothness of the frequency response curve when the electronic device plays a normal audio signal, thereby reducing the difference between the frequency response curve of the actual played audio signal and the standard frequency response curve, improving the quality of the audio signal played by the electronic device, and enhancing the user's listening experience.

[0008] In one possible implementation, after the electronic device plays the test audio signal, the method may further include: the electronic device receiving a first audio signal. The electronic device determines calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. These calibration parameters can be determined by the electronic device itself. After the calibration device acquires the first audio signal, it can send the first audio signal to the electronic device so that the electronic device can calculate and determine the calibration parameters. This simplifies the calibration device and facilitates its development.

[0009] In one possible implementation, after the electronic device plays the test audio signal, the method may further include: the electronic device receiving calibration parameters. These calibration parameters are determined by the calibration device based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. In other words, these calibration parameters can also be determined by the calibration device. Since the calibration parameters can be obtained before the electronic device leaves the factory, having the calibration parameters determined by the calibration device avoids the program instructions for determining the calibration parameters occupying the storage space of the electronic device.

[0010] In one possible implementation, the electronic device plays a test audio signal, including: in response to the electronic device receiving a test command sent by the calibration device, the electronic device plays the test audio signal; or, in response to the electronic device sending a test command to the calibration device, the electronic device plays the test audio signal.

[0011] In one possible implementation, the test audio signal is a full-frequency sweep signal. To ensure good listening experience when the screen sound device of an electronic device plays any audio signal, the full-frequency signal needs to be calibrated during frequency response calibration.

[0012] In one possible implementation, the frequency response of the first audio signal is obtained by time-frequency transformation of the first audio signal.

[0013] In one possible implementation, the equalizer calibration module includes multiple sub-band filters; the calibration parameters are the parameters of these multiple sub-band filters. The calibration parameters include the number of frequency bands to be calibrated, the filter type corresponding to each frequency band, the center frequency of the filter corresponding to each frequency band, and the frequency response gain corresponding to each frequency band. Because capacitive screen sound-emitting devices have non-linear characteristics, multi-segment equalization filters (i.e., multiple sub-band filters) can be used to calibrate the frequency response of the audio signal played by the electronic device, resulting in better frequency response consistency and a better listening experience for the user.

[0014] In one possible implementation, the electronic device further includes an equalizer parameter calculation module. The electronic device determines calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal, including: the electronic device, through the equalizer parameter calculation module, determines the frequency points to be calibrated, the number of frequency points to be calibrated, and the frequency response gain corresponding to the frequency points to be calibrated, based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. The electronic device, through the equalizer parameter calculation module, determines the calibration parameters based on the frequency points to be calibrated, the number of frequency points to be calibrated, and the frequency response gain corresponding to the frequency points to be calibrated.

[0015] In one possible implementation, the frequency point requiring calibration is the point where the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal exceeds a preset frequency response gain. The frequency response gain corresponding to the frequency point requiring calibration is the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal at the frequency point requiring calibration.

[0016] In one possible implementation, if the number of frequency points to be calibrated is less than or equal to N, then the number of frequency bands to be calibrated is N. The center frequencies of the N frequency bands to be calibrated are the N frequency points where the frequency response of the first audio signal and the frequency response of the test audio signal differ the most. The filter type corresponding to each frequency band to be calibrated is a peak filter. The center frequency of the filter corresponding to each frequency band to be calibrated is the frequency corresponding to the center frequency point of the frequency band to be calibrated. The frequency response gain of the filter corresponding to each frequency band to be calibrated is the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal at the center frequency point of the frequency band to be calibrated. Where N is the preset minimum number of supported calibration sub-bands.

[0017] In one possible implementation, if the number of frequency points to be calibrated is greater than N and less than or equal to M, then the number of frequency bands to be calibrated is equal to the number of frequency points to be calibrated. The filter type corresponding to each frequency band to be calibrated is a peak filter. The center frequency of the filter corresponding to each frequency band to be calibrated is the frequency corresponding to each frequency point to be calibrated. The frequency response gain of the filter corresponding to each frequency band to be calibrated is the frequency response gain corresponding to each frequency point to be calibrated. Where N is the preset minimum supported number of calibration subbands; M is the preset maximum supported number of calibration subbands.

[0018] In one possible implementation, if the number of frequency points requiring calibration is greater than M, then the number of frequency bands to be calibrated is N; the frequency bands to be calibrated are obtained by merging the frequency points to be calibrated. Within each frequency band to be calibrated, except for the lowest and highest calibrated frequency bands, the filter type corresponding to each frequency band to be calibrated is a peak filter. The center frequency of the filter corresponding to each frequency band to be calibrated is the frequency corresponding to the center frequency point of the frequency band to be calibrated. The frequency response gain of the filter corresponding to each frequency band to be calibrated is the average gain of the frequency response gains corresponding to all the frequency points to be calibrated within each frequency band to be calibrated.

[0019] In one possible implementation, if the number of frequency points requiring calibration is greater than M, then the number of frequency bands to be calibrated is N. The frequency bands to be calibrated are obtained by merging the frequency points requiring calibration. Among the N frequency bands to be calibrated, if the lowest frequency point of the lowest frequency band is f1, and the number of frequency points requiring calibration in the lowest frequency band is greater than or equal to a first threshold, then the filter type corresponding to the lowest frequency band is a low-frequency shelving filter. The center frequency of the filter corresponding to the lowest frequency band is the frequency corresponding to the highest frequency point in the lowest frequency band. The frequency response gain of the lowest frequency band is the average gain of the frequency response gains corresponding to multiple frequency points requiring calibration in the lowest frequency band. Among the N frequency bands to be calibrated, if the lowest frequency point of the lowest frequency band is greater than f1, or the number of frequency points requiring calibration in the lowest frequency band is less than a first threshold, then the filter type corresponding to the lowest frequency band is a peak filter. The center frequency of the filter corresponding to the lowest frequency band to be calibrated is: the frequency corresponding to the center frequency point in the lowest frequency band to be calibrated. The frequency response gain corresponding to the lowest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to all the frequency points that need to be calibrated in the lowest frequency band to be calibrated. Where f1 is the preset lowest frequency to be calibrated.

[0020] In one possible implementation, if the number of frequency points requiring calibration is greater than M, then the number of filters is N. The frequency band to be calibrated is obtained by merging the frequency points to be calibrated. Among the N frequency bands to be calibrated, if the highest frequency point of the highest frequency band to be calibrated is f2, and the number of frequency points to be calibrated in the highest frequency band to be calibrated is greater than or equal to a second threshold, then the filter type corresponding to the highest frequency band to be calibrated is: a high-frequency shelving filter. The center frequency of the filter corresponding to the highest frequency band to be calibrated is: the frequency corresponding to the lowest frequency point in the highest frequency band to be calibrated. The frequency response gain corresponding to the highest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to multiple frequency points to be calibrated in the highest frequency band to be calibrated. Among the N frequency bands to be calibrated, if the highest frequency point of the highest frequency band to be calibrated is less than f2, or the number of frequency points to be calibrated in the highest frequency band to be calibrated is less than a first threshold, then the filter type corresponding to the highest frequency band to be calibrated is: a peak filter. The center frequency of the filter corresponding to the highest frequency band to be calibrated is: the frequency corresponding to the center frequency point in the highest frequency band to be calibrated. The frequency response gain corresponding to the highest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to all the frequency points that need to be calibrated in the highest frequency band to be calibrated. Where f2 is the preset highest frequency that needs to be calibrated.

[0021] Secondly, another calibration method for frequency response consistency is provided. This method is applied to a calibration device that is communicatively connected to an electronic device. The method includes: acquiring the sound signal played by the electronic device while it is playing a test audio signal, obtaining a first audio signal; determining calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal; using the calibration parameters to adjust the frequency response of the sound signal played by the electronic device when it plays a second audio signal; and sending the calibration parameters to the electronic device.

[0022] In one possible implementation, the calibration device includes an artificial ear. Acquiring the sound signal played by the electronic device includes: in response to receiving a detection command sent by the electronic device, acquiring the sound signal played by the electronic device via the artificial ear; or, in response to sending a detection command to the electronic device, acquiring the sound signal played by the electronic device via the artificial ear. The detection command is used to instruct the electronic device to play a test audio signal.

[0023] In one possible implementation, the test audio signal is a full-frequency sweep signal.

[0024] In one possible implementation, the frequency response of the first audio signal is obtained by time-frequency transformation of the first audio signal.

[0025] In one possible implementation, the equalizer calibration module includes multiple sub-band filters; the calibration parameters include the number of frequency bands to be calibrated, the filter type corresponding to each frequency band to be calibrated, the center frequency of the filter corresponding to each frequency band to be calibrated, and the frequency response gain corresponding to each frequency band to be calibrated.

[0026] In one possible implementation, determining calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal includes: determining the frequency points to be calibrated, the number of frequency points to be calibrated, and the frequency response gain corresponding to the frequency points to be calibrated, based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. The calibration parameters are then determined based on the frequency points to be calibrated, the number of frequency points to be calibrated, and the frequency response gain corresponding to the frequency points to be calibrated.

[0027] In one possible implementation, the frequency point requiring calibration is the point where the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal exceeds a preset frequency response gain. The frequency response gain corresponding to the frequency point requiring calibration is the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal at the frequency point requiring calibration.

[0028] In one possible implementation, if the number of frequency points to be calibrated is less than or equal to N, then the number of frequency bands to be calibrated is N. The center frequencies of the N frequency bands to be calibrated are the N frequency points where the frequency response of the first audio signal and the frequency response of the test audio signal differ the most. The filter type corresponding to each frequency band to be calibrated is a peak filter. The center frequency of the filter corresponding to each frequency band to be calibrated is the frequency corresponding to the center frequency point of the frequency band to be calibrated. The frequency response gain of the filter corresponding to each frequency band to be calibrated is the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal at the center frequency point of the frequency band to be calibrated. Where N is the preset minimum number of supported calibration sub-bands.

[0029] In one possible implementation, if the number of frequency points to be calibrated is greater than N and less than or equal to M, then the number of frequency bands to be calibrated is equal to the number of frequency points to be calibrated. The filter type corresponding to each frequency band to be calibrated is a peak filter. The center frequency of the filter corresponding to each frequency band to be calibrated is the frequency corresponding to each frequency point to be calibrated. The frequency response gain of the filter corresponding to each frequency band to be calibrated is the frequency response gain corresponding to each frequency point to be calibrated. Where N is the preset minimum supported number of calibration subbands; M is the preset maximum supported number of calibration subbands.

[0030] In one possible implementation, if the number of frequency points requiring calibration is greater than M, then the number of frequency bands to be calibrated is N; the frequency bands to be calibrated are obtained by merging the frequency points to be calibrated. Within each frequency band to be calibrated, except for the lowest and highest calibrated frequency bands, the filter type corresponding to each frequency band to be calibrated is a peak filter. The center frequency of the filter corresponding to each frequency band to be calibrated is the frequency corresponding to the center frequency point of the frequency band to be calibrated. The frequency response gain of the filter corresponding to each frequency band to be calibrated is the average gain of the frequency response gains corresponding to all the frequency points to be calibrated within each frequency band to be calibrated.

[0031] In one possible implementation, if the number of frequency points requiring calibration is greater than M, then the number of frequency bands to be calibrated is N. The frequency bands to be calibrated are obtained by merging the frequency points requiring calibration. Among the N frequency bands to be calibrated, if the lowest frequency point of the lowest frequency band is f1, and the number of frequency points requiring calibration in the lowest frequency band is greater than or equal to a first threshold, then the filter type corresponding to the lowest frequency band is a low-frequency shelving filter. The center frequency of the filter corresponding to the lowest frequency band is the frequency corresponding to the highest frequency point in the lowest frequency band. The frequency response gain of the lowest frequency band is the average gain of the frequency response gains corresponding to multiple frequency points requiring calibration in the lowest frequency band. Among the N frequency bands to be calibrated, if the lowest frequency point of the lowest frequency band is greater than f1, or the number of frequency points requiring calibration in the lowest frequency band is less than a first threshold, then the filter type corresponding to the lowest frequency band is a peak filter. The center frequency of the filter corresponding to the lowest frequency band to be calibrated is: the frequency corresponding to the center frequency point in the lowest frequency band to be calibrated. The frequency response gain corresponding to the lowest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to all the frequency points that need to be calibrated in the lowest frequency band to be calibrated. Where f1 is the preset lowest frequency to be calibrated.

[0032] In one possible implementation, if the number of frequency points requiring calibration is greater than M, then the number of filters is N. The frequency band to be calibrated is obtained by merging the frequency points to be calibrated. Among the N frequency bands to be calibrated, if the highest frequency point of the highest frequency band to be calibrated is f2, and the number of frequency points to be calibrated in the highest frequency band to be calibrated is greater than or equal to a second threshold, then the filter type corresponding to the highest frequency band to be calibrated is: a high-frequency shelving filter. The center frequency of the filter corresponding to the highest frequency band to be calibrated is: the frequency corresponding to the lowest frequency point in the highest frequency band to be calibrated. The frequency response gain corresponding to the highest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to multiple frequency points to be calibrated in the highest frequency band to be calibrated. Among the N frequency bands to be calibrated, if the highest frequency point of the highest frequency band to be calibrated is less than f2, or the number of frequency points to be calibrated in the highest frequency band to be calibrated is less than a first threshold, then the filter type corresponding to the highest frequency band to be calibrated is: a peak filter. The center frequency of the filter corresponding to the highest frequency band to be calibrated is: the frequency corresponding to the center frequency point in the highest frequency band to be calibrated. The frequency response gain corresponding to the highest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to all the frequency points that need to be calibrated in the highest frequency band to be calibrated. Where f2 is the preset highest frequency that needs to be calibrated.

[0033] Thirdly, an audio playback method is provided. This audio playback method is applied to an electronic device; the electronic device includes an equalizer calibration module and a screen sound-emitting device. The method includes: receiving an audio playback instruction. The audio playback instruction is used to instruct the electronic device to play a second audio signal. In response to receiving the audio playback instruction, acquiring calibration parameters. The calibration parameters are calibration parameters stored in the electronic device according to any possible implementation of the first aspect above. Adjusting the frequency response of the second audio signal through the equalizer calibration module and using the calibration parameters to obtain a third audio signal. Playing the third audio signal through the screen sound-emitting device.

[0034] Fourthly, a calibration system is provided. The calibration system includes electronic equipment and calibration equipment. The electronic equipment is communicatively connected to the calibration equipment. The electronic equipment is used to perform the methods described in any of the possible implementations of the first aspect above.

[0035] Fifthly, a calibration device is provided. This calibration device is communicatively connected to an electronic device. The calibration device includes: a calibration control module, an equalizer parameter calculation module, and an artificial ear. The calibration control module is used to send a detection command to the electronic device; the detection command instructs the electronic device to play a test audio signal. The artificial ear is used to acquire the test audio signal played by the electronic device during playback, obtaining a first audio signal. The equalizer parameter calculation module is used to determine calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. The calibration parameters are used to adjust the frequency response of the second audio signal played by the electronic device when the electronic device plays a second audio signal. The calibration control module is also used to send the calibration parameters to the electronic device.

[0036] In one possible implementation, the test audio signal is a full-frequency sweep signal.

[0037] In one possible implementation, the frequency response of the first audio signal is obtained by time-frequency transformation of the first audio signal.

[0038] In one possible implementation, the calibration parameters include the number of frequency bands to be calibrated, the filter type corresponding to each frequency band to be calibrated, the center frequency of the filter corresponding to each frequency band to be calibrated, and the frequency response gain corresponding to each frequency band to be calibrated.

[0039] In one possible implementation, the equalizer parameter calculation module is specifically used to: determine the frequency points to be calibrated, the number of frequency points to be calibrated, and the frequency response gain corresponding to the frequency points to be calibrated, based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. Then, it determines the calibration parameters based on the frequency points to be calibrated, the number of frequency points to be calibrated, and the frequency response gain corresponding to the frequency points to be calibrated.

[0040] In one possible implementation, the frequency point requiring calibration is the point where the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal exceeds a preset frequency response gain. The frequency response gain corresponding to the frequency point requiring calibration is the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal at the frequency point requiring calibration.

[0041] Sixthly, a calibration apparatus is provided. The calibration apparatus includes a processor and a memory. The memory stores one or more computer programs, which include instructions that, when executed by the processor, cause the calibration apparatus to perform the methods described in any of the possible implementations of the second aspect above.

[0042] A seventh aspect provides an electronic device. The electronic device includes: one or more processors; a memory; and a communication module. The communication module is used to communicate with a calibration device. The memory stores one or more computer programs, which include instructions that, when executed by the processor, cause the electronic device to perform the methods of any of the possible implementations of the first and third aspects above.

[0043] Eighthly, a chip system is provided, comprising one or more interface circuits and one or more processors. The interface circuits and processors are interconnected via lines. The chip system can be applied to an electronic device including a communication module and a memory. The interface circuits can read instructions stored in the memory of the electronic device and send the instructions to the processor. When the instructions are executed by the processor, the electronic device may perform the method described in any possible implementation of the first aspect above, or the calibration device may perform the method described in any possible implementation of the second aspect above.

[0044] In a ninth aspect, a computer-readable storage medium is provided, wherein instructions are stored therein, which, when executed on a calibration device, cause the calibration device to perform the method of any possible implementation of the second aspect above.

[0045] In a tenth aspect, a computer-readable storage medium is provided, wherein instructions are stored therein, which, when executed on a calibration device, cause an electronic device to perform the method of any possible implementation of the first and third aspects above.

[0046] Understandably, the technical effects of any of the possible implementations of the second to tenth aspects provided above can be seen in the technical effects of the different implementations of the first aspect, and will not be repeated here. Attached Figure Description

[0047] Figure 1 This is a schematic diagram illustrating a scenario where a user conducts voice communication via an electronic device, as provided in an embodiment of this application.

[0048] Figure 2 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application;

[0049] Figure 3 This is a schematic diagram of the structure of another electronic device provided in an embodiment of this application;

[0050] Figure 4 A schematic diagram illustrating the principle of sound generation by the screen sound-emitting device provided in this application embodiment;

[0051] Figure 5Frequency resistance characteristic curve of 4.2 microfarad piezoelectric ceramic provided for embodiments of this application;

[0052] Figure 6 A schematic diagram illustrating the function of different types and parameters of filters provided in the embodiments of this application;

[0053] Figure 7 This is a schematic diagram of the structure of a calibration system provided in an embodiment of this application;

[0054] Figure 8A A system structure block diagram of electronic devices and calibration equipment in a calibration system provided in this application embodiment;

[0055] Figure 8B A system structure block diagram of electronic devices and calibration equipment in another calibration system provided in this application embodiment;

[0056] Figure 9 A software structure block diagram of an electronic device provided in an embodiment of this application;

[0057] Figure 10A A flowchart illustrating a frequency response consistency calibration method provided in this application embodiment;

[0058] Figure 10B for Figure 10A The flowchart in step S1004;

[0059] Figure 11 A comparison diagram of the frequency response curve of a first audio signal and the standard frequency response curve of a test audio signal provided in an embodiment of this application;

[0060] Figure 12 A flowchart illustrating another frequency response consistency calibration method provided in this application embodiment;

[0061] Figure 13 A comparison graph of the frequency response curve of a screen sound-emitting device provided in this application embodiment before and after frequency response consistency calibration;

[0062] Figure 14 This is a schematic diagram of a chip system provided in an embodiment of this application. Detailed Implementation

[0063] For ease of understanding, exemplary descriptions of some concepts related to the embodiments of this application are provided for reference. As shown below:

[0064] Capacitive devices: Generally, a load with capacitive parameters (i.e., a load whose characteristics match voltage lag current) is called a capacitive load or capacitive device. In electronic systems, a capacitive device can be considered equivalent to a capacitor. Examples include piezoelectric microelectromechanical systems (MEMS), thin-film materials, and electrostatic loudspeakers. The voltage of a capacitive device does not change suddenly during charging / discharging.

[0065] The technical solutions of the embodiments of this application will now be described with reference to the accompanying drawings. In the description of this application, unless otherwise stated, "at least one" refers to one or more, and "more than one" refers to two or more. Furthermore, to facilitate a clear description of the technical solutions of the embodiments of this application, the terms "first," "second," etc., are used in the embodiments of this application to distinguish identical or similar items with substantially the same function and effect. Those skilled in the art will understand that the terms "first," "second," etc., do not limit the quantity or execution order, and that "first," "second," etc., do not necessarily imply differences.

[0066] Currently, many electronic devices have voice communication or audio playback functions. To achieve voice communication, electronic devices need to install a sound-producing device so that the user can hear the other party's voice. Similarly, to achieve audio playback, electronic devices also need to install a sound-producing device. Taking mobile phones as an example, the top of the phone has an earpiece (also called a speaker) as the sound-producing device for voice communication. Normally, the earpiece is located inside the phone, requiring a hole to be made in the front panel to form the sound outlet. When the earpiece emits sound, the sound energy is transmitted through the sound outlet so that the user can hear the sound. However, with the continuous development of mobile phones, in order to provide users with a better screen viewing experience, the screen-to-body ratio of mobile phones is getting higher and higher. Since the sound outlet on the front panel occupies part of the front panel area of ​​the phone, it increases the width of the phone's bezel, thus affecting the improvement of the screen-to-body ratio.

[0067] With the development of large-screen and full-screen smartphones, to increase the screen-to-body ratio, it's necessary to reduce the area occupied by the earpiece's sound outlet on the front panel. For example, the earpiece's sound outlet can be designed as a long slit and located at the junction of the phone's frame and the front panel (also known as the side seam). In some cases, to ensure good sound output, a hole can be made at the top of the phone's frame as the sound outlet. However, in this case, when the user uses the phone for voice communication, the user's ear cannot completely cover the sound outlet, and the sound energy from the earpiece cannot be fully transmitted to the user's ear, resulting in sound leakage.

[0068] For example, taking a mobile phone as an example, during voice communication when a user holds the phone and uses the earpiece, the earpiece is used to play the user's voice signal during the voice communication (i.e., the earpiece is the speaker used for sound output during voice communication). Figure 1 As shown, the sound outlet 201 of the phone's earpiece is close to the user's ear (or auricle). At this time, because the sound outlet 201 of the phone's earpiece (such as the sound outlet located at the side seam of the phone and the sound outlet at the top of the mid-frame) cannot be completely covered by the user's ear, the sound signal emitted by the sound outlet 201 can not only be heard by the user, but also by other users in a quiet environment, thus causing sound leakage.

[0069] To avoid sound leakage when using the earpiece, some electronic devices use screen sound instead of earpiece sound, or use both screen sound and earpiece sound simultaneously. For example, Figure 2 The diagram shown is a structural schematic of an electronic device. The electronic device includes a housing structure 100. This housing structure 100 is formed by a front panel (including a screen and a bezel), a rear panel for supporting internal circuitry, and a mid-frame. Figure 2 As shown in (a), the electronic device's housing structure 100 houses an earpiece 101 and a screen sound-emitting device 104. The earpiece 101 is a speaker used for voice communication, also known as a receiver, and is typically located at the top of the housing structure. The screen sound-emitting device 104 can be a vibration source connected to the bottom of the screen. Combined with... Figure 2 As shown in (b), corresponding to the earpiece 101, the electronic device has two sound outlets, namely sound outlet 102 and sound outlet 103. Sound outlet 102 is located at the junction of the front panel and the mid-frame of the electronic device (i.e., at the side seam). Sound outlet 103 is located on the mid-frame of the electronic device, closer to the earpiece (i.e., at the top of the mid-frame). Thus, the... Figure 2 The electronic device shown can produce sound through the earpiece, the screen, or both simultaneously, to avoid sound leakage that occurs when only the earpiece is used.

[0070] It should be understood that the specific structure of the screen sound-generating device in an electronic device varies depending on the screen sound-generating solution. For example, the screen sound-generating device can be a vibration source (such as a piezoelectric ceramic, motor vibrator, exciter, or other vibration unit) connected to the back of the screen. This vibration source can vibrate under the control of a current signal to drive the screen to vibrate, thereby achieving screen sound generation. Another example is a piezoelectric ceramic fixed to the mid-frame of the electronic device via a cantilever beam structure. This piezoelectric ceramic can vibrate under the control of a current signal, and the vibration is transmitted to the screen via the mid-frame to drive the screen to vibrate, thereby achieving screen sound generation. Yet another example is an exciter fixed to the mid-frame of the electronic device. This exciter can vibrate under the control of a current signal, and the vibration is transmitted to the screen via the mid-frame to drive the screen to vibrate, thereby achieving screen sound generation. Finally, the screen sound-generating device can also be a split-type magnetic levitation vibrator. In this split-type magnetic levitation vibrator, one vibrator is fixed to the middle frame of the electronic device, and the other vibrator is fixed to the screen. The vibrator fixed to the screen can vibrate relative to the vibrator fixed to the middle frame of the electronic device under the control of an electric current signal, thereby driving the screen to vibrate and thus making the screen produce sound.

[0071] However, for electronic devices (such as mobile phones) that use screen-based sound-emitting devices (e.g., capacitive devices like piezoelectric ceramics) to generate sound, the screen-based sound-emitting device needs to be attached to the bottom of the phone screen during assembly. Typically, there will be a certain margin of error after the screen-based sound-emitting device and the phone screen are attached. Furthermore, due to differences in phone screen manufacturers, there may be slight variations in screen size and quality. These factors can all lead to a higher degree of dispersion in the frequency response curve of the screen-based sound-emitting device during use, resulting in variations in high and low frequencies and a poor listening experience for the user.

[0072] To address the aforementioned issues, this application provides a calibration method for the frequency response consistency of screen-emitting devices (such as capacitive devices like piezoelectric ceramics). Before the electronic device leaves the factory, a swept frequency signal (i.e., a test audio signal) is played to detect the frequency response curve of the screen-emitting device during sound generation. The detected frequency response curve is compared with a standard frequency response curve to identify several key frequency points that need adjustment during the screen-emitting device's sound generation process, along with calibration parameters for these key frequency points. These key frequency points and calibration parameters are stored in a memory. An equalizer calibration module can also be added to the audio playback path of the electronic device. Before the audio signal to be played through the screen-emitting device, the equalizer calibration module enhances and suppresses key frequency points of the audio signal to adjust the smoothness of the frequency response curve during screen-emitting device sound generation. This ensures that the frequency response curve of the audio signal ultimately output through the screen-emitting device is within a preset factory threshold range, improving the reliability and stability of the electronic device and enhancing the user experience.

[0073] The calibration method for frequency response consistency provided in the embodiments of this application will be described below with reference to the accompanying drawings.

[0074] For example, the electronic device in this application embodiment may be a mobile phone, tablet computer, ultra-mobile personal computer (UMPC), netbook, cellular phone, personal digital assistant (PDA), wearable device (such as smartwatch, smart bracelet), etc., which have voice communication function. This application embodiment does not impose any special restrictions on the specific form of the electronic device.

[0075] For example, taking a mobile phone as an electronic device, Figure 3 A schematic diagram of the structure of another electronic device provided in an embodiment of this application is shown. That is, exemplary, Figure 3 The electronic device shown could be a mobile phone.

[0076] like Figure 3As shown, a mobile phone may include: a processor 310, an external memory interface 320, an internal memory 321, a universal serial bus (USB) interface 330, a charging management module 340, a power management module 341, a battery 342, an antenna 1, an antenna 2, a mobile communication module 350, a wireless communication module 360, an audio module 370, a speaker 370A, a receiver (i.e., earpiece) 370B, a microphone 370C, a headphone jack 370D, a sensor module 380, buttons 390, a motor 391, an indicator 392, a camera 393, a display screen 394, a subscriber identification module (SIM) card interface 395, and a screen sound device 396, etc.

[0077] The aforementioned sensor modules may include sensors such as pressure sensors, gyroscope sensors, barometric pressure sensors, magnetic sensors, accelerometers, distance sensors, proximity sensors, fingerprint sensors, temperature sensors, touch sensors, ambient light sensors, and bone conduction sensors.

[0078] It is understood that the structure illustrated in this embodiment does not constitute a specific limitation on the mobile phone. In other embodiments, the mobile phone may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0079] Processor 310 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. The different processing units may be independent devices or integrated into one or more processors.

[0080] The controller can be the nerve center and command center of a mobile phone. Based on the instruction opcode and timing signals, the controller generates operation control signals to control the fetching and execution of instructions.

[0081] The DSP can include a smart power amplifier (smart PA) hardware circuit, a smart PA algorithm module, and an audio algorithm module. The smart PA hardware circuit can be connected to both the application processor and the screen sound-emitting device (such as piezoelectric ceramic), and is used to control the screen sound-emitting device to produce sound according to instructions from the application processor. The smart PA algorithm module includes an equalizer calibration module, in which multiple filters can be set. The frequency response curve of the screen sound-emitting device is adjusted through the combined effect of filters with different parameters and types.

[0082] It should be understood that the smart PA hardware circuit can also be located outside the DSP chip, and this application embodiment does not impose any special limitations.

[0083] The processor 310 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 310 is a cache memory. This memory can store instructions or data that the processor 310 has just used or that are used repeatedly. If the processor 310 needs to use the instruction or data again, it can directly retrieve it from the memory. This avoids repeated accesses, reduces the waiting time of the processor 310, and thus improves the efficiency of the system. In this embodiment, the memory can be used to store calibration parameters (e.g., filter parameters) for adjusting the consistency of the frequency response curve of the screen sound-emitting device.

[0084] In some embodiments, the processor 310 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0085] It is understood that the interface connection relationships between the modules illustrated in this embodiment are merely illustrative and do not constitute a structural limitation on the mobile phone. In other embodiments, the mobile phone may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.

[0086] The charging management module 340 receives charging input from a charger (such as a wireless charger or a wired charger) to charge the battery 342. The power management module 341 connects the battery 342, the charging management module 340, and the processor 310. The power management module 341 receives input from the battery 342 and / or the charging management module 340 to power various components of the electronic device.

[0087] The wireless communication function of a mobile phone can be achieved through antenna 1, antenna 2, mobile communication module 350, wireless communication module 360, modem processor, and baseband processor.

[0088] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in the mobile phone can be used to cover one or more communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with a tuning switch.

[0089] In some embodiments, the mobile phone's antenna 1 is coupled to the mobile communication module 350, and the antenna 2 is coupled to the wireless communication module 360, enabling the mobile phone to communicate with networks and other devices via wireless communication technology. The mobile communication module 350 can provide solutions for wireless communication applications in mobile phones, including 2G / 3G / 4G / 5G. The mobile communication module 350 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 350 can receive electromagnetic waves through the antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to a modem processor for demodulation.

[0090] The mobile communication module 350 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via the antenna 1. In some embodiments, at least some functional modules of the mobile communication module 350 can be housed in the processor 310. In some embodiments, at least some functional modules of the mobile communication module 350 and at least some modules of the processor 310 can be housed in the same device.

[0091] The 360 ​​wireless communication module can provide solutions for mobile phone applications including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR) technology, and other wireless communication technologies.

[0092] The wireless communication module 360 ​​can be one or more devices integrating at least one communication processing module. The wireless communication module 360 ​​receives electromagnetic waves via antenna 2, performs frequency modulation and filtering of the electromagnetic wave signal, and sends the processed signal to processor 310. The wireless communication module 360 ​​can also receive signals to be transmitted from processor 310, perform frequency modulation and amplification, and convert them into electromagnetic waves for radiation via antenna 2.

[0093] Of course, the aforementioned wireless communication module 360 ​​can also support voice communication on mobile phones. For example, a mobile phone can access a Wi-Fi network through the wireless communication module 360, and then use any application that provides voice communication services to interact with other devices, providing voice communication services to the user. For example, the aforementioned application that provides voice communication services could be an instant messaging application.

[0094] A mobile phone can achieve display functions through a GPU, a display screen 394, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 394 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. The processor 310 may include one or more GPUs, which execute program instructions to generate or modify display information. The display screen 394 is used to display images, videos, etc.

[0095] A mobile phone can perform shooting functions through an ISP, camera 393, video codec, GPU, display 394, and application processor. The ISP is used to process data fed back from the camera 393. In some embodiments, the ISP can be located within the camera 393. The camera 393 is used to capture still images or videos. In some embodiments, the mobile phone may include one or N cameras 393, where N is a positive integer greater than 1.

[0096] The external memory interface 320 can be used to connect an external memory card, such as a Micro SD card, to expand the phone's storage capacity. The internal memory 321 can be used to store computer executable program code, which includes instructions. The processor 310 executes various functions and data processing of the phone by running the instructions stored in the internal memory 321. For example, in this embodiment, the processor 310 can execute instructions stored in the internal memory 321, which may include a program storage area and a data storage area.

[0097] Mobile phones can perform audio functions, such as music playback and recording, through an audio module 370, a speaker 370A, a receiver (i.e., earpiece) 370B, a microphone 370C, a headphone jack 370D, and an application processor.

[0098] Audio module 370 is used to convert digital audio signals into analog audio signals for output, and also to convert analog audio input into digital audio signals. Audio module 370 can also be used for encoding and decoding audio signals. In some embodiments, audio module 370 may be located in processor 310, or some functional modules of audio module 370 may be located in processor 310. Speaker 370A, also called a "loudspeaker," is used to convert audio electrical signals into sound signals. Receiver 370B, also called a "handpiece," is used to convert audio electrical signals into sound signals. Microphone 370C, also called a "microphone" or "microphone," is used to convert sound signals into electrical signals. Headphone jack 370D is used to connect wired headphones. Headphone jack 370D can be a USB interface 330, or a 3.5mm Open Mobile Terminal Platform (OMTP) standard interface, or a Cellular Telecommunications Industry Association of the USA (CTIA) standard interface.

[0099] The receiver 370B (i.e., the "earpiece") can be... Figure 2 The earpiece 101 shown in (a) is shown in the image.

[0100] For example, in this embodiment of the application, the audio module 370 can convert the audio electrical signals received by the mobile communication module 350 and the wireless communication module 360 ​​into sound signals. The sound signal is played by the receiver 370B (i.e., the "earpiece") of the audio module 370, and at the same time, the screen sound device 396 drives the screen (i.e. the display screen) to emit screen sound to play the sound signal.

[0101] Buttons 390 include a power button, volume buttons, etc. A motor 391 can generate vibration alerts. An indicator 392 can be an indicator light, used to indicate charging status, battery level changes, and also to indicate messages, missed calls, notifications, etc. A SIM card slot 395 is used to connect a SIM card. The phone can support one or N SIM card slots, where N is a positive integer greater than 1.

[0102] Of course, it is understandable that the above... Figure 3 The illustration shown is merely an example when the electronic device is a mobile phone. If the electronic device is a tablet, handheld computer, PDA, wearable device (such as a smartwatch, smart bracelet), or other device form factor, the structure of the electronic device may include more advanced features. Figure 3 The fewer structures shown can also include more than Figure 3 The structures shown are not limited here.

[0103] like Figure 4 The diagram shows the principle of sound generation from a screen-based sound-generating device. This device comprises multilayer piezoelectric ceramics. These multilayer piezoelectric ceramics form a diaphragm, which, upon application of an AC drive signal, undergoes bending deformation under the piezoelectric effect, driving the diaphragm to generate sound.

[0104] Typically, the impedance of piezoelectric ceramics (i.e., screen sound-emitting devices) satisfies the following relationship: Where z is the impedance of the piezoelectric ceramic, C is the capacitance, and f is the frequency of the AC signal. It can be seen that the equivalent impedance of the piezoelectric ceramic decreases sharply as the frequency of the input AC signal increases. For example, as... Figure 5 The figure shows the frequency impedance characteristic curve of a 4.2 μF piezoelectric ceramic. When the frequency of the AC signal is 200 Hz, the equivalent impedance of the 4.2 μF piezoelectric ceramic is approximately 160 ohms. When the frequency of the AC signal is 10 kHz, the equivalent impedance of the 4.2 μF piezoelectric ceramic is approximately 3.7 ohms.

[0105] It should be noted that, in reality, a screen-based sound-generating device formed from multilayer piezoelectric ceramics may not only include piezoelectric ceramics, but also electrode leads, dielectric materials, and other components. Therefore, the equivalent impedance of a screen-based sound-generating device formed from multilayer piezoelectric ceramics is a non-linear curve, which is related to temperature, frequency, and materials.

[0106] To accommodate the non-linear characteristics of the screen-generated sound device, an equalizer calibration module is added to the audio playback path of the electronic device. This equalizer calibration module is implemented using a multi-band equalizer filter. That is, the equalizer calibration module typically consists of N sub-band filters. For example, N can be a positive integer between 6 and 12.

[0107] The parameters for each subband filter can include:

[0108] System sampling rate fs: The system sampling rate is determined by the processor model used in the electronic device. For example, the system sampling rate can be 48000Hz, 44100Hz, 16000Hz, etc.

[0109] The center frequency f0 refers to the passband frequency of the filter, typically f0 = (f1 + f2) / 2. For example, f1 and f2 can be the left and right sideband frequencies of the bandpass filter, with a relative drop of 1dB or 3dB. In this embodiment, the center frequency of the filter can be determined based on the frequency point to be calibrated in the frequency response curve of the audio signal.

[0110] Peak bandwidth Q: Also known as the filter's quality factor Q. The filter's quality factor Q is the filter's center frequency f0 divided by the filter's bandwidth BW. Filter bandwidth refers to the width of the spectrum that the filter needs to pass, i.e., filter bandwidth BW = (f2 - f1), where f1 and f2 are the sidebands of the bandpass filter, respectively, that are 1dB or 3dB lower than the center frequency f0 to the left and right. In other words, the filter's quality factor Q = f0 / (f2 - f1).

[0111] Peak gain: In this embodiment of the application, it can be determined by the difference between the frequency response curve of the audio signal and the standard frequency response curve, based on the center frequency of the frequency point or frequency band to be calibrated.

[0112] Filter types: for example, peak filter, low shelf filter (LS), high shelf filter (HS), low-pass filter (LP), high-pass filter (HP), and band-pass filter (BP).

[0113] Figure 6 This diagram illustrates the operation of different types of filters with varying parameters. For peak filters with different Q values, the Q value determines the filter's bandwidth. A larger Q value results in a narrower bandwidth and a smaller affected frequency range. Figure 6 As shown in (a) of the diagram, among the curves extending from the center region to the left and right sides, the innermost curve has the largest Q value, and the outermost curve has the smallest Q value. For peak filters with different gains, the greater the gain, the greater the degree of gain or attenuation, such as... Figure 6 In the filter curves shown in (b), the gains from the outermost to the innermost curves are 12dB, 10dB, 8dB, 6dB, 4dB, and 2dB, respectively. Figure 6 As shown in (c), for low-frequency shelving filters, the main purpose is to boost or attenuate the amplitude of the low-frequency components. For example... Figure 6 As shown in (d) in the figure, for high-frequency shelving filters, they are mainly used to increase or decrease the amplitude of the high-frequency part.

[0114] Filter order: For example, first-order filter, second-order filter, and third-order filter. The coefficients of each sub-band filter can be calculated using the filter parameters of each sub-band. Taking a second-order IIR filter as an example, the coefficients of a second-order IIR filter are a(0), a(1), a(2), b(0), b(1), and b(2).

[0115] In summary, the center frequency, peak bandwidth, peak gain, and filter type of each subband filter can be obtained by comparing the uncalibrated frequency response curve with the standard frequency response curve.

[0116] After obtaining the parameters of the filter mentioned above, the filter coefficients can be calculated according to different orders and types of filters. The following examples illustrate the calculation methods for filter coefficients in different types of filters.

[0117] A method for calculating the coefficients of a second-order IIR peak filter:

[0118] The known parameters are: center frequency f0, peak gain gain, peak bandwidth Q, and system sampling rate fs.

[0119] Intermediate variables:

[0120] A = sqrt(10**(gain / 20));

[0121] w0 = 2 * pi * f0 / fs;

[0122] alpha = sin(w0) / (2*Q);

[0123] The filter coefficients are calculated as follows:

[0124] b0 = 1 + alpha * A;

[0125] b1 = -2*cos(w0);

[0126] b2 = 1 - alpha * A;

[0127] a0 = 1 + alpha / A;

[0128] a1 = -2*cos(w0);

[0129] a2 = 1 - alpha / A.

[0130] A method for calculating the coefficients of a second-order IIR low-frequency shelving filter:

[0131] The known parameters are: center frequency f0, peak gain gain, peak bandwidth Q, and system sampling rate fs.

[0132] Intermediate variables:

[0133] A = sqrt(10**(gain / 20));

[0134] w0 = 2 * pi * f0 / fs;

[0135] alpha = sin(w0) / (2*Q);

[0136] The filter coefficients are calculated as follows:

[0137] b0=A*((A+1)-(A-1)*cos(w0)+2*sqrt(A)*alpha);

[0138] b1=2*A*((A-1)-(A+1)*cos(w0));

[0139] b2=A*((A+1)-(A-1)*cos(w0)-2*sqrt(A)*alpha);

[0140] a0=(A+1)+(A-1)*cos(w0)+2*sqrt(A)*alpha;

[0141] a1=-2*((A-1)+(A+1)*cos(w0));

[0142] a2=(A+1)+(A-1)*cos(w0)-2*sqrt(A)*alpha.

[0143] A method for calculating the coefficients of a second-order IIR high-frequency shelving filter:

[0144] The known parameters are: center frequency f0, peak gain gain, peak bandwidth Q, and system sampling rate fs.

[0145] Intermediate variables:

[0146] A = sqrt(10**(gain / 20));

[0147] w0 = 2 * pi * f0 / fs;

[0148] alpha = sin(w0) / (2*Q);

[0149] The filter coefficients are calculated as follows:

[0150] b0=A*((A+1)-(A-1)*cos(w0)+2*sqrt(A)*alpha);

[0151] b1=2*A*((A-1)-(A+1)*cos(w0));

[0152] b2=A*((A+1)-(A-1)*cos(w0)-2*sqrt(A)*alpha);

[0153] a0=(A+1)+(A-1)*cos(w0)+2*sqrt(A)*alpha;

[0154] a1=-2*((A-1)+(A+1)*cos(w0));

[0155] a2=(A+1)+(A-1)*cos(w0)-2*sqrt(A)*alpha.

[0156] After obtaining the coefficients of the above filters, the output signal of the filter can be obtained by using the following formula (I) based on the input signal and the coefficients of the filter in each sub-band.

[0157]

[0158] Where y(n) is the output of the signal at the nth sampling point after passing through the filter; x(n) is the signal input to the filter at the nth sampling point.

[0159] The following section uses a mobile phone as an example of an electronic device, and combines system architecture and flowcharts to provide a detailed description of a calibration method for frequency response curve consistency provided in the embodiments of this application.

[0160] Figure 7 This is a schematic diagram of a calibration system provided in an embodiment of this application. Figure 7 As shown, the calibration system may include electronic equipment and calibration equipment. On the production line, when it is necessary to calibrate the consistency of the frequency response curve of the screen sound-emitting device in an electronic device, the electronic device can be communicatively connected to the calibration equipment. After the electronic device to be calibrated is communicatively connected to the calibration equipment, the electronic device plays a test audio signal through its screen sound-emitting device, and the calibration equipment acquires the test audio signal played by the electronic device while it is playing the test audio signal, thus obtaining a first audio signal.

[0161] After acquiring the test audio signal played by the electronic device through calibration equipment, the electronic device to be calibrated or the calibration equipment can analyze the acquired first audio signal to obtain the frequency response corresponding to the first audio signal. It can then compare the frequency response of the first audio signal with the standard frequency response of the test audio signal to obtain the frequency points to be calibrated, the frequency response gain corresponding to the frequency points to be calibrated, and the number of frequency points to be calibrated. The electronic device to be calibrated or the calibration equipment can also determine the number of filters, filter type, filter center frequency, filter gain, and filter Q value, etc., based on the required calibration frequency points, the corresponding frequency response gain, and the number of frequency points to be calibrated. Once the electronic device to be calibrated or the calibration equipment obtains the above calibration parameters, it can store these parameters in the non-volatile storage device of the electronic device. This allows the electronic device to adjust the consistency of the frequency response curve of the screen's sound-emitting device when playing audio signals during normal use, thereby ensuring a consistent frequency response, improving the user's listening experience, and enhancing overall user experience.

[0162] Figure 8A and Figure 8B This is a system block diagram of electronic devices and calibration equipment in a calibration system provided in an embodiment of this application. Figure 9 This is a software structure block diagram of the electronic device provided in the embodiments of this application. The system structures of the electronic device and the calibration device are described below.

[0163] For electronic devices:

[0164] Please refer to Figure 8A , Figure 8B and Figure 9 The system architecture of the aforementioned electronic devices (such as mobile phones) can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This application uses the layered architecture of the Android system as an example to exemplify the software structure of a mobile phone. Of course, in other operating systems, the functionality implemented by each functional module can be similar to that of the embodiments in this application.

[0165] A layered architecture divides software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into five layers, from top to bottom: the application layer, the application framework layer, the Android runtime and system libraries, the HAL (hardware abstraction layer), and the kernel layer.

[0166] The application layer can include a series of application packages. For example... Figure 9 As shown, the application layer can install applications such as calling, memos, browser, contacts, camera, gallery, calendar, map, Bluetooth, music, video, and SMS. In this embodiment, the application layer can also install a calibration application. In some embodiments, the calibration application can receive calibration signals (also called test commands) from the calibration device, causing the electronic device to play a test audio signal after receiving the calibration signal, so as to calibrate the frequency response of the audio signal played by the screen sound-emitting device. In other embodiments, the calibration application can send calibration signals (also called test commands) to the calibration device, and after sending the calibration signal, control the electronic device to play the test audio signal, so that the calibration device, after receiving the calibration signal, starts a data acquisition device (such as an artificial ear) to acquire the test audio signal played by the electronic device.

[0167] For example, when the calibration application receives a calibration signal from the calibration device, or after the calibration application sends a calibration signal to the calibration device, the calibration application will send a test command to the corresponding HAL in the HAL layer (such as the smart PA control HAL) so that the smart PA control HAL controls the electronic device to play the test audio signal.

[0168] The application framework layer provides application programming interfaces (APIs) and a programming framework for applications in the application layer. The application framework layer includes some predefined functions. For example... Figure 9 As shown, an audio playback management service is set up in the application framework layer. This service can be used to initialize the audio / video player, obtain the current audio volume, adjust the audio playback volume, add sound effects, etc.

[0169] In addition, the application framework layer may also include window management services, content services, view systems, resource management services, notification management services, etc., and this application embodiment does not impose any restrictions on this.

[0170] For example, the window management service described above is used to manage window programs. The window management service can obtain the screen size, determine if a status bar exists, lock the screen, and capture the screen, etc. The content service described above is used to store and retrieve data, making this data accessible to applications. The data may include videos, images, audio, made and received phone calls, browsing history and bookmarks, phone books, etc. The view system described above can be used to construct the application's display interface. Each display interface can consist of one or more controls. Generally, controls may include icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, widgets, and other interface elements. The resource management service described above provides applications with various resources, such as localized strings, icons, images, layout files, video files, etc. The notification management service described above allows applications to display notification information in the status bar, which can be used to convey informational messages and can disappear automatically after a short pause without user interaction. For example, the notification management service is used to notify of download completion, message reminders, etc. The notification manager can also display notifications in the form of icons or scrollbar text in the system's top status bar, such as notifications from background applications, or notifications appearing on the screen as dialog windows. For example, displaying text messages in the status bar, emitting notification sounds, vibrating, or flashing indicator lights.

[0171] like Figure 9 As shown, the HAL in a mobile phone provides HALs corresponding to different hardware modules of the phone, such as AudioHAL, Camera HAL, Wi-Fi HAL, smart PA control HAL, and information storage HAL.

[0172] The Audio HAL, through its kernel-level audio driver, corresponds to audio output devices (such as speakers or screen sound devices). When a mobile phone has multiple audio output devices (such as multiple speakers or screen sound devices), these multiple audio output devices correspond to multiple audio drivers in the kernel layer.

[0173] The smart PA control HAL corresponds to the smart PA hardware circuit through the smart PA algorithm in the DSP. For example, when the smart PA control HAL receives a test command from a calibration application in the application layer, it can control the smart PA algorithm to run, configuring it to play test audio signals. When the smart PA control HAL receives a call command from a call application or a music playback command from a music application in the application layer, it can control the smart PA algorithm to run, configuring it to play the other party's audio signal or the corresponding audio signal. Furthermore, the smart PA control HAL can also control the smart PA hardware circuit (such as the hardware circuit of the screen sound device (smart PA0)) to open via I2C signals, allowing test audio signals to be played through the screen sound device.

[0174] The Information Storage HAL corresponds to the non-volatile storage medium (such as memory) of an electronic device and is used to store equalizer parameters (i.e., calibration parameters) calculated by the electronic device or calibration equipment into the non-volatile storage medium of the electronic device. For example, when the electronic device calculates the equalizer parameters (i.e., calibration parameters) or receives equalizer parameters (i.e., calibration parameters) calculated by the calibration equipment, the Information Storage HAL can store these equalizer parameters into the non-volatile storage medium of the electronic device. These equalizer parameters are used to adjust the smoothness of the frequency response curve when the electronic device plays a normal audio signal, thereby reducing the difference between the frequency response curve of the actual played audio signal and the standard frequency response curve, improving the quality of the audio signal played by the electronic device, and enhancing the user's listening experience.

[0175] The Android runtime consists of core libraries and a virtual machine. The Android runtime is responsible for scheduling and managing the Android system.

[0176] The core library consists of two parts: one part is the functionalities that need to be called by the Java language, and the other part is the Android core library.

[0177] The application layer and application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.

[0178] System libraries can include multiple functional modules. For example: surface manager, media libraries, 3D graphics processing libraries (e.g., OpenGL ES), 2D graphics engines (e.g., SGL), etc.

[0179] The Surface Manager manages the display subsystem and provides fusion of 2D and 3D layers for multiple applications. The Media Library supports playback and recording of various common audio and video formats, as well as still image files. It supports multiple audio and video encoding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, and PNG. The 3D Graphics Processing Library implements 3D graphics drawing, image rendering, compositing, and layer processing. The 2D Graphics Engine is the drawing engine for 2D graphics.

[0180] The kernel layer, located below the HAL, is the layer between hardware and software. Besides the aforementioned audio driver, the kernel layer may also include display drivers, camera drivers, sensor drivers, etc., but this application embodiment does not impose any limitations on this.

[0181] It should be noted that the hardware circuitry lies below the kernel layer. For example, this application embodiment includes a digital signal processing (DSP) chip, which runs a smart PA algorithm module, an audio algorithm module, and so on.

[0182] The smart PA algorithm module includes an equalizer calibration module. When the smart PA control HAL receives a test command from the calibration application, the information storage HAL checks whether the equalizer parameters (i.e., calibration parameters) are stored in the non-volatile storage device. If the information storage HAL does not detect the equalizer parameters, it cannot send them to the equalizer calibration module, or it sends empty equalizer parameters to the equalizer calibration module, and the equalizer calibration module does not run. In this case, the smart PA algorithm module directly plays the original test audio signal.

[0183] When an electronic device is in normal use, audio-related applications (such as call or music applications) respond to user actions and send audio playback commands to the smart PA control HAL. Upon receiving the audio playback command, the smart PA control HAL checks if equalizer parameters (i.e., calibration parameters) are stored in the non-volatile storage device. If equalizer parameters are detected, the information storage HAL retrieves the calibration parameters from the non-volatile storage medium and sends them to the equalizer calibration module. The equalizer calibration module receives the calibration parameters and determines the equalizer type, center frequency, and frequency response gain based on them. Furthermore, the equalizer calibration module can convert the audio signal to be played into a frequency domain signal and calibrate the frequency domain gain using a multi-band equalizer. The calibrated audio signal is then sent to the smart PA hardware circuitry so that the screen sound device can play the calibrated audio signal.

[0184] In one possible implementation, such as Figure 8B and Figure 9 As shown, the DSP chip also includes an equalizer parameter calculation module. After the calibration device acquires the test audio signal played by the electronic device, it can send the acquired sound signal (i.e., the first audio signal) to the calibration application. The calibration application then sends the first audio signal through the HAL layer (such as a smart PA controlling the HAL) to the equalizer parameter calculation module. After receiving the first audio signal, the equalizer parameter calculation module can determine the equalizer parameters (i.e., calibration parameters) by comparing the frequency response of the first audio signal with the standard frequency response of the transmitted audio signal.

[0185] Of course, the equalizer parameter calculation module mentioned above can also be a module in calibration applications, and this application does not impose any special limitations on it.

[0186] For calibration equipment:

[0187] In one implementation, please refer to Figure 8AWhen the electronic device does not include an equalizer parameter calculation module, the calibration device includes a calibration control module, an equalizer parameter calculation module, and an artificial ear. The calibration control module communicates with the electronic device. For example, the calibration control module can send test commands (i.e., calibration signals) to the electronic device, instructing it to play test audio signals via a smart PA, and after sending the test command, control the artificial ear to start acquiring sound signals. Alternatively, the calibration control module can send calibration parameters output by the equalizer parameter calculation module to the electronic device, instructing it to store the calibration parameters. Furthermore, the calibration control module can receive test commands (i.e., calibration signals) sent by the electronic device, and upon receiving the test command, control the artificial ear to start acquiring sound signals.

[0188] The artificial ear is used to collect the sound signal (i.e., the first audio signal) output by the electronic device when playing test audio signals, and convert the collected sound signal into an electrical signal and transmit it to the equalizer parameter calculation module.

[0189] The equalizer parameter calculation module is used to receive the first audio signal and, after receiving the first audio signal, to determine the equalizer parameters (i.e., calibration parameters) by comparing the frequency response of the first audio signal with the standard frequency response of the transmitted audio signal.

[0190] For another implementation, please refer to Figure 8B When the electronic device includes an equalizer parameter calculation module, the standard device may consist only of a calibration control module and an artificial ear. The calibration control module communicates with the electronic device. For example, it can send a test command (i.e., a calibration signal) to the electronic device, instructing it to play a test audio signal via a smart PA, and then control the artificial ear to start acquiring the sound signal after sending the test command. Alternatively, it can receive test commands (i.e., calibration signals) from the electronic device and, upon receiving the command, control the artificial ear to start acquiring the sound signal. Furthermore, the calibration control module can send the first audio signal acquired by the artificial ear to the electronic device, allowing the equalizer parameter calculation module in the electronic device to compare the frequency response of the first audio signal with the standard frequency response of the transmitted audio signal to determine the equalizer parameters (i.e., calibration parameters).

[0191] The following detailed description, with reference to flowchart, illustrates a frequency response consistency calibration method provided in this application. In some embodiments, such as... Figure 10A As shown, this frequency response consistency calibration method is applied to... Figure 8A The calibration system shown is described. The electronic device under test is communicatively connected to the calibration equipment. The method includes:

[0192] S1001, the calibration equipment sends a test command to the electronic device under test.

[0193] The test command is used to instruct the electronic device under test to play a test audio signal. The test audio signal can be a full-frequency sweep signal or a sweep signal within a specific frequency range (e.g., a sweep signal within the audible frequency range of 20Hz to 20000Hz).

[0194] Once the calibration device and the electronic device under test are connected, the user can press the test button on the calibration device to send test commands to the electronic device under test.

[0195] It should be noted that when electronic devices need to undergo frequency response consistency calibration, the electronic device under test can also send test commands to the calibration device. For example, the electronic device under test can send test commands to the calibration device after receiving a user's click operation on the calibration control in the calibration application.

[0196] S1002, in response to receiving a test command, the electronic device under test plays a test audio signal.

[0197] For example, when the calibration application of the electronic device under test receives a test command, it can send the test command to the smart PA control HAL in the HAL layer. When the smart PA control HAL receives the test command, it controls the smart PA algorithm module to run, thereby controlling the smart PA hardware circuit to play the test audio signal. Furthermore, the smart PA control HAL also controls the smart PA hardware circuit (such as the hardware circuit of the screen sound device (smart PA0)) to open via I2C signals, playing the test audio signal through the screen sound device.

[0198] It should be noted that the test audio signal played by the electronic device under test at this time is an uncalibrated signal from the equalizer calibration module. Playing this uncalibrated test audio signal characterizes the frequency response curve of the electronic device under test when playing audio. This allows for comparison of the uncalibrated frequency response curve with the standard frequency response curve of the test audio signal, identifying the frequency points with significant frequency response deviations and the frequency response gain. Based on these deviations and the frequency response gain, the parameters (i.e., calibration parameters) of the multi-band equalizer in the equalizer calibration module can then be determined.

[0199] Furthermore, if the electronic device under test sends a test command to the calibration device, the electronic device can play a test audio signal after sending the test command to the calibration device.

[0200] S1003, the calibration equipment acquires the test audio signal played by the electronic device under test to obtain the first audio signal.

[0201] For example, the calibration equipment can activate the artificial ear after sending a test command to the electronic device under test. Of course, if the electronic device under test sends the test command to the calibration equipment, the calibration equipment can activate the artificial ear upon receiving the test command from the electronic device.

[0202] When the electronic device under test plays a test audio signal through its screen sound output device, the calibration equipment can acquire the test audio signal played by the electronic device under test through an artificial ear to obtain the first audio signal. The artificial ear can then convert the received first audio signal into an electrical signal and send it to the equalizer parameter calculation module.

[0203] S1004, the calibration equipment determines the calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. The calibration parameters include: the number of frequency bands to be calibrated (i.e., the number of filters), the filter type corresponding to each frequency band to be calibrated, the center frequency of the filter corresponding to each frequency band to be calibrated, the gain of the filter corresponding to each frequency band to be calibrated, and the Q value of the filter corresponding to each frequency band to be calibrated.

[0204] Typically, the equalizer parameter calculation module of the calibration equipment can be preset with a range of the number of sub-bands that can be calibrated. For example, the equalizer calibration module can support the calibration of n to m sub-bands (that is, it can support the calibration of n to m frequency bands to be calibrated).

[0205] Since some frequency ranges of audio signals are inaudible to the human ear when played by electronic devices, these signals do not affect the user's hearing and therefore do not require frequency response calibration. To improve the efficiency of frequency response calibration, the frequency range to be calibrated can be preset. For example, the frequency range to be calibrated can be preset from a first frequency point f1 to a second frequency point f2. Here, the first frequency point f1 is the lowest frequency requiring calibration, and the second frequency point f2 is the highest frequency requiring calibration.

[0206] In addition, the desired calibration discrete range for electronic devices can be preset to ±x dB. That is, when the frequency response of an electronic device at a certain frequency point deviates from the normal frequency response by more than x dB, it indicates that calibration is required at that frequency point.

[0207] In the embodiments of this application, such as Figure 10B As shown, S1004 may include S1004A to S1004D.

[0208] S1004A, the calibration equipment, based on the frequency response of the first audio signal and the frequency response of the test audio signal, can determine the frequency points requiring calibration within the range of a first frequency point f1 to a second frequency point f2, the frequency response gain corresponding to each frequency point requiring calibration, and the number of frequency points requiring calibration. The frequency points requiring calibration are those where the difference between the frequency response of the first audio signal and the frequency response of the test audio signal is greater than a pre-set expected calibration discrete range (i.e., x dB). The frequency response gain corresponding to each frequency point requiring calibration is the difference between the frequency response of the first audio signal and the frequency response of the test audio signal at the frequency point requiring calibration. The number of frequency points requiring calibration is the total number of all frequency points requiring calibration.

[0209] For example, Figure 11 This is a comparison diagram of the frequency response curve of a first audio signal and the standard frequency response curve of a test audio signal provided in an embodiment of this application. Figure 11 As shown, by comparing the frequency response curve of the first audio signal with the standard frequency response curve of the test audio signal, it can be seen that there is a significant difference between the frequency response curve of the first audio signal and the standard frequency response curve of the test audio signal.

[0210] like Figure 11 As shown, based on the characteristics of the frequency response curve of the first audio signal, the frequency response curve of the first audio signal exhibits significant fluctuations. In this case, the frequencies at the inflection points (i.e., the peaks and troughs) of the frequency response curve can be determined as the frequencies that may require calibration, for example, in... Figure 11 The frequency points of 100Hz, 200Hz, 500Hz, 1000Hz, 2000Hz, 3000Hz, 3500Hz, 4000Hz, and 5000Hz in the frequency response curve shown are the frequencies that may require calibration.

[0211] After obtaining the frequency points that may require calibration, the frequency response of the first audio signal at these frequency points can be compared and calculated with the frequency response of the corresponding frequency point in the standard frequency response curve of the test audio signal. For example, at frequency point 100Hz, if the frequency response of the first audio signal differs from the frequency response in the standard frequency response curve of the test audio signal by 5dB, and if the pre-set expected standard discrete range is ±2dB, then 5dB is greater than 2dB. Therefore, frequency point 100Hz can be determined as the frequency point that needs calibration, and the frequency response gain at frequency point 100Hz can be determined to be 5dB.

[0212] The above method can be used to calculate each frequency point that may need calibration, determine the frequency point that needs calibration, the frequency response gain corresponding to the frequency point that needs calibration, and the total number of frequency points that need calibration.

[0213] At this point, based on the frequency points that need to be calibrated within the range of the first frequency point f1 to the second frequency point f2, the frequency response gain corresponding to the frequency points that need to be calibrated, and the number of frequency points that need to be calibrated, the calibration parameters can be determined, which can be used to determine the number of filters, filter type, filter center frequency, filter gain, and filter Q value, etc.

[0214] Since the equalizer calibration module can support the calibration of n to m subbands, the number of filters and filter types will not be exactly the same depending on the number of frequency points to be calibrated.

[0215] The methods for determining calibration parameters are explained below, categorized by situation.

[0216] Case 1: The number of frequency points i that need calibration is less than or equal to the minimum number of subbands n that support calibration. In this case, S1004B can be executed as follows.

[0217] S1004B sets the number of sub-bands to be calibrated to n.

[0218] Each sub-band to be calibrated (i.e., the frequency band to be calibrated) will have one filter. That is, the number of filters is set to n. In this case, each sub-band to be calibrated includes one frequency point to be calibrated. The center frequency of the filter corresponding to each sub-band to be calibrated is the frequency of the corresponding frequency point to be calibrated. The frequency points to be calibrated are set to the n frequency points with the largest difference between the frequency response of the first audio signal and the frequency response of the test audio signal. All filters are set to peak filters. The peak gain of the filter corresponding to each sub-band to be calibrated is the frequency response gain corresponding to the frequency point to be calibrated.

[0219] The second scenario: The number of frequency points i to be calibrated is greater than the minimum supported number of calibration subbands n, and less than or equal to the maximum supported number of calibration subbands m. In this case, the following S1004C can be executed.

[0220] S1004C, set the number of sub-bands to be calibrated to i or n.

[0221] In some embodiments, since n < i ≤ m, the number of sub-bands to be calibrated can be set to i, i.e., the filter data can be set to i. In this case, the filter type is set to peak filter. Each sub-band to be calibrated includes one frequency point to be calibrated. The center frequency of the filter corresponding to each sub-band to be calibrated is the frequency of the corresponding frequency point to be calibrated. All i frequencies to be calibrated are configured as the frequencies to be calibrated. The peak gain of the filter corresponding to each sub-band to be calibrated is the frequency response gain corresponding to the frequency point to be calibrated.

[0222] In some embodiments, frequency points requiring calibration can be merged, for example, merging adjacent frequency points. For instance, the frequency points that need calibration can be... Figure 11 The 100Hz and 200Hz frequencies are merged into one frequency band. After merging adjacent frequencies to obtain n frequency bands to be calibrated, merging of adjacent frequencies stops. At this point, the number of sub-bands to be calibrated can be set to n, i.e., the number of filters can be set to n. The peak gain of the filter corresponding to each sub-band to be calibrated is the average gain of the frequency response gain corresponding to each frequency point in each frequency band to be calibrated. All filter types can be set to peak filters.

[0223] The third scenario: The number of frequency points i that need to be calibrated is greater than the maximum number of supported calibration subbands m. In this case, the following S1004D can be executed.

[0224] S1004D sets the number of sub-bands to be calibrated to n, m, or p; where n≤p≤m; the frequency bands to be calibrated are obtained by merging the frequency points that need to be calibrated, and the number of frequency bands to be calibrated after merging is consistent with the number of sub-bands to be calibrated.

[0225] In this case, the number of frequency points i that need to be calibrated exceeds the maximum number of supported calibration subbands m, and adjacent frequency points need to be merged.

[0226] In some embodiments, the number of subbands to be calibrated can be set to n, i.e., the number of filters can be set to n. In this case, after merging adjacent frequency points, there are n frequency bands to be calibrated. For example, assume that the minimum number of subbands supported for calibration is n = 6, and the maximum number of subbands supported for calibration is m = 12. If the number of frequency points to be calibrated, i, is greater than 12, such as i = 13, the frequency points to be calibrated can be merged in pairs to obtain 6 frequency bands to be calibrated and 1 single frequency point. At this time, this single frequency point can be merged with its adjacent frequency bands to be calibrated, finally obtaining 6 frequency bands to be calibrated (one of the frequency bands to be calibrated includes 3 frequency points to be calibrated).

[0227] After merging adjacent frequency points to obtain n frequency bands to be calibrated, if the lowest frequency point of the lowest frequency band to be calibrated is f1 (where f1 is the preset lowest frequency to be calibrated), and the number of frequency points to be calibrated in the lowest frequency band to be calibrated is greater than or equal to 2, then the filter of the sub-band corresponding to the frequency band to be calibrated is set as a low-frequency shelving filter. The center frequency of the filter is set to the highest frequency point in the frequency band to be calibrated. The peak gain of the filter corresponding to the sub-band to be calibrated is set to the average gain of the frequency response gains corresponding to each frequency point in the frequency band to be calibrated.

[0228] If the highest frequency point of the highest frequency band to be calibrated is f2 (where f2 is the preset highest frequency to be calibrated), and the number of frequency points to be calibrated in the highest frequency band to be calibrated is greater than or equal to 2, then the filter of the sub-band corresponding to the frequency band to be calibrated is set as a high-frequency shelving filter. The center frequency of the filter is set as the lowest frequency point in the frequency band to be calibrated. The peak gain of the filter corresponding to the sub-band to be calibrated is set as the average gain of the frequency response gains corresponding to each frequency point in the frequency band to be calibrated.

[0229] When the above conditions are met, the filters for the sub-bands corresponding to the remaining n-2 frequency bands out of the n frequency bands to be calibrated are all set as peak filters. The center frequency of each filter is set to the center frequency of the corresponding frequency band to be calibrated. The gain to be calibrated is set to the average gain of the frequency response gains corresponding to each frequency point in the frequency band to be calibrated.

[0230] When the above conditions are not met, the filters of the sub-bands corresponding to the n frequency bands to be calibrated can all be set as peak filters. The center frequency of each filter is set to the center frequency of the corresponding frequency band to be calibrated. The peak gain of the filter corresponding to the sub-band to be calibrated is set to the average gain of the frequency response gains corresponding to each frequency point in the frequency band to be calibrated.

[0231] In some embodiments, the number of subbands to be calibrated can be set to m, i.e., the number of filters can be set to m. In this case, after merging adjacent frequency points, there are m frequency bands to be calibrated. For example, assume that the minimum number of subbands that can be calibrated is n = 6, and the maximum number of subbands that can be calibrated is m = 12. If the number of frequency points i to be calibrated is greater than 12, such as i = 13, only two adjacent frequency points can be merged into one frequency band to be calibrated, resulting in one frequency band to be calibrated and 11 frequency points to be calibrated.

[0232] In some embodiments, when i is less than or equal to 2m, the frequency points to be calibrated can be merged in pairs. For example, when i is odd, (i-1) / 2 frequency bands to be calibrated and 1 frequency point to be calibrated are obtained. In this case, the number of sub-bands to be calibrated is set to (i-1) / 2+1, that is, the number of filters is set to (i-1) / 2+1. When i is even, i / 2 frequency bands to be calibrated are obtained. In this case, the number of sub-bands to be calibrated is set to i / 2, that is, the number of filters is set to i / 2.

[0233] When i is greater than 2m, adjacent frequency points can be merged to obtain p frequency bands to be calibrated, where n ≤ p ≤ m. In this case, the number of sub-bands to be calibrated is set to p, which means the number of filters is set to p.

[0234] After merging adjacent frequency points to obtain m, (i-1) / 2+1, i / 2, or p frequency bands to be calibrated, the filter type, filter center frequency, and filter peak gain can be determined using the method described above for obtaining n frequency bands to be calibrated, which will not be elaborated here.

[0235] After determining the number of filters, filter types, filter center frequencies, and filter peak gains, it is also necessary to determine the filter peak bandwidth (also known as quality factor or Q value). The filter peak bandwidth is the filter's center frequency divided by its bandwidth. In this embodiment, the filter bandwidth can be determined by the frequency point or frequency band to be calibrated. For example, as... Figure 11 As shown, the bandwidth of the filter corresponding to the calibrated frequency of 100Hz can be the frequency difference between two frequency points on either side of the calibrated frequency of 100Hz and the standard frequency response, where the frequency response gain is x dB, such as 25Hz. Since the center frequency of the filter corresponding to the calibrated frequency of 100Hz is 100Hz, the peak bandwidth of the filter corresponding to the calibrated frequency of 100Hz is 100 / 25 = 4.

[0236] Similarly, for the frequency band to be calibrated obtained through frequency point combining, the bandwidth of the filter corresponding to this frequency band can be the frequency difference between two frequency points on either side of the center frequency of the frequency band to be calibrated, whose frequency response gain differs from the standard frequency response by x dB. The peak bandwidth of the filter can be calculated based on its center frequency and bandwidth.

[0237] S1005, the calibration equipment sends calibration parameters to the electronic device under test.

[0238] Once the equalizer parameter calculation module calculates the number of filters, the center frequency of the filters, the type of filters, the peak gain of the filters, and the peak bandwidth of the filters, it can transmit these calibration parameters to the screen sound device calibration control module. After receiving these calibration parameters, the screen sound device calibration control module can send them to the electronic device under test.

[0239] S1006, In response to receiving the calibration parameters, the electronic device under test saves the calibration parameters.

[0240] When the electronic device under test receives the above calibration parameters, it can save the calibration parameters to a non-volatile storage medium.

[0241] Table 1 below shows the parameter definitions and functional descriptions of the filter.

[0242] Table 1. Filter parameter definitions and functional descriptions

[0243]

[0244]

[0245] After the electronic device under test saves the above calibration parameters, the consistency of the frequency response curve of the screen sound-emitting device in the electronic device under test is calibrated.

[0246] In other embodiments, such as Figure 12 As shown, this frequency response consistency calibration method is applied to... Figure 8B The calibration system shown is described. The electronic device under test is communicatively connected to the calibration equipment. The method includes:

[0247] S1201, the calibration equipment sends a test command to the electronic device under test.

[0248] Please refer to S1001 above for details, which will not be repeated here.

[0249] S1202, in response to receiving a test command, the electronic device under test plays a test audio signal.

[0250] Please refer to S1002 above for details, which will not be repeated here.

[0251] S1203, the calibration equipment acquires the test audio signal played by the electronic device under test to obtain the first audio signal.

[0252] For example, the calibration equipment can activate the artificial ear after sending a test command to the electronic device under test. Of course, if the electronic device under test sends the test command to the calibration equipment, the calibration equipment can activate the artificial ear upon receiving the test command from the electronic device.

[0253] When the electronic device under test plays a test audio signal through the screen sound device, the calibration device can collect the test audio signal played by the electronic device under test through an artificial ear to obtain the first audio signal.

[0254] S1204, the calibration equipment sends the first audio signal to the electronic device under test.

[0255] Since the calibration equipment only performs sound acquisition when the electronic device under test plays the test audio signal, after the calibration equipment completes the acquisition of the first audio signal, it can send the first audio signal to the electronic device under test. Then, the electronic device under test determines the calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal.

[0256] S1205, the electronic device under test determines the calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal.

[0257] Please refer to the process for determining calibration parameters in S1004 above for details, which will not be repeated here.

[0258] S1206, the electronic device under test saves calibration parameters.

[0259] Please refer to S1006 above for details, which will not be repeated here.

[0260] It should be understood that during normal use, such as when the electronic device under test is making a call via its screen-based sound, the upper-layer application (such as a calling application) will send a call command to the smart PA control HAL upon detecting the user's dialing action. Similarly, when the electronic device is playing music via its screen-based sound, the upper-layer application (such as a music application) will send a music playback command to the smart PA control HAL upon detecting the user's music playback action.

[0261] When the smart PA control HAL receives a call command or music playback command, the smart PA control HAL can control the smart PA algorithm to run, configuring the smart PA algorithm to play the other party's voice signal or the corresponding audio signal of the music. During the configuration of the smart PA algorithm, the smart PA control HAL can control the information storage HAL to retrieve calibration parameters (i.e., equalizer parameters) from non-volatile storage media and send them to the equalizer calibration module in the smart PA algorithm.

[0262] In the smart PA algorithm, the audio signal to be played by the screen-emitting device (such as the other party's voice signal or the audio signal corresponding to music) is processed by the equalizer calibration module in the smart PA algorithm before being played by the screen-emitting device. For example, the audio signal to be played by the screen-emitting device can first be transformed into a frequency domain signal, and then the frequency response can be calibrated by the multi-band filter in the equalizer calibration module to improve the consistency of the frequency response curve of the screen-emitting device, thereby ensuring the consistency of the sound effect of the electronic device and making the user's listening experience better.

[0263] In summary, Figure 13 This is a comparison chart of the frequency response curve of a screen sound-emitting device provided in an embodiment of this application before and after frequency response consistency calibration. Figure 13 Figure (a) shows the distribution of frequency response curves of the screen sound devices in 100 electronic devices (pcs) before calibration. It can be seen from the figure that, without calibration, the frequency response curves of the sound signals played by the screen sound devices of these 100 electronic devices show significant differences and high dispersion. However, after calibration, as shown in Figure (a), the frequency response curves of the sound signals played by the screen sound devices of these 100 electronic devices show significant differences and high dispersion. Figure 13As shown in (b), the frequency response curve of the sound signal played by the screen sound device tends to be more consistent and the frequency response curve is smoother, resulting in better sound output and a better listening experience for the user.

[0264] Furthermore, this application also provides an audio playback method applied to an electronic device. The electronic device includes an equalizer calibration module and a screen sound-emitting device. The method includes: receiving an audio playback command. The audio playback command instructs the electronic device to play a second audio signal. In response to receiving the audio playback command, acquiring calibration parameters. The calibration parameters are calibration parameters stored in the electronic device according to the method described in the above embodiments. Adjusting the frequency response of the second audio signal using the equalizer calibration module and the calibration parameters to obtain a third audio signal. Playing the third audio signal through the screen sound-emitting device.

[0265] This application also provides an electronic device. The electronic device includes: one or more processors; a memory; and a communication module. The communication module is used to communicate with a calibration device. The memory stores one or more computer programs, which include instructions. When the instructions are executed by the processor, the electronic device causes the electronic device to perform the method performed by the electronic device under test or the electronic device described in the above embodiments. The electronic device can be as described above. Figure 9 The electronic device shown.

[0266] This application also provides a calibration device. The calibration device includes a processor and a memory. The memory stores one or more computer programs, which include instructions that, when executed by the processor, cause the calibration device to perform the method described in the above embodiment.

[0267] This application also provides a chip system, such as... Figure 14 As shown, the chip system 1400 can be applied to electronic devices or calibration equipment. The chip system 1400 includes at least one processor 1401 and at least one interface circuit 1402. The processor 1401 and the interface circuit 1402 can be interconnected via lines. For example, the interface circuit 1402 can be used to receive signals from other devices (e.g., the memory of an electronic device). As another example, the interface circuit 1402 can be used to send signals to other devices (e.g., the processor 1401).

[0268] For example, interface circuit 1402 can read instructions stored in the memory of an electronic device and send those instructions to processor 1401. When the instructions are executed by processor 1401, they can cause the electronic device (such as...) to... Figure 9The electronic device shown executes the various functions or steps performed by the electronic device under test in the above embodiments. Alternatively, when the instruction is executed by the processor 1401, the calibration device may execute the various functions or steps performed by the calibration device in the above embodiments.

[0269] Of course, the chip system may also include other discrete components, and this application embodiment does not specifically limit this.

[0270] Another embodiment of this application provides a computer storage medium including computer instructions that, when executed on an electronic device, cause the electronic device to perform various functions or steps performed by the electronic device in the above method embodiment.

[0271] Another embodiment of this application provides a computer program product that, when run on a computer, causes the computer to perform various functions or steps performed by the electronic device in the above method embodiment.

[0272] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0273] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another device, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0274] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0275] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0276] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product, such as a program. This software product is stored in a program product, such as a computer-readable storage medium, and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.

[0277] For example, embodiments of this application may also provide a computer-readable storage medium storing computer program instructions thereon. When the computer program instructions are executed by an electronic device, the electronic device causes the electronic device to implement the audio processing method as described in the foregoing method embodiments.

[0278] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A calibration method for frequency response consistency, characterized in that, The method is applied to an electronic device; the electronic device includes an equalizer calibration module; the electronic device is communicatively connected to a calibration device, and the method includes: The electronic device plays a test audio signal; The electronic device stores calibration parameters; the calibration parameters are the operating parameters of the equalizer calibration module; the calibration parameters are determined by the frequency response of the first audio signal and the standard frequency response of the test audio signal; the first audio signal is obtained by the calibration device acquiring the test audio signal played by the electronic device; the calibration parameters are used to adjust the frequency response of the second audio signal played by the electronic device through the equalizer calibration module when the electronic device plays the second audio signal. The equalizer calibration module includes multiple sub-band filters; the calibration parameters are the parameters of the multiple sub-band filters; the calibration parameters include the number of frequency bands to be calibrated, the filter type corresponding to each frequency band to be calibrated, the center frequency of the filter corresponding to each frequency band to be calibrated, and the frequency response gain corresponding to each frequency band to be calibrated. The calibration parameters are determined by comparing the frequency response of the first audio signal with the standard frequency response of the test audio signal, including: If the number of frequency points to be calibrated is less than or equal to N, where N is the preset minimum number of supported calibration sub-bands, and the frequency points to be calibrated are those where the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal exceeds a preset frequency response gain, then: the number of frequency bands to be calibrated is N; the center frequencies of the N frequency bands to be calibrated are the N frequency points where the difference between the frequency response of the first audio signal and the frequency response of the test audio signal is the largest; the filter type corresponding to each frequency band to be calibrated is a peak filter; the center frequency of the filter corresponding to each frequency band to be calibrated is the frequency corresponding to the center frequency point of the frequency band to be calibrated; and the frequency response gain of the filter corresponding to each frequency band to be calibrated is the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal at the center frequency point of the frequency band to be calibrated.

2. The calibration method according to claim 1, characterized in that, After the electronic device plays the test audio signal, the method further includes: The electronic device receives the first audio signal; The electronic device determines calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal.

3. The calibration method according to claim 1, characterized in that, After the electronic device plays the test audio signal, the method further includes: The electronic device receives the calibration parameters; the calibration parameters are determined by the calibration device based on the frequency response of the first audio signal and the standard frequency response of the test audio signal.

4. The calibration method according to any one of claims 1-3, characterized in that, The electronic device plays test audio signals, including: In response to receiving a detection command from the calibration device, the electronic device plays the test audio signal; or, In response to the electronic device sending the detection command to the calibration device, the electronic device plays the test audio signal.

5. The method according to any one of claims 1-3, characterized in that, The test audio signal is a full-frequency sweep signal.

6. The method according to any one of claims 1-3, characterized in that, The frequency response of the first audio signal is obtained by performing a time-frequency transformation on the first audio signal.

7. The method according to claim 6, characterized in that, The electronic device further includes an equalizer parameter calculation module; the electronic device determines calibration parameters based on the frequency response of the first audio signal and the standard frequency response of the test audio signal, including: The electronic device, through the equalizer parameter calculation module, determines the frequency points that need to be calibrated, the number of frequency points that need to be calibrated, and the frequency response gain corresponding to the frequency points that need to be calibrated, based on the frequency response of the first audio signal and the standard frequency response of the test audio signal. The electronic device determines the calibration parameters through the equalizer parameter calculation module based on the frequency points that need to be calibrated, the number of frequency points that need to be calibrated, and the frequency response gain corresponding to the frequency points that need to be calibrated.

8. The method according to claim 7, characterized in that, The frequency response gain corresponding to the frequency point that needs to be calibrated is: the difference between the frequency response of the first audio signal and the standard frequency response of the test audio signal at the frequency point that needs to be calibrated.

9. The method according to claim 8, characterized in that, If the number of frequency points requiring calibration is greater than N and less than or equal to M, where M is the preset maximum number of supported calibration subbands, then The number of frequency bands to be calibrated is the number of frequency points that need to be calibrated; The filter type corresponding to each frequency band to be calibrated is: peak filter; The center frequency of the filter corresponding to each frequency band to be calibrated is: the frequency corresponding to each frequency point that needs to be calibrated; The frequency response gain of the filter corresponding to each of the frequency bands to be calibrated is: the frequency response gain corresponding to each frequency point that needs to be calibrated.

10. The method according to claim 8, characterized in that, If the number of frequency points requiring calibration is greater than M, where M is the preset maximum number of supported calibration subbands, then The number of frequency bands to be calibrated is N; the frequency bands to be calibrated are obtained by merging the frequency points that need to be calibrated. In the frequency bands to be calibrated, excluding the lowest and highest frequency bands to be calibrated, The filter type corresponding to each frequency band to be calibrated is: peak filter; The center frequency of the filter corresponding to each frequency band to be calibrated is: the frequency corresponding to the center frequency point of the frequency band to be calibrated; The frequency response gain of the filter corresponding to each frequency band to be calibrated is: the average gain of the frequency response gains corresponding to all the frequency points to be calibrated in each frequency band to be calibrated.

11. The method according to claim 8, characterized in that, If the number of frequency points requiring calibration is greater than M, where M is the preset maximum number of supported calibration subbands, then The number of frequency bands to be calibrated is N; the frequency bands to be calibrated are obtained by merging the frequency points that need to be calibrated. If, among the N frequency bands to be calibrated, the lowest frequency point of the lowest frequency band to be calibrated is f1, and the number of frequency points requiring calibration in the lowest frequency band to be calibrated is greater than or equal to a first threshold, then... The filter type corresponding to the lowest frequency band to be calibrated is: low-frequency shelf filter; The center frequency of the filter corresponding to the lowest frequency band to be calibrated is: the frequency corresponding to the highest frequency point in the lowest frequency band to be calibrated; The frequency response gain corresponding to the lowest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to multiple frequency points that need to be calibrated in the lowest frequency band to be calibrated. In the lowest frequency band among the N frequency bands to be calibrated, if the lowest frequency point of the lowest frequency band to be calibrated is greater than f1, or the number of frequency points requiring calibration in the lowest frequency band to be calibrated is less than a first threshold, then The filter type corresponding to the lowest frequency band to be calibrated is: peak filter; The center frequency of the filter corresponding to the lowest frequency band to be calibrated is: the frequency corresponding to the center frequency point in the lowest frequency band to be calibrated; The frequency response gain corresponding to the lowest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to all the frequency points that need to be calibrated in the lowest frequency band to be calibrated. Where f1 is the preset minimum frequency that needs to be calibrated.

12. The method according to claim 8, characterized in that, If the number of frequency points requiring calibration is greater than M, where M is the preset maximum number of supported calibration subbands, then The number of filters is N; the frequency band to be calibrated is obtained by merging the frequency points that need to be calibrated; If, among the N frequency bands to be calibrated, the highest frequency point of the highest frequency band to be calibrated is f2, and the number of frequency points requiring calibration in the highest frequency band to be calibrated is greater than or equal to the second threshold, then... The filter type corresponding to the highest frequency band to be calibrated is: high-frequency shelf filter; The center frequency of the filter corresponding to the highest frequency band to be calibrated is: the frequency corresponding to the lowest frequency point in the highest frequency band to be calibrated; The frequency response gain corresponding to the highest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to multiple frequency points that need to be calibrated in the highest frequency band to be calibrated; If, among the N frequency bands to be calibrated, the highest frequency point of the highest frequency band to be calibrated is less than f2, or the number of frequency points requiring calibration in the highest frequency band to be calibrated is less than a first threshold, then The filter type corresponding to the highest frequency band to be calibrated is: peak filter; The center frequency of the filter corresponding to the highest frequency band to be calibrated is: the frequency corresponding to the center frequency point in the highest frequency band to be calibrated; The frequency response gain corresponding to the highest frequency band to be calibrated is: the average gain of the frequency response gains corresponding to all the frequency points that need to be calibrated in the highest frequency band to be calibrated. Where f2 is the preset highest frequency that needs to be calibrated.

13. An audio playback method, characterized in that, Applied to electronic devices; the electronic devices include an equalizer calibration module and a screen sound-emitting device; the method includes: Receive an audio playback command; the audio playback command is used to instruct the electronic device to play a second audio signal; In response to receiving the audio playback command, calibration parameters are obtained; the calibration parameters are calibration parameters stored in the electronic device according to the method described in any one of claims 1-12. The frequency response of the second audio signal is adjusted by the equalizer calibration module and using the calibration parameters to obtain the third audio signal. The third audio signal is played through the screen sound-emitting device.

14. An electronic device, characterized in that, The electronic device includes: One or more processors; Memory; Communication module; The communication module is used to communicate with the calibration equipment; The memory stores one or more computer programs, the one or more computer programs including instructions that, when executed by the processor, cause the electronic device to perform a frequency response consistency calibration method as described in any one of claims 1-12, or cause the electronic device to perform an audio playback method as described in claim 13.

15. A computer-readable storage medium storing instructions, characterized in that, When the instructions are executed on an electronic device, the electronic device performs a calibration method for frequency response consistency as described in any one of claims 1-12, or performs an audio playback method as described in claim 13.