Module SSD1306 :: Class SSD1306Base
[hide private]
[frames] | no frames]

Class SSD1306Base

source code

object --+
         |
        SSD1306Base
Known Subclasses:

Base class for SSD1306-based OLED displays. Implementors should subclass and provide an implementation for the _initialize function.

Instance Methods [hide private]
 
__init__(self, width, height, rst, dc=None, sclk=None, din=None, cs=None, gpio=None, spi=None, i2c_bus=None, i2c_address=60, i2c=None)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
_initialize(self) source code
 
command(self, c)
Send command byte to display.
source code
 
data(self, c)
Send byte of data to display.
source code
 
begin(self, vccstate=2)
Initialize display.
source code
 
reset(self) source code
 
display(self)
Write display buffer to physical display.
source code
 
image(self, image)
Set buffer to value of Python Imaging Library image.
source code
 
clear(self)
Clear contents of image buffer.
source code
 
set_contrast(self, contrast)
Sets the contrast of the display.
source code
 
dim(self, dim)
Adjusts contrast to dim the display if dim is True, otherwise sets the contrast to normal brightness if dim is False.
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, width, height, rst, dc=None, sclk=None, din=None, cs=None, gpio=None, spi=None, i2c_bus=None, i2c_address=60, i2c=None)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

image(self, image)

source code 

Set buffer to value of Python Imaging Library image. The image should be in 1 bit mode and a size equal to the display size.

set_contrast(self, contrast)

source code 

Sets the contrast of the display. Contrast should be a value between 0 and 255.