
Originally Posted by
xnihilo
Reseting the TMR0 ovf flag and the TMR0 preload value before leaving handler and checking what int flag are set upon entering the int handler did the trick.
More funny, the int period is now all right (about 10ms)... What is strange is that I did not change a lot of things besides setting the preload for TMR0 before leaving the int handler...
Skimask: yes, the code comments were a bit wrong I agree.
RESUME, ENABLE. I changed the comments in my program

As you may have noticed I'm not very strict when I write my code and my comments. I should be more cautious because other people may/will read and use the code...
My brother always tells me that my code is a mess... He's right
This forum is such a great place.
I have to reference it in my code so people reading it will know that if I could finish my projects it is because many people on this forum guided me and even sometimes gave me the answers.
Cool forum!
More Importantly, You will come back to your code, long after you have forgotten the details
and will have to wade through it and try to remember . . . whereas, properly commented code will be easy, sensible, and readable. Spend a little time now or a lot later.
Happy you got it working! Zot! Tag, you're it!
If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
.
Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
.
There simply is no "Happy Spam" If you do it you will disappear from this forum.
Bookmarks