Close

SDD1306 and SH1106 Oled controllers

A project log for ESP8266+OLED

ESP8266-01 server, programmed in Arduino-C, + I2C oled to display text-messages of upto 128 characters that are typed in a browser.

co-stoco sto 06/12/2015 at 15:000 Comments

Initially my sketch only worked for oled's with a SDD1306 controller, which are found in most of the tiny 0.96 inch blue or white I2C Oleds.

I have changed it so that Oled's with a SH1106 controller can also be used. The SH1106 is much like the SSD1306 , the main difference is the memory map which is 128*64 for the SSD1306 and is 132*64 for the SH1106 controller resulting often in a small white or noisy sideband of pixels. The 1.3 inch SPI/I2C Oled I have has 2 solderable jumpers by which the display can be set for 3SPI, 4SPI or I2C. To work with the ESP I changed the jumpers for I2C (S1=0 S2=1)

The difference in the sketch is that the clear function has to clear 8x132 bytes vs. 8*128 bytes. Also the setXY() function needs an lower colom adress offset of 0x02. The right offset value has to enabled in the declaration_part of the ESP_Messenger_v1.0 file

Discussions