Added explicit ADC channel masks for the standard set of ADC channels, as the single-ended channel MUX masks are not equal to the channel number on some AVR models. Changed demos to use the new channel masks when using the ADC driver.

This commit is contained in:
Dean Camera 2010-01-25 00:52:45 +00:00
parent 871d9bf1af
commit b68f7f1649
11 changed files with 116 additions and 12 deletions

View file

@ -52,6 +52,9 @@
/* Macros: */
/** ADC channel number for the microphone input. */
#define MIC_IN_ADC_CHANNEL 2
/** ADC channel MUX mask for the microphone input. */
#define MIC_IN_ADC_MUX_MASK ADC_CHANNEL2
/** Maximum ADC sample value for the microphone input. */
#define SAMPLE_MAX_RANGE 0xFFFF