A loudspeaker protection method, apparatus, chip and electronic device
Patent Information
- Application Number
- CN202310225686.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-09
- Publication Date
- 2026-09-22
- Estimated Expiration
- 2043-03-09
AI Technical Summary
[0004]然而现有的扬声器/喇叭的保护方案中,温度保护和位移保护的过程中的涉及的算法较为复杂
Smart Images

Figure CN116405848B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of electronic equipment technology, and in particular to a speaker protection method, device, chip, and electronic equipment. Background Technology
[0002] To improve the loudness and sound quality of mobile terminal speakers, it is necessary to monitor speaker displacement and temperature in real time and implement displacement and temperature protection measures. On one hand, the amplitude of the speaker diaphragm is a crucial factor affecting its lifespan. Speakers produce sound through diaphragm vibration; at the same frequency, a larger amplitude results in a louder sound. A larger diaphragm amplitude leads to greater vibration displacement. When the diaphragm's vibration displacement exceeds the factory-preset maximum displacement, it can cause irreversible damage. Therefore, displacement protection is essential during speaker operation to ensure that the diaphragm's vibration displacement does not exceed the factory-preset maximum displacement.
[0003] On the other hand, the operating temperature of the speaker / loudspeaker is another important factor affecting its lifespan. When the speaker's operating temperature exceeds the factory-preset maximum operating temperature, it is easily burned out. Therefore, to prevent speaker / loudspeaker burnout, temperature protection is necessary to control the speaker / loudspeaker's operating temperature to be equal to or lower than the factory-preset maximum operating temperature.
[0004] However, existing speaker / loudspeaker protection schemes involve complex algorithms in temperature protection and displacement protection processes. Therefore, providing a speaker protection method with a simple algorithm is an urgent problem to be solved. Summary of the Invention
[0005] This application provides a speaker protection method, apparatus, chip, and electronic device.
[0006] In a first aspect, embodiments of this application provide a method for obtaining a first signal for triggering a speaker to emit sound; calculating the energy dispersion of the first signal, wherein the energy dispersion is used to indicate the degree of dispersion of frequencies contained in the time period corresponding to the first signal; determining a gain value for the first signal based on a comparison result of the energy dispersion and a preset dispersion, wherein the gain value ranges from (0, 1); and performing gain processing on the first signal using the determined gain value to obtain a second signal.
[0007] It can be understood that the energy dispersion of the acquired first signal is calculated to obtain the corresponding energy dispersion. Based on the comparison result between the energy dispersion and the preset dispersion, a first gain value is determined for gain processing of the first signal. Then, the first signal is subjected to gain processing to obtain a second signal used to drive the speaker to produce sound.
[0008] In one possible implementation of the first aspect above, the method further includes: determining a gain value for the first signal based on a comparison result of energy dispersion and a preset dispersion, including: determining a first gain value for the first signal based on a comparison result of energy dispersion being greater than the preset dispersion; and determining a second gain value for the first signal based on a comparison result of energy dispersion being less than the preset dispersion.
[0009] In one possible implementation of the first aspect above, the method further includes: determining a second gain value for the first signal, comprising: obtaining a preset gain table based on a comparison result of energy dispersion being less than a preset dispersion, wherein the gain table records at least the gain values corresponding to signals of each frequency in the first signal; and determining the second gain value for the first signal based on a third gain value corresponding to the signal of the first frequency in the gain table.
[0010] In one possible implementation of the first aspect above, the method further includes: obtaining the gain table by sampling the signal frequency and voltage value corresponding to the upper limit of the loudspeaker displacement threshold and / or the upper limit of the temperature threshold; and statistically determining the gain table based on the sampling results, wherein the gain table records at least the gain value corresponding to each frequency of the signal in the first signal.
[0011] In one possible implementation of the first aspect above, the method further includes: performing gain processing on the first signal, including: multiplying the first signal by a gain value; and using the gain-processed first signal as the second signal.
[0012] In one possible implementation of the first aspect above, the method further includes: multiplying the first signal by a gain value, comprising: selecting the first gain value with the smallest value among the gain values and multiplying it by the first signal.
[0013] In one possible implementation of the first aspect above, the method further includes: determining a first gain value of the first signal, including: preprocessing the first signal according to a comparison result that the energy dispersion is greater than a preset dispersion to obtain a first input voltage and a first input current of the loudspeaker; determining a first temperature and / or predicted displacement of the loudspeaker under the current operating state based on the first input voltage and the first input current; and determining a first gain value according to the first temperature and the predicted displacement and a preset displacement threshold corresponding to the loudspeaker.
[0014] In one possible implementation of the first aspect above, the method further includes: obtaining the first temperature by means of:
[0015] Based on the acquired first input voltage and first input current, calculate the current first impedance of the speaker; based on the second impedance of the speaker at a preset second temperature and the calculated first impedance, calculate and determine the first temperature.
[0016] In one possible implementation of the first aspect above, the method further includes: the predicted displacement is obtained by calculating the predicted displacement of the loudspeaker based on the acquired first input voltage and first input current.
[0017] In one possible implementation of the first aspect above, the method further includes: calculating the energy dispersion of the first signal, including: determining the energy dispersion based on the amplitude spectrum corresponding to the first signal; or determining the energy dispersion based on the power spectrum corresponding to the first signal.
[0018] In one possible implementation of the first aspect above, the method further includes: determining the energy dispersion based on the amplitude spectrum corresponding to the first signal, including: determining a first entropy value of the amplitude spectrum based on the amplitude spectrum corresponding to the first signal; and determining the energy dispersion of the first signal based on the first entropy value of the amplitude spectrum.
[0019] In one possible implementation of the first aspect above, the method further includes: determining the energy dispersion based on the power spectrum corresponding to the first signal, including: determining a second entropy value of the power spectrum based on the power spectrum corresponding to the first signal; and determining the energy dispersion of the first signal based on the second entropy value of the power spectrum.
[0020] Secondly, embodiments of this application provide a loudspeaker protection device, comprising: a data acquisition module for acquiring a first signal that triggers the loudspeaker to emit sound; a calculation module for calculating the energy dispersion of the first signal and for determining a gain value for the first signal based on a comparison between the energy dispersion and a preset dispersion, wherein the energy dispersion is used to indicate the degree of dispersion of frequencies contained within a time period corresponding to the first signal, and the gain value ranges from (0, 1); and a gain module for performing gain processing on the first signal using the determined gain value to obtain a second signal.
[0021] In one possible implementation of the second aspect described above, the apparatus further includes: determining a gain value for the first signal, comprising: a calculation module determining a first gain value for the first signal based on a comparison result showing that the energy dispersion is greater than a preset dispersion; and determining a second gain value for the first signal based on a comparison result showing that the energy dispersion is less than a preset dispersion.
[0022] Thirdly, embodiments of this application provide a chip including any of the above-described speaker protection devices, wherein the speaker protection device is used to execute any of the above-described speaker protection methods.
[0023] Fourthly, embodiments of this application provide an electronic device, including: the chip described above for performing the speaker protection method described above. Attached Figure Description
[0024] Figure 1 A schematic flowchart of a speaker protection method is shown according to an embodiment of this application.
[0025] Figure 2 An embodiment of this application illustrates a relationship between voltage and audio signal at maximum displacement.
[0026] Figure 3 An embodiment of this application illustrates a graph showing the relationship between 10 different signals and the entropy values of their corresponding amplitude spectra.
[0027] Figure 4 A speaker protection device is shown according to an embodiment of this application.
[0028] Figure 5 A schematic diagram of the structure of an electronic device 100 is shown according to an embodiment of this application. Detailed Implementation
[0029] The specific embodiments of this application will now be described in detail with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the protection scope of this application.
[0030] To facilitate understanding of the solutions in the embodiments of this application, the terms used in the embodiments of this application will be explained below.
[0031] (1) Information Entropy (IE): This is a fundamental concept in information theory. It describes the uncertainty of the occurrence of various possible events from an information source. The introduction of information entropy solved the problem of quantifying and measuring information.
[0032] (2) Fast Fourier Transform (FFT): This is a general term for efficient and fast computation methods that use computers to calculate the Discrete Fourier Transform (DFT). Fourier analysis is the most basic method of signal analysis, and the Fourier Transform is the core of Fourier analysis. It transforms the signal from the time domain to the frequency domain, thereby studying the spectral structure and variation law of the signal. The Fourier Transform presents a discrete form in both the time and frequency domains, which is the Discrete Fourier Transform. It transforms the sampling of the time domain signal into the sampling in the frequency domain of the Discrete-Time Fourier Transform (DTFT).
[0033] (3) Normalization: Normalization is a dimensionless processing method, such as converting the absolute value of a physical system into a relative value relationship. This method is an effective way to simplify calculations and reduce the size of quantities. For example, after normalizing each frequency value in a filter to the cutoff frequency, each frequency can be converted into a relative value of the cutoff frequency, and there is no dimension. As another example, after normalizing the impedance to the internal resistance of the power supply, each impedance can be converted into a relative value of the internal resistance of the power supply, and the dimension of "ohm" is also gone. Correspondingly, the data after normalization can be restored to the original dimensional data by inverse normalization after the calculation is completed, which will not be elaborated here.
[0034] To extend the lifespan of loudspeakers, displacement and temperature protection are required during operation. Existing solutions preprocess the raw signal to obtain real-time temperature and displacement data, then compare this data with pre-set maximum displacement and maximum operating temperature values to determine the required gain of the raw signal. The gain of the raw signal is then adjusted according to the corresponding gain value to obtain the target signal. While existing loudspeaker protection schemes can achieve real-time temperature and displacement protection, their implementation process and algorithms are complex.
[0035] To address the aforementioned problems, this invention provides a speaker protection method applied to electronic devices. Specifically, this method determines the frequency dispersion of the original signal input to the speaker to produce sound by calculating its energy dispersion. The original signal comprises multiple sets of signals, each corresponding to one or more signal groups with different frequencies. For example, the entropy value of the amplitude spectrum or the entropy value of the power spectrum of the original signal can reflect the uniformity of the distribution of different frequencies within the original signal; that is, the more different frequencies contained within a given time period of the original signal, the greater the energy dispersion. In this case, a greater energy dispersion results in a greater entropy value for both the amplitude and power spectra of the original signal, and consequently, a greater number of different frequencies. Conversely, a smaller energy dispersion results in a smaller entropy value for both the amplitude and power spectra of the original signal, and a smaller number of different frequencies. Therefore, energy dispersion can be used to indicate the frequency dispersion within a corresponding time period of the original signal. For example, the frequency dispersion in the original signal can be determined by calculating the entropy value of its amplitude spectrum or power spectrum, thus obtaining the energy dispersion. This energy dispersion can then be compared with a preset energy dispersion to determine a suitable protection scheme for the speaker, providing temperature and displacement protection.
[0036] Specifically, when the calculated energy dispersion is greater than the preset energy dispersion, the original signal is processed to obtain the real-time temperature and displacement of the loudspeaker. The displacement gain and temperature gain are then calculated, and the original signal is amplified to obtain the amplified target signal. Conversely, when the calculated energy dispersion is less than the preset energy dispersion, the corresponding gain value can be determined from a pre-obtained gain table based on the frequency value of the original signal. The original signal is then amplified to obtain the amplified target signal. This gain table can be obtained from the preset displacement and temperature models corresponding to the loudspeaker. It is understood that, to ensure the loudspeaker's displacement and temperature do not exceed the upper temperature threshold, the gain applied to the original signal is typically a negative gain.
[0037] It is understood that the speaker protection method provided in this application performs energy dispersion detection on the original signal. When the energy dispersion is lower than the preset energy dispersion, it provides a simple gain calculation method, saving average performance.
[0038] It is understood that the speaker protection method provided in this application can be applied to electronic devices including but not limited to mobile phones, personal computers (PCs) (including laptops, desktop computers, tablets, etc.), servers, wearable devices, head-mounted displays, mobile email devices, in-vehicle devices, portable game consoles, portable music players, e-reader devices, televisions with multiple processors embedded or coupled thereto, or other electronic devices with multiple processors.
[0039] The following is combined with Figure 1 This application provides a detailed description of the specific implementation process of the speaker protection method provided in the embodiments.
[0040] Figure 1 A flowchart illustrating a loudspeaker protection method is shown according to an embodiment of this application. It is understood that the entity executing each step of this method can be a protection device or equipment implementing the loudspeaker protection method of this application. The specific structure of the protection device or equipment will be described in detail below and will not be repeated here.
[0041] like Figure 1 As shown, the process includes the following steps:
[0042] 101: Calculate the energy dispersion of the acquired raw signal to obtain the corresponding energy dispersion.
[0043] For example, energy dispersion is detected on the acquired raw signal, and the energy dispersion of the raw signal is calculated. The specific method for calculating energy dispersion will be described in detail below, and will not be repeated here.
[0044] 102: Determine whether the calculated energy dispersion is greater than the preset energy dispersion. If the determination result is yes, that is, when the calculated energy dispersion is greater than the preset energy dispersion, proceed to step 103a below; if the determination result is no, that is, when the calculated energy dispersion is less than the preset energy dispersion, proceed to step 103b below.
[0045] For example, the energy dispersion of the audio input signal obtained in step 101 above is compared with a preset energy dispersion to determine whether the calculated energy dispersion is greater than the preset energy dispersion. The preset energy dispersion can be adjusted according to actual conditions and is not limited here.
[0046] 103a: Calculate the gain value adjusted for the original signal.
[0047] It is understandable that when the calculated energy dispersion is greater than the preset energy dispersion, the original signal is processed to obtain the speaker's real-time temperature and predicted displacement.
[0048] When calculating the real-time temperature of a loudspeaker, the original signal can be processed to obtain voltage and current data for driving the loudspeaker. Using this voltage and current data, the loudspeaker's DC impedance can be calculated in real time. Since the loudspeaker coil is typically made of a special alloy material, its temperature rise coefficient is relatively fixed. By calculating the real-time DC impedance and the loudspeaker's DC impedance at a reference temperature (typically 25°C), the loudspeaker's real-time operating temperature can be calculated. Based on the loudspeaker's real-time temperature and maximum operating temperature, the temperature gain value can then be obtained. The specific calculation formula is as follows:
[0049]
[0050] in, The reference temperature value is generally set to 25 degrees Celsius. for The DC impedance value corresponding to the temperature. α is the temperature rise coefficient of the speaker coil, which is usually related to the material of the speaker coil. This is the real-time DC impedance value of the speaker.
[0051] The original signal can be processed to obtain voltage and current data for driving the speaker. The voltage data can then be processed and analyzed to obtain the predicted displacement. Furthermore, based on the speaker's real-time temperature, as well as the predicted and maximum displacement values, the displacement gain value can be determined.
[0052] 103b: Based on the frequency value of the original signal, look up the gain table to obtain the corresponding gain value.
[0053] For example, when the calculated energy dispersion is less than or equal to a preset energy dispersion, an FFT analysis is performed on the original audio data signal. Then, based on the frequency of the original signal and a pre-acquired gain table, the corresponding gain value is determined. The gain table includes a displacement gain table and a temperature gain table, which can be pre-acquired based on the speaker's displacement and temperature models. The displacement model at least includes the correspondence between the theoretical voltage and the frequency of the audio input signal at the maximum displacement, and the temperature model at least includes the correspondence between the theoretical voltage and the frequency of the audio input signal at the highest operating temperature. The gain table is drawn by sampling the frequency and theoretical voltage of the audio input signal from the aforementioned displacement and temperature models, and at least includes the frequency signal and its corresponding gain value.
[0054] It is understandable that the acquired raw signal is processed to obtain the corresponding input voltage, and it is then determined whether the input voltage corresponding to the current raw signal exceeds the voltage corresponding to the same frequency in the displacement model and / or temperature model.
[0055] Figure 2 An embodiment of this application illustrates a graph showing the correspondence between voltage and audio input signal frequency under maximum displacement. Wherein, Figure 2 The vertical axis represents the operating voltage of the speaker, measured in volts (V), while the horizontal axis represents the frequency of the audio input signal, measured in Hz.
[0056] refer to Figure 2 As shown at point A, with a maximum displacement of Xmax = 0.3 mm and a frequency of 100 Hz, the corresponding voltage value is approximately 6 V. In some embodiments, for Figure 2 The corresponding relationships shown are sampled to obtain a frequency-voltage table. This table can serve as a displacement gain table for the original signal. Furthermore, if the frequency of the acquired original signal corresponds to 100Hz, but the corresponding actual voltage is 7V, then the amplitude of the original signal needs to be increased. The gain value can be, for example, the ratio of the theoretical voltage to the actual voltage value.
[0057] Correspondingly, the original signal is processed simultaneously to obtain the speaker's real-time temperature, which is then compared with the specified maximum operating temperature to determine whether the current original audio signal requires gain. When gain is required, the temperature gain table is consulted according to a preset temperature model to determine the corresponding gain value.
[0058] It is understandable that, in order to ensure that the original audio input signal after gain can simultaneously meet the requirements of being less than or equal to the maximum displacement and the highest operating temperature, the minimum gain value between the displacement gain table and the temperature gain table is selected based on the comparison between the two.
[0059] 104: Based on the obtained gain value, adjust the amplitude of the original signal to obtain the adjusted target signal.
[0060] It can be understood that, based on the gain value obtained from steps 103a and 103b above, the original signal is subjected to gain processing. For example, the amplitude of the original signal can be 1, the gain value can be 0.5, and the amplitude of the target signal after multiplying the two can be 0.5, that is, the amplitude of the target signal input to the speaker is 0.5. The range of the above gain value is (0, 1).
[0061] The following details the specific implementation process of calculating the energy dispersion of the original signal in step 101 above.
[0062] First, let's explain the definition of information entropy. Information entropy is defined as follows:
[0063] (1)
[0064] Where n is the number of possibilities. For each possible probability, the more information an event contains, the lower its information entropy and the more uneven its probability distribution. Conversely, the less information an event contains, the higher its information entropy and the more uniform its probability distribution. Normalizing the parameters in formula (1) yields the normalized information entropy:
[0065] (2)
[0066] It's understandable that the more uneven the probability distribution, The closer to 0, the more uniform the probability distribution. The closer it is to 1.
[0067] It is understandable that the above theory can be extended to the original signal. Assuming that the N-point FFT of an original signal is X(k), then the proportion of the N points in the entire original signal can be considered as shown in formula (3):
[0068] (3)
[0069] Meanwhile, due to the conjugate symmetry of FFT, only the first N / 2+1 points are needed to represent all the information. Referring to the above formula (2), the formula for calculating the entropy value of the normalized amplitude spectrum in the above formula (3) is as follows:
[0070] (4)
[0071] In addition, FFT analysis can be performed on the signal power of the original signal to determine the proportion of the signal power at that point in the total power of the original signal, as shown in formula (5):
[0072] (5)
[0073] Similarly, referring to formula (2) above, the formula for calculating the entropy value of the normalized power spectrum in formula (5) above is as follows:
[0074] (6)
[0075] According to the probability distribution, the larger the entropy value of the amplitude spectrum of an audio input signal / the entropy value of its power spectrum, the greater the energy dispersion of that audio input signal; conversely, the smaller the entropy value of the amplitude spectrum / the entropy value of its power spectrum, the smaller the energy dispersion and the more concentrated the energy. In this application, after performing FFT analysis on the original signal, the energy dispersion is calculated according to the above formula (3), and further calculated according to the above formula (4) to normalize the entropy value of the amplitude spectrum of the original signal after FFT analysis, thus obtaining the corresponding energy dispersion. In other embodiments, the power of the original signal can also be analyzed by FFT, and the energy dispersion can be calculated according to the above formula (5), and further calculated according to the above formula (6) to normalize the entropy value of the power spectrum of the original signal after FFT analysis, thus obtaining the corresponding energy dispersion. This is not a limitation.
[0076] It is understood that the original signal comprises multiple sets of signals, each corresponding to one or more signal groups with different frequencies. For example, the entropy value of the amplitude spectrum or the entropy value of the power spectrum of the original signal can reflect the uniformity of the distribution of different frequencies contained in the original signal. When the energy dispersion is greater, the entropy value of the amplitude spectrum and the entropy value of the power spectrum of the original signal are both greater, and the number of different frequencies contained is smaller. Conversely, the smaller the energy dispersion, the smaller the entropy value of the amplitude spectrum and the entropy value of the power spectrum of the original signal, and the more different frequencies contained are. Therefore, energy dispersion can be used to indicate the degree of dispersion of frequencies contained within a corresponding time period in the original signal. For example, the degree of frequency dispersion in the original signal can be determined by calculating the entropy value of the amplitude spectrum or the entropy value of the power spectrum of the original signal, thereby obtaining the energy dispersion. This allows for comparison with a preset energy dispersion to determine a suitable protection scheme for temperature and displacement protection of the speaker.
[0077] The original signal mentioned above can be, for example, as follows: Figure 3 The audio input signal shown is Figure 3 The audio consists of 10 different signals, each lasting 10 seconds. Figure 3 The vertical axis can be represented by the entropy value of the amplitude spectrum corresponding to each audio signal segment, and the horizontal axis can be represented by different signal segments. Each signal segment includes one or more signals of different frequencies.
[0078] In some embodiments, the above... Figure 3 The energy dispersion of each audio input signal segment is detected, and the energy dispersion of each segment is calculated. Figure 3The audio input signal consists of the following segments: Segment 1 is a 500Hz single-frequency tone; Segment 2 is an 800Hz single-frequency tone; Segment 3 is a combination of 500Hz, 800Hz, and 1000Hz single-frequency tones; Segment 4 is a combination of 10 single-frequency tones; Segment 5 is white noise with a mean of 0; Segment 6 is white noise passed through a 6th-order 8000Hz low-pass filter; Segment 7 is white noise passed through a 6th-order 5000Hz low-pass filter; Segment 8 is white noise passed through a 6th-order 3000Hz low-pass filter; Segment 9 is white noise passed through a 6th-order 1500Hz low-pass filter; and Segment 10 is a logarithmic-cosine sweep from 20Hz to 10000Hz. Energy dispersion can be detected based on these audio input segments to obtain the corresponding energy dispersion.
[0079] It is understandable that the audio input signals in segments 3 to 5 and segment 10 contain a relatively large number of different frequencies, resulting in low dispersion and therefore low energy dispersion. The other audio input signals contain fewer different frequencies, resulting in higher dispersion and therefore higher energy dispersion.
[0080] Figure 4 A speaker protection device is shown according to an embodiment of this application.
[0081] like Figure 4 As shown, the device includes an acquisition module, a calculation module, and a gain module. The acquisition module acquires the audio input signal to obtain the raw signal. The calculation module calculates the energy dispersion of the raw signal to obtain the corresponding energy dispersion. Based on the comparison result of the energy dispersion with a preset energy dispersion, a protection scheme corresponding to the comparison result is adopted. The gain module processes the acquired raw signal according to the protection process determined by the calculation module, obtains the corresponding gain value, and performs gain processing on the raw signal to obtain the target signal.
[0082] It is understandable that the specific implementation process of the protection procedure determined by the calculation module in the gain module has been combined with... Figure 3 Detailed explanations will not be elaborated here.
[0083] Figure 5 According to some embodiments of this application, a schematic diagram of the structure of an electronic device 100 is shown. It is understood that the electronic device 100 may be a protection device or apparatus that implements the speaker protection method of this application as described above, or other apparatus capable of performing the speaker protection method provided in this application, and no limitation is made herein.
[0084] like Figure 5As shown, the electronic device 100 includes one or more processors 101, system memory 102, non-volatile memory (NVM) 103, communication interface 104, input / output (I / O) devices 105, and system control logic 106. Wherein:
[0085] The processor 101 may include one or more processing units, such as a central processing unit (CPU), a graphics processing unit (GPU), a digital signal processor (DSP), a micro-programmed control unit (MCU), an AI (Artificial Intelligence) processor, or a programmable logic device (FPGA), a neural network processing unit (NPU), etc. The data processing unit or processing circuit may include one or more single-core or multi-core processors. In some embodiments, the processor 101 may be used to execute instructions to implement the relevant functions of the aforementioned data processing unit, tagging unit, and data storage unit.
[0086] System memory 102 is volatile memory, such as random-access memory (RAM), double data rate synchronous dynamic random access memory (DDR SDRAM), etc.
[0087] The non-volatile memory 103 may include one or more tangible, non-transitory computer-readable media for storing data and / or instructions. In some embodiments, the non-volatile memory 103 may include any suitable non-volatile memory such as flash memory and / or any suitable non-volatile storage device, such as a hard disk drive (HDD), a compact disc (CD), a digital versatile disc (DVD), a solid-state drive (SSD), etc. In some embodiments, the non-volatile memory 103 may also be a removable storage medium, such as a Secure Digital (SD) memory card, etc.
[0088] Specifically, system memory 102 and non-volatile memory 103 may each include a temporary copy and a permanent copy of instruction 107. Instruction 107 may include, when executed by at least one of processors 101, causing electronic device 100 to implement the speaker protection method provided in the embodiments of this application.
[0089] The communication interface 104 may include a transceiver for providing a wired or wireless communication interface for the electronic device 100, thereby enabling communication with any other suitable device via one or more networks. In some embodiments, the communication interface 104 may be integrated into other components of the electronic device 100, for example, the communication interface 104 may be integrated into the processor 101. In some embodiments, the electronic device 100 may communicate with other devices through the communication interface 104.
[0090] Input / output (I / O) device 105 may include input devices such as keyboard, mouse, etc., and output devices such as monitor, etc. Users can interact with electronic device 100 through input / output (I / O) device 105.
[0091] System control logic 106 may include any suitable interface controller to provide any suitable interface to other modules of electronic device 100. For example, in some embodiments, system control logic 106 may include one or more memory controllers to provide an interface to system memory 102 and non-volatile memory 103.
[0092] Understandable. Figure 5 The structure of the electronic device 100 shown is merely an example. In other embodiments, the electronic device 100 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.
[0093] This application also provides a program product for implementing the speaker protection methods provided in the above embodiments.
[0094] Various embodiments of the mechanisms disclosed in this application can be implemented in hardware, software, firmware, or a combination of these implementation methods. Embodiments of this application can be implemented as computer modules or module code executing on a programmable system, the programmable system including at least one processor, a storage system (including volatile and non-volatile memory and / or storage elements), at least one input device, and at least one output device.
[0095] Module code can be applied to input instructions to perform the functions described in this application and generate output information. The output information can be applied to one or more output devices in a known manner. For the purposes of this application, the processing system includes any system having a processor such as, for example, a Digital Signal Processor (DSP), a microcontroller, an Application Specific Integrated Circuit (ASIC), or a microprocessor.
[0096] Module code can be implemented using a high-level modular language or an object-oriented programming language to communicate with the processing system. Assembly language or machine language can also be used to implement module code when needed. In fact, the mechanisms described in this application are not limited to any particular programming language. In either case, the language can be a compiled language or an interpreted language.
[0097] In the accompanying drawings, some structural or methodological features may be shown in a specific arrangement and / or order. However, it should be understood that such a specific arrangement and / or order may not be necessary. Rather, in some embodiments, these features may be arranged in a manner and / or order different from that shown in the illustrative drawings. Furthermore, the inclusion of structural or methodological features in a particular figure does not imply that such features are required in all embodiments, and in some embodiments, these features may be omitted or may be combined with other features.
[0098] It should be noted that in the examples and description of this patent, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one" does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes the element.
[0099] Although this application has been illustrated and described with reference to certain preferred embodiments thereof, those skilled in the art should understand that various changes in form and detail may be made thereto without departing from the spirit and scope of this application.
Claims
1. A speaker protection method, characterized in that, include: Acquire the first signal used to trigger the speaker to emit sound; Calculate the energy dispersion of the first signal, wherein the energy dispersion is used to indicate the degree of dispersion of the frequencies contained in the time period corresponding to the first signal; Based on the comparison result between the energy dispersion and the preset dispersion, a gain value for the first signal is determined, wherein the gain value ranges from (0, 1). Determining the gain value for the first signal based on the comparison result between the energy dispersion and the preset dispersion includes: Based on the comparison result that the energy dispersion is greater than the preset dispersion, the first signal is preprocessed to obtain the first input voltage and the first input current of the speaker; Based on the first input voltage and the first input current, determine the first temperature and / or predicted displacement of the speaker in its current operating state; Based on the first temperature and / or the predicted displacement, and a preset displacement threshold corresponding to the loudspeaker, a first gain value for the first signal is determined; and, Based on the comparison result that the energy dispersion is less than or equal to a preset dispersion, a preset gain table is obtained, wherein the gain table records at least the gain values corresponding to each frequency of the signal in the first signal. Based on the third gain value corresponding to the signal at the first frequency in the gain table, determine the second gain value for the first signal; The first signal is subjected to gain processing using a determined first gain value or second gain value to obtain a second signal.
2. The method according to claim 1, characterized in that, The gain table is obtained in the following way: The signal frequency and voltage value corresponding to the upper limit of the speaker displacement threshold and / or the upper limit of the temperature threshold are sampled; The gain table is determined based on the sampling results, wherein the gain table records at least the gain values corresponding to each frequency of the first signal.
3. The method according to claim 1, characterized in that, The gain processing of the first signal includes: Multiply the first signal by the gain value; The first signal after gain processing is used as the second signal.
4. The method according to claim 3, characterized in that, Multiplying the first signal by the gain value includes: Select the first gain value with the smallest value from the gain values and multiply it by the first signal.
5. The method according to claim 1, characterized in that, The first temperature is obtained in the following way: Calculate the current first impedance of the speaker based on the acquired first input voltage and first input current; The first temperature is calculated and determined based on the second impedance corresponding to the loudspeaker at a preset second temperature and the calculated first impedance.
6. The method according to claim 1, characterized in that, The predicted displacement is obtained by calculating the predicted displacement of the loudspeaker based on the acquired first input voltage and first input current.
7. The method according to claim 1, characterized in that, The calculation of the energy dispersion of the first signal includes: The energy dispersion is determined based on the amplitude spectrum corresponding to the first signal; or The energy dispersion is determined based on the power spectrum corresponding to the first signal.
8. The method according to claim 7, characterized in that, Determining the energy dispersion based on the amplitude spectrum corresponding to the first signal includes: The first entropy value of the amplitude spectrum is determined based on the amplitude spectrum corresponding to the first signal; The energy dispersion of the first signal is determined based on the first entropy value of the amplitude spectrum.
9. The method according to claim 8, characterized in that, Determining the energy dispersion based on the power spectrum corresponding to the first signal includes: The second entropy value of the power spectrum is determined based on the power spectrum corresponding to the first signal; The energy dispersion of the first signal is determined based on the second entropy value of the power spectrum.
10. A loudspeaker protection device, characterized in that, include: The acquisition module is used to acquire the first signal that triggers the speaker to emit sound; A calculation module is used to calculate the energy dispersion of the first signal and to determine a gain value for the first signal based on a comparison between the energy dispersion and a preset dispersion. The energy dispersion indicates the degree of dispersion of frequencies contained within a corresponding time period of the first signal, and the gain value ranges from (0 to 1). Determining the gain value for the first signal based on the comparison between the energy dispersion and the preset dispersion includes: Based on the comparison result that the energy dispersion is greater than the preset dispersion, the first signal is preprocessed to obtain the first input voltage and the first input current of the speaker; Based on the first input voltage and the first input current, determine the first temperature and / or predicted displacement of the speaker in its current operating state; Based on the first temperature and / or the predicted displacement, and a preset displacement threshold corresponding to the loudspeaker, a first gain value for the first signal is determined; and, Based on the comparison result that the energy dispersion is less than or equal to a preset dispersion, a preset gain table is obtained, wherein the gain table records at least the gain values corresponding to each frequency of the signal in the first signal. Based on the third gain value corresponding to the signal at the first frequency in the gain table, determine the second gain value for the first signal; A gain module is used to perform gain processing on the first signal using a determined first gain value or a second gain value to obtain a second signal.
11. A chip, characterized in that, include: The loudspeaker protection device of claim 10, wherein the loudspeaker protection device is used to perform the loudspeaker protection method of any one of claims 1 to 9.
12. An electronic device, characterized in that, include: The chip of claim 11 is used to perform the speaker protection method of any one of claims 1 to 9.
Citation Information
Patent Citations
Temperature protection circuit, method, protection device and electronic equipment
CN113810833A
Dynamic sound adjustment based on noise floor estimate
US20190198005A1
Audio clipping prevention
US9325286B1