SSD1306 128x64 Pixel uOLED display module (HCMODU0050&2)

LCD, TFT, OLED, LED modules
neildyr
Posts: 1
Joined: Thu Apr 03, 2014 9:40 am

Re: SSD1306 128x64 Pixel OLED display module (HCMODU0050&2)

Post by neildyr » Mon Feb 09, 2015 12:07 pm

Hi. I am successfully using the screen with code given on a arduino Micro.

I'm slightly confused as pins mentioned below work,
D0 (SCK) D13
D1 (MOSI) D11

When it states that these icsp pins do not connect to any digital I/o pins on the Micro Board.

"SPI: on the ICSP header. These pins support SPI communication using the SPI library. Note that the SPI pins are not connected to any of the digital I/O pins as they are on the Arduino Uno, they are only available on the ICSP connector and on the nearby pins labelled MISO, MOSI and SCK."

when I connect said icsp pins to their respective pins on the screen it doesn't work, i.e D0 to icsp SCK - D1 to iscp MOSI.

Is there a way to define the pins as sck, mosi, etc instead of a digital pin so i can connect the screen to the iscp headers??

Unless I am missing something completely obvious!!

Any help appreciated

Thanks

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

Re: SSD1306 128x64 Pixel OLED display module (HCMODU0050&2)

Post by andrew » Wed Feb 11, 2015 6:50 pm

I'm not an expert on the UG8lib library but a quick look at it and it seems that it uses the hardware SPI interface for boards with an ATMega device but drops to a software SPI interface for other types. This will explain why the SPI interface remains D11-13 pins on your Arduino micro as it's using the software SPI interface which is fixed to D11-13.

To answer your question, it doesn't look to me like it is possible to get the UG8Lib library to use the ICSP header pins on your board without modifying the library. That said if you are capable of modifying it, it should be possible to do this as the hardware SPI interface on your Arduino Micro is multiplexed with GPIO pins, just not ones that are defined for use in the Arduino software environment. So it should be possible to hack the software SPI code to use digital pins multiplexed with the hardware SPI interface.

The UG8lib library is quite a hefty one though so I think it may take a lot of head scratching to figure out how to do this. I'm not an expert on this library though so this is just my opinion from taking a quick look at its structure.
Comments made by this poster do not necessarily reflect the views of Hobby Components Ltd.

Hard16Ware
Posts: 2
Joined: Sun Feb 15, 2015 7:37 pm

Re: SSD1306 128x64 Pixel OLED display module (HCMODU0050&2)

Post by Hard16Ware » Sun Feb 15, 2015 8:25 pm

I tried to used with Arduino Nano V3.0 and I2C with U8GLIB it's NOT working !!!

In "Hello World" example from library my setting is

U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_NO_ACK); // Display which does not send AC

I need help ^^

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

Re: SSD1306 128x64 Pixel OLED display module (HCMODU0050&2)

Post by andrew » Mon Feb 16, 2015 11:19 am

This display will defiantly work with the U8GLIB library if configured and connected correctly. Use this option:

U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_NONE);

Also make sure you have connected the I2C pins as follows:

Uno/Nano........OLED
A5..................D0
A4..................D1

If this doesn't resolve the problem try pulsing the displays reset pin before the above line of code gets executed.
Comments made by this poster do not necessarily reflect the views of Hobby Components Ltd.

Hard16Ware
Posts: 2
Joined: Sun Feb 15, 2015 7:37 pm

Re: SSD1306 128x64 Pixel OLED display module (HCMODU0050&2)

Post by Hard16Ware » Mon Feb 16, 2015 3:46 pm

Ok I test in few hours and I send my result

Thank you

Ghost
Posts: 2
Joined: Fri Apr 03, 2015 5:19 pm

Re: SSD1306 128x64 Pixel uOLED display module (HCMODU0050&2)

Post by Ghost » Fri Apr 17, 2015 11:15 pm

I'm very new to the world of Arduino so spent a while trying to get the display working...only to find that it only seems to work if RST is connected....so, from the demo code I made the following changes to get this working with my UNO:

In the comment (change for RST)

Code: Select all

PINOUT:

MODULE`                UNO
GND                    GND
VCC                    +3.3V
D0 (SCK)               D13
D1 (MOSI)              D11
RST                    D12
DC (A0)                D9
CS (CS)                D10
and the code (note the extra parameter for RST)....

Code: Select all

/* Create an instance of the library for the SSD1306 OLD display in SPI mode */
U8GLIB_SSD1306_128X64 u8g(13, 11, 10, 9, 12);
Hope this helps someone else new like me :)

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

Re: SSD1306 128x64 Pixel uOLED display module (HCMODU0050&2)

Post by andrew » Sat Apr 18, 2015 8:18 am

Yes the modules should be reset before they are initialised by the library. The U8G library doesn't seem to take this into account. However we didn't realise until very recently that this was an issue because oddly it's only the recent batch of modules that seem not work if you don't reset them. I've held off making a correction for the examples that use the U8G library because we've just released our own library for these displays:

http://forum.hobbycomponents.com/viewto ... =58&t=1817

We'll be updating the first post to point towards this new library shortly but the information you have posted will be very helpful for anyone using the U8G library.
Comments made by this poster do not necessarily reflect the views of Hobby Components Ltd.

alanlow
Posts: 2
Joined: Mon May 04, 2015 5:45 am

Re: SSD1306 128x64 Pixel uOLED display module (HCMODU0050&2)

Post by alanlow » Thu May 07, 2015 4:04 am

Hi there,

I just bought 2 pieces of HCMODU0050 modules. I want to use IIC to communicate with it and have the following questions:

1) To configure to IIC I need to:
- Short S1 (with 0 ohm resistor)
- Short S2 to 1

Am I right?

2) I saw some posting regarding no ACK from this module due to D2. I don't know where is D2 as I dun see this label on the module but what I need to know exactly how to make it work with standard IIC master peripheral from an MCU (not uno)?

3) What is the slave address? Any HW configuration on it?

Thanks!

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

Re: SSD1306 128x64 Pixel uOLED display module (HCMODU0050&2)

Post by andrew » Thu May 07, 2015 7:57 am

1) To configure to IIC I need to:
- Short S1 (with 0 ohm resistor)
- Short S2 to 1

Am I right?
Yes that's right although for S1 I find it's easier just to short it with a solder bridge.
2) I saw some posting regarding no ACK from this module due to D2. I don't know where is D2 as I dun see this label on the module but what I need to know exactly how to make it work with standard IIC master peripheral from an MCU (not uno)?
This was an old problem and no longer exsists so you can ignore it now.
3) What is the slave address? Any HW configuration on it?
According to the data sheet when writing to the display the I2C address is either 0x3C (DC pin held low) or 0x3D (DC pin held high).

Btw if you are wanting to run more than one display from the same Arduino have you considered our uOLED library? This uses the displays default SPI mode and allows multiple displays to be connected.
Comments made by this poster do not necessarily reflect the views of Hobby Components Ltd.

alanlow
Posts: 2
Joined: Mon May 04, 2015 5:45 am

Re: SSD1306 128x64 Pixel uOLED display module (HCMODU0050&2)

Post by alanlow » Fri May 08, 2015 4:02 am

Hi Andrew,

Can you provide me the schematic for this HCMODU0050 module?

Thanks!

Post Reply

Return to “Display”