WDT HALY

group nrfy_wdt

Hardware access layer with cache and barrier support for managing the WDT peripheral.

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.

Parameters:
  • p_reg[in] Pointer to the structure of registers of the peripheral.

  • p_config[in] Pointer to the peripheral configuration structure.

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.

Parameters:
  • p_reg[in] Pointer to the structure of registers of the peripheral.

  • mask[in] Mask of interrupts to be initialized.

  • irq_priority[in] Interrupt priority.

  • enable[in] 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.

Parameters:
  • p_reg[in] Pointer to the structure of registers of the peripheral.

NRFY_STATIC_INLINE uint32_t nrfy_wdt_events_process(NRF_WDT_Type *p_reg, uint32_t mask)

Function for processing the specified WDT events.

Parameters:
  • p_reg[in] Pointer to the structure of registers of the peripheral.

  • mask[in] Mask of events to be processed, created by NRFY_EVENT_TO_INT_BITMASK.

Returns:

Mask of events that were generated and processed. To be checked against the result of NRFY_EVENT_TO_INT_BITMASK().

NRFY_STATIC_INLINE void nrfy_wdt_task_trigger(NRF_WDT_Type *p_reg, nrf_wdt_task_t task)

@refhal{nrf_wdt_task_trigger}

NRFY_STATIC_INLINE uint32_t nrfy_wdt_task_address_get(NRF_WDT_Type const *p_reg, nrf_wdt_task_t task)

@refhal{nrf_wdt_task_address_get}

NRFY_STATIC_INLINE void nrfy_wdt_event_clear(NRF_WDT_Type *p_reg, nrf_wdt_event_t event)

@refhal{nrf_wdt_event_clear}

NRFY_STATIC_INLINE bool nrfy_wdt_event_check(NRF_WDT_Type const *p_reg, nrf_wdt_event_t event)

@refhal{nrf_wdt_event_check}

NRFY_STATIC_INLINE uint32_t nrfy_wdt_event_address_get(NRF_WDT_Type const *p_reg, nrf_wdt_event_t event)

@refhal{nrf_wdt_event_address_get}

NRFY_STATIC_INLINE void nrfy_wdt_int_enable(NRF_WDT_Type *p_reg, uint32_t mask)

@refhal{nrf_wdt_int_enable}

NRFY_STATIC_INLINE uint32_t nrfy_wdt_int_enable_check(NRF_WDT_Type const *p_reg, uint32_t mask)

@refhal{nrf_wdt_int_enable_check}

NRFY_STATIC_INLINE void nrfy_wdt_int_disable(NRF_WDT_Type *p_reg, uint32_t mask)

@refhal{nrf_wdt_int_disable}

NRFY_STATIC_INLINE void nrfy_wdt_subscribe_set(NRF_WDT_Type *p_reg, nrf_wdt_task_t task, uint8_t channel)

@refhal{nrf_wdt_subscribe_set}

NRFY_STATIC_INLINE void nrfy_wdt_subscribe_clear(NRF_WDT_Type *p_reg, nrf_wdt_task_t task)

@refhal{nrf_wdt_subscribe_clear}

NRFY_STATIC_INLINE void nrfy_wdt_publish_set(NRF_WDT_Type *p_reg, nrf_wdt_event_t event, uint8_t channel)

@refhal{nrf_wdt_publish_set}

NRFY_STATIC_INLINE void nrfy_wdt_publish_clear(NRF_WDT_Type *p_reg, nrf_wdt_event_t event)

@refhal{nrf_wdt_publish_clear}

NRFY_STATIC_INLINE void nrfy_wdt_behaviour_set(NRF_WDT_Type *p_reg, uint32_t mask)

@refhal{nrf_wdt_behaviour_set}

NRFY_STATIC_INLINE bool nrfy_wdt_started_check(NRF_WDT_Type const *p_reg)

@refhal{nrf_wdt_started_check}

NRFY_STATIC_INLINE bool nrfy_wdt_request_status_check(NRF_WDT_Type const *p_reg, nrf_wdt_rr_register_t rr_register)

@refhal{nrf_wdt_request_status_check}

NRFY_STATIC_INLINE uint32_t nrfy_wdt_request_status_get(NRF_WDT_Type const *p_reg)

@refhal{nrf_wdt_request_status_get}

NRFY_STATIC_INLINE void nrfy_wdt_reload_value_set(NRF_WDT_Type *p_reg, uint32_t reload_value)

@refhal{nrf_wdt_reload_value_set}

NRFY_STATIC_INLINE uint32_t nrfy_wdt_reload_value_get(NRF_WDT_Type const *p_reg)

@refhal{nrf_wdt_reload_value_get}

NRFY_STATIC_INLINE void nrfy_wdt_reload_request_enable(NRF_WDT_Type *p_reg, nrf_wdt_rr_register_t rr_register)

@refhal{nrf_wdt_reload_request_enable}

NRFY_STATIC_INLINE void nrfy_wdt_reload_request_disable(NRF_WDT_Type *p_reg, nrf_wdt_rr_register_t rr_register)

@refhal{nrf_wdt_reload_request_disable}

NRFY_STATIC_INLINE bool nrfy_wdt_reload_request_enable_check(NRF_WDT_Type const *p_reg, nrf_wdt_rr_register_t rr_register)

@refhal{nrf_wdt_reload_request_enable_check}

NRFY_STATIC_INLINE void nrfy_wdt_reload_request_set(NRF_WDT_Type *p_reg, nrf_wdt_rr_register_t rr_register)

@refhal{nrf_wdt_reload_request_set}

struct nrfy_wdt_config_t
#include <nrfy_wdt.h>

WDT configuration structure.

Public Members

uint32_t behaviour

Watchdog behaviour flags bitmask, constructed from nrf_wdt_behaviour_mask_t.

uint32_t reload_value

Watchdog counter initial value.