/* ****************************************************************************** * * @file key.h * @brief key module * * * @version 1.0 * @date 2023/05/12 09:59:40 * @author Alex Xu * * Copyright (c) 2013-2099,Tkplusemi Technology Co.,Ltd. * All Rights Reserved * * History: * Revision Date Author Desc * 1.0.0 2023/07/12 Alex build this file ****************************************************************************** */ #ifndef __KEY_H__ #define __KEY_H__ #include "define.h" #if KEY_HALL_ENABLE extern bit Hall_Positive_Flg; extern bit Hall_Negative_Flg; typedef enum { KEY_EVENT_Empty = 0x00, KEY_EVENT_IN, //Key press interrupt flag KEY_EVENT_SHORT, //Key short press(60ms-1s) interrupt flag KEY_EVENT_L_2S, //Key long press for 2/3s interrupt flag KEY_EVENT_LL_8, //Key super long press for 8s interrupt flag }KEY_EVENT_E; extern idata KEY_EVENT_E Event_key; //extern void Key_Init(void); extern void Key_Handler(void ); #endif #endif