-
Notifications
You must be signed in to change notification settings - Fork 7.7k
Open
Labels
Status: Awaiting triageIssue is waiting for triageIssue is waiting for triage
Description
Board
ESP32 C6
Device Description
Hello,
Please guide me on, How to connect SSD1306 OLED Display with ESP32 C6 Controller?
■ ESP32-C6 + OLED SSD1306 I²C Connection Issue
- Hardware in Use
- Microcontroller: ESP32-C6 DevKitC-1
- Display: 0.96" OLED Module (I²C, SSD1306, 128×64, 3.3V)
- Pins Used:
- SDA → GPIO 6 (LP_I2C_SDA)
- SCL → GPIO 7 (LP_I2C_SCL)
- VCC → 3.3V
- GND → GND
- The Problem
- The OLED does not respond on the I²C bus.
- The serial monitor repeatedly shows:
■ No I2C devices found
E (xxxx) i2c.master: I2C transaction unexpected NACK detected - I²C scanners detect no devices at 0x3C or 0x3D, even though the OLED should use one of these.
- The OLED module has a 472 resistor (≈4.7kΩ), which may be a pull-up or address selector.
Hardware Configuration
- SDA → GPIO 6 (LP_I2C_SDA)
- SCL → GPIO 7 (LP_I2C_SCL)
- VCC → 3.3V
- GND → GND
Version
latest stable Release (if not listed below)
Type
Task
IDE Name
Arduino IDE
Operating System
Windows 11 Pro
Flash frequency
80 MHz
PSRAM enabled
yes
Upload speed
115200
Description
Connection issue
Sketch
#include <Wire.h>
#define SDA_PIN 6 // ESP32-C6 LP_I2C_SDA
#define SCL_PIN 7 // ESP32-C6 LP_I2C_SCL
void setup() {
Serial.begin(115200);
delay(2000);
Serial.println("\n■ ESP32-C6 I2C Scanner (SDA=5, SCL=6)");
Wire.begin(SDA_PIN, SCL_PIN, 100000); // 100kHz
}
void loop() {
byte error, address;
int nDevices = 0;
Serial.println("Scanning...");
for (address = 1; address < 127; address++) {
Wire.beginTransmission(address);
error = Wire.endTransmission();
if (error == 0) {
Serial.print("■ I2C device found at 0x");
if (address < 16) Serial.print("0");
Serial.println(address, HEX);
nDevices++;
}
else if (error == 4) {
Serial.print("■ Unknown error at 0x");
if (address < 16) Serial.print("0");
Serial.println(address, HEX);
}
}
if (nDevices == 0)
Serial.println("■ No I2C devices found\n");
delay(2000);
}
Debug Message
No I2C devices found
Other Steps to Reproduce
No response
I have checked existing issues, online documentation and the Troubleshooting Guide
- I confirm I have checked existing issues, online documentation and Troubleshooting guide.
Metadata
Metadata
Assignees
Labels
Status: Awaiting triageIssue is waiting for triageIssue is waiting for triage