Simple library for LED blinking.

Dependents:   roam_v2 finalV1 finalV1 finalv2 ... more

Blinker.h

Committer:
tbjazic
Date:
2014-12-16
Revision:
1:ea5bb72717cc
Parent:
0:c9a302c4bed9
Child:
2:190915d53c0b

File content as of revision 1:ea5bb72717cc:

#ifndef MBED_BLINKER_H_TB
#define MBED_BLINKER_H_TB

#include "mbed.h"

/** Simple class for learning development of libraries.
 * 
 * Author: TVZ Mechatronics Team
 *
 * Example of use:
 * @code
 * #include "mbed.h"
 * #include "Blinker.h"
 *
 * int main() {
 *    Blinker mojBlinker(LED3);
 *    mojBlinker.blink(10);
 *    wait(2);
 *    mojBlinker.blink(5, 0.5);
 * }
 * @endcode
 */
class Blinker {
private:
    DigitalOut myled;
public:
    Blinker(PinName pin);
    void blink(int n, float t = 0.2);
};

#endif