📄 uhal.h
字号:
/************************************************** * * <filename> * * CVS ID: $Id: uHAL.h,v 1.7 2007/08/20 16:30:32 longauer Exp $ * Author: Leos Longauer [LL] - STM * Date: $Date: 2007/08/20 16:30:32 $ * Revision: $Revision: 1.7 $ * * Description: * * Hardware abstraction layer header. * *************************************************** * * COPYRIGHT (C) ST Microelectronics 2005 * All Rights Reserved * ***************************************************/#ifndef _UHAL_H#define _UHAL_H#include "intgrt.h"/*************************** DEFINITIONS **************************//*---------------------------------------------------------------------------*//*!\brief compilation switches *//*---------------------------------------------------------------------------*//* compilation switch between DYN_malloc and standart malloc */#define _DYN_MALLOC/*********************** FUNCTION PROTOTYPES **********************//*---------------------------------------------------------------------------*//*!\brief uHAL interrupt handling functions *//*---------------------------------------------------------------------------*/void uHALr_RequestInterrupt (unsigned int IrqNo, void (*pfUsbIsr)(), unsigned char* IsrName);void uHALr_EnableInterrupt(unsigned int IrqNo);void uHALr_DisableInterrupt(unsigned int IrqNo);void uHALr_FreeInterrupt(unsigned int IrqNo);/*---------------------------------------------------------------------------*//*!\brief uHAL timer functions *//*---------------------------------------------------------------------------*/int uHALr_RequestTimer(void (*MGC_TimerExpired)(), unsigned char* timer_name);//int uHALr_SetTimerState(unsigned int iIndex, unsigned char bPeriodic);int uHALr_SetTimerInterval(unsigned int iIndex, unsigned int dwInterval);//int uHALr_GetTimerState(unsigned int iTimerIndex);//void uHALr_InstallTimer(int iIndex);void uHALr_EnableTimer(int iIndex);void uHALir_DisableTimer(int iIndex);//unsigned int uHALir_CountTimers(void);unsigned int uHALir_GetTimerInterrupt(int iIndex);//int uHALr_FreeTimer(unsigned int iIndex); //[LL] new one/*---------------------------------------------------------------------------*//*!\brief uHAL debug interface functions *//*---------------------------------------------------------------------------*/#if (MUSB_DIAG!=0)int uHALr_CharAvailable(void);unsigned char uHALr_getchar(void);void uHALr_putchar(unsigned char bData);#endif /*MUSB_DIAG*/#if (MUSB_DIAG!=0)int uHALr_printf(const unsigned char* pInput);#else#define uHALr_printf(...) //printf(...)#endif/*---------------------------------------------------------------------------*//*!\brief uHAL memory management functions *//*---------------------------------------------------------------------------*/void* uHALr_malloc(unsigned long dwLength);void uHALr_free(void* pDestination);void uHALr_memcpy(void* pDestination, void* pSource, unsigned short iSize);void uHALr_memset(void* pDestination, unsigned short iData, unsigned short iSize);#endif /* _UHAL_H */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -