In the Help file section entitled "More on Variables and Constants," the usual candidates are mentioned (TRUE, FALSE, etc.). Here are three more named constants which could be added to that list for completeness:
OSC = 1
EXT = 2
EXTOSC = 3
These are defined in TIMER.H and used by the InitTimer0 command, for instance.
For that matter, the prescaler constants are also defined in the file just mentioned. Which brings up another matter. In the Help file entry on InitTimer0, the description states that the form of the constant is PS_2, for instance. (The format is similar for the other prescalers.) But then in the sample code, the format PS_1/2 is used.
In fact, either format is acceptable to the compiler. But perhaps it is confusing to newcomers to describe one, then use the other in the sample without explaining that.
Added to May 2014 Help Filehanks for the information/correction.
This is now in the latest revision of the help file.
Log in to post a comment.