1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768 |
- #ifndef __HS_KEY_H_
- #define __HS_KEY_H_
- #include "common.h"
- #define KEY_SELECT 0
- #define KEY_UP 1
- #define KEY_DOWN 3
- #define KEY_BACK 2
- typedef struct tsHSKey{
- unsigned char onFlag;
- unsigned char softRelease;
- unsigned char pressedSec;
- unsigned int pressTime;
- unsigned int longPressTimeOne;
- unsigned int longPressTimeKeep;
- unsigned int prevTime;
- }HSKey;
- void ReadKEY(void);
- void KeyInit(void);
- void KeySelectPressed(void);
- void KeySelectReleased(void);
- void KeySelectLongPressedOne(void);
- void KeySelectLongPressedKeep(void);
- void KeyUpPressed(void);
- void KeyUpReleased(void);
- void KeyUpLongPressedOne(void);
- void KeyUpLongPressedKeep(void);
- void KeyDownPressed(void);
- void KeyDownReleased(void);
- void KeyDownLongPressedOne(void);
- void KeyDownLongPressedKeep(void);
- void KeyBackPressed(void);
- void KeyBackReleased(void);
- void KeyBackLongPressedOne(void);
- void KeyBackLongPressedKeep(void);
- #endif
|