Hello everyone,
I'm currently working with the capacitive touch library on an MSP430FR5989. So far I got everything to work (with some help of this forum) but there is one thing left that's bugging me:
If I use SMCLK as clock source for the gate timer (in my case TA0) everything works as expected, and i can pick any number of accumulation cycles and any clock divider. But if I try to use ACLK, I have to pick incredible high numbers of accumulation cycles in order to make it work. way higher than I actually want. If there are too few cycles the MSP will simply reset, putting 0x000A in SYSRSTIV, somewhere between entering LPM3 and leaving it again in the RO_PINOSC_HAL() function in CTS_HAL.c .
Additional info that might help solve this puzzle:
-ACLK is sourced by an external crystal, running at 32.768kHz.
-SMCLK is sourced by the DCO, running at 16MHz
-I am using ACLK and LPM3 to make the main loop run once a second, so LPM3 with ACLK works with Capio disabled.
-The resetting occurs with and without JTAG connection.
-The minimum number of accumulation cycles that works is 20000. Or 5000 with a timer predivider of 4, so not the number, but the actual time matters.
I really want to use the LPM3 during measurement, as I need the power consumption to be as low as possible.
Any help would be greatly appreciated.
Best Regards,
Andreas