OLED modules based on SSD1306 provides 128x64 (or 128x32) monochrome displays with SPI and/or I2C interface. Focus here is SPI 128x64 version.
Info:
Modules can be bought for ~$3 on ebay.
Module characteristics:
Controller | SSD1306 |
Resolution | 128x64 (128x32 exists) |
Color | Monochrome, White, blue or Yellow/Blue |
Interface | SPI, I2C |
Supply | 3-5V |
Size | 0.96" or 1.3" |
This library relies on ATmega or STM32 HW SPI master, so SCK and MOSI are connected to SPI pins. SS (or CS) is managed in SW (allowing multiple devices on same SPI bus).
On application with limited number on IOs, some pins can be ommited: SS and RST can be tied low (then, only a single device is supported).
OLED Module | Description | Pro Mini (ATmega) | STM32 |
---|---|---|---|
GND (1) | Ground | (GND) | (G) |
VCC (2) | Power (3.3V) | (VCC) | (3.3) |
D0 (3) | Serial Clock | SCK/PB5 (13) | SCK1/PB3 (B3) |
D1 (4) | Data (MOSI) | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
RST (5) | Reset (low) | Any Digital/PB0 (8) | Any Digital/PB7 (B7) |
DC (6) | Data/Command | Any Digital/PB1 (9) | Any Digital/PB8 (B8) |
CS (7) | Chip Select (low) | Any Digital/PB2 (10) | Any Digital/PB9 (B9) |
TFT LCD modules based on ILI9341 (TJCTM24024-SPI) provides 240x320 color displays (with touchscreen support) via SPI interface.
Info: https://learn.adafruit.com/monochrome-oled-breakouts/downloads
Modules can be bought for ~$8 on ebay.
Module characteristics:
Controller (LCD) | ILI9341 |
Controller (Touch) | XPT2046/ADS7843 |
Resolution | 240x320 |
Color | 262K color (18-bits) |
Interface | SPI |
Supply/b> | 3.0V (IO are 3.3V max) |
Size | 2.4" (or 1.8", 1.44") |
LCD Module | Description | Pro Mini (ATmega) | STM32 |
---|---|---|---|
VCC (1) | Power (3.3V) | (VCC) | (3.3) |
GND (2) | Ground | (GND) | (G) |
CS (3) | Chip Select (low) | Any Digital/PB2 (10) | Any Digital/PB9 (B9) |
RESET (4) | Reset (low) | Any Digital/PB0 (8) | Any Digital/PB7 (B7) |
D/C (5) | Data/Command | Any Digital/PB1 (9) | Any Digital/PB8 (B8) |
SDI(MOSI) (6) | Data In (MOSI) | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
SCK (7) | Serial Clock | SCK/PB5 (13) | SCK1/PB3 (B3) |
LED (8) | LED (Backlight) | VCC | 3.3 |
SDO(MISO) (9) | Data Out (MISO) | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
T_CLK (10) | Touch Serial Clock | SCK/PB5 (13) | SCK1/PB3 (B3) |
T_CS (11) | Touch Chip Select (low) | Any Digital/PB2 (10) | Any Digital/PB9 (B9) |
T_DIN (12) | Touch Data In | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
T_DO (13) | Touch Data Out | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
T_IRQ (14) | Touch Interrupt | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
SD_CS (1) | SDCard Chip Select (low) | Any Digital/PB2 (10) | Any Digital/PB9 (B9) |
SD_MOSI (2) | SDCard Data In (MOSI) | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
SD_MISO (3) | SDCard Data Out (MISO) | MOSI/PB3 (11) | MOSI1/PB5 (B5) |
SD_SCK (4) | SDCard Serial Clock | SCK/PB5 (13) | SCK1/PB3 (B3) |