FMUSER Wirless Transmit Video And Audio More Easier !

[email protected] WhatsApp +8618078869184
Language

    How to use STM32F4 DSP library

     

    The CPU we usually use is a fixed-point CPU, meaning the CPU of the entire point numerical operation. When you encounter a floating point of 1.1 + 1.1, the fixed-point CPU encounters a big problem. For 32-bit single-chip microcomputer, use q-based processing to play his own performance, but accuracy and speed still will not increase much. A new CPU is now designed, called FPU, this chip dedicates the operation of floating point numbers, so that the processor is separated from the number of points and floating point numbers, and the total number of dotted CPUs is handed over, the floating point number is handed over. We have seen Ti's DSP, as well as a Microcontroller with a DSP function. The former is not used, does not comment, and the latter must make some necessary settings if you need to use the FPU floating point calculation function. First, since the floating point operation is carried out in the FPU, the FPU should be enabled first. In system_init (), define __fpu_present and __fpu_used / * FPU SETTINGS ---------------------------------------------------------------------------------------------------------------------------------------- -------------- * / #If (__fpu_present == 1) && (__fpu_used == 1) SCB- "CPACR | = ((3 ul" "10 * 2) | (3 ul" "11 * 2)); / * SET CP10 and CP11 Full Access * / #ENDIF This will enable the FPU. For the above changes, this simple addition and subtraction and division operation FPU appears in the program works. But for complex, such as triangular operations, the opening operation, etc., we need to join the Math.h header file. But if you add him simple, Keil will automatically call the internal Math.h, which is designed for the ARM processor, specifically for the fixed-point CPU and standard algorithm (IEEE-754). There is no effect on STM32F4 using the FPU. Therefore, it is necessary to change Math.h to the ST library, namely arm_math.h. In this header file, it involves another file Core_cmx.h (x = 0, 3, 4), of course, as in the STM32F1 series, add CORE_CM4.H in the project. When it is here, it is all set, the difference is the last step, call! But don't underestimate this step, because if the call is incorrect, the settings in front are white. Do not write as above, because the triangle function is used as Sin (), because the name of their function comes from Math.h, so you call the standard Math.h in the Keil library. To use the ARM_SIN_F32 () function in ARM_Math.h (see line.5780, see DSP_LIB \ Source \ FastMathFunctions), you can see that he uses three spline interpolation methods to quickly evaluate (see line.263 / * cubic Interpolation process * /). Note the exception function, SQRT (), in ARM_Math.H is ARM_SQRT_F32 (). When you use him, you need to open #if (__fpu_used == 1) && defined (__cc_arm), remember! It can also be found that the top function is also divided into Q15 and Q31. I think their difference is the accuracy problem, but they don't have the FPU to calculate. It is to use the 0x5f3759df to quickly and open. If you are very Unfamiliar, view http://en.wikipedia.org/wiki/fast_inverse_square_root. However, his handling may be different. There are also many DSP functions in DSP_LIB \ SOURCE, interested in research. , Reading the full text, the technology area MYBATIS Dynamic SQL Detailed Design the HDB3 encoder in the data transmission system with VHDL language How does the bare metal program drive hardware? What is the seniors say? Typical examples of object-oriented programming SOC principles Introduction to Java Common Development Tools for Embedded Development

     

     

     

     

    List all Question

    Nickname

    Email

    Questions

    Our other product:

    Professional FM Radio Station Equipment Package

     



     

    Hotel IPTV Solution

     


      Enter email  to get a surprise

      fmuser.org

      es.fmuser.org
      it.fmuser.org
      fr.fmuser.org
      de.fmuser.org
      af.fmuser.org ->Afrikaans
      sq.fmuser.org ->Albanian
      ar.fmuser.org ->Arabic
      hy.fmuser.org ->Armenian
      az.fmuser.org ->Azerbaijani
      eu.fmuser.org ->Basque
      be.fmuser.org ->Belarusian
      bg.fmuser.org ->Bulgarian
      ca.fmuser.org ->Catalan
      zh-CN.fmuser.org ->Chinese (Simplified)
      zh-TW.fmuser.org ->Chinese (Traditional)
      hr.fmuser.org ->Croatian
      cs.fmuser.org ->Czech
      da.fmuser.org ->Danish
      nl.fmuser.org ->Dutch
      et.fmuser.org ->Estonian
      tl.fmuser.org ->Filipino
      fi.fmuser.org ->Finnish
      fr.fmuser.org ->French
      gl.fmuser.org ->Galician
      ka.fmuser.org ->Georgian
      de.fmuser.org ->German
      el.fmuser.org ->Greek
      ht.fmuser.org ->Haitian Creole
      iw.fmuser.org ->Hebrew
      hi.fmuser.org ->Hindi
      hu.fmuser.org ->Hungarian
      is.fmuser.org ->Icelandic
      id.fmuser.org ->Indonesian
      ga.fmuser.org ->Irish
      it.fmuser.org ->Italian
      ja.fmuser.org ->Japanese
      ko.fmuser.org ->Korean
      lv.fmuser.org ->Latvian
      lt.fmuser.org ->Lithuanian
      mk.fmuser.org ->Macedonian
      ms.fmuser.org ->Malay
      mt.fmuser.org ->Maltese
      no.fmuser.org ->Norwegian
      fa.fmuser.org ->Persian
      pl.fmuser.org ->Polish
      pt.fmuser.org ->Portuguese
      ro.fmuser.org ->Romanian
      ru.fmuser.org ->Russian
      sr.fmuser.org ->Serbian
      sk.fmuser.org ->Slovak
      sl.fmuser.org ->Slovenian
      es.fmuser.org ->Spanish
      sw.fmuser.org ->Swahili
      sv.fmuser.org ->Swedish
      th.fmuser.org ->Thai
      tr.fmuser.org ->Turkish
      uk.fmuser.org ->Ukrainian
      ur.fmuser.org ->Urdu
      vi.fmuser.org ->Vietnamese
      cy.fmuser.org ->Welsh
      yi.fmuser.org ->Yiddish

       
  •  

    FMUSER Wirless Transmit Video And Audio More Easier !

  • Contact

    Address:
    No.305 Room HuiLan Building No.273 Huanpu Road Guangzhou China 510620

    E-mail:
    [email protected]

    Tel / WhatApps:
    +8618078869184

  • Categories

  • Newsletter

    FIRST OR FULL NAME

    E-mail

  • paypal solution  Western UnionBank OF China
    E-mail:[email protected]   WhatsApp:+8618078869184   Skype:sky198710021 Chat with me
    Copyright 2006-2020 Powered By www.fmuser.org

    Contact Us