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
7
class
GurdyButton
{
8
protected
:
9
Bounce*
bounce_obj
;
10
bool
being_pressed
;
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
GurdyButton
Definition:
gurdybutton.h:7
GurdyButton::update
void update()
Polls the button and updates its state.
Definition:
gurdybutton.cpp:21
GurdyButton::wasPressed
bool wasPressed()
Reports if the button was pressed down this update() cycle.
Definition:
gurdybutton.cpp:42
GurdyButton::beingPressed
bool beingPressed()
Reports if the button is being pressed this update() cycle.
Definition:
gurdybutton.cpp:36
GurdyButton::wasReleased
bool wasReleased()
Reports if the button was released this update() cycle.
Definition:
gurdybutton.cpp:48
GurdyButton::being_pressed
bool being_pressed
Definition:
gurdybutton.h:10
GurdyButton::bounce_obj
Bounce * bounce_obj
Definition:
gurdybutton.h:9
Generated by
1.9.5