Introducing the nonlinear operation library function method[Copy link]
Calling the library functions of the DSP compilation system The C compiler of TMS320C2X/C5X provides a relatively rich runtime support library function. These library functions include commonly used nonlinear functions such as logarithms, square roots, trigonometric functions, exponentials, etc. In the C program (or in the assembler), as long as the same variable definition as the library function is used, it can be called directly. For example, in the library function, the common logarithm log10() with base 10 is defined: #include<math.h> double, log10(double x); Copy code Call it as follows in the C program: float x, y; X=10.0; y=log10(x); Copy code From the above example, it can be seen that the common logarithm log10() in the library function requires the input value to be a floating point number, and the return value is also a floating point number, so the accuracy of the operation can be fully guaranteed. It is very convenient to call the library function directly, but due to the large amount of calculation, it is difficult to be applied in real-time DSP.