elec350

Dependencies:   mbed

Fork of elec350 by Bob Merrison-Hort

button.h

Committer:
rmerrisonhort
Date:
2015-10-20
Revision:
8:a82ea42026db
Parent:
7:aa63d1e53be6

File content as of revision 8:a82ea42026db:

#ifndef _BUTTON_H_
#define _BUTTON_H_

#include "mbed.h"
#include <string>

class Button {
    private:
        DigitalIn* pin;
    public:
        Button(string name);
        bool isPressed();
        float getPulse(float timeout=-1.0f);
};

#endif