Hardware access layer with cache and barrier support for managing the WDT peripheral. More...
Data Structures | |
struct | nrfy_wdt_config_t |
WDT configuration structure. More... | |
Macros | |
#define | NRFY_WDT_HAS_STOP 1 |
Functions | |
NRFY_STATIC_INLINE void | nrfy_wdt_periph_configure (NRF_WDT_Type *p_reg, nrfy_wdt_config_t const *p_config) |
Function for configuring the WDT. | |
NRFY_STATIC_INLINE void | nrfy_wdt_int_init (NRF_WDT_Type *p_reg, uint32_t mask, uint8_t irq_priority, bool enable) |
Function for initializing the specified WDT interrupts. | |
NRFY_STATIC_INLINE void | nrfy_wdt_int_uninit (NRF_WDT_Type *p_reg) |
Function for uninitializing the WDT interrupts. | |
NRFY_STATIC_INLINE uint32_t | nrfy_wdt_events_process (NRF_WDT_Type *p_reg, uint32_t mask) |
Function for processing the specified WDT events. | |
NRFY_STATIC_INLINE void | nrfy_wdt_task_trigger (NRF_WDT_Type *p_reg, nrf_wdt_task_t task) |
NRFY_STATIC_INLINE uint32_t | nrfy_wdt_task_address_get (NRF_WDT_Type const *p_reg, nrf_wdt_task_t task) |
NRFY_STATIC_INLINE void | nrfy_wdt_event_clear (NRF_WDT_Type *p_reg, nrf_wdt_event_t event) |
NRFY_STATIC_INLINE bool | nrfy_wdt_event_check (NRF_WDT_Type const *p_reg, nrf_wdt_event_t event) |
NRFY_STATIC_INLINE uint32_t | nrfy_wdt_event_address_get (NRF_WDT_Type const *p_reg, nrf_wdt_event_t event) |
NRFY_STATIC_INLINE void | nrfy_wdt_int_enable (NRF_WDT_Type *p_reg, uint32_t mask) |
NRFY_STATIC_INLINE uint32_t | nrfy_wdt_int_enable_check (NRF_WDT_Type const *p_reg, uint32_t mask) |
NRFY_STATIC_INLINE void | nrfy_wdt_int_disable (NRF_WDT_Type *p_reg, uint32_t mask) |
NRFY_STATIC_INLINE void | nrfy_wdt_subscribe_set (NRF_WDT_Type *p_reg, nrf_wdt_task_t task, uint8_t channel) |
NRFY_STATIC_INLINE void | nrfy_wdt_subscribe_clear (NRF_WDT_Type *p_reg, nrf_wdt_task_t task) |
NRFY_STATIC_INLINE void | nrfy_wdt_publish_set (NRF_WDT_Type *p_reg, nrf_wdt_event_t event, uint8_t channel) |
NRFY_STATIC_INLINE void | nrfy_wdt_publish_clear (NRF_WDT_Type *p_reg, nrf_wdt_event_t event) |
NRFY_STATIC_INLINE void | nrfy_wdt_behaviour_set (NRF_WDT_Type *p_reg, uint32_t mask) |
NRFY_STATIC_INLINE bool | nrfy_wdt_started_check (NRF_WDT_Type const *p_reg) |
NRFY_STATIC_INLINE bool | nrfy_wdt_request_status_check (NRF_WDT_Type const *p_reg, nrf_wdt_rr_register_t rr_register) |
NRFY_STATIC_INLINE uint32_t | nrfy_wdt_request_status_get (NRF_WDT_Type const *p_reg) |
NRFY_STATIC_INLINE void | nrfy_wdt_reload_value_set (NRF_WDT_Type *p_reg, uint32_t reload_value) |
NRFY_STATIC_INLINE uint32_t | nrfy_wdt_reload_value_get (NRF_WDT_Type const *p_reg) |
NRFY_STATIC_INLINE void | nrfy_wdt_reload_request_enable (NRF_WDT_Type *p_reg, nrf_wdt_rr_register_t rr_register) |
NRFY_STATIC_INLINE void | nrfy_wdt_reload_request_disable (NRF_WDT_Type *p_reg, nrf_wdt_rr_register_t rr_register) |
NRFY_STATIC_INLINE bool | nrfy_wdt_reload_request_enable_check (NRF_WDT_Type const *p_reg, nrf_wdt_rr_register_t rr_register) |
NRFY_STATIC_INLINE void | nrfy_wdt_reload_request_set (NRF_WDT_Type *p_reg, nrf_wdt_rr_register_t rr_register) |
NRFY_STATIC_INLINE void | nrfy_wdt_task_stop_enable_set (NRF_WDT_Type *p_reg, bool enable) |
Hardware access layer with cache and barrier support for managing the WDT peripheral.
#define NRFY_WDT_HAS_STOP 1 |
NRFY_STATIC_INLINE void nrfy_wdt_behaviour_set | ( | NRF_WDT_Type * | p_reg, |
uint32_t | mask | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Watchdog behaviour mask, created using nrf_wdt_behaviour_mask_t. |
NRFY_STATIC_INLINE uint32_t nrfy_wdt_event_address_get | ( | NRF_WDT_Type const * | p_reg, |
nrf_wdt_event_t | event | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | Event. |
NRFY_STATIC_INLINE bool nrfy_wdt_event_check | ( | NRF_WDT_Type const * | p_reg, |
nrf_wdt_event_t | event | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | Event to be checked. |
true | The event has been generated. |
false | The event has not been generated. |
NRFY_STATIC_INLINE void nrfy_wdt_event_clear | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_event_t | event | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | Event. |
NRFY_STATIC_INLINE uint32_t nrfy_wdt_events_process | ( | NRF_WDT_Type * | p_reg, |
uint32_t | mask | ||
) |
Function for processing the specified WDT events.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of events to be processed, created by NRFY_EVENT_TO_INT_BITMASK. |
NRFY_STATIC_INLINE void nrfy_wdt_int_disable | ( | NRF_WDT_Type * | p_reg, |
uint32_t | mask | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of interrupts to be disabled. Use nrf_wdt_int_mask_t values for bit masking. |
NRFY_STATIC_INLINE void nrfy_wdt_int_enable | ( | NRF_WDT_Type * | p_reg, |
uint32_t | mask | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of interrupts to be enabled. Use nrf_wdt_int_mask_t values for bit masking. |
NRFY_STATIC_INLINE uint32_t nrfy_wdt_int_enable_check | ( | NRF_WDT_Type const * | p_reg, |
uint32_t | mask | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of interrupts to be checked. Use nrf_wdt_int_mask_t values for bit masking. |
NRFY_STATIC_INLINE void nrfy_wdt_int_init | ( | NRF_WDT_Type * | p_reg, |
uint32_t | mask, | ||
uint8_t | irq_priority, | ||
bool | enable | ||
) |
Function for initializing the specified WDT interrupts.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of interrupts to be initialized. |
[in] | irq_priority | Interrupt priority. |
[in] | enable | True if interrupts are to be enabled, false otherwise. |
NRFY_STATIC_INLINE void nrfy_wdt_int_uninit | ( | NRF_WDT_Type * | p_reg | ) |
Function for uninitializing the WDT interrupts.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRFY_STATIC_INLINE void nrfy_wdt_periph_configure | ( | NRF_WDT_Type * | p_reg, |
nrfy_wdt_config_t const * | p_config | ||
) |
Function for configuring the WDT.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_config | Pointer to the peripheral configuration structure. |
NRFY_STATIC_INLINE void nrfy_wdt_publish_clear | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_event_t | event | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | Event for which to clear the configuration. |
NRFY_STATIC_INLINE void nrfy_wdt_publish_set | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_event_t | event, | ||
uint8_t | channel | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | Event for which to set the configuration. |
[in] | channel | Channel through which to publish the event. |
NRFY_STATIC_INLINE void nrfy_wdt_reload_request_disable | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_rr_register_t | rr_register | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | rr_register | Reload request register to be disabled. |
NRFY_STATIC_INLINE void nrfy_wdt_reload_request_enable | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_rr_register_t | rr_register | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | rr_register | Reload request register to be enabled. |
NRFY_STATIC_INLINE bool nrfy_wdt_reload_request_enable_check | ( | NRF_WDT_Type const * | p_reg, |
nrf_wdt_rr_register_t | rr_register | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | rr_register | Reload request register to be checked. |
true | The reload request register is enabled. |
false | The reload request register is not enabled. |
NRFY_STATIC_INLINE void nrfy_wdt_reload_request_set | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_rr_register_t | rr_register | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | rr_register | Reload request register to set. |
NRFY_STATIC_INLINE uint32_t nrfy_wdt_reload_value_get | ( | NRF_WDT_Type const * | p_reg | ) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRFY_STATIC_INLINE void nrfy_wdt_reload_value_set | ( | NRF_WDT_Type * | p_reg, |
uint32_t | reload_value | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | reload_value | Watchdog counter initial value. |
NRFY_STATIC_INLINE bool nrfy_wdt_request_status_check | ( | NRF_WDT_Type const * | p_reg, |
nrf_wdt_rr_register_t | rr_register | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | rr_register | Reload request register to be checked. |
true | Reload request is running. |
false | No reload requests are running. |
NRFY_STATIC_INLINE uint32_t nrfy_wdt_request_status_get | ( | NRF_WDT_Type const * | p_reg | ) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRFY_STATIC_INLINE bool nrfy_wdt_started_check | ( | NRF_WDT_Type const * | p_reg | ) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
true | The watchdog is started. |
false | The watchdog is not started. |
NRFY_STATIC_INLINE void nrfy_wdt_subscribe_clear | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_task_t | task | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | task | Task for which to clear the configuration. |
NRFY_STATIC_INLINE void nrfy_wdt_subscribe_set | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_task_t | task, | ||
uint8_t | channel | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | task | Task for which to set the configuration. |
[in] | channel | Channel through which to subscribe events. |
NRFY_STATIC_INLINE uint32_t nrfy_wdt_task_address_get | ( | NRF_WDT_Type const * | p_reg, |
nrf_wdt_task_t | task | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | task | Task. |
NRFY_STATIC_INLINE void nrfy_wdt_task_stop_enable_set | ( | NRF_WDT_Type * | p_reg, |
bool | enable | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | enable | True if stopping is to be enabled, false otherwise. |
NRFY_STATIC_INLINE void nrfy_wdt_task_trigger | ( | NRF_WDT_Type * | p_reg, |
nrf_wdt_task_t | task | ||
) |
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | task | Task. |