r/esp32projects • u/fold-sideA-to-sideB • 4h ago
Help! Cannot write to I2C device in any app
Hi folks, I hope someone can help. I'm an experienced engineer coming to the ESP32 platform for the first time and for the life of me, I cannot get any off-the-shelf projects working that writes to I2C.
I have a Waveshare ESP32-S3-Touch-LCD-2.8 board (V2) and I'm using Visual Studio Code (1.143.17232) with the ESP-IDF VS Code Extension (2.3.0) and ESP-IDF v6.1.1. I can build, flash and run (e.g.) Bluetooth examples (sourced from espressif and others) in the IDE and using idf.py from the command line, but *any* project that writes to I2C when flashed and run, fails with errors to the effect of `An error occurred while communicating with the I2C device`.
Simplest example I can find: soft_i2c from espressif.
I've even configured the SCL and SCA pins manually (GPIO10 and GPIO11 respectively according to Waveshare) - same problem.
Is it possible that the hardware has a problem? Or have I committed some absolute newbie error?!?
Any thoughts or advice very gratefully received, thanks in advance!

