| 7 | } |
| 8 | |
| 9 | void BARO_Sensor::start() { |
| 10 | if (available) { |
| 11 | return; |
| 12 | } |
| 13 | |
| 14 | Wire1.begin(); // Call if neccessary |
| 15 | |
| 16 | if (Baro->begin(BMP280_ADDRESS_ALT, BMP280_CHIPID)) { |
| 17 | available = true; |
| 18 | Baro->setSampling(Adafruit_BMP280::MODE_NORMAL, |
| 19 | Adafruit_BMP280::SAMPLING_X2, |
| 20 | Adafruit_BMP280::SAMPLING_X1, |
| 21 | Adafruit_BMP280::FILTER_OFF, |
| 22 | Adafruit_BMP280::STANDBY_MS_1); |
| 23 | } |
| 24 | } |
| 25 | |
| 26 | void BARO_Sensor::end() { |
| 27 | if (!available) { |
nothing calls this directly
no test coverage detected