Audio playing method and device, electronic equipment and storage medium

CN122934146APending Publication Date: 2026-10-16REALME MOBILE TELECOMM SHENZHEN CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510442752.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-09
Publication Date
2026-10-16

AI Technical Summary

Technical Problem

电子设备常被用于进行音频播放,电子设备通过扬声器播放音频时,为了避免扬声器受损,通常会限制响度,从而影响扬声器的响度和音质

Benefits of technology

[0008] The solution provided in this application targets electronic devices including an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. During audio playback, the smart power amplifier transmits feedback voltage and current data from the speaker to the digital signal processor, which then transmits the same data to the application processor. The application processor then controls the audio parameters of the audio signal to be played based on the feedback voltage and current data. Therefore, even when the digital signal processor in the electronic device is a non-open digital signal processor, and the smart power amplifier does not contain a dedicated digital signal processor, feedback control based on the speaker's feedback voltage and current data can still be achieved through the application processor. This improves audio playback quality and reduces the implementation cost of feedback control during audio playback.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122934146A_ABST
    Figure CN122934146A_ABST
Patent Text Reader

Abstract

The application discloses an audio playing method and device, electronic equipment and a storage medium. The audio playing method is applied to the electronic equipment, and the electronic equipment comprises an application processor, a non-open digital signal processor, an intelligent power amplifier and a loudspeaker. The method comprises the following steps: in the process of playing audio, the feedback voltage data and the feedback current data of the loudspeaker are transmitted to the digital signal processor through the intelligent power amplifier; the feedback voltage data and the feedback current data are transmitted to the application processor through the digital signal processor; and the audio parameters of the audio signal to be played are controlled according to the feedback voltage data and the feedback current data through the application processor. The method can improve the audio playing effect and reduce the implementation cost of feedback control during audio playing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of electronic equipment technology, and more specifically, to an audio playback method, apparatus, electronic device, and storage medium. Background Technology

[0002] With the rapid advancement of technology and living standards, electronic devices (such as smartphones and tablets) have become one of the most commonly used electronic products in people's lives. Electronic devices are often used for audio playback. When electronic devices play audio through speakers, the loudness is usually limited to avoid damaging the speakers, thus affecting the loudness and sound quality of the speakers. Summary of the Invention

[0003] This application proposes an audio playback method, apparatus, electronic device, and storage medium that can improve the audio playback effect while reducing the implementation cost of feedback control during audio playback.

[0004] In a first aspect, embodiments of this application provide an audio playback method applied to an electronic device, the electronic device including an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The method includes: during audio playback, transmitting feedback voltage data and feedback current data from the speaker to the digital signal processor via the smart power amplifier; transmitting the feedback voltage data and feedback current data to the application processor via the digital signal processor; and controlling the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data via the application processor.

[0005] Secondly, embodiments of this application provide an audio playback device applied to an electronic device. The electronic device includes an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The device includes a first transmission module, a second transmission module, and a parameter control module. The first transmission module is used to transmit feedback voltage data and feedback current data from the speaker to the digital signal processor via the smart power amplifier during audio playback. The second transmission module is used to transmit the feedback voltage data and feedback current data to the application processor via the digital signal processor. The parameter control module is used to control the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data through the application processor.

[0006] Thirdly, embodiments of this application provide an electronic device, including: an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker, wherein the smart power amplifier is used to transmit feedback voltage data and feedback current data of the speaker to the digital signal processor during audio playback; the digital signal processor is used to transmit the feedback voltage data and feedback current data to the application processor; and the application processor is used to control the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

[0007] Fourthly, embodiments of this application provide a computer-readable storage medium storing program code, which can be called by a processor to execute the audio playback method provided in the first aspect above.

[0008] The solution provided in this application targets electronic devices including an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. During audio playback, the smart power amplifier transmits feedback voltage and current data from the speaker to the digital signal processor, which then transmits the same data to the application processor. The application processor then controls the audio parameters of the audio signal to be played based on the feedback voltage and current data. Therefore, even when the digital signal processor in the electronic device is a non-open digital signal processor, and the smart power amplifier does not contain a dedicated digital signal processor, feedback control based on the speaker's feedback voltage and current data can still be achieved through the application processor. This improves audio playback quality and reduces the implementation cost of feedback control during audio playback. Attached Figure Description

[0009] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0010] Figure 1 A schematic diagram of the application environment provided in the embodiments of this application is shown.

[0011] Figure 2 A flowchart illustrating an audio playback method according to an embodiment of this application is shown.

[0012] Figure 3 A flowchart illustrating an audio playback method according to another embodiment of this application is shown.

[0013] Figure 4 A flowchart illustrating an audio playback method according to yet another embodiment of this application is shown.

[0014] Figure 5 A flowchart illustrating an audio playback method according to another embodiment of this application is shown.

[0015] Figure 6 A schematic diagram illustrating the playback effect of the audio playback method provided in this application embodiment is shown.

[0016] Figure 7 A flowchart illustrating an audio playback method according to yet another embodiment of this application is shown.

[0017] Figure 8 A schematic diagram illustrating the principle of the audio playback method provided in the embodiments of this application is shown.

[0018] Figure 9 A block diagram of an audio playback device according to an embodiment of this application is shown.

[0019] Figure 10 This is a block diagram of an electronic device for performing an audio playback method according to an embodiment of this application.

[0020] Figure 11 This is a storage unit in this application embodiment for storing or carrying program code that implements the audio playback method according to this application embodiment. Detailed Implementation

[0021] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.

[0022] With the development of electronic devices, they are increasingly used for audio playback, which brings significant challenges to improving their sound quality. In practical use, to protect the speakers of electronic devices, the current and power output to the speakers are usually limited to limit the loudness and prevent excessive vibration of the speaker diaphragm, thus affecting the loudness and sound quality of the electronic device.

[0023] In related technologies, playback control can be performed based on the speaker's real-time operating status by monitoring its temperature and amplitude, thereby maximizing the speaker's performance. When monitoring the speaker's temperature and amplitude, a Smart Power Amplifier (SmartPA) can be incorporated into the electronic device to monitor the speaker's voltage and current, thereby implementing feedback adjustments to the audio playback based on relevant audio playback algorithms.

[0024] When implementing feedback adjustment for audio playback, an open digital signal processor (OPEN DSP) can be incorporated into the electronic device. This DSP runs the relevant playback control algorithm, enabling feedback control based on the voltage and current of the speakers detected by the intelligent power amplifier. In contrast, electronic devices using a conventional digital signal processor (DSP) instead of an open DSP can only achieve feedback control by running the playback control algorithm through the intelligent power amplifier equipped with the DSP, based on the detected voltage and current of the speakers.

[0025] In the above solutions, whether an open digital signal processor or a smart power amplifier with a built-in digital signal processor is used, the cost of the electronic device will increase. Moreover, setting up a digital signal processor in the smart power amplifier will also affect the internal layout of the smart power amplifier, increase the size of the smart power amplifier, thereby increasing the size of the electronic device and affecting its aesthetics.

[0026] To address the aforementioned problems, the inventors have proposed an audio playback method, apparatus, electronic device, and storage medium as described in the embodiments of this application. Even when the digital signal processor (DSP) in the electronic device is a non-open DSP, and the intelligent power amplifier does not have a DSP, feedback control based on the speaker's feedback voltage and current data can be implemented through an application processor. This improves audio playback quality and reduces the implementation cost of feedback control during audio playback. The specific audio playback method will be described in detail in subsequent embodiments.

[0027] The scenarios involved in the embodiments of this application will be introduced below.

[0028] like Figure 1 As shown, in Figure 1The scenario depicted includes an electronic device 100, which may include an application processor (AP) 101, a non-open digital signal processor (DSP) 102, a smart power amplifier 103, and a speaker 104. The AP can communicate with the DSP 102, the DSP 102 can communicate with the smart power amplifier 103, and the smart power amplifier 103 can be connected to the speaker 104. The AP 101 is the core computing unit of electronic devices such as smartphones, tablets, and smart wearable devices, responsible for running the operating system and various user-installed applications. The DSP is a microprocessor optimized for digital signal processing tasks, capable of efficiently performing real-time signal analysis, filtering, transformation, encoding, and other operations. Through hardware acceleration and instruction set optimization, the DSP has significant performance advantages in processing digital signals. The smart power amplifier is an electronic device that adds a current and voltage acquisition module at the output end to a traditional power amplifier.

[0029] When the electronic device 100 plays audio, the application processor 101 can output an audio signal to the digital signal processor 102. The digital signal processor 102 then processes the audio signal by performing equalization, sound enhancement, noise suppression, and other functions, and outputs the processed audio signal to the intelligent power amplifier 103. The intelligent power amplifier 103 receives the processed audio signal, amplifies the power, and outputs it to the speaker 104. The speaker 104 then converts the amplified electrical signal into a sound signal and emits sound.

[0030] In implementing feedback control during audio playback, the intelligent power amplifier 103 acquires the feedback voltage and current data of the speaker 104 and transmits this data to the digital signal processor 102. The digital signal processor 102 then transmits the feedback voltage and current data to the application processor 101, which controls the audio parameters of the audio signal to be played based on the feedback voltage and current data. This allows for feedback control based on the speaker's feedback voltage and current data even when the digital signal processor in the electronic device is not a fully functional one, and even if the intelligent power amplifier does not have a built-in digital signal processor. This improves audio playback quality and reduces the implementation cost of feedback control during audio playback.

[0031] The audio playback method provided in the embodiments of this application will now be described in detail with reference to the accompanying drawings.

[0032] Please see Figure 2 , Figure 2 A flowchart illustrating an embodiment of an audio playback method provided in this application is shown. In a specific embodiment, the audio playback method is applied to the aforementioned electronic device, which includes an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The following will focus on... Figure 2 The process shown will be described in detail. The audio playback method may specifically include the following steps:

[0033] Step S110: During audio playback, the feedback voltage data and feedback current data of the speaker are transmitted to the digital signal processor via the intelligent power amplifier.

[0034] In this embodiment, during audio playback in an electronic device, the intelligent power amplifier can acquire the speaker's current data (as feedback current data) and voltage data (as feedback voltage data) during operation. This feedback data is then fed back to the relevant processor, enabling feedback control during audio playback. This protects the speaker while improving its performance. Specifically, the intelligent power amplifier adds a current and voltage acquisition module to the output of a traditional power amplifier, such as an IV sensor. This module is connected to the signal line between the intelligent power amplifier and the speaker, allowing for the detection of the speaker's current and voltage.

[0035] In some implementations, the intelligent power amplifier can transmit acquired feedback voltage and current data to the digital signal processor (DSP) via a communication connection. The intelligent power amplifier and DSP can communicate through a digital control interface, a high-speed data interface, etc. The digital control interface may include an Inter-IC Sound (IIS) interface, a Serial Peripheral Interface (SPI) interface, an Inter-Integrated Circuit (IIC) bus, etc.; the high-speed data interface may include a High Definition Multimedia Interface (HDMI) interface, a Low-Voltage Differential Signaling (LVDS) interface, etc. Of course, in the embodiments of this application, the specific communication method between the intelligent power amplifier and the DSP is not limited.

[0036] In some implementations, when the target playback mode is enabled, the electronic device can transmit the speaker's feedback voltage and current data to the digital signal processor via a smart power amplifier during audio playback, i.e., execute step S110 and subsequent steps, to implement the audio playback method provided in this application embodiment. The target playback mode can be a mode used to control the electronic device to perform feedback control based on the speaker's feedback voltage and current data during audio playback. This target playback mode can be enabled or disabled. When the target playback mode is enabled, the electronic device can execute the audio playback method provided in this application embodiment while playing audio; when the target playback mode is disabled, the electronic device can play audio without obtaining the speaker's feedback current and voltage data via the smart power amplifier, thereby reducing the consumption of processing resources in the electronic device.

[0037] In one possible implementation, the electronic device may display a settings interface for the target playback mode, which may include a switch control for controlling the target playback mode; the electronic device may control the target playback mode to be enabled or disabled upon detecting an operation on the switch control, and reduce the power consumption of the electronic device.

[0038] In some implementations, considering that providing feedback on the speaker's current and voltage, and performing corresponding feedback control, would increase processing resource consumption and power consumption, the electronic device can also determine the application playing the audio during playback. It can further determine whether the application playing the audio is any of the applications on a target list. If the application playing the audio is on the target list, it means that the application requires user-defined feedback control based on the speaker's feedback voltage and current data during audio playback. In this case, the electronic device can obtain the speaker's feedback current and voltage data through a smart power amplifier and execute subsequent steps. If the application playing the audio is not on the target list, it means that the application playing the audio is not required by the user to perform feedback control based on the speaker's feedback voltage and current data during audio playback. In this case, obtaining the speaker's feedback current and voltage data through a smart power amplifier can be avoided, thereby reducing the consumption of processing resources in the electronic device and lowering its power consumption.

[0039] In one possible implementation, the target list may be pre-determined by the electronic device based on user input. For example, the electronic device may display a settings interface for the target list, which may include options corresponding to all applications installed on the electronic device; the electronic device adds the application corresponding to the selected target option to the target list based on the detected selection operation of the target option.

[0040] In one possible implementation, a demand score for playback volume and sound quality can be pre-determined for each application. After determining the demand score for each application, applications whose demand scores meet the target score criteria can be added to the target list. The demand score characterizes the required playback volume and sound quality of an application; a higher demand score indicates higher required playback volume and sound quality, and vice versa. The target score criteria can be a demand score greater than a target score, or it can be the demand score ranked among the top N after sorting the target scores of each application. Understandably, higher required playback volume and sound quality mean that feedback control based on speaker feedback current and voltage data can ensure improved playback volume and sound quality. Therefore, applications whose demand scores meet the target score criteria can be added to the target list so that applications in the target list can perform corresponding feedback control based on feedback voltage and current data when playing audio during operation.

[0041] Step S120: The feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor.

[0042] In this embodiment, after the digital signal processor (DSP) obtains the feedback voltage data and feedback current data transmitted by the intelligent power amplifier, since the DSP is a non-open DSP, it can only run the relevant audio algorithms of its platform and cannot execute the relevant algorithms for implementing feedback control based on the feedback voltage data and feedback current data. Therefore, the DSP can transmit the feedback voltage data and feedback current data to the application processor so that the application processor can perform corresponding feedback control based on the feedback voltage data and feedback current data.

[0043] In some implementations, the digital signal processor (DSP) and the application processor can communicate via a System-on-Chip (SoC) internal architecture or external interface connections. The SoC typically integrates the application processor and DSP on the same chip, achieving high-speed data transmission through an internal bus. External interface connections can include high-speed serial interfaces, parallel buses, and dedicated hardware accelerator interfaces. If the application processor and DSP are separate chips, they can be connected via high-speed interfaces such as Peripheral Component Interconnect (PCIe). Parallel buses can include Double Data Rate (DDR) interfaces. Of course, the specific communication method between the DSP and the application processor is not limited.

[0044] Step S130: The application processor controls the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

[0045] In this embodiment, after the application processor obtains the feedback current data and feedback voltage data transmitted by the digital signal processor, the application processor can control the audio parameters of the audio signal to be played based on the obtained feedback voltage data and feedback current data, thereby realizing feedback control when playing audio based on the current and voltage of the speaker when it is working, and thus improving the audio playback effect.

[0046] In some implementations, the application processor can determine the current operating status parameters of the speaker, such as temperature and amplitude, based on the obtained feedback current and feedback voltage data. Then, based on the determined operating status parameters, it can control the audio parameters of the audio signal to be played. This achieves fine management and protection of the speaker by controlling the output audio signal according to the feedback current and voltage, thereby maximizing the loudness and sound quality of the speaker without damaging it.

[0047] The audio playback method provided in this application embodiment can improve the audio playback effect and reduce the implementation cost of feedback control during audio playback, even if the digital signal processor in the electronic device is a non-open digital signal processor or the intelligent power amplifier in the electronic device does not have a digital signal processor.

[0048] Please see Figure 3 , Figure 3A flowchart illustrating another embodiment of the audio playback method provided in this application is shown. This audio playback method is applied to the aforementioned electronic device, which includes an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The following will focus on... Figure 3 The process shown will be described in detail. The audio playback method may specifically include the following steps:

[0049] Step S210: During audio playback, the feedback voltage data and feedback current data of the speaker are transmitted to the digital signal processor via the intelligent power amplifier.

[0050] In this embodiment, step S210 can be referred to the content of other embodiments, and will not be repeated here.

[0051] Step S220: The feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor using a first transmission method, wherein the transmission speed of the first transmission method is higher than the target speed.

[0052] In this embodiment, when the digital signal processor transmits the acquired feedback voltage and feedback current data to the application processor, it can use a first transmission method with a transmission speed higher than the target speed to ensure data transmission efficiency and achieve real-time feedback control based on the speaker's current and voltage. The target speed can be determined based on the transmission speed of traditional data transmission methods between the digital signal processor and the application processor, such as the transmission speed via interrupts or message queues, or the transmission speed via a parallel bus. Understandably, when implementing feedback control based on the speaker's current and voltage, the real-time nature of the feedback control is crucial because the speaker's operating state may change at any time. Therefore, a faster transmission method can be used to achieve data transmission between the digital signal processor and the application processor, thereby enabling real-time feedback of the speaker's current and voltage, and thus allowing for real-time control to ensure optimal audio playback.

[0053] In some implementations, the first transmission method described above can transmit data using shared memory. Specifically, the feedback voltage and current data can be written to a shared memory region between the digital signal processor (DSP) and the application processor, and then the application processor can read the feedback voltage and current data from this shared memory region. Shared memory is a technology that allows different processors or cores to access the same physical memory region. Through shared memory, the DSP can directly write the feedback voltage and current data to the shared memory region, and the application processor can read this data in real time. In the above method, creating a feedback path using shared memory to transmit the speaker's feedback voltage and current data to the application processor avoids the overhead of traditional data transmission methods (such as interrupts or message queues) and improves data transmission efficiency.

[0054] In one possible implementation, a portion of memory can be allocated on the application processor side as the shared memory region. Specifically, a target number of memory pages can be allocated for the speaker's feedback voltage and current data. The target number can be determined based on the amount of feedback voltage and current data acquired each time; that is, the target number of memory pages can store the acquired feedback voltage and current data at least once. A memory page is a management unit in memory management. In memory paging memory management, a process's virtual memory space is divided into several equal-sized slices called pages. Page sizes vary, such as 4KB, 16KB, 64KB, 2MB, and 1GB pages.

[0055] Optionally, considering the need for real-time and continuous feedback of speaker voltage and current data during audio playback, the memory pages corresponding to these feedback voltage and current data should not be swapped out during audio playback. To prevent the electronic device from swapping these memory pages out to other storage areas outside of memory, such as flash memory or hard disks, the page priority of these memory pages can be set to the highest page priority. This prevents them from being swapped out due to their low page priority, thus affecting the real-time performance of data transmission. Memory swapping is a traditional memory management strategy that allows the operating system to "swap out" data from memory to hard drives, compress it to other memory areas, flash memory, or other storage media to free up memory space for other processes. When the "swapped out" data is needed again, the operating system will "swap it back" from the above storage media into memory. However, if the above storage media is a physical hard disk, the access speed limit of the physical hard disk (current mainstream disk read / write speeds are typically in the hundreds of megabytes per second) makes the entire process very time-consuming, during which the user may feel that the system is unusually slow.

[0056] In the above embodiments, the page priority of a memory page can be determined based on at least one of the memory page's access frequency, importance, and modification frequency. The importance of a memory page can be determined based on at least one of the importance of its associated running entity and its memory usage requirements. The running entity can be an application, a system service, a process, etc. For different page priorities, the higher the page priority, the higher the access frequency, importance, and modification frequency of the corresponding memory page.

[0057] In some implementations, the first transmission method described above may also include other transmission methods with a transmission speed higher than the target speed. For example, it may include a serial communication interface for data transmission. The serial communication bus interface is characterized by full-duplex operation, high speed (up to tens of megahertz), support for master-slave mode, and simple hardware connection.

[0058] Step S230: The application processor controls the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

[0059] In this embodiment, step S230 can be found in other embodiments and will not be repeated here.

[0060] The audio playback method provided in this application embodiment, even when the digital signal processor in the electronic device is a non-open digital signal processor, can still achieve feedback control based on the feedback voltage and feedback current data of the speaker through the application processor, even if the intelligent power amplifier in the electronic device does not have a digital signal processor. This can improve the audio playback effect and reduce the implementation cost of feedback control during audio playback. In addition, when the digital signal processor transmits the feedback voltage and feedback current data of the speaker to the application processor, it uses a transmission method with a transmission speed higher than the target speed to ensure data transmission efficiency and achieve real-time feedback control based on the current and voltage of the speaker.

[0061] Please see Figure 4 , Figure 4 A flowchart illustrating another embodiment of the audio playback method provided in this application is shown. This audio playback method is applied to the aforementioned electronic device, which includes an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The following will focus on... Figure 4 The process shown will be described in detail. The audio playback method may specifically include the following steps:

[0062] Step S310: During audio playback, the feedback voltage data and feedback current data of the speaker are transmitted to the digital signal processor via the intelligent power amplifier.

[0063] In this embodiment, step S310 can be referred to the content of other embodiments, and will not be repeated here.

[0064] Step S320: If the electronic device is currently in the target audio playback scenario, the feedback voltage data and feedback current data are transmitted to the application processor through the digital signal processor using the first transmission method. The transmission speed of the first transmission method is higher than the target speed, the required playback volume in the target audio playback scenario is greater than the target volume, and / or the proportion of low-frequency audio signals in the audio signal to be played in the target audio playback scenario is greater than the target proportion.

[0065] In this embodiment, considering that transmitting feedback voltage data and feedback current data between the digital signal processor and the application processor would increase resource consumption and hardware overhead by using a transmission method with a higher transmission speed, the digital signal processor can only transmit the feedback voltage data and feedback current data to the application processor using the first transmission method when the electronic device is currently in the target audio playback scenario.

[0066] In the above-mentioned target audio playback scenario, the required playback volume is greater than the target volume, and / or, the proportion of low-frequency audio signals in the audio signal to be played in the target audio playback scenario is greater than the target proportion. The target volume can be 60 dB, 70 dB, 80 dB, etc., and the specific value is not limited; the frequency range of the low-frequency audio signal can be 20 Hz to 250 Hz; the target proportion can be 20%, 30%, 50%, etc., and the specific value is not limited. Understandably, in audio playback scenarios where a high playback volume is required, if real-time feedback control based on the speaker's current and voltage is not implemented, the required volume may not be achieved at certain times. Therefore, the feedback voltage and current data can be transmitted to the application processor via the first transmission method described above, with a transmission speed greater than the target speed, to achieve real-time feedback control based on the speaker's current and voltage, thereby better meeting the volume requirements of the current audio playback scenario. Furthermore, speakers typically have large amplitudes when playing low-frequency audio signals. If real-time feedback control based on the speaker's current and voltage is not implemented, the diaphragm of the speaker may vibrate excessively at certain times, potentially causing damage. Therefore, in audio playback scenarios where low-frequency audio signals constitute a large proportion, the feedback voltage and current data can be transmitted to the application processor via the first transmission method described above, with a transmission speed greater than the target speed, to achieve real-time feedback control based on the speaker's current and voltage, thereby better protecting the speaker.

[0067] In some implementations, the target playback scenario may include a first playback scenario and a second playback scenario. The first playback scenario involves an audio playback scenario where the required playback volume is greater than the target volume. In the second playback scenario, the proportion of low-frequency audio signals in the audio signal to be played is greater than the target proportion. The first transmission method may include a first data transmission method and a second data transmission method. The transmission speed of the first data transmission method is higher than the transmission speed of the second data transmission method, and both the first and second data transmission methods have transmission speeds higher than the target speed. When the electronic device is in the first playback scenario, the digital signal processor can transmit the feedback voltage data and feedback current data to the application processor via the second data transmission method; when the electronic device is in the second playback scenario, the digital signal processor can transmit the feedback voltage data and feedback current data to the application processor via the first data transmission method.

[0068] For example, in the first playback scenario described above, the feedback voltage and feedback current data can be transmitted to the application processor via shared memory. In the second playback scenario, the data can be transmitted via the SPI interface. Therefore, in audio playback scenarios where low-frequency audio signals are predominant, the feedback voltage and feedback current data can be transmitted at a relatively high speed, thus better protecting the speaker. Furthermore, in audio playback scenarios where the required playback volume is higher than the target volume, the transmission speed remains higher than the target speed, ensuring real-time feedback control and meeting the volume requirements of the audio playback scenario.

[0069] In some implementations, an electronic device can determine the current audio playback scenario based on the application currently playing the audio and the interface displayed in the foreground. For example, application information and screenshots of the foreground interface can be input into a pre-trained scene recognition model to obtain the scene recognition result output by the model, which may include the identified audio playback scenario.

[0070] Step S330: If the electronic device is not currently in the target audio playback scenario, the feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor using the second transmission method, wherein the transmission speed of the second transmission method is lower than or equal to the target speed.

[0071] In this embodiment of the application, when the electronic device is not currently in the above-mentioned target audio playback scenario, the digital signal processor can use the second transmission method to transmit the feedback voltage data and feedback current data to the application processor. The transmission speed of the second transmission method is lower than or equal to the target speed, thereby transmitting at a relatively low transmission speed to reduce resource consumption and hardware overhead.

[0072] Step S340: The application processor controls the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

[0073] In this embodiment, step S340 can be found in other embodiments and will not be repeated here.

[0074] The audio playback method provided in this application embodiment, when the digital signal processor in the electronic device is a non-open digital signal processor, even if the intelligent power amplifier in the electronic device does not have a digital signal processor, can still achieve feedback control based on the feedback voltage and feedback current data of the speaker through the application processor. This can improve the audio playback effect and reduce the implementation cost of feedback control during audio playback. In addition, when the digital signal processor transmits the feedback voltage and feedback current data of the speaker to the application processor, if the electronic device is currently in the target audio playback scenario, it uses a transmission method with a transmission speed higher than the target speed to ensure data transmission efficiency and achieve real-time feedback control based on the current and voltage of the speaker. If the electronic device is not in the target audio playback scenario, it uses a transmission method with a transmission speed lower than or equal to the target speed to reduce resource consumption and hardware overhead.

[0075] Please see Figure 5 , Figure 5 A flowchart illustrating an audio playback method according to another embodiment of this application is shown. This audio playback method is applied to the aforementioned electronic device, which includes an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The following will focus on... Figure 5 The process shown will be described in detail. The audio playback method may specifically include the following steps:

[0076] Step S410: During audio playback, the feedback voltage data and feedback current data of the speaker are transmitted to the digital signal processor via the intelligent power amplifier.

[0077] Step S420: The feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor.

[0078] In the embodiments of this application, steps S410 and S420 can be referred to the contents of other embodiments, and will not be repeated here.

[0079] Step S430: The application processor executes the configured audio playback control algorithm based on the feedback voltage data and feedback current data to control the audio parameters of the audio signal to be played according to the output of the audio playback control algorithm. The audio playback control algorithm takes the feedback voltage data and feedback current data as input, and the audio playback control algorithm cannot be executed by the digital signal processor.

[0080] In this embodiment, when the application processor performs feedback control based on the acquired feedback voltage and feedback current data, it can execute an audio playback control algorithm. This allows the audio parameters of the audio signal to be played to be controlled based on the algorithm's output. This audio playback control algorithm is configured to be executed by the application processor. Since the digital signal processor (DSP) in the electronic device is a non-open-source DSP, it can only execute algorithms specific to its platform. The aforementioned audio playback control algorithm cannot be executed by the DSP. Specifically, the audio playback control algorithm can be a feedback control algorithm used in the electronic device to play audio based on the speaker's feedback voltage and feedback current data. In other words, the application processor inputs the feedback voltage and feedback current data into the audio playback control algorithm and controls the audio parameters of the audio signal to be played based on the algorithm's output.

[0081] In some implementations, when the application processor controls the audio parameters of the audio signal to be played based on the feedback voltage data and the feedback current data, it may control at least one of the following: the gain of the audio signal to be played, the amplitude of the signal waveform of the audio signal to be played, and the dynamic range of the audio signal to be played.

[0082] In one possible implementation, the audio playback control algorithm includes a conversion relationship between feedback voltage data, feedback current data, and speaker status parameters (e.g., temperature, power). Based on this conversion relationship, the real-time status parameters of the speaker can be determined. Furthermore, the audio playback control algorithm can output gain adjustment information for the audio signal to be played based on the determined real-time status parameters. Specifically, when the temperature exceeds a preset threshold, the gain can be reduced to decrease heat generation; conversely, when the temperature does not exceed the preset threshold, or when the power is low, the gain can be increased to improve sound quality or volume, thereby maximizing the speaker's volume and achieving a super-volume effect.

[0083] Alternatively, adaptive algorithms (such as PID control) can be used to smoothly adjust the gain, avoiding sound distortion or system shock caused by sudden changes.

[0084] In one possible implementation, based on the determined real-time status parameters, if the speaker power or temperature exceeds a preset threshold, the audio playback control algorithm can output control information to limit the amplitude of the audio signal to be played. The application processor can then limit the amplitude of the signal waveform to the range corresponding to the rated power based on the control information, preventing the speaker from being damaged due to overload.

[0085] In one possible implementation, if it is determined that the speaker power or temperature does not exceed a preset threshold, the audio playback control algorithm can output adjustment information to adjust the dynamic range of the audio signal. The application processor can adjust the dynamic range of the audio signal to be played to ensure clear and consistent sound quality at different volume levels.

[0086] For example, please refer to Figure 6 , Figure 6 The diagram illustrates the frequency response curves of the audio playback method provided by the embodiments of this application and the frequency response curves without feedback control based on the feedback voltage and current of the speaker. The frequency response curve of the audio playback method provided by the embodiments of this application is curve 1, and the frequency response curve without feedback control based on the feedback voltage and current of the speaker is curve 2. It can be seen that the loudness of curve 1 in the mid-low frequency range is much greater than that of curve 2 in the mid-low frequency range. Therefore, the audio playback method provided by the embodiments of this application can significantly improve the loudness of the audio signal in the mid-low frequency range.

[0087] The audio playback method provided in this application embodiment can improve audio playback performance and reduce the implementation cost of feedback control during audio playback, even when the digital signal processor in the electronic device is a non-open digital signal processor or the intelligent power amplifier in the electronic device does not have a digital signal processor. Furthermore, by running an audio playback control algorithm, the application processor controls the audio parameters of the audio signal to be played, thereby effectively maximizing the performance of the speaker, improving the sound quality of the speaker, and achieving super volume while protecting the speaker.

[0088] Please see Figure 7 , Figure 7 A flowchart illustrating another embodiment of the audio playback method provided in this application is shown. This audio playback method is applied to the aforementioned electronic device, which includes an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The following will focus on... Figure 7 The process shown will be described in detail. The audio playback method may specifically include the following steps:

[0089] Step S510: During audio playback, the feedback voltage signal and feedback current signal of the speaker are obtained through the intelligent power amplifier.

[0090] In this embodiment, when the intelligent power amplifier feeds back the speaker's feedback voltage and feedback current data to the digital signal processor, it can acquire the speaker's feedback voltage and feedback current signals. Specifically, the speaker's feedback voltage and feedback current signals can be acquired through an output current-voltage acquisition module, such as an IV sensor.

[0091] Step S520: The feedback voltage signal and feedback current signal are converted into data of the inter-chip audio interface (IIS) through the intelligent power amplifier to obtain feedback voltage data and feedback current data, and the feedback voltage data and feedback current data are transmitted to the digital signal processor.

[0092] In this embodiment, after the intelligent power amplifier obtains the feedback voltage signal and the feedback current signal, it can convert the feedback voltage signal and the feedback current signal into digital signals through an analog-to-digital converter. Then, the converted digital signals are converted according to the protocol of the Inter-IC Sound (IIS) interface to obtain feedback voltage data and feedback current data, and the feedback voltage data and feedback current data are transmitted to the digital signal processor.

[0093] Step S530: The feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor.

[0094] Step S540: The application processor controls the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

[0095] In the embodiments of this application, steps S530 and S540 can be referred to the content of the foregoing embodiments, and will not be repeated here.

[0096] For example, please refer to Figure 8 After collecting current and voltage data from the speaker, the intelligent power amplifier can transmit this data to the digital signal processor (DSP) via the IIS interface. The DSP then transmits the data to the application processor based on a feedback path created using shared memory. The application processor can then perform feedback control based on the current and voltage data and an audio playback control algorithm. This allows the intelligent power amplifier to achieve feedback control of the speaker's voltage and current even without a dedicated DSP, even if it is not configured with one. This improves the audio playback performance of the electronic device and reduces the cost of implementing feedback control during audio playback.

[0097] The audio playback method provided in this application embodiment can improve the audio playback effect and reduce the implementation cost of feedback control during audio playback, even if the digital signal processor in the electronic device is a non-open digital signal processor or the intelligent power amplifier in the electronic device does not have a digital signal processor.

[0098] Please see Figure 9 This diagram illustrates a structural block diagram of an audio playback device 600 according to an embodiment of this application. The audio playback device 600 utilizes the aforementioned electronic device, which includes an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The audio playback device 600 includes: a first transmission module 610, a second transmission module 620, and a parameter control module 630. The first transmission module 610 transmits feedback voltage data and feedback current data from the speaker to the digital signal processor via the smart power amplifier during audio playback. The second transmission module 620 transmits the feedback voltage data and feedback current data to the application processor via the digital signal processor. The parameter control module 630 controls the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data through the application processor.

[0099] In some implementations, the second transmission module 620 may be specifically used to: transmit the feedback voltage data and feedback current data to the application processor via the digital signal processor and using a first transmission method, wherein the transmission speed of the first transmission method is higher than the target speed.

[0100] In one possible implementation, the second transmission module 620 may be specifically used to: write the feedback voltage data and feedback current data to a shared memory area between the digital signal processor and the application processor via the digital signal processor; and read the feedback voltage data and feedback current data from the shared memory area via the application processor.

[0101] In one possible implementation, the second transmission module 620 may be specifically used to: if the electronic device is currently in a target audio playback scenario, transmit the feedback voltage data and feedback current data to the application processor through the digital signal processor and using the first transmission method, wherein the required playback volume in the target audio playback scenario is greater than the target volume, and / or, the proportion of low-frequency audio signals in the audio signal to be played in the target audio playback scenario is greater than the target proportion.

[0102] Optionally, the second transmission module 620 can also be used to transmit the feedback voltage data and feedback current data to the application processor through the digital signal processor and using a second transmission method if the electronic device is not currently in the target audio playback scenario, wherein the transmission speed of the second transmission method is lower than or equal to the target speed.

[0103] In some implementations, the parameter control module 630 may be specifically used by the application processor to execute a configured audio playback control algorithm based on the feedback voltage data and feedback current data, so as to control the audio parameters of the audio signal to be played according to the output of the audio playback control algorithm. The audio playback control algorithm takes the feedback voltage data and feedback current data as input, and the audio playback control algorithm cannot be executed by the digital signal processor.

[0104] In some implementations, the parameter control module 630 may be specifically used to: control at least one of the gain of the audio signal to be played, the amplitude of the signal waveform of the audio signal to be played, and the dynamic range of the audio signal to be played, based on the feedback voltage data and the feedback current data by the application processor.

[0105] In some implementations, the first transmission module 610 may be specifically used to: acquire the feedback voltage signal and feedback current signal of the speaker through the intelligent power amplifier during audio playback; convert the feedback voltage signal and feedback current signal into data of the inter-chip audio interface (IIS) through the intelligent power amplifier to obtain feedback voltage data and feedback current data, and transmit the feedback voltage data and feedback current data to the digital signal processor.

[0106] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the above-described device and module can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0107] In the several embodiments provided in this application, the coupling between modules can be electrical, mechanical, or other forms of coupling.

[0108] Furthermore, the functional modules in the various embodiments of this application can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The integrated modules described above can be implemented in hardware or as software functional modules.

[0109] In summary, the solution provided in this application targets electronic devices including an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. During audio playback, the smart power amplifier transmits the speaker's feedback voltage and current data to the digital signal processor, which then transmits these data to the application processor. The application processor then controls the audio parameters of the audio signal to be played based on the feedback voltage and current data. Therefore, even when the digital signal processor in the electronic device is a non-open digital signal processor, and the smart power amplifier does not contain a digital signal processor, feedback control based on the speaker's feedback voltage and current data can still be achieved through the application processor. This improves audio playback quality and reduces the implementation cost of feedback control during audio playback.

[0110] Please refer to Figure 10 This document illustrates a structural block diagram of an electronic device according to an embodiment of this application. The electronic device 100 can be a smartphone, tablet computer, smartwatch, e-reader, or other electronic device capable of running applications. The electronic device 100 in this application may include one or more of the following components: a processor 110, a memory 120, and one or more applications, wherein the one or more applications can be stored in the memory 120 and configured to be executed by the one or more processors 110, and the one or more applications are configured to perform the methods described in the foregoing method embodiments.

[0111] Processor 110 may include one or more processing cores. Processor 110 connects to various parts within the electronic device 100 using various interfaces and lines, and performs various functions and processes data of the electronic device 100 by running or executing instructions, programs, code sets, or instruction sets stored in memory 120, and by calling data stored in memory 120. Optionally, processor 110 may be implemented using at least one of the following hardware forms: application processor, digital signal processor, field-programmable gate array (FPGA), and programmable logic array (PLA). Processor 110 may integrate one or more of the following: central processing unit (CPU), graphics processing unit (GPU), and modem. The CPU primarily handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the displayed content; and the modem handles wireless communication. It is understood that the modem may also not be integrated into processor 110 and may be implemented separately using a communication chip.

[0112] The memory 120 may include random access memory (RAM) or read-only memory (ROM). The memory 120 can be used to store instructions, programs, code, code sets, or instruction sets. The memory 120 may include a program storage area and a data storage area. The program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as touch functionality, sound playback functionality, image playback functionality, etc.), and instructions for implementing the various method embodiments described below. The data storage area may also store data created by the electronic device 100 during use (such as phonebook data, audio and video data, chat log data, etc.).

[0113] The intelligent power amplifier 103 is used to acquire the feedback voltage data and feedback current data of the speaker 104, and transmit the feedback voltage data and feedback current data of the speaker 104 to the digital signal processor; the digital signal processor is used to transmit the feedback voltage data and feedback current data to the application processor, and then the application processor controls the audio parameters of the audio signal to be played according to the feedback voltage data and feedback current data.

[0114] Please refer to Figure 11This diagram illustrates a structural block diagram of a computer-readable storage medium provided in an embodiment of this application. The computer-readable medium 800 stores program code that can be called by a processor to execute the methods described in the above method embodiments.

[0115] The computer-readable storage medium 800 may be an electronic memory such as flash memory, EEPROM (Electrically Erasable Programmable Read-Only Memory), EPROM, hard disk, or ROM. Optionally, the computer-readable storage medium 800 includes a non-transitory computer-readable storage medium. The computer-readable storage medium 800 has storage space for program code 810 that performs any of the method steps described above. This program code can be read from or written to one or more computer program products. The program code 810 may be compressed, for example, in a suitable form.

[0116] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application.

Claims

1. An audio playback method, characterized in that, Applied to an electronic device, the electronic device including an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker, the method includes: During audio playback, the smart power amplifier transmits the speaker's feedback voltage data and feedback current data to the digital signal processor. The digital signal processor transmits the feedback voltage data and feedback current data to the application processor. The application processor controls the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

2. The method according to claim 1, characterized in that, The step of transmitting the feedback voltage data and feedback current data to the application processor via the digital signal processor includes: The feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor using a first transmission method, wherein the transmission speed of the first transmission method is higher than the target speed.

3. The method according to claim 2, characterized in that, The step of transmitting the feedback voltage data and feedback current data to the application processor via the digital signal processor and using the first transmission method includes: The feedback voltage data and feedback current data are written to the shared memory area between the digital signal processor and the application processor by the digital signal processor. The application processor reads the feedback voltage data and feedback current data from the shared memory region.

4. The method according to claim 2, characterized in that, The step of transmitting the feedback voltage data and feedback current data to the application processor via the digital signal processor and using the first transmission method includes: If the electronic device is currently in a target audio playback scenario, the feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor using the first transmission method. The required playback volume in the target audio playback scenario is greater than the target volume, and / or the proportion of low-frequency audio signals in the audio signal to be played in the target audio playback scenario is greater than the target proportion.

5. The method according to claim 4, characterized in that, The step of transmitting the feedback voltage data and feedback current data to the application processor via the digital signal processor further includes: If the electronic device is not currently in the target audio playback scenario, the feedback voltage data and feedback current data are transmitted to the application processor via the digital signal processor using a second transmission method, wherein the transmission speed of the second transmission method is lower than or equal to the target speed.

6. The method according to claim 1, characterized in that, The step of controlling the audio parameters of the audio signal to be played by the application processor based on the feedback voltage data and feedback current data includes: The application processor executes a configured audio playback control algorithm based on the feedback voltage data and feedback current data to control the audio parameters of the audio signal to be played according to the output of the audio playback control algorithm. The audio playback control algorithm takes the feedback voltage data and feedback current data as input and cannot be executed by the digital signal processor.

7. The method according to claim 1, characterized in that, The step of controlling the audio parameters of the audio signal to be played by the application processor based on the feedback voltage data and feedback current data includes: The application processor controls at least one of the following based on the feedback voltage data and feedback current data: the gain of the audio signal to be played, the amplitude of the signal waveform of the audio signal to be played, and the dynamic range of the audio signal to be played.

8. The method according to any one of claims 1-7, characterized in that, During audio playback, the process of transmitting the speaker's feedback voltage and feedback current data to the digital signal processor via the intelligent power amplifier includes: During audio playback, the feedback voltage signal and feedback current signal of the speaker are obtained through the intelligent power amplifier; The intelligent power amplifier converts the feedback voltage signal and feedback current signal into data from the inter-chip audio interface (IIS), obtaining feedback voltage data and feedback current data, and then transmits the feedback voltage data and feedback current data to the digital signal processor.

9. An audio playback device, characterized in that, Applied to electronic devices, the electronic devices include an application processor, a non-open digital signal processor, a smart power amplifier, and a speaker. The device includes: a first transmission module, a second transmission module, and a parameter control module, wherein... The first transmission module is used to transmit the feedback voltage data and feedback current data of the speaker to the digital signal processor through the intelligent power amplifier during audio playback. The second transmission module is used to transmit the feedback voltage data and feedback current data to the application processor via the digital signal processor; The parameter control module is used by the application processor to control the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

10. An electronic device, characterized in that, include: Application processor, non-open digital signal processor, intelligent power amplifier, and speaker, among which, The intelligent power amplifier is used to transmit the feedback voltage data and feedback current data of the speaker to the digital signal processor during audio playback. The digital signal processor is used to transmit the feedback voltage data and feedback current data to the application processor; The application processor is used to control the audio parameters of the audio signal to be played based on the feedback voltage data and feedback current data.

11. A computer-readable storage medium, characterized in that, The computer-readable storage medium contains program code that can be invoked by a processor to execute the method as described in any one of claims 1-8.