[Libs] Avoid using Wire.begin()

This commit is contained in:
Ton Huisman
2025-02-10 23:28:40 +01:00
parent 22b02d74b9
commit 26c9fa8a5d
5 changed files with 7 additions and 7 deletions
@@ -82,7 +82,7 @@ void Sodaq_UBlox_GPS::resetValues()
void Sodaq_UBlox_GPS::init(int8_t enable_pin)
{
_enablePin = enable_pin;
Wire.begin();
// Wire.begin(); ESPEasy has already taken care of this
digitalWrite(_enablePin, GPS_ENABLE_OFF);
pinMode(_enablePin, OUTPUT);
}
@@ -82,7 +82,7 @@ void Sodaq_UBlox_GPS::resetValues()
void Sodaq_UBlox_GPS::init(int8_t enable_pin)
{
_enablePin = enable_pin;
Wire.begin();
// Wire.begin(); ESPEasy has already taken care of this
digitalWrite(_enablePin, GPS_ENABLE_OFF);
pinMode(_enablePin, OUTPUT);
}
@@ -55,9 +55,9 @@ ADXL345::ADXL345(int CS) {
}
void ADXL345::powerOn() {
if (I2C) {
Wire.begin(); // If in I2C Mode Only
}
// if (I2C) {
// Wire.begin(); // If in I2C Mode Only ESPEasy has already taken care of this
// }
// ADXL345 TURN ON
writeTo(ADXL345_POWER_CTL, 0); // Wakeup
+1 -1
View File
@@ -8,7 +8,7 @@
_scl(scl) {}
bool SH1106Wire::connect() {
Wire.begin(this->_sda, this->_scl);
// Wire.begin(this->_sda, this->_scl); // ESPEasy already has Wire initialized properly
return true;
}
+1 -1
View File
@@ -8,7 +8,7 @@
}
bool SSD1306Wire::connect() {
Wire.begin(this->_sda, this->_scl);
// Wire.begin(this->_sda, this->_scl); // ESPEasy already has Wire initialized properly
return true;
}