|
Re: PIC 18F2431
Quote:
|
Originally Posted by Sparks333
...Yes, I am fully aware it's not good programming practice to set option registers in the main loop, but it should work...
...What does happen is if I initialize CAP1BUF to anything, it will always be that something, and never change...
|
Dane,
Absolutely, definitely change the initialization to be done once and once only.
As an example, you are setting CAP1BUF to zero every time through the loop. Except for a brief microsecond or two, why would it ever be anything else?
Mike
__________________
Mike Betts
Alumnus, Team 3518, Panthrobots, 2011
Alumnus, Team 177, Bobcat Robotics, 1995 - 2010
LRI, Connecticut Regional, 2007-2010
LRI, WPI Regional, 2009 - 2010
RI, South Florida Regional, 2012 - 2013
As easy as 355/113...
|