Configuring oled to I2C [SOLVED]

Hi,

I have this multiprotocol OLED

It works well in the default 4 wire SPI configuration.
If I'm understanding the table correctly to configure it to I2C I'll need to solder resistors in positions R1 and R8 and I'm not sure if I have to remove the resistor in positions R3 and R5.
In any case, can I make sure it is 4.7K resistors ? R5 is the only one that is not 4.7k, 914 should be 91K, does that make sense ?
Why do they do this to us, I have no idea where I'm going to get two 4.7k resistors, and even if I got them I don't know if I'll be able to solder them, I can't even read the numbers without a magnifier let alone solder it.
Can't I just connect the pads with solder ?

No, you can see the printed instructions.

Short R1, R8 with solder blobs (or 0R resistors).

From memory, the R4, R6, R7 resistors can just remain untouched.
I have the schematic somewhere. From memory, there are already pullup resistors.
I have the same OLED that I have configured for I2C. I can find it and check what I did.

The good news is: I2C acks correctly (due to R8).

David.

Great news. Thank you David.

Hi again,

I was able to connect a 0 ohm SD resistor on R8 and a solder blob on R1. Not pretty but it might work. :frowning:

Running a i2c scanner finds the device, but not always, the output is

Scanning...
No I2C devices found

Scanning...
No I2C devices found

Scanning...
No I2C devices found

Scanning...
No I2C devices found

Scanning...
I2C device found at address 0x3D  !
done

Scanning...
No I2C devices found
<and so on>

Maybe I need a pull up in R8 or R1 ?

I'm going to try to use it anyway but it may take same time as I'm not using an Arduino but an ESP-01s module.
And using a lib I haven't use before: GitHub - ThingPulse/esp8266-oled-ssd1306: Driver for the SSD1306 and SH1106 based 128x64, 128x32, 64x48 pixel OLED display running on ESP8266/ESP32

Ah-ha. My OLED is on a board with existing external pullups. But I think the OLED has pullups anyway (R6, R7).

I have removed 0R from R2, R3. And added 0Rs to R1, R8.

It is late. I can't find the schematic.

David.

No luck.
I removed R3, (R2 was already empty) and added 2 external 4k7 pullups, now the oled is never found by the scanner.

I assume that I only have to connect VCC, GND, D0 and D1. RES, DC and CS are left unconnected, right ?

I wander if this oled is supposed to work at 3.3V ? I tested it (in 4spi) with a Nano (5V).

Gonna test it with the Nano again, I might have burned it when adding the solder blobs.

:frowning: can't find it with a nano, with or without external pullups... :frowning:

Well you should pull RST up to 3.3V with a 10k resistor.
And DC works as Slave address select.

David.

I feel so stupid... :sunglasses: I was connecting it on the wrong side of the uno... :open_mouth:

Scanning...
I2C device found at address 0x3C  !
done

No pullups on the i2c bus, only the 10k on RST.

thanks

Well, got it working at last.
Using U8G2 lib the initiator is:

U8G2_SSD1306_128X64_NONAME_F_HW_I2C u8g2(U8G2_R0, /* reset=*/ U8X8_PIN_NONE);

I had some trouble with it, my guess is that having the RES (RESET) pin pulled up to 5V via a 10k resistor does not reset the display when loading new code to the NANO, I was getting only random dots until I removed the power (the RESET button didn't clean that either).

In the end the wiring was:

GND --> Ground
VCC --> +5V 
D0 --> SCL (Nano pin A4)
D1 --> SCA (Nano pin A5)
RES --> 10 Kohm resistor --> +5V
RC --> not connected
CS --> not connected

With this configuration the display gets I2C addr 0x3C.

Here are the before and after pictures

1 Like

Well, of course the Reset pin will not be used if you specify PIN_NONE in the constructor.

Seriously, these OLEDs are much happier with a proper hardware Reset pin.

David.

1 Like