Searching \ for 'Timer 1 on the DS30F' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page:
Search entire site for: 'Timer 1 on the DS30F'.

Truncated match.
PICList Thread
'Timer 1 on the DS30F'
2005\08\23@202614 by John Nall

picon face
I think that I am beginning to get the hang of how the timers work on
the ds30F, and would greatly appreciate it if someone would confirm my
thinking.  (If I am wrong on any or all points, please let me know).  I
am going to only talk with reference to Timer1, although some of these
things are general.

1.  TMR1, the timer register, begins incrementing once the timer has
been enabled (by setting bit TON in T1CON).  It increments once for each
instruction cycle (unless prescaled).

2.  If a value is entered into PR1, (the period register) then when TMR1
reaches the value that is in PR1 it will trigger a Timer1  interrupt,
provided that the interrupt control bit (T1IE) in IFS0 has been set.  
One presumes that most likely TMR1 is incremented before checking, so
that if PR1 starts out as zero then the interupt will not occur until
65535 instruction cycles have passed.

3.  Bit T1IF of IFS0 is set by the action of the value in TMR1 reaching
the value in PR1.

Does that seem to be correct?  I am looking at sample code in the
Microchip Family Reference Manual, but now you guys have me convinced
that I have to take that with a grain of salt.  :-(


More... (looser matching)
- Last day of these posts
- In 2005 , 2006 only
- Today
- New search...