Faster SSD1306 OLED refresh through bit banging

I've written a blog post about my experiments to speed up display refresh on the I2C version of the SSD1306 OLED displays. I was able to go from the "normal" speed of 23.5FPS using the I2C 400Khz 'fast' clock to > 150FPS using a brute force method. Step by step details and code can be found here:

Blog Post

Some disclaimers:

  1. The purpose of this experiment was to see what was possible. I don't recommend putting this code into a production/commercial environment.
  2. My code doesn't precisely follow the I2C spec. This is purposefully done to speed it up.
  3. Not all SSD1306 devices will work with this code. Buyer beware.
  4. Why did I do it? To learn and share what I learned.
1 Like

Nice work and good documentation. Karma+

Oliver

I went ahead and optimized a Bresenham line drawing function for the SSD1306. It smartly minimizes memory accesses and writes to the display. It runs many times faster than the "standard way" of drawing lines. Here's a short video of it in action:

Does anyone think it deserves a new blog post describing how I optimized it?

1 Like