00001 /***************************************************************************/ 00018 #ifndef _BSPBUTTONS_H 00019 #define _BSPBUTTONS_H 00020 00021 /****************************************************************************** 00022 Includes section 00023 ******************************************************************************/ 00024 // \cond 00025 #include <types.h> 00026 // \endcond 00027 00028 /****************************************************************************** 00029 Define(s) section 00030 ******************************************************************************/ 00031 // \cond 00032 #define BSP_KEY0 ((uint8_t)1 << 0) 00033 #define BSP_KEY1 ((uint8_t)1 << 1) 00034 // \endcond 00035 00036 /****************************************************************************** 00037 Types section 00038 ******************************************************************************/ 00039 00040 // \cond 00041 typedef void (*BSP_ButtonsEventFunc_t)(uint8_t); 00042 // \endcond 00043 00044 /****************************************************************************** 00045 Prototypes section 00046 ******************************************************************************/ 00047 /**************************************************************************/ 00059 result_t BSP_OpenButtons(void (*pressed)(uint8_t bn), void (*released)(uint8_t bn)); 00060 00061 /**************************************************************************/ 00067 result_t BSP_CloseButtons(void); 00068 00069 /**************************************************************************/ 00075 uint8_t BSP_ReadButtonsState(void); 00076 00077 #endif /* _BSPBUTTONS_H */ 00078 //eof buttons.h