Advertisement
Guest User

Untitled

a guest
Aug 1st, 2019
304
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <SPI.h>
  2. #include <TFT_eSPI.h>
  3. #include "Free_Fonts.h"
  4.  
  5. #define podsviceni 4
  6.  
  7. TFT_eSPI displej = TFT_eSPI(135, 240);
  8.  
  9. void setup(){
  10.   displej.init();
  11.  
  12.   pinMode(podsviceni, OUTPUT);
  13.   digitalWrite(podsviceni, LOW);
  14.  
  15.   displej.setRotation(1);
  16.   displej.fillScreen(TFT_RED);
  17.   displej.setTextFont(GLCD);
  18.   displej.setFreeFont(&FreeSerif9pt7b);
  19.   displej.setTextColor(TFT_WHITE);
  20.   digitalWrite(podsviceni, HIGH);
  21.   displej.drawString("Ahoj", displej.width() / 2, displej.height() / 2);
  22. }
  23.  
  24. void loop(){
  25.  
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement