Data Logger BLE Cellular Board
Loading...
Searching...
No Matches
watchdog_app.h File Reference

Watchdog module for Asset Tracker v2. More...

#include <zephyr/kernel.h>

Go to the source code of this file.

Classes

struct  watchdog_evt
 

Typedefs

typedef void(* watchdog_evt_handler_t) (const struct watchdog_evt *evt)
 Watchdog library event handler.
 

Enumerations

enum  watchdog_evt_type { WATCHDOG_EVT_START , WATCHDOG_EVT_TIMEOUT_INSTALLED , WATCHDOG_EVT_FEED }
 

Functions

int watchdog_init_and_start (void)
 Initialize and start application watchdog module.
 
void watchdog_register_handler (watchdog_evt_handler_t evt_handler)
 Register handler to receive watchdog callback events.
 

Detailed Description

Watchdog module for Asset Tracker v2.

Definition in file watchdog_app.h.

Typedef Documentation

◆ watchdog_evt_handler_t

typedef void(* watchdog_evt_handler_t) (const struct watchdog_evt *evt)

Watchdog library event handler.

Parameters
[in]evtThe event and any associated parameters.

Definition at line 32 of file watchdog_app.h.

Enumeration Type Documentation

◆ watchdog_evt_type

Enumerator
WATCHDOG_EVT_START 
WATCHDOG_EVT_TIMEOUT_INSTALLED 
WATCHDOG_EVT_FEED 

Definition at line 21 of file watchdog_app.h.

Function Documentation

◆ watchdog_init_and_start()

int watchdog_init_and_start ( void )

Initialize and start application watchdog module.

Returns
Zero on success, otherwise a negative error code is returned.

Initialize and start application watchdog module.

Returns
0 on success, or a negative error code on failure.

Definition at line 258 of file watchdog_app.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ watchdog_register_handler()

void watchdog_register_handler ( watchdog_evt_handler_t evt_handler)

Register handler to receive watchdog callback events.

Note
The library only allows for one event handler to be registered at a time. A passed in event handler in this function will overwrite the previously set event handler.
Parameters
evt_handlerEvent handler. Handler is de-registered if parameter is NULL.

Definition at line 291 of file watchdog_app.c.

Here is the call graph for this function: