Digigurdy-baz
Loading...
Searching...
No Matches
gurdybutton.h
Go to the documentation of this file.
1#ifndef GURDYBUTTON_H
2#define GURDYBUTTON_H
3
4#include <Arduino.h>
5#include <Bounce.h>
6
8 protected:
9 Bounce* bounce_obj;
11 public:
12 GurdyButton(int my_pin, int interval);
13
14 void update();
15 bool beingPressed();
16 bool wasPressed();
17 bool wasReleased();
18};
19
20#endif
Definition: gurdybutton.h:7
void update()
Polls the button and updates its state.
Definition: gurdybutton.cpp:21
bool wasPressed()
Reports if the button was pressed down this update() cycle.
Definition: gurdybutton.cpp:42
bool beingPressed()
Reports if the button is being pressed this update() cycle.
Definition: gurdybutton.cpp:36
bool wasReleased()
Reports if the button was released this update() cycle.
Definition: gurdybutton.cpp:48
bool being_pressed
Definition: gurdybutton.h:10
Bounce * bounce_obj
Definition: gurdybutton.h:9