PinLab › Components › OLED display 0.96″ (SSD1306)
T: 23.4 C H: 48 % GNDVCCSCLSDA 0.96″ 128×64 I2C

OLED display 0.96″ (SSD1306)

128×64 pixels, I2C

A small monochrome display with excellent contrast. Write text, draw graphs, show sensor values. Only 4 wires.

Open the course →

How it works

It communicates over I2C — two lines: SDA (data) and SCL (clock). The ESP32 is the "master" and sends what to draw to address 0x3C. The Adafruit_SSD1306 library keeps a copy of the screen in memory (1 kB); you draw into it with print(), drawLine()… and finally call display() to show it.

Pins and wiring

PinWhat it isWhere it connects / why
GNDGround→ GND. WARNING: on some modules the order is VCC-GND-SCL-SDA — read the label on the board!
VCCPower→ 3V3 (the module has a regulator, tolerates 5 V too).
SCL (SCK)I2C clock→ GPIO 22 (default SCL on the ESP32).
SDAI2C data→ GPIO 21 (default SDA on the ESP32).

Specifications

Resolution128 × 64
Diagonal0.96″ (24 mm)
InterfaceI2C, address 0x3C (rarely 0x3D)
Power3.3 – 5 V, ~20 mA
Colourwhite, blue or yellow-blue
LibrariesAdafruit SSD1306 + Adafruit GFX

Tips and typical mistakes

Used in projects