Just make sure that all register match from one to another. Sometimes, some specific bits on a device are not located at the same place on another one.
If you don't mind, post your code here.
Just make sure that all register match from one to another. Sometimes, some specific bits on a device are not located at the same place on another one.
If you don't mind, post your code here.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Thanks Steve. One interesting thing is the beginning of the program runs slow - delays that are supposed to last only 1/2 second take 2 seconds to complete. I was able to eliminate this by changing the Watchdog Postscaler from it's default of 1:128 to 1:8. However, later in the program there are delays that are supposed to last up to 6 seconds but finish in about 4-1/2 seconds. Any ideas?? - Thank you.
I didn't check the datasheet but, are you using the internal OSC (if there's) ?
try the eternal Led Blink first and post your observations here.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Hi Steve. The circuit uses a 4MHZ ceramic resonator. Again, the 16F76 worked perfectly until I compiled it for 18F2510. I must be missing something???
Weird,
your ADCON setting is good, the comparator are off at POR... so...
Any way to post your config fuses setting here?
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
What is so weird is that both delays are implemented the same way using the pause command. Changing the Watchdog Postscaler from 1:128 to 1:8 speeds-up one but not the other. The timers are basically like this:
timer:
pause 60
let x = x + 1
if x >= 100 then blahblah
goto timer
This 6 second routine is exactly 6 seconds with the 16F76 but is about 4-1/2 with the 18F2510. Changing the Watchdog Postscaler has no effect on this one. Now this 500 MS routine takes 2 seconds and speeds-up to 500 MS with the Postscaler set to 1:8:
if porta.5 = 0 then pause 500 : goto start
I was hoping I was missing something (never used an 18F before). But it looks like it's time to order some new PIC's (I only have 1) I was driven crazy 2 times before by what turned out to be a bad PIC. It's that time of year here when everytime you touch a doorknob you get a shock. Maybe I toasted it. Thanks for the help everybody.
Bookmarks