<< Chapter < Page Chapter >> Page >
Explains how to use the MSP430 analog-to-digital converter (ADC).

The analog to digital converter (ADC) on the ez430 is a type called a Sigma-Delta (SD) Converter. The way it operates is slightly different from what was described in the previous section (although the end result is the same) but those specifics are out of the scope of this course. The SD converter on the ez430 has 8 channels and a 16 bit resolution. The module is highly configurable and can run largely free of program involvement. In this portion of the lab, we will broadly explain the features of the module, but the particular effects of each register are listed, as usual, in Chapter 12 of the User’s Guide .

Range of measurement

The result of each conversion will be 16 bits long in the form of an unsigned integer whose value is:

SD16_MEMx (65,536) Vin Vrneg Vrpos Vrneg
Where Vin is the input voltage to be measured, Vrneg is the lower reference voltage, and Vrpos is the higher reference voltage. The reference voltages are set to power and ground by default, but they can be changed to an internal reference generator or an externally supplied reference using the SD16CTL register.

Input channels for the adc

The following is a table of the 8 input channels on the ez430. "Analog signal input" channels will take any analog source (we will get to the pin mapping's shortly). Other channels perform specific tool integrated tasks. For example, channel A6 is an integrated temperature sensor. For detailed descriptions of the others, see the User's Guide .

    Sd16 input channels

  • A0 : Analog signal input
  • A1 : Analog signal input
  • A2 : Analog signal input
  • A3 : Analog signal input
  • A4 : Analog signal input
  • A5 : Vcc Vss 11
  • A6 : Integrated temperature sensor
  • A7 : Short for PGA offset measurement
Here is a pin diagram corresponding to the 14 accessible pins showing which pins correspond to which input channels. Notice that each channel has a "+" and a "-" input. Although with other ADC's, we would simply have one input pin and connect the other to the ground, the SD converter requires us to connect the positive and negative inputs to the corresponding input channels. Note that the numbers from 1-14 on the chip correspond to pins 1-14 on the target board.

Pin map

Shows which pins correspond to specific SD converter inputs. Also shows which pins correspond to specific ports (i.e pin 4 is connected to P1.2).

Operation reminders for the adc

Remember the following when attempting to use the ADC:

  • Be sure to enable SD16 interrupts (on SD16CCTL0 ) and to select the specific channel which you are using (on SD16INCTL )
  • After configuring the ADC, you must enable the SD16SC bit to start conversion.
  • All ADC values will be stored in the SD16MEMx variable where "x" is the number of the channel
The User's Guide will be very useful for this lab because of the complexity of this part of the MSP430. Be sure to go over the chapter atleast briefly before jumping into programming.

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, Introduction to the texas instruments ez430. OpenStax CNX. Jun 19, 2006 Download for free at http://cnx.org/content/col10354/1.6
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Introduction to the texas instruments ez430' conversation and receive update notifications?

Ask