First version with a button and added the Blinker library to the source root.

This commit is contained in:
Johannes Findeisen 2022-11-29 03:51:52 +01:00
commit 15e33b531f
9 changed files with 246 additions and 31 deletions

View file

@ -0,0 +1,28 @@
#ifndef _BLINKER_H
#define _BLINKER_H
#if (ARDUINO >= 100)
# include <Arduino.h>
#else
# include <WProgram.h>
#endif
class Blinker {
private:
int _blinkPin;
uint32_t _highDelay;
uint32_t _lowDelay;
uint32_t _lastBlink;
boolean _blinkState;
boolean _running;
public:
Blinker(int pin);
void setDelay(uint32_t d);
void setDelay(uint32_t h, uint32_t l);
void blink();
void start();
void stop(bool idleState = LOW);
};
#endif