Henk Meewis / Mbed 2 deprecated USB_serial_LED_controller

Dependencies:   mbed

Fork of frdm_echo by Henk Meewis

Committer:
silverpanda
Date:
Fri Apr 25 16:22:54 2014 +0000
Revision:
15:a32db434af65
Parent:
13:019e24491f32
debugged

Who changed what in which revision?

UserRevisionLine numberNew contents of line
silverpanda 13:019e24491f32 1 #ifndef pushbuttons_h__
silverpanda 13:019e24491f32 2 #define pushbuttons_h__
silverpanda 13:019e24491f32 3
silverpanda 13:019e24491f32 4 typedef enum {pb2 = 0, pb3} ePushButton;
silverpanda 13:019e24491f32 5
silverpanda 13:019e24491f32 6 class PushButtons {
silverpanda 13:019e24491f32 7 public:
silverpanda 13:019e24491f32 8 PushButtons();
silverpanda 13:019e24491f32 9 bool tick10ms();
silverpanda 13:019e24491f32 10 bool getJustPressed(ePushButton);
silverpanda 13:019e24491f32 11 bool getPressed(ePushButton);
silverpanda 13:019e24491f32 12 private:
silverpanda 13:019e24491f32 13 void reset(ePushButton);
silverpanda 13:019e24491f32 14 void process(ePushButton);
silverpanda 13:019e24491f32 15 DigitalIn *getPointer(ePushButton);
silverpanda 13:019e24491f32 16
silverpanda 13:019e24491f32 17 DigitalIn *sw2, *sw3;
silverpanda 13:019e24491f32 18 uint32_t timer[2];
silverpanda 13:019e24491f32 19 bool justPressed[2], oldPressed[2];
silverpanda 13:019e24491f32 20 };
silverpanda 13:019e24491f32 21
silverpanda 13:019e24491f32 22 #endif