⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 global.h

📁 实现快速傅立叶变换算法,provides test framwork for FFT testing
💻 H
📖 第 1 页 / 共 5 页
字号:
                                        // Variables with this attribute can be located in external
                                        // or internal data memory.
    #define MEM                         // Memory attribute to optimize speed and code of pointer access.

    #define HWACC                       // hardware access through external memory (i.e. CAN)

    #define REENTRANT
    #define PUBLIC

    #ifndef NDEBUG
        #include <stdio.h>              // prototype printf() (for TRACE)
        #define TRACE  printf
    #endif

//---------------------------------------------------------------------------
//  definitions for BECK 1x3
//---------------------------------------------------------------------------
#elif defined (__BORLANDC__) && defined (__PARADIGM__)


     #define TARGET_SYSTEM      _NO_OS_
     #define DEV_SYSTEM         _DEV_PAR_BECK1X3_



     #define ROM                     // code or variables mapped to ROM (i.e. flash)
                                     // usage: CONST BYTE ROM foo = 0x00;
     #define HWACC                   // hardware access through external memory (i.e. CAN)

     // These types can be adjusted by users to match application requirements. The goal is to
     // minimize code memory and maximize speed.
     #define GENERIC                 // generic pointer to point to application data
                                     // Variables with this attribute can be located in external
                                     // or internal data memory.
     #define MEM                     // Memory attribute to optimize speed and code of pointer access.
     #define NEAR __near             // variables mapped to internal data storage location
     #define FAR  __far              // variables mapped to external data storage location
     #define CONST const             // variables mapped to ROM (i.e. flash)
     #define LARGE

     #define REENTRANT
     #define PUBLIC

     #ifndef NDEBUG
         #ifndef TRACE
             #include <stdio.h>
             #define TRACE printf
         #endif
     #endif



//---------------------------------------------------------------------------
//  definitions for PC
//---------------------------------------------------------------------------

#elif defined (__BORLANDC__)

    // ------------------ definition target system --------------------------

    #ifdef _WIN32
        #define TARGET_SYSTEM   _WIN32_     // WIN32 definition
        #define DEV_SYSTEM      _DEV_WIN32_
    #else
        #define TARGET_SYSTEM   _DOS_
        #define DEV_SYSTEM      _DEV_BORLAND_DOS_
    #endif


    // ------------------ WIN32 ---------------------------------------------

    #if (TARGET_SYSTEM == _WIN32_)

        #define ROM                     // code or variables mapped to ROM (i.e. flash)
                                        // usage: CONST BYTE ROM foo = 0x00;
        #define HWACC                   // hardware access through external memory (i.e. CAN)

        // These types can be adjusted by users to match application requirements. The goal is to
        // minimize code memory and maximize speed.
        #define GENERIC                 // generic pointer to point to application data
                                        // Variables with this attribute can be located in external
                                        // or internal data memory.
        #define MEM                     // Memory attribute to optimize speed and code of pointer access.

        #ifndef NEAR
            #define NEAR                // variables mapped to internal data storage location
        #endif

        #ifndef FAR
            #define FAR                 // variables mapped to external data storage location
        #endif

        #ifndef CONST
            #define CONST const         // variables mapped to ROM (i.e. flash)
        #endif

        #define LARGE

        #define REENTRANT
        #define PUBLIC __stdcall

        #ifndef NDEBUG
            #ifndef TRACE
                    #include <stdio.h>
            #define TRACE printf
            #endif
        #endif

    #elif (TARGET_SYSTEM == _DOS_)

        #define ROM                     // code or variables mapped to ROM (i.e. flash)
                                        // usage: CONST BYTE ROM foo = 0x00;
        #define HWACC                   // hardware access through external memory (i.e. CAN)

        // These types can be adjusted by users to match application requirements. The goal is to
        // minimize code memory and maximize speed.
        #define GENERIC                 // generic pointer to point to application data
                                        // Variables with this attribute can be located in external
                                        // or internal data memory.
        #define MEM                     // Memory attribute to optimize speed and code of pointer access.
        #define NEAR near               // variables mapped to internal data storage location
        #define FAR  far                // variables mapped to external data storage location
        #define CONST const             // variables mapped to ROM (i.e. flash)
        #define LARGE

        #define REENTRANT
        #define PUBLIC

        #ifndef NDEBUG
            #ifndef TRACE
                #include <stdio.h>
                #define TRACE printf
            #endif
        #endif

    #endif

#elif (_MSC_VER == 800) // PC MS Visual C/C++ for DOS applications

    #define TARGET_SYSTEM   _DOS_
    #define DEV_SYSTEM      _DEV_MSVC_DOS_

    #define ROM                     // code or variables mapped to ROM (i.e. flash)
                                    // usage: CONST BYTE ROM foo = 0x00;
    #define HWACC near              // hardware access through external memory (i.e. CAN)

    // These types can be adjusted by users to match application requirements. The goal is to
    // minimize code memory and maximize speed.
    #define GENERIC                 // generic pointer to point to application data
                                    // Variables with this attribute can be located in external
                                    // or internal data memory.
    #define MEM                     // Memory attribute to optimize speed and code of pointer access.
    #define NEAR near               // variables mapped to internal data storage location
    #define FAR  far                // variables mapped to external data storage location
    #define CONST const             // variables mapped to ROM (i.e. flash)
    #define LARGE

    #define REENTRANT
    #define PUBLIC

    #ifndef NDEBUG
        #ifndef TRACE
            #include <stdio.h>
            #define TRACE printf
        #endif
    #endif


//---------------------------------------------------------------------------
// definitions for RTX under WIN32
//---------------------------------------------------------------------------
#elif (defined (UNDER_RTSS) && defined (WIN32))

    // ------------------ definition target system --------------------------
    #define TARGET_SYSTEM   _WIN32_RTX_
    #define DEV_SYSTEM      _DEV_WIN32_RTX_

    #define ROM                     // code or variables mapped to ROM (i.e. flash)
                                    // usage: CONST BYTE ROM foo = 0x00;
    #define HWACC                   // hardware access through external memory (i.e. CAN)

    // These types can be adjusted by users to match application requirements. The goal is to
    // minimize code memory and maximize speed.
    #define GENERIC                 // generic pointer to point to application data
                                    // Variables with this attribute can be located in external
                                    // or internal data memory.
    #define MEM                     // Memory attribute to optimize speed and code of pointer access.

    #ifndef NEAR
        #define NEAR                // variables mapped to internal data storage location
    #endif

    #ifndef FAR
        #define FAR                 // variables mapped to external data storage location
    #endif

    #ifndef CONST
        #define CONST const         // variables mapped to ROM (i.e. flash)
    #endif

    #define LARGE

    #define REENTRANT
    #define PUBLIC __stdcall

    #ifndef NDEBUG
        #ifndef TRACE
            #define TRACE RtPrintf
        #endif
    #endif

//---------------------------------------------------------------------------
// definitions for WinCE
//---------------------------------------------------------------------------
#elif defined (_WIN32_WCE)

    // ------------------ definition target system --------------------------
    #define TARGET_SYSTEM           _WINCE_
    #define DEV_SYSTEM              _DEV_WIN_CE_

    #define ROM                     // code or variables mapped to ROM (i.e. flash)
                                    // usage: CONST BYTE ROM foo = 0x00;
    #define HWACC                   // hardware access through external memory (i.e. CAN)

    // These types can be adjusted by users to match application requirements. The goal is to
    // minimize code memory and maximize speed.
    #define GENERIC                 // generic pointer to point to application data
                                    // Variables with this attribute can be located in external
                                    // or internal data memory.
    #define MEM                     // Memory attribute to optimize speed and code of pointer access.

    #ifndef NEAR
        #define NEAR                // variables mapped to internal data storage location
    #endif

    #ifndef FAR
        #define FAR                 // variables mapped to external data storage location
    #endif

    #ifndef CONST
        #define CONST const         // variables mapped to ROM (i.e. flash)
    #endif

    #define LARGE

    #ifndef QWORD
      //#define QWORD long long int // MSVC .NET can use "long long int" too (like GNU)
        #define QWORD __int64
    #endif

    #define REENTRANT
    #define PUBLIC __cdecl

    #ifdef ASSERTMSG
        #undef ASSERTMSG
    #endif

    #ifndef NDEBUG
        #ifndef TRACE
            #define TRACE printf
//            void trace (char *fmt, ...);
        #endif
    #endif

#else   // ===> PC MS Visual C/C++

    // ------------------ definition target system --------------------------

    #ifdef _WIN32
        #define TARGET_SYSTEM   _WIN32_     // WIN32 definition
        #define DEV_SYSTEM      _DEV_WIN32_
    #else
        #define TARGET_SYSTEM   _WIN16_     // WIN16 definition
        #define DEV_SYSTEM      _DEV_WIN16_
    #endif


    // ------------------ WIN16 ---------------------------------------------

    #if (TARGET_SYSTEM == _WIN16_)

        #define ROM                     // code or variables mapped to ROM (i.e. flash)
                                        // usage: CONST BYTE ROM foo = 0x00;
        #define HWACC                   // hardware access through external memory (i.e. CAN)

        // These types can be adjusted by users to match application requirements. The goal is to
        // minimize code memory and maximize speed.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -