bitbank2 / ss_oled

Simple and small library to control 1-bpp OLED displays (Linux + Arduino)
GNU General Public License v3.0
190 stars 34 forks source link

Support for 64x48 display #51

Closed fijam closed 3 years ago

fijam commented 3 years ago

Would it be possible to add support for a 1306-based 64x48px display?

Product pictured below, tested with adafruit_ssd1306 python library.

IMG_20210902_120357

bitbank2 commented 3 years ago

I don't have that size handy to test. It isn't hard to add support, but you need to verify the init sequence (2 possible ones) and the memory offset of the visible portion of the display. At the moment I can't do that verification without having a display in hand.

fijam commented 3 years ago

Can you describe in more detail how to calculate the memory offset? I could give it a shot.

bitbank2 commented 3 years ago

If you look at the code, you'll see the various x/y offset values that are set up in init() depending on the display chosen. It's not a matter of calculating it, but a matter of figuring out the value by trial and error. The info is not documented and can't be guessed.