我想用定时器触发ADC12转换,根据数据手册所说
ADC12SHS位为01时可以有TA1触发,代码如下
ADC12CTL0 = ADC12ON+ADC12SHT0_4 + ADC12REFON + ADC12REF2_5V;
ADC12CTL1 = ADC12SHP+ADC12CONSEQ_0 + ADC12SHS_1;
ADC12IE = 0x01;
ADC12CTL0 |= ADC12ENC;
TA1CCTL0= CCIE + CCIS_1; // CCR0 interrupt enabled
TA1CCR0 = 30;
TA1CCR1 = 20;
TA1CTL = TASSEL_2 + MC_1 + TACLR;
我这样配置后不能触发ADC12开始转换,请问是否有相关示例代码提供?

