Esp32-WROOM I2C problem

Hello,

I know that the issue was questioned several times, but either the solution doesn't solve my problem; either there was no solution at all...
I am desperatly trying to connect an ADS1115 on an ESP32 (WROOM).
I stay put at the I2C scanning step : no device is found.

I am using : the latest esp32 by espressif systems card softwares, and the basic Wire library included. (I tested serveral ADS1115 libraries, but it is not probably the cause.)
I have tried several versions of the software, custom Wire library.
I have also tried to change the usual pins on the ESP32 . (GPIO 21: SDA; GPIO 22 : SCL)
Of course, I have changed boards and ADS1115.
I put pull up resistors, without any additionnal success.

This is really frustrating; it seems like everbody can do it ... except me.
Do you have any clue ? Thanks !

My latest tests are based on this sketch

#include <Wire.h>
 
void setup() {
  Wire.begin();
  Serial.begin(115200);
  Serial.println("\nI2C Scanner");
    byte error, address;
  int nDevices;
  Serial.println("Scanning...");
  nDevices = 0;
  for(address = 1; address < 127; address++ ) {
    Wire.beginTransmission(address);
    error = Wire.endTransmission();
    if (error == 0) {
      Serial.print("I2C device found at address 0x");
      if (address<16) {
        Serial.print("0");
      }
      Serial.println(address,HEX);
      nDevices++;
    }
    else if (error==4) {
      Serial.print("Unknown error at address 0x");
      if (address<16) {
        Serial.print("0");
      }
      Serial.println(address,HEX);
    }    
  }
  if (nDevices == 0) {
    Serial.println("No I2C devices found\n");
  }
  else {
    Serial.println("done\n");
  }
  delay(5000);  
  Serial.print("i2c devices found:");
  Serial.println(nDevices); 
}
 
void loop() {
      
}

looking at the photo it appears that SCL is to D21 and SDA is to D22

1 Like

The pullup resistors do not appear to be tied to Vcc?

From the photo, it appears that you forgot to solder the header pins on the module.

Fix the problem by soldering them, carefully.

2 Likes

Hello
I forgot to switch back the SCL and SDA wires, before taking the photo.
This was one of my final tests before asking for help. Thanks for your answer

Hello,
It is through the right VCC and GND lines of the board.

Hello
I am not confident with my soldering skills for the moment. And I didn’t solder at all the card.
I read some other users were able to make it work without soldering … but I will try and get back to you as soon as I can find a proper soldering iron.
Thanks

That can work for a few moments, but more likely, intermittent power connections will destroy the module, the Arduino, or both.

It is not hard to solder if you have the proper tools, and they are not expensive. Practice with PCBs from discarded toys or other electronics.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.