Hi,
We have two versions of the same code (in assembler) running on an MSP430F2132, where one uses the watchdog timer in interval mode and the other timer A0 in continuous mode, to interrupt at a period of 15.625ms.
Both the watchdog and the timer are using the same reference clock and the registers divide the clock down to the same period.
The 15.625ms time is used to flash an LED once every second by counting 64 interrupts and then turning the LED on.
We have the ability to synchronize the two versions of the code (running at the same time on separate devices) so that the LEDs flash in unison with each other. However, over a period of 3 minutes, the two LED flashes drift apart and go out of sync with each other (this is noticeable by eye).
If we flash both devices with the same version of code (either both using the WDT or both using timer A0) then the LEDs stay in sync indefinitely.
The code inside the WDT interrupt and Timer A0 interrupts are almost identical. The only difference is that the timer A0 code adds the period onto its current CCR0 value to set up for the next interval.
If we reduce the timer CCR0 value by 2 counts (equivalent of 3.81us) then the two remain almost in sync (after 30 mins it becomes noticeable).
Do you know of any differences between the watchdog timer and timer A0 that would cause the timer period to be slightly slower than the watchdog. Such as time to service the interrupt.
Regards
Calex