SSD1306 OLED display driver
1.8.2
This library is developed to control SSD1306/SSD1331/SSD1351/IL9163/PCD8554 RGB i2c/spi LED displays
|
#include <lcd_common.h>
Public Attributes | |
lcd_type_t | type |
lcduint_t | width |
lcduint_t | height |
void(* | set_block )(lcduint_t x, lcduint_t y, lcduint_t w) |
Sets block in RAM of lcd display controller to write data to. More... | |
void(* | next_page )(void) |
void(* | send_pixels1 )(uint8_t data) |
void(* | send_pixels_buffer1 )(const uint8_t *buffer, uint16_t len) |
void(* | send_pixels8 )(uint8_t data) |
Sends RGB pixel encoded in 3-3-2 format to OLED driver. Sends RGB pixel encoded in 3-3-2 format to OLED driver. More... | |
void(* | send_pixels16 )(uint16_t data) |
Sends RGB pixel encoded in 5-6-5 format to OLED driver. Sends RGB pixel encoded in 5-6-5 format to OLED driver. More... | |
void(* | set_mode )(lcd_mode_t mode) |
Sets library display mode for direct draw functions. More... | |
Structure, describing display driver configuration
Definition at line 88 of file lcd_common.h.
lcduint_t ssd1306_lcd_t::height |
Current display height
Definition at line 97 of file lcd_common.h.
void(* ssd1306_lcd_t::next_page) (void) |
Switches to the start of next RAM page for the block, specified by set_block(). For ssd1306 it does nothing, while for sh1106 the function moves cursor to next page.
Definition at line 122 of file lcd_common.h.
void(* ssd1306_lcd_t::send_pixels1) (uint8_t data) |
Sends 8 monochrome vertical pixels to OLED driver.
data | - byte, representing 8 pixels. |
Definition at line 128 of file lcd_common.h.
void(* ssd1306_lcd_t::send_pixels16) (uint16_t data) |
Sends RGB pixel encoded in 5-6-5 format to OLED driver. Sends RGB pixel encoded in 5-6-5 format to OLED driver.
data | 16-bit word, representing RGB16 pixel |
Definition at line 149 of file lcd_common.h.
void(* ssd1306_lcd_t::send_pixels8) (uint8_t data) |
Sends RGB pixel encoded in 3-3-2 format to OLED driver. Sends RGB pixel encoded in 3-3-2 format to OLED driver.
data | - byte, representing RGB8 pixel. |
Definition at line 142 of file lcd_common.h.
void(* ssd1306_lcd_t::send_pixels_buffer1) (const uint8_t *buffer, uint16_t len) |
Sends buffer containing 8 monochrome vertical pixels, encoded in each byte.
buffer | - buffer containing monochrome pixels. |
len | - length of buffer in bytes. |
Definition at line 135 of file lcd_common.h.
Sets block in RAM of lcd display controller to write data to.
Sets block in RAM of lcd display controller to write data to. For ssd1306 it uses horizontal addressing mode, while for sh1106 the function uses page addressing mode. Width can be specified as 0, thus the library will set the right boundary to region of RAM block to the right column of the display.
x | - column (left region) |
y | - page (top page of the block) |
w | - width of the block in pixels to control |
Definition at line 114 of file lcd_common.h.
void(* ssd1306_lcd_t::set_mode) (lcd_mode_t mode) |
Sets library display mode for direct draw functions.
Sets library display mode for direct draw functions. There are currently 2 modes supported: LCD_MODE_SSD1306_COMPAT and LCD_MODE_NORMAL. In general, ssd1306 compatible mode uses different GDRAM addressing mode, than normal mode, intended for using with RBG full-color functions.
mode | lcd mode to activate. |
Definition at line 164 of file lcd_common.h.
lcd_type_t ssd1306_lcd_t::type |
Current selected lcd display type
Definition at line 91 of file lcd_common.h.
lcduint_t ssd1306_lcd_t::width |
Current display width
Definition at line 94 of file lcd_common.h.