AbleButtons V0.4.0
Lightweight button library for Arduino.
 
Loading...
Searching...
No Matches
Callback.cpp File Reference

Definition of the callback functiosn. More...

#include "Callback.h"
#include "Checks.h"
#include "Utils.h"

Go to the source code of this file.

Functions

void onEvent (Button::CALLBACK_EVENT event, uint8_t id)
 Callback function for button events. More...
 

Detailed Description

Definition of the callback functiosn.

These functions perform some assertions on the state of the button list and the individual button pressed when a button is pressed. They also set button state flags so the main program can verify button states after hendling the events.

Definition in file Callback.cpp.

Function Documentation

◆ onEvent()

void onEvent ( Button::CALLBACK_EVENT  event,
uint8_t  id 
)

Callback function for button events.

Parameters
eventThe event that has occured.
idThe identifier of the button generating the callback.

Definition at line 20 of file Callback.cpp.