How to use TFT_eSPI library and ESP32 (PROGRAMING TUTORIAL PART 1.)
Ғылым және технология
This is my first programing tutorial in this tutorial we will use this TTGO t-display board. But you can use any esp32 board and tft display. I will show you how to use tft_espi library (made by Bodmer), how to make these good looking interefaces and much more. Dealing with fonts, colors and so onOfc we will also use progrming fundamentals like conditions, loops arrays of data and more. Later we will try to make game .This si PART1.
Hot to setup Arduino IDE for TTGO T-Display
• How to Install and Set...
Colos Picker:
www.barth-dev.de/online/rgb565...
You can buy TTGO T-Display here:
www.lilygo.cc/Q0oIsn
PART 2 VIDEO:
• How to use TFT_eSPI li... Lines, circles, rectangles
PART 3:
• How to program TTGO T-... Images and Custom Fonts
You can also buy me a coffe at:
ko-fi.com/volosprojects
Пікірлер: 161
You can also check PART2 video : kzread.info/dash/bejne/c62pz6yOcanKipM.html
@johnh5073
Жыл бұрын
You are THE BEST and the MOST PATIENT. TY so much. It was indeed that select file.
So timely and excited about this series!
That is the exact Video I need, because I just ordered my own boards
@VolosProjects
2 жыл бұрын
I am glad you like it😀
Thanks for sharing this. The fact that you provide this for free is even more awesome. I just subscribed to your channel. Please share more and thanks again!
Thank you for both TFT video's. It helped me greatly to get on my feet using this library. I love your video's so far. I really like how you make these video's. You go slow and explain everything very well. Most other content makers go too fast. And they tend to jump over critical information. So thank you, thank you, thank you. ❤
I liked it too much! I've always seen your TTGO projects and now I can learn from you! It's fantastic! Thanks.
@VolosProjects
2 жыл бұрын
glad you like it :)
Very Informative. You put alot of important information into your videos, that others just assume us newbies know. Thank You for your time.
Nice!!! Putting this into practice after seeing the video. Great that you are taking time to teach us the basics. Thank you.
@VolosProjects
2 жыл бұрын
Thank you for the coffe. Feel free to ask if you need help😀
I am new to these ESP32s...Your teaching style fits my learning style well!!! This has been the most comprehensive tutorial I have watched so far!! Thank you!!
@VolosProjects
2 жыл бұрын
Thank you Jason, i am glad i helped you. Tnx for cofee 😀
Thank you so much! It is the best class about TFT display, that I saw on youtube. You are gold mate!
@VolosProjects
Жыл бұрын
Tnx, i am glad you like it :)
Excellent explanations at an understandable speed. Very Well done
Thanks, very clear and perfect for a beginner as I am. Cheers from France
Excellent video for my students starting off using a TFT eSPI display!
Thank you for this series
So glad i found this video of yours, it'll help me a lot with my T Display S3 Pro while i wait for my WaveShare 7" display that's on its way. Now I just need to figure out how all the touchscreen features are implemented to use it as an actual screen to control stuff 😅 keep up the amazing work Volos, love your channel and the amazing projects you do 🙌
Just what I was looking for!
Thank you. I've learned a lot. You are a good instructor 😊
I Watched whole video. Great work, thankyou.
Such a fantastic video, thank you! Please don’t be her in yourself about your English! You are very easy to understand and are giving all of us the gift of your experience!
Excellent video for those of us starting off using a TFT eSPI display! By the way, the next time you are looking for "Dark Blue" color, use the "Navy" (TFT_NAVY) color. That is "Dark Blue". Always look forward to your videos!
@VolosProjects
2 жыл бұрын
Thanks man, I just tried navy, thank you.
Good stuff. Nice clear explanations.
Thank you !!, I liked it too much! I've always seen your TTGO projects and now I can learn from you! And.. your English is perfect!. Thanks.
@VolosProjects
Жыл бұрын
Thank you Sandra, I hope that you will find interesting content on my channel. Cheers
This was a great tutorial! Thank you
Perfect explanation, the best.
Excellent ,it might be basic stuff as you say but for us learning its extremely helpfull Your Videos are wonderfull thank you so much
Hi! My name is Cezar, from Rio de Janeiro - Brazil. Congratulations by the series! I hope you continue this work! You are the best channel talking about TTGO. I always follow your videos. As soon as possible, I'll get you some coffee. You've deserved it for a long time. Hugs.
@VolosProjects
2 жыл бұрын
Thank you Cezar, I am glad that you like videos😀
I spend too much time on fonts and colours too, you are not alone. By the way your English is fine, thank you
Thank you sir for this video .The world is a wonderful place because of people like you
@VolosProjects
3 ай бұрын
It's my pleasure. Thank you!
This is amazing man! Thanks! Early Christmas present!!!
@VolosProjects
2 жыл бұрын
No problem, enjoy :)
Ops Hit wrong button... As I was saying I will being using this for both myself and my grandson to get him interested in building his own games instead of buying them. Thanks again for your presentation, This was great for this 75 yr old guy.
Sehr gut gemacht , danke Werner
Perfect!!! Well done!!
@VolosProjects
3 ай бұрын
Thanks a lot!
Amazing! Subscribed immediately :)
this vidéo was really helpfull, thank you
Great vid tutorial. Thanks.
Wonderfull instruction, thank you.
Amazing, thanks!
Very nice! Thank YOU!
Complimenti per la semplicità con qui spieghi. Grazie
Thank you for this. Excellentm
Ottimo 1 sei un grande
Really helpful video.
I am very much looking forward to these tutorial videos as I started last year programming ESP32's and I am trying to make a GPS speed meter which displays the maximum speed a RC car has reached before you press a button to reset it and I had all kinds of problems with the display and fonts, The font size I wanted to use didn't have the characters I needed so in the end I stopped working on it but I hope to learn enough from your tutorial to start it back up again.
@SirSiegward
2 жыл бұрын
This is my first time working with an ESP32. I’m using it for a rather useless reason. I have a really decked out guitar hero controller, I have a custom paint job, custom buttons, custom everything pretty much. I even swapped out the old mechanism for the fret buttons with mechanical keyboard fret buttons underneath. Anyways…I’m going to cut a hole for a little screen in the body of the guitar hero controller, put a little protective lens over the screen hole, mount the screen on the inside of the guitar hero controller in front of the little lens window, and then play gifs on the screen. I’ve routed everything out, and it should go as planned…I’ve got a hole drilled out on the shell of the guitar hero controller for the battery pack that I have for the ESP32 to be recharged…it’s going to be great. It’s going to be cool to have a little screen on a guitar hero controller, but it’s never been done before!
I love your videos, they are very helpfull with My college project. Your English is very good and relaxing tho.
Very well explained
Yes I watched the entire video THANKS
Great video, helping me to use this display and ESP32
@VolosProjects
2 жыл бұрын
Thank you. Nice to hear that.
Excellent. More pls :)
Very good video.
very helpfull thank u sir!
Thank You Very Much, I will be watching all of your videos to the end. I cant get your Alien game to work, Spent many hours researching Stray Errors. lots of suggestions but none worked. Lilygo S3 Arduino 2.0.4.
Yes - definitely watched till the end. As a result, you got a new subscriber! Your English is fine and because you speak at that pace, it's very clear. I share your passion for displays, especially small ones and can't wait for your next video's. As a challenge - could you eventually have a tutorial to display video at 24 fps ??
@VolosProjects
2 жыл бұрын
Thank you. I am thinking for a while about videos , i hope soon..
Nice project
Well done! Many thanks!
@VolosProjects
2 жыл бұрын
Your welcome😀
@ghazimalik
2 жыл бұрын
Excellent.
Man your gauges look so good, I only managed to get one display working on my Arduino Uno using the code from someone else but the guy didn't update the code and it was quite a long time ago for him to make the project so the questions I asked him about how he created the graphics he couldn't give me any useful answers. Because of that I had to figure it all out myself by changing one value at a time, uploading the sketch and then see what happens and that over and over again until I almost had it working on my display which is smaller so I had to change everything manually, that took a long time and it's still not exactly as I need it to be and I can't figure that part out because I don't know what I'm doing when it comes to displays and coding graphics is not my strongest point so whenever I can use something from someone else who already knows how it works I don't see the need to invent the wheel again so to speak right? Saves a lot of time when it works the right way first time and the code is clear to understand and has the necessary comments in the right place so I can easily see what part of the code does what and what I need to change to make it work for my hardware which is especially important when the hardware isn't exactly the same as the person sharing the project online. In my case I thought I could easily change the code because the guy sharing it added in the comments that using his code on a different display smaller or bigger could be done simply by scaling but he didn't explain what I needed to change and where to make that scaling happen and because I don't know what I'm doing I couldn't get that figured out so I just changed everything manually to get the graphics to fit on my display, can you imagine the process I had to do? That was not a lot of fun I can tell you that much. So I really hope that your code is easier for me to understand and I bought the exact same model board as you showed in your latest video using your link, that way I know there's no difference at all in the hardware which should make it much easier for me to follow along with you. Thanks for sharing this here on KZread, I appreciate it very much.
Thank you.
muito bom mano vei...
Thank you
thank you for this tutorial, i ordered one of these and aim to use it for the bargraphs in my ghostbusters gun.
@VolosProjects
Жыл бұрын
your ghostbusters gun? interesting, can you explain a bit?
@IowaMan
Жыл бұрын
@@VolosProjects oh yeah for sure! if you look up ghostbusters nuetrino/neutrona gun you'll see there are two bar graphs located by two switches, usually most people get the bar graph animated with led's, some times the circle ones too! after seeing this a lightbulb lit up as this would be so cool for having both on one display! with your tutorial i'm hoping i can figure something =D
Thank you, this was very informative, as a very beginner. And don't worry about your English it will improve as you make more tutorials. Thanks again
@VolosProjects
2 жыл бұрын
Thank you😁
Thank you for this video:-). You should do more 'basic Staff' videos:-), It is helpful more than you know.
@VolosProjects
2 жыл бұрын
Hvala, drago mi je da pomognu. Uskoro planiram više ovakvih videa. Uživaj!
excellent video very well explained a question you could explain with configuring the user.setup.h file for an esp32 thank you ..!
A suggestion for a useful project would be a colour picker based on the st7789, st7735, Ili9341 displays, some colours and combinations look great while others look very poor, to generate the RGB 565 code on the actual display would be great. Many thanks.
@VolosProjects
2 жыл бұрын
My next video will be color picker, dont miss it. Thank you for idea :)
Pretty good. Where can i find a list of all your projects? Reinhard
Your tutorials are great. Can you do one on ttgo data retrieval and displaying the data on screen
@VolosProjects
2 жыл бұрын
Thank you😀 i havent fully understand you, data retrieval?
ultra interesting i buy lilygo display with SD card but impossible to use it , if you have time it could be very cool to get help. I m also interesting to use this TTGO with an external SD card to display a video.
Hi, Great video man. Will this library work with st7735 display? I have tried that display with arduino nano to build a menu system using adafruit libraries, but the display seems to be very slow to update, but the same logic works with the 0.96" i2c oled ssd1306 display without any lag and flickering. Do you know why? Is the library causing the problem or the st7735 display?
tuyệt vời
Great work, many thanks, please switch off the mouse click noise.
Have you found how to make a multiline text or word wrap with TFT_eSPI? I want to set a large text that will fill in the screen or a textbox.
Thank you! Very helpful. Is there a way to draw text in landscape style (rotated 90 degrees)?
@OldManSparkplug
2 жыл бұрын
answered my own question, it's tft.setRotation(1);
Hey, Volos! Which type of image is used in this board? The array have only 1 byte per position, so, it's not a RGB565, I suppose.
@VolosProjects
Жыл бұрын
it is rgb565, two bytes per pixel
@dobitaobyte
Жыл бұрын
@@VolosProjects Sorry, man! I commented in this vídeo because I was watching this one too. My doubt is related to T-Display S3. The example in LilyGo sketch is using an array uint8, I'm getting crazy to understand it
I get no display functions as soon as I activate the display functions and vice versa. Each work on the same board without issues, individually. But as soon as I start the server, the display dies. I believe server and display driver have conflicts. Did you test this with wifi AND display at the same time?
Nice video ! Nice explanations. What about if you would like to paint one part of the screen in one color, and the other part in other color ? Thanks for everything.
@VolosProjects
2 жыл бұрын
you will draw two rectangles , each in diferent color and on diferent cordinates, here is tutorial how to draw rectangles kzread.info/dash/bejne/c62pz6yOcanKipM.html
@jean-noelcollin9912
2 жыл бұрын
@@VolosProjects Thank you so much ! Nice day to you, from Greece.
@VolosProjects
2 жыл бұрын
@@jean-noelcollin9912 have a nice day you too. 😁
Great video! But Ive faced a problem that my numbers overlap one on top of each other. As I saw in your video, u didn’t “refresh” the screen. (I use TFT on IL9341 (240x320), if it matters) Any suggestions on that?
i think world needs a library that can program other devices on the fly, like program ttgo to be serial programmer and simplified way of wordlist to program another device. thatll be usefull.... hope so eone writes that before i find time to start trying ;p
A question: how to implement accented characters (ì, ì, è, ò, ù) and relative capitalization, with the TFT_eSPI library? I'm Italian and I need these characters. It prints everything for me but not those. Thank you
Hi, great video, looking forward to more esp32 projects, The link to the Color picker is incorrect, the “b” is missing off the beginning of the link.
@VolosProjects
2 жыл бұрын
Thank you, i corrected mistake in link. Thank you again :)
Excellent Tutorial and Starting point, I need to make several projects using this TTGO T Display board Thanks .. You're busy or missed this (below) so I have answered my own questions. LoL I hope they are right but I'm a rank novice at this : 1.) Why do you seem to always select the Board type for these TTGO T Display board projects as "TTGO LoRa 32-OLED" when this is not and OLED is it? and its definitely not the LoRa radio version of the TTGO dev board either as far as I can tell.. Ans: the internal Espressif ESP chip is the same on the LoRa boards so it's a good fit for the TTGO T-Display ( standard) dev module. 2.) is that Board type selection valid for all TTGO Display types, Ans: No, its definitely not. The newer TTGO T-Display S3 series and OMOLED boards as well as the T-QT all need a fifferent Board type selection. I am not sure not believe these all need Type: "ESP32 S3 Dev Kit" or sometrhing similar. One thing I found out is you can't expect the Board type name to be the same in the Arduino IDE as it is called in the PlatformIO IDE, they are slightly different and if your board type selection is wrong or some of the parameters under it don't match the code may not compile without a lot of warnings and errors. 3.) How would you know what Board type to use for other types of display dev boards with different types of displays? is this Board to Board Part Name or Number type cross-reference info located some where in a table in English? Perhaps I should just Google it .. and like everything else .. the answer would likely appear.. Sorry I'm so lazy.. 😝 Ans: I couldn't find a way other than to ask the mfr's tech support team,, ( or look here in the YT videos Danko is making. I'm not sure that is his 1st name but suspect it is because that is the name of his C:\Users subdirectory. 😂😂
Your videos have been VERY helpful in understanding how to use my ESP32 and TFT display... I'm struggling to find any documentation on the functions in the TFT_eSPI library and their parameters. Have you found anything which lists all of the functions in library?
@VolosProjects
2 жыл бұрын
Thanks Mike, I haven't find list of all functions, i learned from examples, but good documentation wood be so useful.
@ursmii_
Жыл бұрын
look in the library TFT_eSPI.h -> Section 8: Class member and support functions
Can font 7, the seven segment numbers be any larger or are they just one size?
@VolosProjects
2 жыл бұрын
They are always same size, in next video i will show how to make custom font in any size
@0miker0
2 жыл бұрын
@@VolosProjects great and thank you.
Please make tutorial for lvgl
can use esp8266 ?
Hi, is this tutorial valid for the new T-Display S3 AMOLED? Thanks
Good introduction, but....Please speak up a bit, the sound in this video was to low.
@tlclstuff
2 жыл бұрын
I agree, the volume level varies between just about acceptable to a distant murmur, and that's on headphones. Otherwise it could be a good series.
My TTGO has arrived and the factory example works on powerup but when I tried a basic sketch everything loads fine without any errors but the display remains blank. After some searching there is mention of setting up the display in user_setup.h. Did you have to do this?
@VolosProjects
2 жыл бұрын
Yes, you need to do that, here is whole tutorial kzread.info/dash/bejne/lGxml5ZmXczInbA.html
Great video! For me, if I only put color on the text, and no background color for the counter. It actually messes up the counting. 0. 8, 88. Very strange. I just put the background as black.
@Paul-rs4gd
Жыл бұрын
This happened for me too. I'm using a TTGO T-Display V1.1 with ST7789V 1.14 inch from AliExpress. I set the text colour to black and redisplayed the number to clear it.
At the link I can select CH304K 4MB, CH304K 16MB,, CH9102F 16MB or CP2104 4MB. Which is the best for your projects (and in general)? Thanks!
@VolosProjects
2 жыл бұрын
I am using that with 4mb memory. But any will be fine.
@VolosProjects
2 жыл бұрын
Thank you for the coffe😀 .. when your ttgo arives feel free to ask me for any help if you need it. Cheers
Can you show how to use sprite?
can we install Android auto on esp32?
HI How can to write whith Greek leters
It's not working. I don't know why. Do you have an ESP32 dev + 135x240 1.14 tft lcd connection diagram? 1.14tft lcd Where should I connect to the far right "BLK"?
Great, I have a question I would like to ask, how can I combine multiple .c files with converted hexadecimal digits into one .h file, your animation is more than 100 frames, one by one is a waste of time, if you Please answer me if you can see it. Many thanks!
@VolosProjects
2 жыл бұрын
Hello, here is your answer kzread.info/dash/bejne/X5xtuM9pf9rFedY.html
Can you change the brightness of the screen to make it Less bright. Perhaps a black background and make font numbers less bright? I want to make clock that is not so bright at night in dark room. ? Thank you.
@toddroles3234
2 жыл бұрын
I believe I found the answer in your vid on the weather station, in its code about lines 145-157 “digital read (35)”...is this dealing with dimming the screen? Can anyone give more details on this, and can these 12 lines just be put into other code for a ttgo-t-display to dim screen?
@VolosProjects
2 жыл бұрын
Hello! Most my examples have code that is used to set brightnes, in my last example kzread.info/dash/bejne/f4agxamAhMerds4.html lines i code are 38, 39, 40 thease lines need sto be outside setup or loop bracket. Also you will need lines 65,66,67, you can put thease lines in setup or loop part of code. In line 67 you can find number 90 , that number represent brightnes, you can set any value between 20 and 254. Just cope thease line sin your project and it will work.
Can someone Help me? I can not upload sketches to my TTGO. Concerning data given by the manufacturer, I need a CP2104 diver. I installed the CP210x drivers and it still do not work.
@VolosProjects
2 жыл бұрын
Did you install board and libraries in arduino ide?
Sir, Do you have wiring diagram for ESP32 and TFT ILI9341?. I have ESP32 that doesn't have built-in TFT. I'm also using TFT_eSPI library. I able to run sample sketch like TFT_Clock and some sketch that displays image from SD card. (very slow) Now I have problem with touch function. I able to run Calibrate sketch and 4 corners touch test run without any problem. But when I run On_Off_button, it doesn't response at all. This is how I wire the connection between tft and esp32 wroom TFT_MISO TOUCH_DO SD_MISO pin 19 TFT_MOSI TOUCH_DIN SD_MOSI pin 23 TFT_SCK TOUCH_CLK pin 18 TFT_DC pin 2 TFT_RST pin 4 TFT_CS 15 SD_CS 5 TOUCH_CS 21 I also want to use TOUCH_CS on pin other than 21 because I found out that pin 21 and 22 are for I2C. I might add other module in the future that use i2c. This will cause conflict between TFT and I2C. Which ESP32 pin is good for TOUCH_CS?
I started here since it was titled PART 1 - therefore I did not follow the step from the other video and did not edit User_Setup_Select.h - I think either the comments here or the video would be vastly improved if this was mentioned
color picker url is wrong. correct it in your description, because there are no links allowed in user comment
@VolosProjects
Жыл бұрын
i did, you can try it now
Everything seemed to work. I do indeed manager to upload, etc BUT, I see nothing on the screen. Serial.print("hello"); etc all work - so I know I have the right device. The screen did come on when I FIRST powered it up. It is now stuck black since uploading what I learned here. Help Please!
@VolosProjects
Жыл бұрын
Did you fallow this tutorial in details, did you edited user setup files, did you delete old tft_espi library
@johnh5073
Жыл бұрын
@@VolosProjects I did follow in DETAIL, YES! Not sure what you mean by "user setup files" but if you mean "board manager" etc, YES. I did NOT delete an old tft_espi library. I do not see that in the instructions
@johnh5073
Жыл бұрын
@@VolosProjects My system tells me that I have version 2.5.0 installed
@VolosProjects
Жыл бұрын
Version of what?
@VolosProjects
Жыл бұрын
@@johnh5073 we are in wrong video, this is tutorial kzread.info/dash/bejne/lGxml5ZmXczInbA.html
Only for 64bit not 32.