30.3.1 Initialization
The following steps are recommended to initialize the SWDT for basic operation:
- Configure the Reset Value of the SWDT by writing to the RESET register
- Configure the WINDOW register. As shown in the block diagram above, this value is compared with CNT to determine when the window is open for clearing the counter.
- Enable the SWDT by simultaneously writing a
‘
1
’ to the ENABLE bit and either a ‘0
’ or a ‘1
’ to the MODE selection bit (to choose count mode) in the CTRLA register