شحن مجاني للأوردرات فوق
1000 ج
رمضان كريم
High-Contrast Display Solution for Arduino and ESP Projects
The 0.96″ OLED display module is a popular, low-power display solution featuring a 128×64 pixel resolution with crisp white, blue, or yellow pixels on a black background. These displays use SSD1306 or SH1106 drivers and communicate via I2C or SPI interfaces.

Consumes only 0.04W during operation
16:1 contrast ratio for excellent readability
27.3mm × 27.8mm module dimensions
GDDRAM for display data storage
| Display Type | OLED (Organic LED) |
|---|---|
| Resolution | 128 × 64 pixels |
| Driver IC | SSD1306 or SH1106 |
| Interface | I2C (default) or SPI |
| Operating Voltage | 3.3V – 5V |
| Viewing Angle | >160° |

| Pin | Description | Arduino Connection |
|---|---|---|
| GND | Ground | GND |
| VCC | Power (3.3V-5V) | 3.3V or 5V |
| SCL | I2C Clock | A5 (Uno) or SCL |
| SDA | I2C Data | A4 (Uno) or SDA |

// Basic I2C Connections:
// OLED VCC → Arduino 5V
// OLED GND → Arduino GND
// OLED SCL → Arduino SCL (A5 on Uno)
// OLED SDA → Arduino SDA (A4 on Uno)
Run this code to detect your OLED’s I2C address:
#include <Wire.h>
void setup() {
Wire.begin();
Serial.begin(9600);
Serial.println("I2C Scanner");
}
void loop() {
byte error, address;
int devices = 0;
Serial.println("Scanning...");
for(address = 1; address < 127; address++ ) {
Wire.beginTransmission(address);
error = Wire.endTransmission();
if (error == 0) {
Serial.print("Device found at 0x");
if (address<16) Serial.print("0");
Serial.println(address,HEX);
devices++;
}
}
if (devices == 0) Serial.println("No devices found");
delay(5000);
}
Arduino #include <SPI.h> #include <Wire.h> #include <Adafruit_GFX.h> #include <Adafruit_SSD1306.h>
#define SCREEN_WIDTH 128
#define SCREEN_HEIGHT 64
#define OLED_RESET -1
Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET);
void setup() {
display.begin(SSD1306_SWITCHCAPVCC, 0x3C); // Address 0x3C
display.clearDisplay();
display.setTextSize(1);
display.setTextColor(SSD1306_WHITE);
display.setCursor(0,0);
display.println("Hello, OLED!");
display.display();
delay(2000);
}
void loop() {
// Show sensor data or animations here
}
// Draw a rectangle
display.drawRect(10, 10, 50, 30, SSD1306_WHITE);
// Draw a filled circle
display.fillCircle(64, 32, 15, SSD1306_WHITE);
display.setTextSize(2); // 2x size text
display.setTextColor(SSD1306_WHITE);
display.setCursor(10, 10);
display.println("Large Text");
display.setTextSize(1);
display.println("Normal Text");
// Use LCD Assistant to convert images
static const unsigned char PROGMEM logo[] = {
// Bitmap data here
};
display.drawBitmap(0, 0, logo, 128, 64, 1);
for(int i=0; i<128; i++) {
display.clearDisplay();
display.fillRect(i, 16, 10, 32, WHITE);
display.display();
delay(20);
}
No account yet?
Create an Account
Recent Comments