Contiki-NG
Loading...
Searching...
No Matches
CC13xx/CC26xx watchdog timer driver.

Files

 Header file of the CC13xx/CC26xx watchdog driver.

Functions

void watchdog_init (void)
 Initialises the Watchdog module.
uint32_t watchdog_arch_next_timeout (void)
 Return the next expiration time for the Watchdog.
void watchdog_start (void)
 Start the Watchdog.
void watchdog_periodic (void)
 Refresh (feed) the Watchdog.
void watchdog_stop (void)
 Stop the Watchdog such that it won't timeout and cause a system reset.
void watchdog_reboot (void)
 Manually trigger a Watchdog timeout.

Detailed Description

Function Documentation

◆ watchdog_arch_next_timeout()

uint32_t watchdog_arch_next_timeout ( void )

Return the next expiration time for the Watchdog.

Returns
Non-zero value of the next expiration time in Watchdog ticks. If the Watchdog is not running, this returns 0.

Definition at line 84 of file watchdog-arch.c.

References value().

◆ watchdog_init()

void watchdog_init ( void )

Initialises the Watchdog module.

Initialisation function for the WDT.

   Simply sets the reload counter to a default value. The WDT is not
   started yet. To start it, watchdog_start() must be called.

Currently simply explicitly sets the WDT interval to max interval

< Watchdog Control

Definition at line 68 of file watchdog-arch.c.

◆ watchdog_periodic()

void watchdog_periodic ( void )

Refresh (feed) the Watchdog.

Writes the WDT clear sequence.

Due to how the SMWDTHROSC_WDCTL works, it is OK to simply write these bits rather than use RMW operations.

< Watchdog Control

< Clear timer mask[3]

< Clear timer mask[1]

< Watchdog Control

< Clear timer mask[2]

< Clear timer mask[0]

Definition at line 123 of file watchdog-arch.c.

◆ watchdog_reboot()

void watchdog_reboot ( void )

Manually trigger a Watchdog timeout.

Keeps control until the WDT throws a reset signal.

Starts the WDT if not already started.

< Watchdog Control

< Interval Select mask

< Enable mask

Definition at line 147 of file watchdog-arch.c.

References watchdog_start().

◆ watchdog_start()

void watchdog_start ( void )

Start the Watchdog.

Starts the WDT in watchdog mode if enabled by user configuration, maximum interval.

< Watchdog Control

< Enable mask

Definition at line 112 of file watchdog-arch.c.

References watchdog_periodic().

◆ watchdog_stop()

void watchdog_stop ( void )

Stop the Watchdog such that it won't timeout and cause a system reset.

Stops the WDT such that it won't timeout and cause MCU reset.

Definition at line 136 of file watchdog-arch.c.