Gemphet8 ; 8-polyphonic synthesizer control application
Dependencies: MIDI REnc button mbed
btn2/btn2.h
- Committer:
- ChuckTimber
- Date:
- 2014-12-13
- Revision:
- 12:dc6208de53cc
- Parent:
- 11:e6a47dc75120
File content as of revision 12:dc6208de53cc:
/** * @file btn2.h * Project button long press handling sample * @brief button long press handling class * @version 1.00 * @author Chuck Timber * @date 09/08/2014 */ #ifndef MBED_BUTTON2_H #define MBED_BUTTON2_H #include "mbed.h" #include "button.h" namespace mbed { /** Class: BTN2 * A class handles button long press */ class BTN2 { public: /// constructor BTN2(PinName pin); /** button return value * * @retval 1 - button pressed shortly * @retval 2 - button pressed longly */ unsigned char CMD2; private: /// use BTN lib BTN _btn; /// use Ticker for intaval timer Ticker _tick; /// button check function void check_btn_pressed(void); }; } #endif