This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

NRF51822 WDT Cycle

#if (WDT_ENABLED == 1)

#define WDT_CONFIG_BEHAVIOUR     NRF_WDT_BEHAVIOUR_RUN_SLEEP

#define WDT_CONFIG_RELOAD_VALUE  (2000)

#define WDT_CONFIG_IRQ_PRIORITY  APP_IRQ_PRIORITY_HIGH

#endif

In NRF51822 SDK11.0.0, What is the maximum value of WDT_CONFIG_RELOAD_VALUE? Thanks!

  • Hi,

    The reload value is given by the CRV register, and from the product specification it is stated that the valid value is between 0x0000000F and 0xFFFFFFFF. You can see form the nrf_drv_wdt_init() implementation that the value written to the register is 

    (p_config->reload_value * 32768) / 1000

    and here reload_value is typically WDT_CONFIG_RELOAD_VALUE. Therefor the maximum value of WDT_CONFIG_RELOAD_VALUE is 

    floor((0xFFFFFFFF*1000)/32768) = 131071999

Related