NXPCUP-libary
Library for car's control board on NXPCUP competition based on the Mbed framework.
Classes | List of all members
nxpcup::Buttons Class Reference

#include <Buttons.h>

Classes

struct  Config
 
 Buttons (const Config &config)
 
ButtonId getPressed ()
 
ButtonId getPressed (ButtonId &buttonId)
 
bool isPressed (ButtonId buttonId)
 
void waitForPress (ButtonId buttonId)
 

Constructor & Destructor Documentation

nxpcup::Buttons::Buttons ( const Config config)
inline

Constructor of class Buttons.

Parameters
configstructureConfig}

Member Function Documentation

ButtonId nxpcup::Buttons::getPressed ( )
inline

Return the id of pressed button.

Returns
ButtonId} type
ButtonId nxpcup::Buttons::getPressed ( ButtonId buttonId)
inline

Return the id of pressed button and save it to parameter buttonId.

Parameters
buttonIdvariable for saving current value
Returns
ButtonId} type
bool nxpcup::Buttons::isPressed ( ButtonId  buttonId)
inline

Check button with specific id.

Parameters
buttonIdid of the button
Returns
true if is pressed, else false
void nxpcup::Buttons::waitForPress ( ButtonId  buttonId)
inline

Wait for press button with specific id.

Parameters
buttonIdid of button on which will wait

The documentation for this class was generated from the following file: