/*
* Tiny4kOLED - Drivers for SSD1306 controlled dot matrix OLED/PLED 128x32 displays
*
* Based on ssd1306xled, re-written and extended by Stephen Denne
* from 2017-04-25 at https://github.com/datacute/Tiny4kOLED
*
*/
// Choose your I2C implementation before including Tiny4kOLED.h
// The default is selected is Wire.h
// To use the Wire library:
//#include <Wire.h>
// To use the Adafruit's TinyWireM library:
#include <TinyWireM.h>
// To use the TinyI2C library from https://github.com/technoblogy/tiny-i2c
//#include <TinyI2CMaster.h>
// The blue OLED screen requires a long initialization on power on.
// The code to wait for it to be ready uses 20 bytes of program storage space
// If you are using a white OLED, this can be reclaimed by uncommenting
// the following line (before including Tiny4kOLED.h):
//#define TINY4KOLED_QUICK_BEGIN
#include <Tiny4kOLED.h>
const uint8_t solomon_systech_logo_bitmap[] PROGMEM = {
// Here's the data...
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xC0,0xC0,0xC0,0xE0,0xE0,0xE0,0xF0,0xF0,0xF0,0xF0,0xF8,0xF8,0xF8,0xF8,0xF8,0xF8,0xF8,0xF8,0xF0,0x70,0x70,0x60,0x60,0x40,0x00,0x00,
0x00,0x00,0x00,0x80,0xC0,0x60,0x60,0x30,0x31,0x18,0x1C,0x9C,0x8E,0x8E,0x87,0xC7,0xC7,0xC3,0xC3,0xE3,0xE1,0xE1,0xE1,0xE1,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF0,0xF8,0xF8,0xF8,0xF8,0xF8,0x38,
0x02,0x05,0x05,0x04,0x06,0x06,0x02,0x03,0x03,0x03,0x03,0x03,0x03,0x03,0x03,0x83,0x83,0xC3,0xE3,0xF3,0xFB,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0x7F,0x3F,0x1F,0x0F,0x07,0x03,0x00,0x00,
0x00,0x00,0x00,0x00,0x0C,0x0C,0x1C,0x1C,0x1C,0x1C,0x1E,0x1E,0x1E,0x1F,0x1F,0x1F,0x0F,0x0F,0x0F,0x0F,0x07,0x07,0x07,0x03,0x03,0x01,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00
};
// Here's the data for the second "SOLOMON SYSTECH" image, 69 pixels wide x 4 pages
const uint8_t solomon_systech_text_bitmap[] PROGMEM = {
0x78,0xFC,0xFE,0xC6,0xC6,0x9E,0x9C,0x18,0x00,0xE0,0xFC,0xFC,0x0E,0x06,0x0E,0xFC,0xFC,0xF8,0x00,0x00,0xFE,0xFE,0x00,0x00,0x00,0x00,0x00,0xE0,0xFC,0xFC,0x0E,0x06,0x06,0xFC,0xFC,0xF8,0x00,0x00,0xFE,0xFE,0x3C,0xFC,0xE0,0x00,0xF0,0xFC,0x3C,0xFE,0xFC,0x00,0x00,0xF8,0xFC,0xFE,0x06,0x06,0x1E,0xFC,0xFC,0x00,0x00,0xFE,0xFE,0xFC,0x7C,0xE0,0x00,0xFE,0xFE,
0x1C,0x1C,0x3C,0x31,0x31,0x3F,0x1F,0x0F,0x00,0x03,0x1F,0x1F,0x38,0x30,0x38,0x3F,0x1F,0x0F,0x00,0x00,0x3F,0x3F,0x38,0x38,0x38,0x38,0x10,0x03,0x1F,0x1F,0x38,0x30,0x30,0x3F,0x1F,0x0F,0x00,0x00,0x3F,0x3F,0x00,0x01,0x1F,0x3F,0x1F,0x00,0x00,0x3F,0x3F,0x00,0x00,0x0F,0x1F,0x3F,0x30,0x30,0x3C,0x1F,0x1F,0x00,0x00,0x3F,0x3F,0x1F,0x00,0x07,0x1F,0x3F,0x3F,
0x00,0x00,0x00,0x00,0xF0,0xF8,0xD8,0x88,0x18,0x38,0x38,0x20,0x00,0x38,0xF8,0xF8,0xC0,0xC0,0xF8,0x78,0x18,0x00,0xF0,0xF8,0xF8,0x88,0x18,0x38,0x38,0x20,0x00,0x18,0x18,0xF8,0xF8,0xF8,0x18,0x18,0x00,0x00,0xF8,0xF8,0xB8,0x18,0x18,0x18,0x18,0x00,0xE0,0xF8,0xF8,0x18,0x08,0x18,0x78,0x70,0x00,0x00,0xF8,0xF8,0xF8,0x80,0x80,0xF8,0xF8,0xF8,0x00,0x00,0x00,
0x00,0x00,0x00,0x00,0x39,0x79,0x63,0x63,0x67,0x7F,0x3E,0x1C,0x00,0x00,0x00,0x2F,0x7F,0x7F,0x03,0x00,0x00,0x00,0x38,0x79,0x73,0x63,0x67,0x7F,0x3E,0x1C,0x00,0x00,0x00,0x7F,0x7F,0x7F,0x00,0x00,0x00,0x00,0x7F,0x7F,0x73,0x63,0x63,0x63,0x61,0x00,0x1F,0x3F,0x7F,0x60,0x60,0x70,0x7C,0x3C,0x00,0x00,0x7F,0x7F,0x7F,0x03,0x03,0x7F,0x7F,0x7F,0x00,0x00,0x00
};
// ============================================================================
void setup() {
// put your setup code here, to run once:
oled.begin();
// Two rotations are supported,
// The begin() method sets the rotation to 1.
//oled.setRotation(0);
// Some newer devices do not contain an external current reference.
// Older devices may also support using the internal curret reference,
// which provides more consistent brightness across devices.
// The internal current reference can be configured as either low current, or high current.
// Using true as the parameter value choses the high current internal current reference,
// resulting in a brighter display, and a more effective contrast setting.
//oled.setInternalIref(true);
// This example does not use double buffering.
// To save space, the bitmap is cropped left and right,
// intended to be drawn onto a clear screen
oled.clear();
// The display will show two bitmaps,
// one of SOLOMON SYSTECH's logo
// one of the text SOLOMON SYSTECH
// The logo bitmap is 37 pixels wide
// The text bitmap is 69 pixels wide
// Both are 32 pixels (4 pages) high
oled.bitmap(6, 0, 6 + 37, 4, solomon_systech_logo_bitmap);
oled.bitmap(54, 0, 54 + 69, 4, solomon_systech_text_bitmap);
// Now that the display is all setup, turn on the display
oled.on();
}
void loop() {
// This example only shows a static image on the display.
// The microcontroller could be turned off now.
}