Merge pull request #2027 from alignan/pull/fix-adc-channels

zoul: fix a bitmask bug in channels used
master-31012017
George Oikonomou 2017-01-09 21:02:20 +00:00 committed by GitHub
commit 14757201a5
1 changed files with 2 additions and 1 deletions

View File

@ -162,7 +162,8 @@ configure(int type, int value)
}
adc_init();
set_decimation_rate(SOC_ADC_ADCCON_DIV_512);
enabled_channels += value;
enabled_channels |= value;
PRINTF("ADC: enabled channels 0x%02X\n", enabled_channels);
break;
case ZOUL_SENSORS_CONFIGURE_TYPE_DECIMATION_RATE: