Sam Price started a new discussion on bsps/riscv/esp32/start/bspstart.c: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1555#note_161775 > + * field before any other register of the same watchdog timer can be > + * changed." > + * > + * Each watchdog has its own write-key field, and the value is the same for > + * all of them: > + * > + * Register 11.17, TIMG_WDTWPROTECT_REG (0x0064), page 300: > + * "TIMG_WDT_WKEY If the register contains a different value than its > + * reset value, write protection is enabled." Its reset value is > + * 0x50d83aa1. > + * > + * Register 9.37, RTC_CNTL_WDTWPROTECT_REG (0x00A8), page 254: > + * "RTC_CNTL_WDT_WKEY If the register contains a different value than > + * 0x50d83aa1, write protection for the RTC watchdog (RWDT) is enabled." > + */ > +#define WDT_WKEY_VALUE 0x50d83aa1U **Reference code for the key value.** ESP-IDF unlocks both digital watchdogs with this value: - Timer group watchdog: [`mwdt_ll_write_protect_disable()`](https://github.com/espressif/esp-idf/blob/0e6b480f858c69862ffb6001d96e9eef74599a6e/components/esp_hal_wdt/esp32c3/include/hal/mwdt_ll.h#L241-L244) writes `0x50D83AA1` to `wdtwprotect.wdt_wkey`. - RTC watchdog: [`RTC_CNTL_WDT_WKEY_VALUE`](https://github.com/espressif/esp-idf/blob/0e6b480f858c69862ffb6001d96e9eef74599a6e/components/esp_hal_wdt/esp32c3/include/hal/rwdt_ll.h#L24) is `0x50D83AA1`, and [`rwdt_ll_write_protect_disable()`](https://github.com/espressif/esp-idf/blob/0e6b480f858c69862ffb6001d96e9eef74599a6e/components/esp_hal_wdt/esp32c3/include/hal/rwdt_ll.h#L283-L286) writes it to `wdt_wprotect`. -- View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1555#note_161775 You're receiving this email because of your account on gitlab.rtems.org. Unsubscribe from this thread: https://gitlab.rtems.org/-/namespace/49/sent_notifications/6-8svw4xdtvio8htmn48csdl5jn-1d/unsubscribe | Manage all notifications: https://gitlab.rtems.org/-/profile/notifications | Help: https://gitlab.rtems.org/help
_______________________________________________ bugs mailing list [email protected] http://lists.rtems.org/mailman/listinfo/bugs
