728x90

What's the difference between Adafruit SSD1306 and SH1106?

Jul 22, 2014, 02:39 am

Hey all!  I've scoured some pretty sketchy sites in search of this, and haven't found anything concrete.  I have a need to use Adafruit's SSD1306 library for my OLED displays.  The problem?  I'm using these cheap ones which only support SH1106:  http://www.amazon.com/Huhushop-TM-Serial-Display-Arduino/dp/B00JM7SWI4/ref=sr_1_4?ie=UTF8

I hear that there isn't much difference between the two libraries, but there's enough to cause me problems.  Does anyone know what I ought to do to modify SSD1306 so that it works with my displays?

I know it's a long shot, but I'd appreciate any help!

 

 

 

Re: What's the difference between Adafruit SSD1306 and SH1106?

#1

Jul 22, 2014, 02:53 am

I have here one cheap OLED screen like that and I'm using the library from Adafruit too, and without problems. I saw this:
https://www.youtube.com/watch?v=VEZGn0zYHiE

video too, and it seems like yours, an he are using that library too.

 

 

 

  • Guest

Re: What's the difference between Adafruit SSD1306 and SH1106?

#2

Jul 22, 2014, 05:25 am

Hi luisilva, thanks for responding.  That was a handy video!  Unfortunately, I can't get my display to work in the same way that the guy in the video did.  The reason being that I'm actually using a Spark Core (www.spark.io) to run the display, which has a much more limited library selection than the Arduino.  I don't mean to derail an arduino forum, however, which is why I was specifically asking about the differences between the SSD1306 and SH1106 libraries.

At present, using SSD1306 yields the very same issu as this person's: https://github.com/adafruit/Adafruit_SSD1306/issues/14   That's the only place I've been able to find somebody else with the same issue of the screen being filled with junk, btw.  However, that person's issues were solved by simply switching to the u8glib.  I'd love to do just that, but u8glib isn't compatible with Spark.  Hence me trying to figure out a way to modify the existing SSD1306 library to be compatible with my display.

Thanks again for any insight!

 

 

Re: What's the difference between Adafruit SSD1306 and SH1106?

#3

Jul 22, 2014, 05:38 am

OK. Now I understand. From this discussion:
http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&p=1150108

They point out this library:
https://github.com/stanleyhuangyc/MultiLCD

 

stanleyhuangyc/MultiLCD

Arduino LCD library supporting multiple types of LCD shields and modules - stanleyhuangyc/MultiLCD

github.com

 

 

Re: What's the difference between Adafruit SSD1306 and SH1106?

#4

Jul 22, 2014, 09:03 pm

There is only one small difference between SSD1306 and SH1106: The SH1106 controller has an internal RAM of 132x64 pixel. The SSD1306 only has 128x64 pixel.

First problem for standard 128x64 OLEDs with SH1106 controller is: How is the 128x64 window mapped into the 132x64 RAM?
It seems, that the 128x64 OLED is centered in most cases within the 132x64 area, that means pixel (2,0) in ram is pixel (0,0) on the display.

For u8glib, the update for the SH1106 was very small. I just had to shift the display by 2 pixel. This is more complicated with the Adafruit lib. Mainly the procedure "Adafruit_SSD1306::display(void)" depends very much on the hardware architecture and assumes, that the width of the RAM area is 128 (which is wrong for the SH1106). I think the procedure Adafruit_SSD1306::display(void) needs to be rewritten completly (including the commands, which are sent).

Oliver

+ Recent posts