#include <Arduino.h>
#include <U8g2lib.h>
#ifdef U8X8_HAVE_HW_SPI
#include <SPI.h>
#endif
#ifdef U8X8_HAVE_HW_I2C
#include <Wire.h>
#endif
/*
Illustrating the use of cyrillic text on the 128x64 OLED display
*/
U8G2_SSD1306_128X64_NONAME_F_SW_I2C u8g2(U8G2_R0, SCL, SDA, U8X8_PIN_NONE);
void setup(void) {
u8g2.begin();
u8g2.enableUTF8Print(); // enable UTF8 support for the Arduino print() function
}
void loop(void) {
// select a font with 11px height
u8g2.setFont(u8g2_font_cu12_t_cyrillic);
u8g2.firstPage();
do {
u8g2.setCursor(0, 40);
u8g2.print("Всем привет!");
u8g2.setCursor(0,12);
u8g2.print("Как у вас?");
} while ( u8g2.nextPage() );
}