void main(void)
{
WDTCTL = WDTPW + WDTHOLD; // Stop WDT
Init_Clk();
TA1CTL |= TASSEL_1+TACLR+TAIE; // ACLK, clear TAR // P1.0 output
TA1CTL |= MC1; // 连续计数模式
TA1CCTL1 |= CCIE;
TA1CCTL2 |= CCIE;
_EINT(); // Enable interrupts
for (;;)
{
// _BIS_SR(LPM3_bits); // Enter LPM3
_NOP(); // Required only for C-spy
}
} |