From 08ef60d436102a3502add158eb038462789f07f2 Mon Sep 17 00:00:00 2001 From: Michael du Breuil Date: Mon, 9 Jul 2018 22:31:08 -0700 Subject: [PATCH] AP_ADC: Remove unused AP_ADC class --- libraries/AP_ADC/AP_ADC.cpp | 21 ----------- libraries/AP_ADC/AP_ADC.h | 58 ------------------------------- libraries/AP_ADC/AP_ADC_ADS1115.h | 2 -- 3 files changed, 81 deletions(-) delete mode 100644 libraries/AP_ADC/AP_ADC.cpp delete mode 100644 libraries/AP_ADC/AP_ADC.h diff --git a/libraries/AP_ADC/AP_ADC.cpp b/libraries/AP_ADC/AP_ADC.cpp deleted file mode 100644 index 548dc64c9e..0000000000 --- a/libraries/AP_ADC/AP_ADC.cpp +++ /dev/null @@ -1,21 +0,0 @@ -/* - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . -*/ -/* - * ADC.cpp - Analog Digital Converter Base Class for Ardupilot Mega - * Code by James Goppert. DIYDrones.com - * - */ - -#include "AP_ADC.h" diff --git a/libraries/AP_ADC/AP_ADC.h b/libraries/AP_ADC/AP_ADC.h deleted file mode 100644 index d455a418cd..0000000000 --- a/libraries/AP_ADC/AP_ADC.h +++ /dev/null @@ -1,58 +0,0 @@ -#pragma once - -#include -/* - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - */ - -/* - * AP_ADC.cpp - Analog Digital Converter Base Class for Ardupilot Mega - * Code by James Goppert. DIYDrones.com - * - * Methods: - * Init() : Initialization of ADC. (interrupts etc) - * Ch(ch_num) : Return the ADC channel value - * Ch6(channel_numbers, result) : Return 6 ADC channel values - */ - -class AP_ADC -{ -public: - AP_ADC() { - }; // Constructor - virtual void Init() = 0; - - /* read one channel value */ - virtual float Ch(uint8_t ch_num) = 0; - - /* read 6 channels values as a set, used by IMU for 3 gyros - * and 3 accelerometeres. - * - * Pass in an array of 6 channel numbers and results are - * returned in result[] - * - * The function returns the amount of time (in microseconds) - * since the last call to Ch6(). - */ - virtual uint32_t Ch6(const uint8_t *channel_numbers, float *result) = 0; - - // check if Ch6() can return new data - virtual bool new_data_available(const uint8_t *channel_numbers) = 0; - - virtual uint16_t num_samples_available(const uint8_t *channel_numbers) = 0; - -private: -}; - -#include "AP_ADC_ADS1115.h" diff --git a/libraries/AP_ADC/AP_ADC_ADS1115.h b/libraries/AP_ADC/AP_ADC_ADS1115.h index 5eca42666b..6816280b68 100644 --- a/libraries/AP_ADC/AP_ADC_ADS1115.h +++ b/libraries/AP_ADC/AP_ADC_ADS1115.h @@ -4,8 +4,6 @@ #include #include -#include "AP_ADC.h" - struct adc_report_s { uint8_t id;