Arduino Project: Real time clock DS3231 and 1.8 Color TFT display ST7735

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
Dear friends, welcome to another video. This is Nick and today we are going to see how to build this low-cost real-time clock and thermometer with a color TFT display using Arduino. Let's start ! About a year ago I built this simple real time clock with a thermometer using a simple 2-line LCD display. Now that we know how to drive better displays, it is time to update that project. So, in this project we are using a 1.8' color TFT display in order to display the date, the time, the temperature and the minimum and maximum temperature that we have measured. The parts needed in order to build this project are these: An Arduino Uno, a DS3231 real time clock module, a 1.8' color TFT display (ST7735), a small breadboard and some wires. You can find links for all the parts that I use in this project, in the description of the video. The cost of the project is around $12. $5 for the display, $5 for the Arduino and around $2 for the real time clock module. The real time clock module is all we need in order to measure the temperature and get the time and the date. It contains the DS3231 real-time clock chip, which also contains a temperature sensor. Let's now see how to connect all these parts together. First, we are going to connect the real-time clock module. Ground goes to breadboard Ground and that goes to Arduino Ground. VCC goes to breadboard VCC and that goes to Arduino 5V. SDA goes to analog pin 4 and SCL goes to analog pin 5. Next, we connect the 1.8' color TFT display. Please watch our detailed tutorial on how to connect it to any Arduino Project. OK. That's it. Now, we are ready to power up the project and see if it is working. OK, it is working fine. Now, let's take a look at the software side of the project. That's the code of the project. We are using the Adafruit GFX library along with the Adafruit ST7735 library for the display. We also use the SODAQ library for the DS3231 real-time clock Because driving this display with Arduino is a bit slow, I am using a small trick in order to make it a bit faster. If we update the display every second, because this update takes a long time, there is big a visible flickering on the display. So, in the code, what we do, is we update only parts of the display, only when needed, when the value has changed, not every second. For example, for the temperature value, we measure the temperature value every second, if the value has not changed, there is no need to update the display. If the value has changed, I draw a black rectangle over the temperature value on the display, and over it I write the new value. This way, I have only updated a small part of the display, so the procedure is very fast. At the first time you run the program, you have to set the time to the real-time clock if it is not already set. Go to the setRTCtime function and set the current time and date. Then, uncomment this line here and run the program once. Now, time has been set to the real-time clock and it is kept internally with the use of the small battery on the back of the RTC module. Now, you have to comment this line of code again and upload the code once more to Arduino. That's it! I have prepared two versions of the code. One in degrees C and one in degrees F. Of course, as always, you can find the code of the project in the description of the video. The project is not very hard to build and for the first time we add a color screen to Arduino. Using the Arduino DUE, which is much faster, would have resulted in a much easier implementation, but as you can see, the slow Arduino Uno can do just fine with some code tweaking. The ST7735 color TFT display is a cheap and nice display to add to our Arduino projects, so I am going to use it a lot in the future. So, stay tuned! If this is your first time here, I would love to have you subscribed. In this channel I post videos about DIY projects every Saturday. I love making things and I believe that anyone can make things, anyone can become a maker. That's why I made this channel, in order to share my knowledge with the community and learn from the community. I hope that you will join us. Until next Saturday, Watch, Learn, Build!
Info
Channel: educ8s.tv
Views: 147,143
Rating: undefined out of 5
Keywords: Arduino Clock, Arduino real time, real time clock, arduino color clock, arduino diy clock, st7735, color clock, arduino diy project, color tft, 1.8 color tft, educ8s.tv, arduino ds3231, arduino ds3231 clock, ds3231 RTC module, arduino easy project, temperature monitor arduino, arduino temperature, arduino thermometer, Arduino (Brand), Computer Monitor (Product Category), Temperature (Dimension)
Id: yE-Q3_Ox5rk
Channel Id: undefined
Length: 4min 57sec (297 seconds)
Published: Sat Oct 03 2015
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.