OLED 0.91 I2C 128x32 White (SSD1306) [D054]



https://www.youtube.com/watch?v=tj0cw7PF3as


*GitHubhttps://github.com/rdiot/rdiot-d054.git


* Specs

0.91 Inch OLED LCD Module SPI/IIC Interface 128*32 Dot Matrix  new original


* Contents

- DataSheet : http://www.buydisplay.com/download/manual/ER-OLED0.91-1_Series_Datasheet.pdf


- Connect

GND ----- GND

VCC ----- 3.3~5V

SCK ---- SCL

SDA ---- SDA


- Key Code


#include "U8glib.h"

U8GLIB_SSD1306_128X32 u8g(U8G_I2C_OPT_NONE); 


void loop(void) {


  // picture loop

  u8g.firstPage();  

  do {

    draw();

  } while( u8g.nextPage() );

  // rebuild the picture after some delay


  delay(500);

}


void draw(void) {

  u8g.setFont(u8g_font_9x15B);

  u8g.setPrintPos(0, 12); 

  u8g.println("OLED 0.91");

  u8g.setFont(u8g_font_helvB14);

  u8g.setPrintPos(0,30);

  int var = 0;

  u8g.print("128x32");

}

Posted by RDIoT
|