|
ptt-fhss
Bare-metal PTT firmware for nRF52840 with FHSS
|
Power management: DC/DC regulator, GPIOTE wakeup, WFI sleep. More...
#include <stdbool.h>Go to the source code of this file.
Functions | |
| void | power_init (void) |
| Enable the DC/DC converter, configure GPIO input and GPIOTE wakeup on the PTT button. | |
| void | power_sleep_until_button (void) |
| Enter SYSTEM_ON low-power sleep and return on the next GPIOTE event. | |
| bool | power_button_pressed (void) |
| Return the current state of the PTT button. | |
Power management: DC/DC regulator, GPIOTE wakeup, WFI sleep.
| bool power_button_pressed | ( | void | ) |
Return the current state of the PTT button.
| void power_init | ( | void | ) |
Enable the DC/DC converter, configure GPIO input and GPIOTE wakeup on the PTT button.
| void power_sleep_until_button | ( | void | ) |
Enter SYSTEM_ON low-power sleep and return on the next GPIOTE event.
Sets TASKS_LOWPWR then executes WFI. The CPU wakes when the GPIOTE interrupt fires (button press) and resumes from here.