2011-11-12 23:14:55 -04:00
|
|
|
|
|
|
|
#include "AP_AnalogSource_ADC.h"
|
|
|
|
|
2012-10-11 13:39:27 -03:00
|
|
|
float AP_ADC_AnalogSource::read() {
|
2011-12-16 16:18:29 -04:00
|
|
|
float fullscale = _adc->Ch(_ch);
|
|
|
|
float scaled = _prescale * fullscale;
|
2011-11-12 23:14:55 -04:00
|
|
|
return scaled;
|
|
|
|
}
|