![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
TOF based Presence Detector
Dependencies: BLE_API X_NUCLEO_6180XA1 X_NUCLEO_IDB0XA1 mbed
Fork of BLE_HeartRate_IDB0XA1 by
bricks/stop.cpp
- Committer:
- hux
- Date:
- 2018-08-20
- Revision:
- 29:eceecbe28088
- Parent:
- 28:a23b16555909
File content as of revision 29:eceecbe28088:
// stop.cpp - stop button functionality #include "bricks/stop.h" //============================================================================== // Stop Button Functionality //============================================================================== static bool flag; // stop indication flag static void cbButton(void) // button press callback { flag = true; } void StopButton::set() // set stop flag { flag = true; } void StopButton::clear() // clear stop flag { flag = false; } bool StopButton::request() // stop requested? { return flag; } StopButton::StopButton(PinName pin) : InterruptIn(pin) // constructor { clear(); rise(&cbButton); } // eof