User Manual
oled.print("A0: ");
oled.setFontType(2);
oled.print(analogRead(A0));
oled.setCursor(0, 16);
oled.setFontType(0);
oled.print("A1: ");
oled.setFontType(2);
oled.print(analogRead(A1));
oled.setCursor(0, 32);
oled.setFontType(0);
oled.print("A2: ");
oled.setFontType(2);
oled.print(analogRead(A2));
oled.display();
delay(100);
}
oled.setFontType(3);
int ms = 0;
int s = 0;
while (s <= 5)
{
oled.clear(PAGE);
oled.setCursor(0, 0);
if (s < 10)
oled.print("00");
else if (s < 100)
oled.print("0");
oled.print(s);
oled.print(":");
oled.print(ms);
oled.display();
ms++;
if (ms >= 10)
{
ms = 0;
s++;
}
}
}
void printTitle(String title, int font)
{
int middleX = oled.getLCDWidth() / 2;
int middleY = oled.getLCDHeight() / 2;
oled.clear(PAGE);
oled.setFontType(font);
oled.setCursor(middleX - (oled.getFontWidth() * (title.length()/2)),
13/17