nrfcxx
0.1.0
C++-17 Framework for Nordic nRF5 Devices
|
Go to the documentation of this file. 11 #ifndef NRFCXX_BOARD_THINGY52_HPP 12 #define NRFCXX_BOARD_THINGY52_HPP 36 misc::sx1509b&
iox () noexcept;
81 bool linear = false) noexcept;
105 if (psel != (0x0F & psel)) {
136 unsigned int configuration ()
const override;
138 void configure (
unsigned int pin_cnf)
override;
140 bool read ()
const override;
void failsafe(FailSafeCode code)
Record a critical system failure and reset the system.
Definition: core.hpp:1692
int enable_led_driver(unsigned int iox_mask=0, bool linear=false) noexcept
Enable the SX1509B LED driver functionality.
const uint8_t psel
The pin index on the IO extender, from 0 through 15 inclusive .
Definition: thingy52.hpp:114
void clear() override
Set the pin to drive the output low.
Definition: thingy52.hpp:126
Application attempted to retrieve a non-existent peripheral instance.
iox_pin(int psel)
Construct the instance.
Definition: thingy52.hpp:101
Material supporting low-power-mode operations.
power_monitor(notifier_type notify)
Construct an instance.
void toggle() override
Toggle the pin drive state.
Definition: thingy52.hpp:131
const gpio_regs_type & gpio_cache() const noexcept
Access the internal cache of GPIO registers.
Definition: sx1509b.hpp:82
Extension of gpio::generic_pin using the SX1509B IO extender.
Definition: thingy52.hpp:94
int led_setup_battery_display(unsigned int batt_mV)
Configure to display the battery level.
Support for monitoring LiPo batteries.
int output_sct(uint16_t set, uint16_t clear) noexcept
Multi-signal set, clear, and toggle API.
Support for the power source interface.
Definition: thingy52.hpp:149
const uint16_t bit
The bit associated with the pin on the IO extender.
Definition: thingy52.hpp:111
std::function< void()> notifier_type
Type used to hold a notifier.
Definition: core.hpp:514
int disable_led_driver() noexcept
Enable the SX1509B LED driver functionality.
bool is_set() const override
Return true iff the pin is valid and is configured to drive the output high.
Definition: thingy52.hpp:142
Base (or mixin) class for anything that supports a state_machine.
Definition: lpm.hpp:426
unsigned int battery_level_pptt(unsigned int batt_mV)
Estimated battery level from measured voltage.
void set() override
Set the pin to drive the output high.
Definition: thingy52.hpp:121
A state machine to monitor a LiPo battery and charger.
Definition: lipomon.hpp:49
bool valid() const override
Indicate whether the pin is functional.
Definition: thingy52.hpp:116
Primary namespace for nrfcxx functionality.
Definition: clock.hpp:17
misc::sx1509b & iox() noexcept
Access the SX1509B instance.
Support for Semtex SX1509B.