Arduino Universal Inputs
A collection of libraries for managing/processing input devices on Arduino.
Main Page
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
ArduinoMatrixButton.h
Go to the documentation of this file.
1
3
#ifndef _ARDUINOUNIVERSALINPUTS_ARDUINOMATRIXBUTTON_H
4
#define _ARDUINOUNIVERSALINPUTS_ARDUINOMATRIXBUTTON_H
5
6
#include "
IButton.h
"
7
12
class
ArduinoMatrixButton
:
public
IButton
13
{
14
public
:
15
ArduinoMatrixButton
(
inputid_t
id
,
inputpin_t
colPin,
inputpin_t
rowPin);
16
17
virtual
~
ArduinoMatrixButton
() {}
18
23
inputpin_t
getColPin
()
const
{
return
m_colPin; }
24
29
inputpin_t
getRowPin
()
const
{
return
m_rowPin; }
30
31
protected
:
32
uint8_t
getPhysicalState
()
const
;
33
34
private
:
35
inputpin_t
m_colPin;
36
inputpin_t
m_rowPin;
37
};
38
39
#endif
ArduinoMatrixButton::ArduinoMatrixButton
ArduinoMatrixButton(inputid_t id, inputpin_t colPin, inputpin_t rowPin)
Creates a new button in a matrix configuration.
Definition:
ArduinoMatrixButton.cpp:11
ArduinoMatrixButton::getRowPin
inputpin_t getRowPin() const
Gets the pin attached to the matrix row for this button.
Definition:
ArduinoMatrixButton.h:29
inputid_t
uint16_t inputid_t
Holds the value of a device ID.
Definition:
UniversalInputTypes.h:13
ArduinoMatrixButton::getPhysicalState
uint8_t getPhysicalState() const
Gets the current physical state of the button.
Definition:
ArduinoMatrixButton.cpp:26
inputpin_t
uint8_t inputpin_t
Holds the value of a pin number.
Definition:
UniversalInputTypes.h:19
ArduinoMatrixButton::getColPin
inputpin_t getColPin() const
Gets the pin attached to the matrix column for this button.
Definition:
ArduinoMatrixButton.h:23
IButton
Represents a two state button.
Definition:
IButton.h:14
IButton.h
ArduinoMatrixButton
Represents a single button in a matrix configuration.
Definition:
ArduinoMatrixButton.h:12
Generated on Fri Aug 3 2018 14:58:25 for Arduino Universal Inputs by
1.8.6