AP_HAL_Linux: AnalogIn_ADS1115: return 5V on board_voltage

board voltage is not available - don't return 0V since that prevents
arming.
This commit is contained in:
Lucas De Marchi 2016-07-28 11:00:36 -03:00
parent 59135fc615
commit 47d2f8dc6d

View File

@ -25,14 +25,13 @@ private:
class AnalogIn_ADS1115: public AP_HAL::AnalogIn {
public:
AnalogIn_ADS1115();
void init();
AP_HAL::AnalogSource* channel(int16_t n);
void init() override;
AP_HAL::AnalogSource *channel(int16_t n) override;
/* Board voltage is not available */
float board_voltage(void)
{
return 0.0f;
}
float board_voltage() override { return 5.0f; }
private:
uint8_t _channels_number;
void _update();