#include <Arduino.h>
#include <U8g2lib.h>
#include <Wire.h>
#define SCL 2
#define SDA 4
//U8G2_SSD1306_128×64_NONAME_F_SW_I2C u8g2(U8G2_RO,SCL,SDA,U8X8_PIN_NONE){初始化绑定IO}
// u8g2.clearBuffer();{清空显示}
//u8g2.setFont(u8g2_font_ncenB14_tr){设置字体格式}
//u8g2.drawStr(0,24,"hello!"){设置显示内容}
//u8g2.sendBuffer();{开始显示}
U8G2_SSD1306_128X64_NONAME_F_SW_I2C u8g2(U8G2_R0,SCL,SDA,U8X8_PIN_NONE);
void setup() {
// put your setup code here, to run once:
u8g2.begin();
}
void loop() {
// put your main code here, to run repeatedly:
u8g2.clearBuffer();
u8g2.setFont(u8g2_font_ncenB14_tr);
u8g2.drawStr(0,24,"LOVEMYLU!");
u8g2.sendBuffer();
delay(1000);
}
// put function definitions here:
esp:VIN
esp:GND.2
esp:D13
esp:D12
esp:D14
esp:D27
esp:D26
esp:D25
esp:D33
esp:D32
esp:D35
esp:D34
esp:VN
esp:VP
esp:EN
esp:3V3
esp:GND.1
esp:D15
esp:D2
esp:D4
esp:RX2
esp:TX2
esp:D5
esp:D18
esp:D19
esp:D21
esp:RX0
esp:TX0
esp:D22
esp:D23
oled1:GND
oled1:VCC
oled1:SCL
oled1:SDA