Black screen SSD1306 with Pro Micro

I’m trying to get my Oled running on my Pro Micro, but unfortunately, the screen stays black. In order to test if my allocation was right I ran i2c scanner, which returned i2c found on 0x3C.

Bringing that knowledge back to my code, it still shows a black screen, while not getting any compile errors. Screen is connected to pin 2 and 3 as needed with the micro pro.

This is the code;


#include <Adafruit_GFX.h>
#include <Adafruit_SSD1306.h>
#include <Wire.h>

#define SCREEN_WIDTH 128
#define SCREEN_HEIGHT 64

Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, -1);

void setup() {
  

  if (!display.begin(SSD1306_SWITCHCAPVCC, 0x3C)) {
    while (true) {} 
  }

  display.clearDisplay();
  display.setTextSize(1);
  display.setTextColor(SSD1306_WHITE);
  display.setCursor(0, 0);
  display.print("OLED Test!");
  display.display();
}

void loop() {
  // Empty
}

Used your sketch with no modifications on a 5V Pro Micro with a 0.96" OLED/SSD1306 hooked up to the pins on the Pro Micro marked 2 (SDA) and 3 (SCL). Compiled and uploaded sketch, display showed "OLED Test!".

Interesting, guess it’s a faulty screen then…thanks for helping.

  • Always show us good images of your ‘actual’ wiring.

Sorry about, photos included.


Those sorts of OLED displays should be powered by 3V3 and controlled by 3V3 signals. With the I2C lines pulling up to a 3V3 with a 1K8 resistor.

Not sure if they can take 5V without damage.

By the way pictures with wires disappearing out of frame and then back into frame are not thr best way to show wiring.

Best to show a schematic.

I’m really sorry. I got delivered a wrong Oled, it’s an sh1106, so after using the u8g2 library, it came alive. Aa this is a test doesn’t matter for now. Again, sorry for this here. I’m just starting out and my knowledge is not there yet. I did order the ssd1603 screen, but my inexperience can’t tell them apart yet.


You need to solder the header pins to the Pro Micro. Push the Pro Micro firmly down onto them so they stick up above the PCB, and then solder each pin like this:

You are very lucky that worked without soldering!

1 Like

Good to say, I feel stupid. I have only soldered cables until now, so I’m really the new kid on the block. Now that it’s soldered, it indeeds reacts better to all my knobs, switches etc etc. Apreciate the feedback.