Has anyone tried an SSD1306 OLED LCD ( http://s.aliexpress.com/QNzQRnaQ ) with smoothie?

Has anyone tried an SSD1306 OLED LCD (http://s.aliexpress.com/QNzQRnaQ) with smoothie? This is SPI not I2C, and according to smoothie documentation some SPI panels are supported but this particular driver is not listed. If there is an incompatibility, any thoughts on what needs to get solved to add support?

it is almost identical to the ST7565 that is supported, there are just a couple of initialization bytes that need changing. I have a patch somewhere that is supposed to work, but never bothered to merge it.

I have such a display on the way, if you can point me in the right direction or pull up that patch, I can test.

+Peter van der Walt I have the display I ordered sitting on my bench. If you or @Wolfmanjm advise what needs to be changed in the code I can test.

I know someone who has it working it was like two lines of changes to the existing code. But I need to do some searching to find which lines were changed.

Ok I’m adding it to the panel as an variant on the ST7565

please test this branch https://github.com/wolfmanjm/Smoothie/tree/add/ssd1306-oled
set panel.lcd ssd1306_oled

contrast may need some tweaking.
and reverse is not supported.

Someone else will need to do that the only reason I did this was someone sent me their changes a while back and it was on my todo list to integrate their changes.

Was able to compile the firmware branch.
No activity on the LCD though.
I will have to get a known arduino sketch going to verify it works first, as I have not used it yet.

We are trying to get 3 pin SPI working, which is how this module is configured. (R3 and R4 jumpers installed)

The pins on the LCD header are gnd, vdd, sck, sda, res, dc, and CS.

I have mine hooked up:
Gnd-gnd
Vdd-3.3v
Sck-Sck1
Sda-Mosi1
CS-Ssel1

I have tried having res(reset) disconnected and when that did not work I tried grounding it, then holding down smoothie reset, unground, release reset, and still nothing.

@raykholo AFAIK the reset must be connected and configured in smoothie. without it the thing will not initialize.

@Wolfmanjm this is the only reset reference I found in the code: https://github.com/wolfmanjm/Smoothie/blob/add/ssd1306-oled/src/modules/utils/panel/panels/ST7565.cpp#L99

Can you advise if this is what you are referring to, and if so what the config line should be?
https://github.com/wolfmanjm/Smoothie/blob/add/ssd1306-oled/src/modules/utils/panel/panels/ST7565.cpp#L99

yes you need to hook up a pin to the reset on the oled. Then configure it in config with… panel.rst_pin 2.13 # or whatever pin you use
Note rst is high normal then brought low to reset then high, I think that works for the oled. if not you can invert the pin in the config.

looks like you do not need an a0 pin so set that to nc

@Wolfmanjm will there be a problem if a0 is not in the config at all? If that is a problem can you advise on the config line for that as well please?

yea you need to explicitly set it to nc so

panel.a0_pin nc # set to not connected

@raykholo did you get it working?

Sry I forgot to reply back. No, that didn’t help. There’s no activity on the screen at all. I’m gonna try to get an arduino set up to test it before fiddling further, to make sure my screen works.

ok I have a 1306 chinese clone display someone gave me, I’ll hook it up and test it. I’ve seen it working, but maybe I made an error in copying the setup sequence.

@raykholo what is the pinout on your display, there are several different types… one has no reset like this one, and you need to use a0_pin…
http://www.hotmcu.com/ssd1306-096-128×64-oled-display-–-i2cspi-interface-p-144.html