I'm interested in build one chronometer to count from 0,001s to 9,999s
The input of the system is one interrupt in one PIC microcontroller.
My questions:
- Why normally in the RTC the people use one crystal of 32,768KHz ?
- If I use one external crystal of 32,768KHz in one timer, I have one resolution of 0.000305 seconds that is very suitable for my application.
- I'm going to get a better result if I use the Main Oscillator 20MHz uC?
32768Hz is chosen because a 15 bit binary counter divides it to exactly 1 second. It is not the best choice if you want 1ms resolution. You may want a higher speed clock for the software anyway.
Using a higher clock will let you do more - ie. have more room for procedures between the 'ticks' of the chronometer. Normally, the highest you can use is the one you should use. You should be able to achieve better precision with a higher clock, if you write the code right.