-
Notifications
You must be signed in to change notification settings - Fork 7.6k
ESP32 I2C not setting up #462
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
try to register the I2C by passing the pins: If it still loop within the Wire.begin(...) - try to add 10k pull-ups on SDA and SCL lines. |
Thanks, I did that and it was at least getting initialized. But, I think, the readings are probably some garbage values. Any suggestions? The serial output after adding pull ups -
|
void setup() { |
Hello,
I am using an ADXL345 sensor with ESP32 on Arduino IDE (1.8.1) The issue I am facing is I2C is not being initialized on the Sparkfun ESP32 Thing.
I used the following pins for I2C on ESP32
# SDA - Pin 21
# SCL - Pin 22
I have tried the same code with ESP8266 (NodeMCU 1.0) and it works just fine without any issues.
I have also attached the code and if anyone could explain to me why this is happening, it'd be great!
Thanks!
Code:
Serial Output:
The text was updated successfully, but these errors were encountered: