Dear Group:
We have a Freescale MC9S08SH8 data sheet: http://www.mouser.com/ds/2/302/MC9S08SH8-783274.pdf
We're on the Freescale Demo Board DEMO9S08SH8/SG8 user guide: http://www.nxp.com/assets/documents/data/en/user-guides/DEMO9S08SH8UG.pdf
Using Codewarrior v10.6
We are using an external crystal oscillator with the RTC. We can not seem to figure out the code to get the two in harmony.
Our code is as follows:
// Use external clock (32.768kHz crystal), based on table 13-3
RTCMOD = 0b00100000; // 32 (32*31.25ms=1s)
RTCSC = 0b00110111; // CS=ERCLK, RTIE, PS=0111 (/1024=31.25ms)
Crystal oscillator circuit has been designed per Appendix B of the data sheet and connected to the demo board header at XTAL & EXTAL.
We can get the RTC to trigger an interrupt and blink an LED when we use the 1kHz low power oscillator, but not when we use the crystal.
What are we missing?
Many thanks in advance.
We have a Freescale MC9S08SH8 data sheet: http://www.mouser.com/ds/2/302/MC9S08SH8-783274.pdf
We're on the Freescale Demo Board DEMO9S08SH8/SG8 user guide: http://www.nxp.com/assets/documents/data/en/user-guides/DEMO9S08SH8UG.pdf
Using Codewarrior v10.6
We are using an external crystal oscillator with the RTC. We can not seem to figure out the code to get the two in harmony.
Our code is as follows:
// Use external clock (32.768kHz crystal), based on table 13-3
RTCMOD = 0b00100000; // 32 (32*31.25ms=1s)
RTCSC = 0b00110111; // CS=ERCLK, RTIE, PS=0111 (/1024=31.25ms)
Crystal oscillator circuit has been designed per Appendix B of the data sheet and connected to the demo board header at XTAL & EXTAL.
We can get the RTC to trigger an interrupt and blink an LED when we use the 1kHz low power oscillator, but not when we use the crystal.
What are we missing?
Many thanks in advance.