Hi Arduino experts ;D I realize this is the Arduino forum, and I'm using an ESP8266 (NodeMCU dev kit) - Programming with Arduino IDE though ![]()
I've read several discussions about SSD1306 OLED displays on this forum. And someone here might recognize my problem with the display?
The display that I bought on eBay - almost the same, except mine has an area with yellow pixels at the top:
http://www.ebay.com/itm/0-96-Blue-SPI-Serial-128X64-OLED-Display-Module-for-Arduino-DC-3V-5V-/361020852330 (no longer available)
On arrival the display was set to run in SPI mode. There doesn't seem to be a way to easily switch to I2C, but I've read that SPI can be faster and my MCU is supposed to support Hardware SPI on dedicated pins... So SPI it is!
There is no CS pin ("Chip Select" or "Slave Select") on the OLED circuit board.
When I bought it, relatively cheap I think ($4.65 at the time), there was no manual or datasheet included. The seller did send me some code samples (with Chinese comments, hah!) but those were targeted at I2C. Then I did some tinkering with Espruino; JavaScript running on the ESP8266. And got some life signs out of the OLED display. Unfortunately limited to some garbage output, I only managed to send some basic commands for contrast, on/off, invert.
Right now I've been getting the best results with a SSD1306 library (C++) written by Daniel Eichhorn.
The SPI library (which uses SPI.h) is initialized in this manner:
SSD1306Spi(uint8_t _rst, uint8_t _dc, uint8_t [color=#ff0000][b]_cs[/b][/color])
Since my display doesn't have the CS pin, I (naively) put the GPIO number for the 'clock' pin there and it seems to work with demo projects (sketches) that came with the library 8)
But lines of pixels are 'missing'/black, causing the output to look interlaced (like scan lines) ![]()
I might have messed it up by using that 'clock' pin... however the display stops working if I leave that pin disconnected, so it is somehow needed.
Perhaps I should try U8glib to see if it leads to better results...
Any ideas?
