📄 c6x.h
字号:
long long _saddsub (int, int);long long _saddsub2 (unsigned, unsigned);long long _shfl3 (unsigned, unsigned);int _smpy32 (int, int);int _ssub2 (int, int);unsigned _xormpy (unsigned, unsigned);#endifextern __cregister volatile unsigned int AMR;extern __cregister volatile unsigned int CSR;extern __cregister volatile unsigned int IFR;extern __cregister volatile unsigned int ISR;extern __cregister volatile unsigned int ICR;extern __cregister volatile unsigned int IER;extern __cregister volatile unsigned int ISTP;extern __cregister volatile unsigned int IRP;extern __cregister volatile unsigned int NRP;#ifdef _TMS320C6400extern __cregister volatile unsigned int GFPGFR;extern __cregister volatile unsigned int DIER;#endif#ifdef _TMS320C6700extern __cregister volatile unsigned int FADCR;extern __cregister volatile unsigned int FAUCR;extern __cregister volatile unsigned int FMCR;#endif#ifdef _TMS320C6700_PLUSextern __cregister volatile unsigned int DESR;extern __cregister volatile unsigned int DETR;#endif#ifdef _TMS320C6400_PLUSextern __cregister volatile unsigned int REP;extern __cregister volatile unsigned int TSCL;extern __cregister volatile unsigned int TSCH;extern __cregister volatile unsigned int ARP;extern __cregister volatile unsigned int ILC;extern __cregister volatile unsigned int RILC;extern __cregister volatile unsigned int PCE1;extern __cregister volatile unsigned int DNUM;extern __cregister volatile unsigned int SSR;extern __cregister volatile unsigned int GPLYA;extern __cregister volatile unsigned int GPLYB;extern __cregister volatile unsigned int TSR;extern __cregister volatile unsigned int ITSR;extern __cregister volatile unsigned int NTSR;extern __cregister volatile unsigned int ECR;extern __cregister volatile unsigned int EFR;extern __cregister volatile unsigned int IERR;extern __cregister volatile unsigned int DMSG;extern __cregister volatile unsigned int CMSG;extern __cregister volatile unsigned int DT_DMA_ADDR;extern __cregister volatile unsigned int DT_DMA_DATA;extern __cregister volatile unsigned int DT_DMA_CNTL;extern __cregister volatile unsigned int TCU_CNTL;extern __cregister volatile unsigned int RTDX_REC_CNTL;extern __cregister volatile unsigned int RTDX_XMT_CNTL;extern __cregister volatile unsigned int RTDX_CFG;extern __cregister volatile unsigned int RTDX_RDATA;extern __cregister volatile unsigned int RTDX_WDATA;extern __cregister volatile unsigned int RTDX_RADDR;extern __cregister volatile unsigned int RTDX_WADDR;extern __cregister volatile unsigned int MFREG0;extern __cregister volatile unsigned int DBG_STAT;extern __cregister volatile unsigned int BRK_EN;extern __cregister volatile unsigned int HWBP0_CNT;extern __cregister volatile unsigned int HWBP0;extern __cregister volatile unsigned int HWBP1;extern __cregister volatile unsigned int HWBP2;extern __cregister volatile unsigned int HWBP3;extern __cregister volatile unsigned int OVERLAY;extern __cregister volatile unsigned int PC_PROF;extern __cregister volatile unsigned int ATSR;extern __cregister volatile unsigned int TRR;extern __cregister volatile unsigned int TCRR;#endif#ifdef __cplusplus} /* extern "C" */#endif /* __cplusplus *//*****************************************************************************//* DATA_IS_ALIGNED_2, DATA_IS_ALIGNED_4, DATA_IS_ALIGNED_8 - *//* Tell the compiler that data is already aligned to a 2-byte, 4-byte *//* or 8-byte boundary. Note: this macro does not change the *//* alignment of data. Use DATA_ALIGN to change alignment. *//*****************************************************************************/#define DATA_IS_ALIGNED_2(x) (_nassert(((unsigned int)(x) & 0x1) == 0))#define DATA_IS_ALIGNED_4(x) (_nassert(((unsigned int)(x) & 0x3) == 0))#define DATA_IS_ALIGNED_8(x) (_nassert(((unsigned int)(x) & 0x7) == 0))/*****************************************************************************//* SAVE_AMR - *//* Define a local 'volatile unsigned int' variable in your interrupt *//* routine. *//* When invoking this macro, pass that local variable to save the AMR. *//* *//* If you interrupted an assembly coded routine that may be using *//* circular addressing, and you interrupt into a C coded interrupt *//* service routine, you need to set the AMR to 0 for the C code and save *//* off the AMR register, so that it will have the correct value upon *//* leaving the C interrupt service routine and returning to the assembly *//* code. *//* *//* Add this routine immediately after your local variable definitions *//* and before the start of your C interrupt code. *//*****************************************************************************/#define SAVE_AMR(temp_AMR) \ do { \ temp_AMR = AMR; \ AMR = 0; \ } while (0)/*****************************************************************************//* RESTORE_AMR - *//* When invoking this macro, pass the same local variable that was passed *//* to the SAVE_AMR macro. This macro will restore the AMR to the value *//* it had when interrupted out of the hand assembly routine. *//* *//* Add this macro immediately before exiting the C interrupt service *//* routine. */ /*****************************************************************************/#define RESTORE_AMR(temp_AMR) \ do { \ AMR = temp_AMR; \ } while (0)/*****************************************************************************//* SAVE_SAT - *//* Define a local 'volatile unsigned int' variable in your interrupt *//* routine. *//* When invoking this macro, pass that local variable to save the SAT *//* bit. *//* *//* If you interrupted a routine that was performing saturated arithmetic *//* and the interrupt service routine is also performing saturated *//* arithmetic, then you must save and restore the SAT bit in your *//* interrupt service routine. *//* *//* Add this routine immediately after your local variable definitions *//* and before the start of your C interrupt code. *//*****************************************************************************/#define SAVE_SAT(temp_SAT) \ do { \ temp_SAT = _extu(CSR, 22, 31); \ } while (0)/*****************************************************************************//* RESTORE_SAT - *//* When invoking this macro, pass the same local variable that was passed *//* to the SAVE_SAT macro. This macro will restore the SAT bit to the *//* value it had when your application was interrupted. *//* *//* Add this macro immediately before exiting the C interrupt service *//* routine. */ /*****************************************************************************/#define RESTORE_SAT(temp_SAT) \ do { \ CSR = _clr(CSR, 9, 9); \ temp_SAT = _sshl(temp_SAT, 31); \ } while (0)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -