Watch Dog Timer (wdt), 12F683 nanowatt prescalar setting
Posted: Thu Jul 21, 2005 10:16 am
Just started playing with the watch dog timer on the 12F683. Data sheet says the time out can be set between 1ms and 268 seconds. Is this a typo? Has anyone ever used such a long time out in a product? Is WDTCON the only register needed to be modified or is there something else?
languer
Joined: 09 Jan 2004 Posts: 144 Location: USA
Posted: Thu Jul 21, 2005 1:11 pm
Never used this feature on the chip, but after reading the datasheet it should be possible.
Referring to Figure 12-9. The WDT will use the LFINTOSC (31kHz) as reference. From there it goes through a 16-bit Prescaler (÷32 through ÷65536), and can further be routed through a 7-bit prescaler (÷1 through ÷128) shared with TMR0 (8-bit if used for TMR0). So you could have a maximum divisor of 8388608 (23-bit) - pretty nifty.
Registers used (all summarized in Table 12-8):
WDTCON.7-0
OPTION.3-0 -> PSA, PS2, PS1, PS0
CONFIG.3
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum