button.h
来自「里面给出了ATmega103单片机编程的C语言实例程序」· C头文件 代码 · 共 38 行
H
38 行
/* ATmega103 button.h file
Author : Robert Stuart
Company : PDL Industries Ltd
Date of Creation : 26 August 1999
*/
/* includes */
#include <iom103.h>
#include "logic.h"
#include "ports.h"
/* External Variables */
extern enum
{
SET=1,
UP,
DOWN,
BUTTON_NONE
} Button;
extern char ButtonStatus;
/* Local Variables */
static unsigned int Buffer;
static enum ButtonMap
{
SET_MAP=1,
UP_MAP,
DOWN_MAP,
NONE_MAP
}; /* the buttons will exist in one of these states */
static enum ButtonMap PushedButton, LastButton;
/* used to controll the triggering of the buttons */
/* Local Prototypes */
void BufferButton( void );
void DebounceButton( void );
void DetermineButtonState( void );
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?