ahgan84 0 Posted October 3, 2011 Share Posted October 3, 2011 Hi guys, I know that the INCHx in ADC10CTL1 is for selecting the channel for the ADC. Is it selecting a single channel only at a time? How am I select like from A0 to A7 which is 8 channel at a time? And by the way, does 'channel' means the input pin? Is one channel means one of the input pins like for example A0? Quote Link to post Share on other sites
xpg 127 Posted October 3, 2011 Share Posted October 3, 2011 Hi guys,I know that the INCHx in ADC10CTL1 is for selecting the channel for the ADC. Is it selecting a single channel only at a time? How am I select like from A0 to A7 which is 8 channel at a time? You cannot as such perform multiple ADC conversion at the same time. What you can do is to do the conversion right after each other, which for many cases will be roughly "at the same time". The ADC10 and ADC12 (depending on your device) of the MSP430s have a sequence-of-channel sampling mode where it samples multiple channels in a sequence. And by the way, does 'channel' means the input pin? Is one channel means one of the input pins like for example A0? A "channel" can be an input pin, but it can also be internal things like the temperature sensor. The following list is obtained from the User's Guide (the numbers being binary representation of the channel number): 0000 A0 0001 A1 0010 A2 0011 A3 0100 A4 0101 A5 0110 A6 0111 A7 1000 VeREF+ 1001 VREF-/VeREF- 1010 Temperature sensor 1011 (VCC - VSS) / 2 1100 (VCC - VSS) / 2, A12 on MSP430x22xx devices 1101 (VCC - VSS) / 2, A13 on MSP430x22xx devices 1110 (VCC - VSS) / 2, A14 on MSP430x22xx devices 1111 (VCC - VSS) / 2, A15 on MSP430x22xx devices A0-A7 are external source meaning that they are input pins. The rest are internal. Hope this helps somewhat. /Paul bluehash 1 Quote Link to post Share on other sites
ahgan84 0 Posted October 3, 2011 Author Share Posted October 3, 2011 I see. Is it by selecting CONSEQ1 which is 'sequence of channels'? Then if I put INCH7, that means my input that I select will be from A0 to A7. Am I right? Quote Link to post Share on other sites
xpg 127 Posted October 3, 2011 Share Posted October 3, 2011 I see.Is it by selecting CONSEQ1 which is 'sequence of channels'? Then if I put INCH7, that means my input that I select will be from A0 to A7. Am I right? Correct, though in the opposite order (A7, then A6 down until A0). /Paul ahgan84 1 Quote Link to post Share on other sites
ahgan84 0 Posted October 6, 2011 Author Share Posted October 6, 2011 OK. Thanks sir. I got another question regarding ADC12. From ADC12SREFx register, we have to set the reference voltage. Could you guys explain the purpose of reference voltage? And how to choose between AVcc, internal voltage reference Vref+ or external voltage reference Veref+? Quote Link to post Share on other sites
gwdeveloper 275 Posted October 6, 2011 Share Posted October 6, 2011 Reference voltage = "the largest signal the ADC is to convert for comparisons" http://en.wikipedia.org/wiki/Analog-to-digital_converter ahgan84 1 Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.