Package: luma.oled
luma.core|luma.docs|luma.emulator|luma.examples|luma.lcd|luma.led_matrix|luma.oledluma.oledDisplay drivers for SSD1306 / SSD1309 / SSD1322 / SSD1325 / SSD1327 / SSD1331 / SSD1351 / SSD1362 / SH1106 / SH1107 / WS0010Python 3 library interfacing OLED matrix displays with the SSD1306, SSD1309,
SSD1322, SSD1325, SSD1327, SSD1331, SSD1351, SH1106, SH1107 or WS0010 driver using
I2C/SPI/Parallel on the Raspberry Pi and other linux-based single-board
computers - it provides aPillow-compatible
drawing canvas, and other functionality to support:scrolling/panning capability,terminal-style printing,state management,color/greyscale (where supported),dithering to monochromeDocumentationFull documentation with installation instructions and examples can be found onhttps://luma-oled.readthedocs.io.A list of tested devices can be found in thewiki.The display pictured below is a SSD1306 (128 x 64 pixels), and the board istinyenough to fit
inside the RPi case.As well as display drivers for various physical OLED devices, there are
emulators that run in real-time (with pygame) and others that can take
screenshots, or assemble animated GIFs, as per the examples below (source code
for these is available in theluma.examplesgit repository:UpgradeVersion 2.0.0 was released on 11 January 2017: this came with a rename of the
github project fromssd1306toluma.oledto reflect the changing nature
of the codebase.Some core functionality has been moved out to another git repository,luma.core: this has enabled
another project to have a facelift:pcd8544has now been reborn asluma.lcd: the same API can now be
used across both projects. Likewisemax7219has been renamed toluma.led_matrixso
it can also take advantage of the common API.The consequence is that any existing code that uses the oldssd1306package
will need to be updated. The changes should be limited to altering import
statements only, and are described in theupgrade documentation.LicenseThe MIT License (MIT)Copyright (c) 2014-2023 Richard Hull and contributorsPermission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the “Software”), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.ContributingPull requests (code changes / documentation / typos / feature requests / setup)
are gladly accepted. If you are intending to introduce some large-scale
changes, please get in touch first to make sure we’re on the same page: try to
include a docstring for any new method or class, and keep method bodies small,
readable and PEP8-compliant. Add tests and strive to keep the code coverage
levels high.GitHubThe source code is available to clone at:https://github.com/rm-hull/luma.oledContributorsThijs Triemstra (@thijstriemstra)Christoph Handel (@fragfutter)Boeeerb (@Boeeerb)xes (@xes)Roger Dahl (@rogerdahl)Václav Šmilauer (@eudoxos)Claus Bjerre (@bjerrep)Vx Displays LLC (@VxGeeks)Christopher Arndt (@SpotlightKid)Sascha Walther (@leragequit)Marcus Kellerman (@sharkusk)Phil Howard (@gadgetoid)@wjgeorgeDoug Burrell (@doug-burrell)Xavier Carcelle (@xcarcelle)Dhrone (@dhrone)George Harker (@georgeharker)@Pako2Graeme Smecher (@gsmecher)Romit Raj (@QuicksandDesignStudio)ChangeLogVersionDescriptionDate3.13.0Add support for 128x128 SH11072023/08/123.12.0Fix 96x16 OLED panel offset2023/03/193.11.0Add support for SH1107 greyscale OLED2023/01/263.10.0Fix SSD1322 NHD initialization and encode each pixel as 4bit+4bit
identical nibbles2022/11/143.9.0Use native namespace package configurationDrop support for Python 3.62022/10/193.8.1Fix mutable default parameter bug when using multiple displays2020/11/153.8.0Improved diff_to_previous framebuffer performance2020/11/063.7.0Drop support for Python 3.5, only 3.6 or newer is supported nowAdd support for SSD1351 128x96 displayPin luma.core to 1.x.y line only, in anticipation of performance
improvements in upcoming major release2020/10/253.6.0Add support for Winstar OLED displays2020/09/243.5.0Drop support for Python 2.7, only 3.5 or newer is supported now2020/07/043.4.0Add support for SSD1362 256x64 Greyscale OLED2020/01/193.3.0Namespace fix2019/06/193.2.1Fix bug where SSD1325framebuffer=diff_to_prevdidn’t set
column address properly, resulting in garbled output2019/04/303.2.0Add support for 128x64 OLED (Newhaven SSD1322_NHD))2019/04/173.1.1Fix bug where SSD1327framebuffer=diff_to_prevdidn’t set
column address properly, resulting in garbled outputMinor API documentation improvements2019/03/303.1.0Add support for 128x64 monochrome OLED (SSD1309)2018/12/213.0.1Fix bug where SSD1325/1327 didn’t handleframebufferproperly2018/12/213.0.0BREAKINGFix SSD1351 init sequence didn’t set RGB/BGR color
order properly. Users of this device should verify proper color
rendering and addbgr=Trueif blue/red color components
appear to be reversedDevice consolidation - greyscale and colour SSD13xx devices now
share common base classes.2018/12/022.5.1Fix bug where SSD1331/1351 didn’t render green accurately2018/09/142.5.0Add support form 128x128 Monochrome OLED (SH1106) (by @Gadgetoid)Dependency and documentation updatesMinor packaging changes2018/09/072.4.1Fix bug where SSD1327 init sequence exceeds serial command size2018/05/282.4.0Support for 128x128 4-bit OLED (SSD1327)2018/04/182.3.2Support for 96x96 color OLED (SSD1351)2018/03/032.3.1Changed version number to insideluma/oled/__init__.py2017/11/232.3.0Support for 128x128 color OLED (SSD1351)2017/10/302.2.12Explicitly state ‘UTF-8’ encoding in setup when reading files2017/10/182.2.11Update dependenciesAdditional troubleshooting documentation2017/09/192.2.10Add support for 128x32 mode for SH11062017/05/012.2.9luma.core 0.9.0 or newer is required nowDocumentation amends2017/04/222.2.8SSD1331 & SSD1322 framebuffer & API docstrings2017/04/132.2.7Add support for 64x32 SSD1306 OLED2017/04/122.2.6Add support for 64x48 SSD1306 OLED2017/03/302.2.5Restrict exported Python symbols fromluma.oled.device2017/03/022.2.4Tweaked SSD1325 init settings & replaced constantsUpdate dependencies2017/02/172.2.3Monochrome rendering on SSD1322 & SSD13252017/02/142.2.2SSD1325 performance improvements (perfloop: 25.50 –> 34.31 FPS)SSD1331 performance improvements (perfloop: 34.64 –> 51.89 FPS)2017/02/022.2.1Support for 256x64 4-bit greyscale OLED (SSD1322)Improved API documentation (shows inherited members)2017/01/292.1.0Simplify/optimize SSD1306 display logic2017/01/222.0.1Moved examples to separate git repoAdd notes about breaking changes2017/01/152.0.0Package rename toluma.oled(Note:Breaking changes)2017/01/111.5.0Performance improvements for SH1106 driver (2x frame rate!)Support for 4-bit greyscale OLED (SSD1325)Landscape/portrait orientation with rotate=N parameter2017/01/091.4.0Add savepoint/restore functionalityAdd terminal functionalityCanvas image ditheringAdditional & improved examplesLoad config settings from file (for examples)Universal wheel distributionImproved/simplified error reportingDocumentation updates2016/12/231.3.1Add ability to adjust brightness of screenFix for wrong value NORMALDISPLAY for SSD1331 device2016/12/111.3.0Support for 16-bit color OLED (SSD1331)Viewport/scrolling supportRemove pygame as an install dependency in setupEnsure SH1106 device collapses color images to monochromeFix for emulated devices: do not need cleanupFix to allow gifanim emulator to process 1-bit imagesEstablish a single threadpool for all virtual viewportsFix issue preventing multiple threads from running concurrentlyDocumentation updates2016/12/111.2.0Add support for 128x32, 96x16 OLED screens (SSD1306 chipset only)Fix boundary condition error when supplying max-frames to gifanimBit pattern calc rework when conveting color -> monochromeApprox 20% performance improvement indisplaymethod2016/12/081.1.0Add animated-GIF emulatorAdd color-mode flag to emulatorFix regression in SPI interfaceRename emulator transform option ‘scale’ to ‘identity’2016/12/051.0.0Add HQX scaling to capture and pygame emulatorsSPI support (NOTE:contains breaking changes)Improve benchmarking examplesFix resource leakage & noops on emulated devicesAdditional tests2016/12/030.3.5Pygame-based device emulator & screen capture device emulatorAdd bouncing balls demo, clock & Space Invaders examplesAuto cleanup on exitAddbounding_boxattribute to devicesDemote buffer & pages attributes to “internal use” onlyReplaced SH1106 data sheet with version that is not “preliminary”Add font attributionTests for SSD1306 & SSH1106 devicesAdd code coverage & upload to coveralls.ioflake8 code complianceDocumentation updates2016/11/300.3.4Performance improvements - render speeds ~2x fasterDocumentation updates2016/11/150.3.3Add PyPi badgeUse smbus22016/11/150.3.2Fix bug in maze example (integer division on python 3)Use latest pipAdd tox & travis config (+ badge)Add RTFD configDocumentation updates2016/11/130.3.1Adjust requirements (remove smbus)Default RTFD themeDocumentation updates2016/11/130.3.0Allow SMBus implementation to be suppliedAdd show, hide and clear methodsCatch & rethrowIOErrorexceptionsFix error in ‘hello world’ exampleCleanup importsAllow setting width/heightDocumentation updates2016/11/130.2.0Add Python 3 supportAdd options to demosMicro-optimizationsRemove unused optional argFix bug in rendering image dataAdded more examplesAdd setup fileSupport SH1106Documentation updates2016/09/06