0.9" 128 x 32 Serial I2C uOLED Display (HCMODU0118 & 119)

LCD, TFT, OLED, LED modules
Post Reply
admin
Site Admin
Posts: 865
Joined: Sun Aug 05, 2012 4:02 pm

0.9" 128 x 32 Serial I2C uOLED Display (HCMODU0118 & 119)

Post by admin » Tue May 23, 2017 1:44 pm

Image


Image

These tiny 0.9 inch uOLED displays have a resolution of 128 x 32 pixels and use a standard serial I2C interface (address = 0x3C) for communication. Based on the SSD1306 controller, the module is available in both white and blue pixel colours. By making use of OLED screen technology these displays are self illuminated and therefore require no back light. When compared to standard LCD and TFT technology they have significantly less power consumption and a significantly clearer display. If using with an Arduino board they are also compatible with our own HCOLED graphic library (see http://forum.hobbycomponents.com/viewto ... =58&t=1817)

Image Image



Image



Image


Product code: HCMODU0118 (white) HCMODU0119 (blue)
Module size: 38 x 12mm
High pixel density
Resolution: 128 x 32
Ultra-low power consumption: normal display 0.06W (far below the TFT display)
Wide supply range: DC 3V-5V (without any changes, directly compatible with common 3.3V and 5V power supply system)
Industrial grade: Operating temperature range -30 C ~ 70 C
5V tolerant interface.
OLED screen, internal drive chip: SSD1306


Image

1....GND: Power ground
2....VCC: 3.3V or 5V power supply
3....SCL: I2C Clock
4....SDA: I2C Data



Image

  1. #include "HCDisplay.h"
  2.  
  3. // Default I2C address
  4. #define I2C_ADD 0x3C
  5.  
  6. HCDisplay HCDisplay;    //Creates an instance of the HCDisplay library
  7.  
  8.  
  9. void setup()
  10. {
  11.   HCDisplay.Init(I2C_ADD);        
  12.  
  13.   // Print some text
  14.   HCDisplay.Pos(44,0);
  15.   HCDisplay.Print("Hobby");
  16.   HCDisplay.Pos(24,10);
  17.   HCDisplay.Print("Components");
  18.  
  19.   // Change the font
  20.   HCDisplay.SetFont(Tiny_6ptFont);
  21.   HCDisplay.Pos(12,24);
  22.   HCDisplay.Print("HCMODU0118 & HCMODU0119");
  23. }
  24.  
  25.  
  26. void loop()
  27. {
  28.  
  29. }


Image

HCDisplay Arduino library for above sketch is available for download from the software section of our support forum here:

viewtopic.php?f=58&t=2827



Old HCuOLED library:

viewtopic.php?f=58&t=1817



Diagrams, libraries, and example code are provided as an additional free service by Hobby Components and are not sold as part of this product. We do not provide any guarantees or warranties as to their accuracy or fitness for purpose.

Descriptions and diagrams on this page are copyright Hobby Components Ltd and may not be reproduced without permission.

pvrancke
Posts: 5
Joined: Tue Oct 01, 2013 3:27 pm

Re: 0.9" 128 x 32 Serial I2C uOLED Display (HCMODU0118 & 119)

Post by pvrancke » Sat Jan 05, 2019 11:36 am

Hello,
I tried to compile for ESP8266/Wemos D1 or Adafruit Huzzah but get the following error:

Arduino: 1.8.2 (Windows 10), Board: "WEMOS D1 & mini, 80 MHz, 921600, 4M (3M SPIFFS), Disabled, None"

In file included from C:\Users\cttp\Documents\Arduino\libraries\HCuOLED-master\HCuOLED.cpp:41:0:

C:\Users\cttp\Documents\Arduino\libraries\HCuOLED-master\fonts.h:3114:1: error: cannot convert 'const uint16_t* {aka const short unsigned int*}' to 'const unsigned int*' in initialization

};

^

C:\Users\cttp\Documents\Arduino\libraries\HCuOLED-master\HCuOLED.cpp: In static member function 'static void HCuOLED::SetFont(const byte*)':

C:\Users\cttp\Documents\Arduino\libraries\HCuOLED-master\HCuOLED.cpp:807:19: error: cannot convert 'const unsigned int* const' to 'const uint16_t* {aka const short unsigned int*}' in assignment

_FontDescriptor = Terminal_8ptFontInfo.Descriptors;

^

C:\Users\cttp\Documents\Arduino\libraries\HCuOLED-master\HCuOLED.cpp:812:19: error: cannot convert 'const unsigned int* const' to 'const uint16_t* {aka const short unsigned int*}' in assignment

_FontDescriptor = MedProp_11ptFontInfo.Descriptors;

^

C:\Users\cttp\Documents\Arduino\libraries\HCuOLED-master\HCuOLED.cpp:817:19: error: cannot convert 'const unsigned int* const' to 'const uint16_t* {aka const short unsigned int*}' in assignment

_FontDescriptor = LCDLarge_24ptFontInfo.Descriptors;

^

exit status 1
Error compiling for board WEMOS D1 & mini.

Can you help me ?
thanks !!
patrick

andrew
Site Admin
Posts: 1374
Joined: Sun Aug 05, 2012 4:15 pm

Re: 0.9" 128 x 32 Serial I2C uOLED Display (HCMODU0118 & 119)

Post by andrew » Sun Jan 06, 2019 9:51 am

I've been able to replicate the problem and have uploaded an updated version of the library. I don't have access to a display to test it with at the moment but hopefully it has fixed the issue.

You can download the new version (V0.5) from the software section of the forum here:

viewtopic.php?f=58&t=1817&p=4337

Don't use the github link as I've not updated it there yet, just use the V0.5 link in the first post of the above thread.
Comments made by this poster do not necessarily reflect the views of Hobby Components Ltd.

pvrancke
Posts: 5
Joined: Tue Oct 01, 2013 3:27 pm

Re: 0.9" 128 x 32 Serial I2C uOLED Display (HCMODU0118 & 119)

Post by pvrancke » Sun Jan 06, 2019 4:03 pm

Dear Andrew,
it compiles and works !!
thanks a lot !

andrew
Site Admin
Posts: 1374
Joined: Sun Aug 05, 2012 4:15 pm

Re: 0.9" 128 x 32 Serial I2C uOLED Display (HCMODU0118 & 119)

Post by andrew » Mon Jan 07, 2019 12:01 pm

Great, and thanks for letting me know.
Comments made by this poster do not necessarily reflect the views of Hobby Components Ltd.

Post Reply

Return to “Display”