35 lines
520 B
C
35 lines
520 B
C
![]() |
/*
|
|||
|
* key.h
|
|||
|
*
|
|||
|
* Created on: 2020<EFBFBD><EFBFBD>11<EFBFBD><EFBFBD>18<EFBFBD><EFBFBD>
|
|||
|
* Author: Administrator
|
|||
|
*/
|
|||
|
|
|||
|
#ifndef KEY_H_
|
|||
|
#define KEY_H_
|
|||
|
|
|||
|
#include "Cpu.h"
|
|||
|
#include <stdio.h>
|
|||
|
#include <stdint.h>
|
|||
|
|
|||
|
#ifndef KEY_INPUT_H_
|
|||
|
#define KEY_INPUT_H_
|
|||
|
|
|||
|
|
|||
|
|
|||
|
#define BTN1 ((PINS_DRV_ReadPins(PTC)>>14)&0x01)
|
|||
|
#define BTN2 ((PINS_DRV_ReadPins(PTC)>>15)&0x01)
|
|||
|
#define BTN3 ((PINS_DRV_ReadPins(PTC)>>16)&0x01)
|
|||
|
|
|||
|
#define BTN1_PRES 1
|
|||
|
#define BTN2_PRES 2
|
|||
|
#define BTN3_PRES 3
|
|||
|
unsigned char KEY_Proc (unsigned char mode);
|
|||
|
|
|||
|
|
|||
|
|
|||
|
#endif /* KEY_INPUT_H_ */
|
|||
|
|
|||
|
|
|||
|
#endif /* KEY_H_ */
|