Method and system for changing terminal digital power amplifier driving parameters and electronic equipment

文档序号:189991 发布日期:2021-11-02 浏览:36次 中文

阅读说明:本技术 一种变更终端数字功放驱动参数的方法及系统、电子设备 (Method and system for changing terminal digital power amplifier driving parameters and electronic equipment ) 是由 许基业 于 2021-09-26 设计创作,主要内容包括:本发明公开了一种变更终端数字功放驱动参数的方法及系统、电子设备,所述方法包括:在终端上配置用于连接可移动存储设备的接口,终端通过所述接口与可移动存储设备连接,通过设定算法读取所述可移动存储设备的文件;所述可移动存储设备包含设定格式的文件;设定格式的文件包含第一数字功放驱动参数信息;加载所述设定格式的文件,调用所述设定格式的文件中的第一数字功放驱动参数信息;用第一数字功放驱动参数替换所述数字功放芯片的第二数字功放驱动参数。本发明只需要更改设定格式文件中的第一数字功放驱动参数,就可以快速更新终端系统的数字功放驱动参数,提高了工程师调试数字功放的效率,降低了调试的工作量。(The invention discloses a method and a system for changing terminal digital power amplifier driving parameters and electronic equipment, wherein the method comprises the following steps: configuring an interface for connecting a movable storage device on a terminal, connecting the terminal with the movable storage device through the interface, and reading a file of the movable storage device through a set algorithm; the removable storage device contains files in a set format; the file with the set format comprises first digital power amplifier driving parameter information; loading the file with the set format, and calling first digital power amplifier driving parameter information in the file with the set format; and replacing the second digital power amplifier driving parameter of the digital power amplifier chip by the first digital power amplifier driving parameter. According to the invention, the digital power amplifier driving parameters of the terminal system can be rapidly updated only by changing the first digital power amplifier driving parameters in the set format file, so that the efficiency of an engineer debugging the digital power amplifier is improved, and the debugging workload is reduced.)

1. A method for changing terminal digital power amplifier driving parameters is characterized by comprising the following steps:

configuring an interface for connecting a movable storage device on a terminal, wherein the terminal is provided with a digital power amplifier chip;

the terminal is connected with the movable storage device through the interface and reads the file of the movable storage device through a set algorithm; the removable storage device contains files in a set format; the file with the set format comprises first digital power amplifier driving parameter information;

loading the file with the set format, and calling first digital power amplifier driving parameter information in the file with the set format;

and acquiring a second digital power amplifier driving parameter of the digital power amplifier chip, and replacing the second digital power amplifier driving parameter of the digital power amplifier chip by the first digital power amplifier driving parameter.

2. The method for changing the driving parameters of the digital power amplifier of the terminal according to claim 1, wherein the file with the set format comprises the name of a manufacturer of the digital power amplifier and the information of the model of the digital power amplifier; the file with the set format is a file with a bin format.

3. The method for changing the driving parameters of the digital power amplifier of the terminal according to claim 1, wherein the obtaining the second driving parameters of the digital power amplifier chip comprises:

the terminal obtains the chip model of the digital power amplifier chip in a mode of reading the equipment address of the digital power amplifier chip through an I2C bus;

and matching a driving parameter of the chip model according to the obtained chip model, and using the driving parameter as a second digital power amplifier driving parameter of the digital power amplifier chip.

4. The method for changing the driving parameters of the digital power amplifier of the terminal according to claim 3, wherein the matching of the driving parameters of the chip type includes:

determining the chip type of the digital power amplifier chip according to the chip type of the digital power amplifier chip;

and extracting power amplifier driving parameters associated with the type of the digital power amplifier chip from prestored power amplifier driving parameters.

5. The method for changing the driving parameters of the digital power amplifier of the terminal according to claim 1, wherein the step of replacing the driving parameters of the second digital power amplifier of the digital power amplifier chip with the driving parameters of the first digital power amplifier comprises:

after the terminal is powered on, judging whether the terminal receives a parameter switching instruction;

and initializing the digital power amplifier chip according to the first digital power amplifier driving parameter and completing the configuration of the digital power amplifier chip when a parameter switching instruction is received.

6. The method of claim 1, wherein the digital power amplifier driving parameters comprise one or more of audio system channel, main clock frequency, sampling frequency, power amplification gain, input/output mode, audio processing mode, limiter threshold, filter, and equalizer.

7. The method for changing the driving parameters of the digital power amplifier of the terminal according to claim 1, wherein the reading the file of the removable storage device by the setting algorithm comprises:

detecting parameters of the movable storage equipment, and customizing the file name of the movable storage equipment to be detected;

calling a file detection function of a system to detect a file corresponding to the self-defined file name;

reading the file content corresponding to the self-defined file name;

if the first digital power amplifier driving parameter fails to replace the second digital power amplifier driving parameter of the digital power amplifier chip, whether the file of the movable storage device corresponds to the self-defined file name or not is continuously detected, and if yes, the file content corresponding to the self-defined file name is read.

8. A system for changing digital power amplifier driving parameters is characterized by comprising:

the terminal comprises a configuration unit, a storage unit and a control unit, wherein the configuration unit is used for configuring an interface for connecting a movable storage device on the terminal, and the terminal is provided with a digital power amplifier chip;

the reading unit is used for connecting the terminal with the movable storage equipment through the interface and reading the file of the movable storage equipment through a set algorithm; the removable storage device contains files in a set format; the file with the set format comprises first digital power amplifier driving parameter information;

the loading unit is used for loading the file with the set format and calling the first digital power amplifier driving parameter information in the file with the set format;

and the replacing unit is used for acquiring the second digital power amplifier driving parameter of the digital power amplifier chip and replacing the second digital power amplifier driving parameter of the digital power amplifier chip by adopting the first digital power amplifier driving parameter.

9. An electronic device, comprising: at least one processor, and a memory communicatively coupled to the at least one processor, wherein the memory stores instructions executable by the at least one processor, the instructions being executable by the at least one processor to enable the at least one processor to perform the method of changing a driving parameter of a digital power amplifier according to any one of claims 1 to 7.

10. A computer storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method for changing a digital power amplifier driving parameter of a terminal according to any one of claims 1 to 7.

Technical Field

The invention relates to the technical field of digital power amplifiers, in particular to a method and a system for changing terminal digital power amplifier driving parameters and electronic equipment.

Background

The digital power amplifier is an amplifier with the characteristics of small distortion, low noise, large dynamic range and the like, and is incomparable with the traditional power amplifier in terms of the cold and warm degree of tone quality, the analytic power, the tranquility of background and the shocking force of low frequency.

The current terminal (such as a television and an all-in-one machine) generally adopts a digital power amplifier for better sound effect, and the digital power amplifier needs to be loaded and driven. When an engineer debugs a digital power amplifier, the android system is often required to be recompiled, and the specific method is as follows: the digital power amplifier driving parameters are required to be changed according to the selected digital power amplifier chip every time, and then the parameters are solidified into a software version, and the software of one version corresponds to the driving of one IC chip module.

Disclosure of Invention

In view of the above technical problems, an object of the present invention is to provide a method, a system, and an electronic device for changing a driving parameter of a digital power amplifier of a terminal, which solve the problems of low efficiency and large debugging workload of the conventional method for debugging a digital power amplifier.

The invention adopts the following technical scheme:

a method for changing terminal digital power amplifier driving parameters comprises the following steps:

configuring an interface for connecting a movable storage device on a terminal, wherein the terminal is provided with a digital power amplifier chip;

the terminal is connected with the movable storage device through the interface and reads the file of the movable storage device through a set algorithm; the removable storage device contains files in a set format; the file with the set format comprises first digital power amplifier driving parameter information;

loading the file with the set format, and calling first digital power amplifier driving parameter information in the file with the set format;

and acquiring a second digital power amplifier driving parameter of the digital power amplifier chip, and replacing the second digital power amplifier driving parameter of the digital power amplifier chip by the first digital power amplifier driving parameter.

Optionally, the file with the set format includes a name of a manufacturer of the digital power amplifier and information of a model of the digital power amplifier; the file with the set format is a file with a bin format.

Optionally, the obtaining of the second digital power amplifier driving parameter of the digital power amplifier chip includes:

the terminal obtains the chip model of the digital power amplifier chip in a mode of reading the equipment address of the digital power amplifier chip through an I2C bus;

and matching a driving parameter of the chip model according to the obtained chip model, and using the driving parameter as a second digital power amplifier driving parameter of the digital power amplifier chip.

Optionally, the matching of the driving parameters of the chip model includes:

determining the chip type of the digital power amplifier chip according to the chip type of the digital power amplifier chip;

and extracting power amplifier driving parameters associated with the type of the digital power amplifier chip from prestored power amplifier driving parameters.

Optionally, the step of replacing the second digital power amplifier driving parameter of the digital power amplifier chip with the first digital power amplifier driving parameter includes:

after the terminal is powered on, judging whether the terminal receives a parameter switching instruction;

and initializing the digital power amplifier chip according to the first digital power amplifier driving parameter and completing the configuration of the digital power amplifier chip when a parameter switching instruction is received.

Optionally, the digital power amplifier driving parameter includes one or more information of a sound system channel, a main clock frequency, a sampling frequency, a power amplification gain, an input/output mode, a sound effect processing mode, a limiter threshold, a filter, and an equalizer.

Optionally, the reading the file of the removable storage device by setting an algorithm includes: detecting parameters of the movable storage equipment, and customizing the file name of the movable storage equipment to be detected;

calling a file detection function of a system to detect a file corresponding to the self-defined file name;

reading the file content corresponding to the self-defined file name;

if the first digital power amplifier driving parameter fails to replace the second digital power amplifier driving parameter of the digital power amplifier chip, whether the file of the movable storage device corresponds to the self-defined file name or not is continuously detected, and if yes, the file content corresponding to the self-defined file name is read.

A system for changing a driving parameter of a digital power amplifier comprises:

the terminal comprises a configuration unit, a storage unit and a control unit, wherein the configuration unit is used for configuring an interface for connecting a movable storage device on the terminal, and the terminal is provided with a digital power amplifier chip;

the reading unit is used for connecting the terminal with the movable storage equipment through the interface and reading the file of the movable storage equipment through a set algorithm; the removable storage device contains files in a set format; the file with the set format comprises first digital power amplifier driving parameter information;

the loading unit is used for loading the file with the set format and calling the first digital power amplifier driving parameter information in the file with the set format;

and the replacing unit is used for acquiring the second digital power amplifier driving parameter of the digital power amplifier chip and replacing the second digital power amplifier driving parameter of the digital power amplifier chip by adopting the first digital power amplifier driving parameter.

An electronic device, comprising: the device comprises at least one processor and a memory which is in communication connection with the at least one processor, wherein the memory stores instructions which can be executed by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute the method for changing the terminal digital power amplifier driving parameter.

A computer storage medium having stored thereon a computer program which, when executed by a processor, implements the method of altering a digital power amplifier driver parameter of a terminal.

Compared with the prior art, the invention has the beneficial effects that:

the file with the set format of the movable storage device is read through the set algorithm, the file with the set format comprises the first digital power amplifier driving parameter information, the first digital power amplifier driving parameter information is adopted to replace the second digital power amplifier driving parameter of the digital power amplifier chip, the digital power amplifier driving parameter of the terminal system can be quickly updated only by changing the first digital power amplifier driving parameter in the file with the set format, the efficiency of an engineer for debugging the digital power amplifier is improved, and the debugging workload is reduced.

Drawings

Fig. 1 is a schematic flow chart of a method for changing a terminal digital power amplifier driving parameter according to an embodiment of the present invention;

fig. 2 is a schematic structural diagram of a system for changing a terminal digital power amplifier driving parameter according to an embodiment of the present invention;

fig. 3 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.

Detailed Description

The present invention will be further described with reference to the accompanying drawings and specific embodiments, and it should be noted that, in the premise of no conflict, the following described embodiments or technical features may be arbitrarily combined to form a new embodiment:

the first embodiment is as follows:

referring to fig. 1-3, fig. 1 shows a method for changing a terminal digital power amplifier driving parameter according to the present invention, which includes the following steps:

step S1, configuring an interface for connecting a movable storage device on a terminal, wherein the terminal is provided with a digital power amplifier chip;

in this embodiment, the terminal may be a television or an all-in-one machine, the television or the all-in-one machine includes a CPU, a digital power amplifier chip is disposed on a core board of the television or the all-in-one machine, and the CPU communicates with the digital power amplifier chip through a communication module.

In this embodiment, the interface configured on the terminal for connecting the removable storage device may be an interface of the terminal itself, or may be an interface for additionally performing a newly added power amplifier parameter change function.

The power amplifier parameter changing function is specifically set as follows:

calling a function for reading the file content of the USB flash disk;

if the content of the U disk file is successfully read, updating the content of the target power amplifier file into the content of the U disk file;

if the USB flash disk file content fails, whether the specified USB flash disk file content is updated or not is continuously detected, if the specified USB flash disk file content is updated, a function for reading the USB flash disk file content is called, the USB flash disk file content is read, and the target power amplifier file content is updated to be the USB flash disk file content.

In specific implementation, the power amplifier parameter modification function interface execution instruction is as follows:

calling a function for reading the file content of the USB flash disk;

if (U disk file content reading success)

{

Updating the content of the target power amplifier file into the content of a U disk file;

}

else (failure)

{

Continuously detecting whether the content of the specified file of the USB flash disk is updated;

}

}

the removable storage device may be any one of a PD optical drive, mo (magneto optical), removable hard disk, large capacity floppy drive, FlashRAM, tape drive, CDR/CDRW, usb flash drive, and card reader.

As a specific application embodiment, the removable storage device adopts a USB flash disk. In the following specific application example, a U disk is used to replace the removable storage device.

Step S2, the terminal is connected with the mobile storage device through the interface and reads the file of the mobile storage device through a set algorithm; the removable storage device contains files in a set format; the file with the set format comprises first digital power amplifier driving parameter information;

optionally, the file with the set format includes a name of a manufacturer of the digital power amplifier and information of a model of the digital power amplifier; the file with the set format is a file with a bin format.

The setting format can be customized by a user according to the hardware configuration performance. Specifically, the name of the file with the set format can comprise the name of a manufacturer of the digital power amplifier and the model information of the digital power amplifier, so that the replaced digital power amplifier driving parameters can be clearly and intuitively known.

Optionally, the digital power amplifier driving parameter includes one or more information of a sound system channel, a main clock frequency, a sampling frequency, a power amplification gain, an input/output mode, a sound effect processing mode, a limiter threshold, a filter, and an equalizer.

Step S3, loading the file with the set format and calling the first digital power amplifier driving parameter information in the file with the set format;

in a specific application, a customized USB flash disk file is read through a set algorithm.

After the system is started, the system detects the USB flash disk file through a set algorithm, and when the USB flash disk file is detected, the file with the set format in the USB flash disk is loaded. If the loading fails, the system continues to detect the file with the specified file format until the file with the specified file format is loaded successfully, then a newly-added power amplifier parameter changing function is called to read the first digital power amplifier driving parameter information in the file with the specified format, and the system updates and stores the power amplifier driving parameters.

And step S4, acquiring a second digital power amplifier driving parameter of the digital power amplifier chip, and replacing the second digital power amplifier driving parameter of the digital power amplifier chip with the first digital power amplifier driving parameter.

Optionally, the obtaining of the second digital power amplifier driving parameter of the digital power amplifier chip includes:

s41, the terminal obtains the chip model of the digital power amplifier chip by reading the equipment address of the digital power amplifier chip through the I2C bus;

and step S42, matching the driving parameters of the chip type according to the obtained chip type, and using the driving parameters as the second digital power amplifier driving parameters of the digital power amplifier chip.

Optionally, the matching of the driving parameters of the chip model includes:

determining the chip type of the digital power amplifier chip according to the chip type of the digital power amplifier chip;

and extracting power amplifier driving parameters associated with the type of the digital power amplifier chip from prestored power amplifier driving parameters.

Optionally, the step of replacing the second digital power amplifier driving parameter of the digital power amplifier chip with the first digital power amplifier driving parameter includes:

after the terminal is powered on, judging whether the terminal receives a parameter switching instruction;

and initializing the digital power amplifier chip according to the first digital power amplifier driving parameter and completing the configuration of the digital power amplifier chip when a parameter switching instruction is received. The first digital power amplifier driving parameter is adopted to replace the second digital power amplifier driving parameter of the digital power amplifier chip, so that the television and the all-in-one machine system can achieve the purpose of rapidly updating the digital power amplifier driving parameter by reading a file with a specified format.

Optionally, the reading the file of the removable storage device by setting an algorithm includes:

detecting parameters of the movable storage equipment, and customizing the file name of the movable storage equipment to be detected;

calling a file detection function of a system to detect a file corresponding to the self-defined file name;

reading the file content corresponding to the self-defined file name;

if the first digital power amplifier driving parameter fails to replace the second digital power amplifier driving parameter of the digital power amplifier chip, whether the file of the movable storage device corresponds to the self-defined file name or not is continuously detected, and if yes, the file content corresponding to the self-defined file name is read.

In the implementation process, the terminal reads the file with the set format of the movable storage device through the set algorithm, the file with the set format contains the first digital power amplifier driving parameter information, the first digital power amplifier driving parameter information is adopted to replace the second digital power amplifier driving parameter of the digital power amplifier chip, the digital power amplifier driving parameter of the terminal system can be rapidly updated only by changing the first digital power amplifier driving parameter in the file with the set format, the efficiency of debugging the digital power amplifier by an engineer is improved, and the debugging workload is reduced.

Example two:

referring to fig. 2, fig. 2 shows a system for changing a driving parameter of a digital power amplifier according to the present invention, which includes:

the terminal comprises a configuration unit 10, a storage unit and a control unit, wherein the configuration unit is used for configuring an interface for connecting a movable storage device on the terminal, and the terminal is provided with a digital power amplifier chip;

a reading unit 20, configured to connect the terminal with a removable storage device through the interface, and read a file of the removable storage device through a set algorithm; the removable storage device contains files in a set format; the file with the set format comprises first digital power amplifier driving parameter information;

the loading unit 30 is configured to load the file with the set format and call first digital power amplifier driving parameter information in the file with the set format;

and the replacing unit 40 is configured to obtain a second digital power amplifier driving parameter of the digital power amplifier chip, and replace the second digital power amplifier driving parameter of the digital power amplifier chip with the first digital power amplifier driving parameter.

Example three:

fig. 3 is a schematic structural diagram of an electronic device according to an embodiment of the present application, and in the present application, an electronic device 100 for implementing a method for changing a terminal digital power amplifier driving parameter according to the present invention according to the embodiment of the present application may be described by using the schematic diagram shown in fig. 3.

As shown in fig. 3, an electronic device 100 includes one or more processors 102, one or more memory devices 104, and the like, which are interconnected via a bus system and/or other type of connection mechanism (not shown). It should be noted that the components and structure of the electronic device 100 shown in fig. 3 are only exemplary and not limiting, and the electronic device may have some of the components shown in fig. 3 and may have other components and structures not shown in fig. 3 as needed.

The processor 102 may be a Central Processing Unit (CPU) or other form of processing unit having data processing capabilities and/or instruction execution capabilities, and may control other components in the electronic device 100 to perform desired functions.

The storage 104 may include one or more computer program products that may include various forms of computer-readable storage media, such as volatile memory and/or non-volatile memory. The volatile memory may include, for example, Random Access Memory (RAM), cache memory (cache), and/or the like. The non-volatile memory may include, for example, Read Only Memory (ROM), hard disk, flash memory, etc. On which one or more computer program instructions may be stored that may be executed by processor 102 to implement the functions of the embodiments of the application (as implemented by the processor) described below and/or other desired functions. Various applications and various data, such as various data used and/or generated by the applications, may also be stored in the computer-readable storage medium.

The invention also provides a computer storage medium on which a computer program is stored, in which the method of the invention, if implemented in the form of software functional units and sold or used as a stand-alone product, can be stored. Based on such understanding, all or part of the flow of the method according to the embodiments of the present invention may also be implemented by a computer program, which may be stored in a computer storage medium and used by a processor to implement the steps of the embodiments of the method. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer storage medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer storage media may include content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer storage media that does not include electrical carrier signals and telecommunications signals as subject to legislation and patent practice.

Various other modifications and changes may be made by those skilled in the art based on the above-described technical solutions and concepts, and all such modifications and changes should fall within the scope of the claims of the present invention.

11页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:芯片启动控制方法、芯片及电子设备

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!