Dear Zhengsu,
First don't forget to enable the appropriate interrupt in ADC12IE.

Be sure to 'toggle' ENC bit of ADC12CTL0 within your ADC12 ISR to allow the
subsequent Timer A signals to trigger the next ADC12 conversion.  See
MSP430x1xx User Manual chapter (slau049d.pdf Rev D) section 17.2.6 ADC12
Conversion Modes paragraph Single-Channel Single-Conversion Mode 
"When any other trigger source is used, ENC must be toggled
between each conversion."  The same is also true for Sequence-of-Channels
Mode. 


Regards,
Brian Capoccia
Fluke Corporation

-----Original Message-----
From: mspgcc-users-ad...@lists.sourceforge.net
[mailto:mspgcc-users-ad...@lists.sourceforge.net]on Behalf Of Gao
Zhengsu
Sent: Wednesday, April 14, 2004 10:44 AM
To: mspgcc-users@lists.sourceforge.net
Subject: Re: [Mspgcc-users] About msp430x149


Hi,Mark 
        Thank you for your good way!!
        I read manual said that we can use TamerA OUTPUT UNIT1 to trigger
ADC12 
conversion like this

  TACTL = TASSEL_2+MC_2;                // Timer_A setup
  TACCTL1 = OUTMOD_3;                   // CCR1 setup
  TACCR1 = 0x0fff;                      // Compare value
  
  ADC12CTL0 = ADC12ON+SHT0_2;           // Turn on ADC12, set sampling time
  ADC12CTL1 = SHS_1+SHP;                // TAOUT.1 triggers sampling timer
    ADC12CTL0 |= ENC;                   // Enable conversions
    ADC12CTL0 |= ADC12SC;               // Start conversion

but this doen's work to my code , it never stop by ADC interrupt routine. 
What's the reason?
Thank you!
Regards
Zhengsu
 



-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
Mspgcc-users mailing list
Mspgcc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mspgcc-users

Reply via email to