Hi, this is one of my first Arduino projects, and it's also my first time posting on this forum, so if I've done anything incorrectly or missed something obvious please try to be understanding. I appreciate any help thanks in advance
I recently purchased a character OLED from Vishay, more specifically, this one :
I'm trying to use the Adafruit Character OLED library, which to the best of my knowledge is a modded LiquidCrystal Library.
It's initially configured for 16x2 display, but I've changed the begin line (for a 20x4 display) as show below :
pinMode(_rs_pin, OUTPUT);
pinMode(_rw_pin, OUTPUT);
pinMode(_enable_pin, OUTPUT);
_displayfunction = LCD_FUNCTIONSET | LCD_4BITMODE;
begin(20, 4);
}
I've also added a delay after the clear function since the display manufacturer (Vishay) informed me it would be needed :
/********** high level commands, for the user! */
void Adafruit_CharacterOLED::clear()
{
command(LCD_CLEARDISPLAY); // clear display, set cursor position to zero
delayMicroseconds(6200); // this command takes a long time!
}
So far these are the only changes I've brought to the library. My pinout from my Arduino follows both the instructions by Adafruit relating to the code, and Vishay's datasheet. I am quite confident it is correct and that the problem isn't there.
My display shows off random strings of characters that scramble and flicker. Most of the time these characters are dimmed, as if the display is rapidly refreshing. They change a couple times after the Arduino and screen is powered on, and then they stop changing and stay static.
I was wondering if someone could look over the library, and if they can spot glaring inconsistencies or issues the code I'm using. It's probably not configured properly for the OLED I'm using, and that's where I could use your help.
Thanks for taking the time to read this, and for your help if you can offer any !
Attached will be the OLED datasheet, the .cpp file I've modified for the Adafruit Character OLED library I'm using, the link to the Adafruit pinout instructions I've followed. Let me know if I can provide you with any other information I've used so far.
Adafruit_CharacterOLED.cpp (7.81 KB)