SPI version of the SSD1306 OLED library
SPI version of the SSD1306 OLED library
I ported my library for the I2C version of the SSD1306 to the SPI version of the OLED display. The SPI version is much faster and the code is more compact. This means that most of the functions fit in one library and we can also use the full resolution of the display (128x64). As an example, I have uploaed also a simplified version of Steve Stagg's bitflyer game. Six cables are needed to connect the microbit and the oled display, but you can buy 6P dupont shells and just remove the housing of standard dupont cables and stick them into the 6P shells to create your own connector. Make sure the wiring links the appropriate pins. Suprisingly, both ends are exchangeable, so no need to remember which side plugs into the micro:bit and which side plugs into the oled display. Just align the VCC pin and you are good to go.
- pythoncoder
- Posts: 5956
- Joined: Fri Jul 18, 2014 8:01 am
- Location: UK
- Contact:
Re: SPI version of the SSD1306 OLED library
There is an official driver for the SSD1306 which supports I2C and SPI here https://github.com/micropython/micropyt ... ssd1306.py.
Peter Hinch
Index to my micropython libraries.
Index to my micropython libraries.
Re: SPI version of the SSD1306 OLED library
I have seen several driver versions. Most of them use a Framebuffer, which is not supported by the micro:bit; others does not support text and all of them are too big and too memory consuming for the micro:bit standards. My version is specifically aimed at the microbit, and tries to have a small footprint...