57 lines
1.7 KiB
C
57 lines
1.7 KiB
C
/*
|
||
* File: __GP22Gas_KEY_APP_H
|
||
* Author:
|
||
*
|
||
* Created on:2015-5-18
|
||
*/
|
||
|
||
#ifndef __UWater_KEY_APP_H
|
||
#define __UWater_KEY_APP_H
|
||
|
||
#include "type.h"
|
||
#include "UWater_key_driver.h"
|
||
#include "UWater_lcd_app.h"
|
||
|
||
#ifdef __cplusplus
|
||
extern "C" {
|
||
#endif
|
||
|
||
/*------------------------------- Variable Define -----------------------------------*/
|
||
#define KEY_SYS_S0 0 //按键应用状态机状态号
|
||
#define KEY_SYS_S1 1
|
||
|
||
//#define MENU_TWO 0b10 // 切2级菜单MSG
|
||
//#define MENU_ONE 0b01 // 切1级菜单MSG
|
||
//#define MENU_DEFAULT 0b100 //切默认菜单MSG
|
||
//#define MENU_TEST 0b1000 //切检定状态菜单MSG
|
||
//#define MENU_TEST_GP30 0b10000 //切测试菜单MSG
|
||
//#define MENU_ACTIVE_RF 0b100000 //无线活跃MSG 递传
|
||
//#define MENU_ACTIVE_RF_APP 0b1000000 //无线活跃MSG 小无线应用
|
||
|
||
#define MENU_TWO 0x01//0b01 // 切2级菜单MSG
|
||
#define MENU_ONE 0x02//0b10 // 切1级菜单MSG
|
||
#define MENU_DEFAULT 0x04//0b100 //切默认菜单MSG
|
||
#define MENU_TEST 0x08//0b1000 //切检定状态菜单MSG
|
||
#define MENU_ACTIVE_RF 0x20//0b100000 //唤醒无线GSM
|
||
|
||
|
||
/*-------------------------------- 外部接口函数 ---------------------------------*/
|
||
void KeyInitApp(void); //应用层按键管理初始化
|
||
void KeyMachineApp(void); //应用层建立任务接口
|
||
u8 KeyCheckLcdMsgApp(u8 msg); //查询按键对LCD的MSG输出
|
||
u8 KeyClearLcdMsgApp(u8); //清除按键对LCD的MSG输出
|
||
void KeySetLcdMsgApp(u8 msg);
|
||
u8 KeyIfSleepApp(void); //查询模块是否允许休眠
|
||
void KeySetIrOpenMsg(void);
|
||
u8 KeyCheckIrOpenMsg(void);
|
||
void KeyClearIrOpenMsg(void);
|
||
|
||
|
||
#ifdef __cplusplus
|
||
}
|
||
#endif //#ifndef __cplusplus
|
||
|
||
|
||
#endif /* __UWater_KEY_APP_H */
|
||
|