On 2/23/07, Rikard Bosnjakovic wrote: > I read about this (and some other crystal-based text) in my PIC-book, > but what I cannot understand is why a 32768Hz-crystal is magical > enough to use for clock-applications. Dividing 32768 with 4 gives me > 8192, and that's a value that I certainly don't connect with anything > that's got to do with timing. 2^16 = 65536. 2^15 = 32768. Timer1 in PICs is a 16 bit timer which can be driven by an external source, in this case a 32768 Hz crystal. Preloading the timer1 high register with 0x80 (set the 7th bit), and running the timer will overflow after 32768 cycles. Configure an interrupt on overflow and you get an interrupt every 1 second. -Scott -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist