📄 funcgetch.c
字号:
#include "Includes.h"
#include "funccommon.h"
#include "event.h"
//this is a common function to wait for message and discard useless message
//return 0xff for MSG_MENU_CANCEL and key value for key press event
INT8U MFunc_WaitForInput(INT8U val){
INT8U rom * pMsg;
INT8U err,retval;
for(;;){
pMsg = OSQPend(peventMenu,val,&err);
if(err==OS_TIMEOUT)
return(0xFD);
else if((INT24U)pMsg >= PTR_MAX){
if((INT24U)pMsg == MSG_MENU_CANCEL){
return(0xff);
}
}
else{
retval = 0xff;
if(((MSG_HEAD *)pMsg)->Msg_ID == MSG_MENU_KEY){
retval = ((MSG_KEYPRESS *)pMsg)->Key;
}
Func_Clear_Msg(pMsg);
if(retval != 0xff) return(retval);
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -