Page 1 of 1
TMR1 and 12F1840
Posted: Thu Dec 08, 2011 1:11 pm
by Jan Lichtenbelt
Using timer1 with 12F1840 gives and error that the Timer1 Clock Source Selection bit TMR1CS in Timer1 Control Register T1CON is an unknown identifier.
What to do?
Jan Lichtenbelt
Re: TMR1 and 12F1840
Posted: Thu Dec 08, 2011 2:24 pm
by Benj
Hi Jan,
Here is an updated FCD file.
Let me know how you get on.
Re: TMR1 and 12F1840
Posted: Thu Dec 08, 2011 2:32 pm
by Jan Lichtenbelt
Hi Ben,
Thanks, this one works correctly.
Jan
PS. TMR1CS has been replaced by TMR1CS1
Re: TMR1 and 12F1840
Posted: Wed Dec 21, 2011 5:37 pm
by Jan Lichtenbelt
I still have problems, even with the new FDC file (using Flowcode V4.5)
The Timer1 does not work and I do not know why. But I solved the problem with an additional C-code t1con=0x01; directly after the enable macro. This enables the Timer1, with precsaler 1:1 ansd clock source Fosc/4. If you need other prescaler values or trigger on external pin, see datasheet chapter 21.11.
Kind regards,
Jan Lichtenbelt