GR10-30 not working on ESP32: I2C pins cannot be defined

userHead PedroMartin 2023-07-23 21:45:34 225 Views2 Replies

I'm using a dev board with an ESP32­-PICO-­MINI-­02. The I2C pins on this dev board are SDA=22 and SCL=20

 

Even when specifying these I2C ports in line 48 of DFRobot_GR10_30.cpp: _pWire->begin(22,20); the board fails to initialize, presumably because the ESP32 can't find it on the I2C bus.

 

All works fine on an Arduino MKR WiFi 1010 whose I2C pins default to SDA=11, SCL=12

 

How can I define the I2C pins?

2023-07-23 22:12:57

Solved. It was a wiring problem. The sensor and its library work just fine.

userHeadPic PedroMartin
bidrohini.bidrohini wrote:

What was the solution? May I know?

2023-07-24 23:29:48
1 Replies