I'm using a ICD2 compiler.
He're is the hex file
OK i got the same problem here. Are you using the same code as in POST #1 ???
One thing is sure, if i disable the Watchdog timer, it works...
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
That's why I asked 'Does it show ">Start<" every 2 seconds out the serial port'...
In the picture posted earlier with all the fuses shown, the WDT prescaler is set to 1:128 and Enabled.
(Yesterday when I asked the question about the 2 seconds, I had the math worked out and it came up to about 2 seconds (give or take)...
Tonight when I do the math, I only get 1/2 second...I musta been drunk or something)
So you guys say shut down the watchdog timer. How can i do this?
Can this be the reason that a other microprocessor board with same config and same sort of simple program hangs after a few days.
1 - Reopen the same program you opened in Post #5 (MPLAB IDE)
2 - Left-Click on the 'Configure' menu
3 - Further click on 'Configuration Bits'
4 - Press the down arrow on your keyboard 10 times
5 - By now you should have '300003 1F Watchdog Timer Enabled' selected
6 - Left-Click on the line that is now highlighted
7 - Left-Click on the drop-down menu that appears
8 - Left-Click on the words 'Disabled-Controlled by SWDTEN bit'
2nd question - it's possible...
Or you could turn up your WDT post-scaler.
Last edited by skimask; - 9th May 2007 at 08:50.
Yeah... but, from what i suppose, PBP have to take care of the watch dog... maybe 2.47 fixed it.
Anyways, i'm doing cofee here, i will try the original code with WatchDog enabled. i think i already did it here... but curiosity...
EDIT:
interesting;----- CONFIG2H Options --------------------------------------------------
_WDT_OFF_2H EQU H'FE' ; HW Disabled - SW Controlled
_WDT_ON_2H EQU H'FF' ; HW Enabled - SW Disabled
Last edited by mister_e; - 9th May 2007 at 13:56.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Why not just addinside the tight loop?Code:CLEARWDT
Paul Borgmeier
Salt Lake City, UT
USA
__________________
Find your .lst file for this program. Search for the:
Main:
High Relais1
Goto Main:
block and see if there is a CLEARWDT in the middle of the loop. If not, then do like Paul said and add a CLEARWDT in the middle of the loop in your source file. That should fix it without having to mess with the config settings.
And which version of PBP are you using? Maybe that's got something to do with the problem...
well.. unless you really want to use the Watch-dog features, just disable it.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Bookmarks