0.5_Inch_OLED_Display_SKU_DFR0376 - jimaobian/DFRobotWiki GitHub Wiki

Product Name

Introduction

This is a mini OLED display, only 5", which has the same size of a grown-up's fingernail. This small display has 450cd/m^2 screen brightness with extremely high contrast and readability. It contains 60 x 32 independent white OLED pixels and each pixel can be controlled by the driver chip separately. It means you can display any images and words on the screen . And the spontaneous light OLED display does not require a backlight, which greatly reduces the power consumption.

Specification

  • Operating Voltage:3.3V
  • PCB dimension: 17.8mm X 15.5mm
  • Screen size: 0.5" inch (W*H: 15.30x10.20 mm)
  • Color: Monochrome (white)
  • OLED  type: PM -OLED
  • OLED driver: LD7032
  • Pixels : 60 x 32
  • Contrast: 2000: 1
  • Communication: SPI, I2C

Board Overview

center

Tutorial

### Requirements
### How to connect Oled PCB and Display

First we need Assembly the OLED PCB and display, Be careful in this process, the display connector is thin and fine.

  • 0pen the Oled PCB connector

400px

  • Make the display cable into the connector, take care not to invert !!
center please be sure to use the tweezers or pen inserted into the the small hole on the top of the liquid crystal! don't use hand! don't use hand! don't use hand! important things need to be repeated for 3 times! the test by hand in hand, we've broken three pieces direct use hand push when we started test it. This is the lesson of blood

center ATTENTION:Please Gently! Gently! Gently! Push the LCD screen when start,The two iron with floor can just keep a screen cable inserted in the gap.Insert it from this gap,When encounter resistance, Don't force! Don't force! Don't force!At this time use tweezers or other sharp objects into the small hole,Use a little force and keep this force until you feel that you have push it on the top,When you feel like it is not moving.Don't force! Don't force! Don't force!Then the one thing you need to do is that pulled out the tweezers or other objects. 800px 800px *Buckle the OLED PCB Board connector. 300px OK, The two things had connected together. Congratulations! You have completed the first step.

Connection Diagram

This step, it will requires you to solder the Pins on the PCB holes, please be careful with when you solder the pins.

Connect the module to DFRduino according to the following connection diagram

Note: Do not mix 3.3V and GND .

550px Finally, Connect your USB cable to your PC. OK, all the hardware step we need has been done.

Sample Code

Since your hardware connection has been finished, the next step will be the code uploading. First you need to download the library, and move these files to ARDUINO libraries folder, which is in the Arduino installation directory. Click here to download U8glib library Do you know how to install an Arduino library? You can refer to this tutorial: How to install an Arduino library And then we need to open the ARDUINO IDE, copy the following code and put it in the IDE windows. Select the right serial port and board type (Arduino UNO) in the menu, click "download" button.

#include "U8glib.h"
U8GLIB_LD7032_60x32 u8g(9, 8, 11, 10, 12);

void setup(void) {
}
const uint8_t rook_bitmap[] PROGMEM = {
  0x00,         // 00000000
  0x55,         // 01010101
  0x7f,          // 01111111
  0x3e,         // 00111110
  0x3e,         // 00111110
  0x3e,         // 00111110
  0x3e,         // 00111110
  0x7f           // 01111111
};

void loop(void) {
  // picture loop
  u8g.firstPage();
  do {
    u8g.setFont(u8g_font_unifont);
    //       u8g.setFont(u8g_font_osb21);
    u8g.drawStr( 5, 20, "DFROBOT");
  } while ( u8g.nextPage() );
  delay(1000);
  u8g.firstPage();
  do {
    u8g.drawCircle(30, 20, 18);
    u8g.drawEllipse(26, 12, 7, 5,U8G_DRAW_UPPER_LEFT );
    u8g.drawEllipse(34, 12, 7, 5, U8G_DRAW_UPPER_RIGHT);
    u8g.drawTriangle(30,14, 27, 18, 33, 18);
    u8g.drawFilledEllipse( 30, 25, 10,5, U8G_DRAW_LOWER_LEFT);
    u8g.drawFilledEllipse( 30, 25, 10,5, U8G_DRAW_LOWER_RIGHT);
    u8g.drawLine(30, 13, 30, 16);


    u8g.drawFrame(0, 0,60 ,32);

  } while ( u8g.nextPage() );
  delay(5000);

  u8g.firstPage();
  do {
    u8g.drawBitmapP(30, 16,1, 8, rook_bitmap);
  } while ( u8g.nextPage() );
  delay(1000);
  u8g.firstPage();
  do {

  } while ( u8g.nextPage() );
  delay(2000);

}

Result

烧录示意图

Trouble Shooting

centerAny question and more cool ideas to share, please visit DFRobot Forum

More

0.5 inch OLED Display Library

link=http://www.dfrobot.com/ buy from dfrobot store or dfrobot distributor list