nrfcxx
0.1.0
C++-17 Framework for Nordic nRF5 Devices
|
Go to the documentation of this file. 7 #ifndef NRFCXX_SENSOR_BUTTON_HPP 8 #define NRFCXX_SENSOR_BUTTON_HPP 57 static const char* eventstr (
unsigned int evt);
69 using event_callback = std::function<void(
unsigned int evt, uint64_t duration_utt)>;
75 unsigned int state ()
const;
83 unsigned int state (uint64_t& duration_utt)
const;
114 return debounce_utt_;
176 static constexpr
bool state_xor = board::button_active_low;
178 static void level_callback_ (
Button* bp);
192 uint64_t process_utt{};
193 uint64_t press_utt{};
Object used to manage sense callbacks.
Definition: periph.hpp:854
active_signal< false > active_low
Alias type used for CSn, RESETn, and other active low output signals.
Definition: gpio.hpp:669
std::function< void()> notifier_type
Type used to hold a notifier.
Definition: core.hpp:514
Class supporting an alarm with custom callback and repeatability.
Definition: clock.hpp:498
constexpr static int64_t from_ms(int64_t ms)
Convert integral milliseconds to uptime ticks (rounding down).
Definition: clock.hpp:422
Primary namespace for nrfcxx functionality.
Definition: clock.hpp:17