Miya Miyagawa
/
OREWOTAOSITAI
aaaaa
Diff: Input/Switch/Switch.h
- Revision:
- 0:562021ed1ba9
- Child:
- 1:e73cf2469f83
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Input/Switch/Switch.h Sat Jan 13 13:33:09 2018 +0000 @@ -0,0 +1,27 @@ +#ifndef SWITCH_H_ +#define SWITCH_H_ + +#include "mbed.h" + +extern DigitalIn limitSw[]; + +namespace SWITCH +{ + #define LIMITSW0_PIN NC + #define LIMITSW1_PIN A7 + #define LIMITSW2_PIN A6 + #define LIMITSW3_PIN A5 + #define LIMITSW4_PIN A4 + + #define MOUNTING_LIMITSW_NUM (4 + 1) //limitSw[0]の関係で+1 + + class Switch + { + public: + static void Initialize(void); + static bool checkPushed(int mySwitch); + }; +} + +#endif +