Would an SPI 0.9" oled screen be better than an I2c for my application?

Hi everybody! I am working on something using I2C oled screens, 128x32, 0.91".

Basically, the only things displayed are

  1. full white screen
  2. white filled square on the center

Depending on the sensor value the toggling between them will become faster or slower.

Problem is that if I toggle between them too fast, there is some very ugly artifacts, specially when showing the full white. Here is a video (looks a little worse on video but live its actually pretty bad)

So what I would like to know is

First, is it even possible to get a clean toggling between these screen configurations having intervals between them from 100ms to less, using these OLED 128x32 screens?

If yes, what can I do to get there?

Use SPI instead of I2C?

Get a better quality screen? Im using these https://www.amazon.co.jp/gp/product/B085C67PF1/ref=ppx_yo_dt_b_asin_title_o02_s00?ie=UTF8&psc=1

Is there anythig to be improved on the code part? Im using Adafruit_GFX.h and Adafruit_SSD1306.h libraries. Here is the code

void loop() {
  display.clearDisplay();
  display.fillRect(0, 0, display.width(), display.height(), SSD1306_WHITE); // arg0-1: top left corner -----  arg2-3: width, height
  display.display();
  delay(100);
  display.clearDisplay();
  display.fillRect(cr_xStart, 0, centerRectSize , display.height(), SSD1306_WHITE);
  display.display();
  delay(100);
}

Or any other ideas? Maybe not Oled... I dont know.

Overall, it should be black and white, have the aspect similar to 128x32, and not be so much bigger than 1 inch (0.91" is perfect actually but if its a little bigger would also work, maintaning a similar aspect)

Thank you very much!

Use some imagination. Think of a more attractive method. e.g. a barchart, pieslice, rotating arrow, numbers, icons, ...

Anything other than irritating flashing screen.
Mind you, a single led with variable blink speed would be not too bad.

Regarding I2C vs SPI. It will make little difference to the overall look. SPI would just be faster executing the display.display();

the ssd1306 has enough ram for dubble buffering on 128x32 screens. so a perfect transition is possible.
see:

Works beautifully, thanks!

1 Like

thanks for the answers everybody.

@david_prentice its for an art project, the content have to be that one! Thanks for the reply :slight_smile:

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.