Skip to content

Hardware::Button - Library for detecting button clicks, multiple clicks and long press on a button for use with the Arduino environment.

License

Notifications You must be signed in to change notification settings

andriitishchenko/HardwareButton

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HardwareButton

Hardware::Button - Library for detecting button clicks, multiple clicks and long press on a button for use with the Arduino environment.

Example

Hardware::Button button = Hardware::Button(2);
//  
  button.onPress = &onPress;
  button.onLongPress = &onLongPress;
  button.onLongPressing = &onLongPressing;
  button.onMultiplePress = &onMultiplePress;

//optional settings
  button.id = 100;
  button.setPressTimeout(600);
  button.setLongPressTimeout(1000);
  button.setMultiPressTimeout(260);

Usage

1 Install library

2 open demo project "HardwareButton->ButtonDemo"

About

Hardware::Button - Library for detecting button clicks, multiple clicks and long press on a button for use with the Arduino environment.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages