View previous topic :: View next topic |
Author |
Message |
HGHK
Joined: 29 Jun 2010 Posts: 33
|
I have problem to disable Watchdog Timer in sleeping |
Posted: Tue Sep 21, 2010 3:24 pm |
|
|
I use external INT for wake up and if WDT were on it makes INT to wake up! what must i do?
I use pic16f876 and cant turn WDT off. I need it to communicate processes and ADC after wake up. |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Sep 21, 2010 4:17 pm |
|
|
Quote: |
I use pic16f876 and cant turn WDT off. I need it to communicate
processes and ADC after wake up.
|
Watchdog Timer has nothing to do with communication. |
|
![](templates/subSilver/images/spacer.gif) |
HGHK
Joined: 29 Jun 2010 Posts: 33
|
Worry about Turn OFF WDT |
Posted: Wed Oct 06, 2010 5:14 am |
|
|
If I turn off WDT, then I2C, delay, usart are work or not? and tell me WDT take effect in what components in PIC16f876a?
Thanks ![Question](images/smiles/icon_question.gif) |
|
![](templates/subSilver/images/spacer.gif) |
Ttelmah
Joined: 11 Mar 2010 Posts: 19383
|
|
Posted: Wed Oct 06, 2010 7:36 am |
|
|
WDT, does not affect _any_ components.
It affects the whole _chip_.
It basically provides one function. If the wdt_restart is not called at regular intervals. it resets the chip. The 'point' is that if you are performing functions that must be serviced, and wish to potentially 'deal' with the situation where a particle traversing the chip accidentally makes it jump somewhere it shouldn't, or where an electrical spike again puts the chip into a state it should not reach, you write your code so that provided all things that should happen, do happen, it will reset the watchdog (and _only_ then), so that the chip will 'reset itself' if it is not running as it should.
Best Wishes |
|
![](templates/subSilver/images/spacer.gif) |
HGHK
Joined: 29 Jun 2010 Posts: 33
|
Worry about WDT |
Posted: Sun Oct 10, 2010 12:37 am |
|
|
I worry If I turn off WDT, then I2C, usart, sleep and delay are work or not? and tell me WDT take effect in what components in PIC16f876a? (for example if WDT were on effect in sleep and wake up occured)
Thanks |
|
![](templates/subSilver/images/spacer.gif) |
dyeatman
Joined: 06 Sep 2003 Posts: 1924 Location: Norman, OK
|
|
Posted: Sun Oct 10, 2010 5:46 am |
|
|
As was told to you twice earlier...NO..turning off WDT will not directly
affect ADC, I2C or the UART. Turning it off will also NOT keep the SLEEP
or DELAY functions from functioning normally.
However, WDT can be used to wake up from a sleep condition. If the
WDT is enabled when SLEEP is entered the WDT will wake the chip up
when it times out.
Turning off the WDT WILL affect the ability of the chip to recover from a
potential lockup condition due to coding errors or power instability!
Read the 16F876A DATASHEET section 14.13 on the WDT for more
information. Also, see the PIC MCU Midrange Family Reference Manual
Section 26.3 for a detailed explanation of WDT.
http://ww1.microchip.com/downloads/en/devicedoc/33023a.pdf _________________ Google and Forum Search are some of your best tools!!!! |
|
![](templates/subSilver/images/spacer.gif) |
HGHK
Joined: 29 Jun 2010 Posts: 33
|
Thanks |
Posted: Wed Oct 13, 2010 1:09 am |
|
|
Thanks for your guidance thanks a lot ![Cool](images/smiles/icon_cool.gif) |
|
![](templates/subSilver/images/spacer.gif) |
|