Getting Started | Real-Time Clock vs. NTP Tracking Time w/ Arduino & ESP32 (DS3231 RTC) | BRK-00026

  Рет қаралды 26,684

datasith

datasith

Күн бұрын

• Your support helps me post videos more frequently:
/ acrobotic
www.paypal.me/...
buymeacoff.ee/...
BTC: 1ZpLvgETofMuzCaKoq5XJZKSwe5UNkwLM
==========
• Find me on:
/ acrobotic
/ acrobotic
/ acrobotic
==========
• My shops:
acrobotic.com/...
amazon.com/sho...
==========
• Description:
This is a getting started series for the products found on my online shops!
In this video, we setup a DS3231 real-time clock (a higher precision version of the DS1307) to keep track of time using an Arduino Uno and an ESP32 development board:
amzn.to/3bZLId0
Real-Time Clocks allow us to easily and accurately keep track of seconds, minutes, hours, week, date, month and year information. They're typically used for time-stamping sensor data while it's being logged. Using an external (CR2032 coin cell) battery, the RTC is able to keep tracking time even when it loses power.
==========
• Related vids:
Getting started with the ESP32 using Arduino: • Getting Started | ESP3...
Getting started with Websockets: • ESP8266 Web Server and...
==========
• Project parts:
ACROBOTIC Development Boards for ESP32:
amzn.to/2D3KiA6 (affiliate)
amzn.to/303INZK (affiliate)
acrobotic.com/...
ACROBOTIC DS3231 RTC Real-Time Clock Breakout Board:
amzn.to/3hgomlg (affiliate)
==========
• Project code:
Arduino Library for the DS3231: Available through Tools - Manage Libraries... - RTClib
Arduino Library for getting time data from an NTP server: Available through Tools - Manage Libraries... - NTPclient
==========
• Music:
Epidemic Sound (epidemicsound.com). Standard KZbin License.
==========
#Arduino #RTC #ESP32

Пікірлер: 28
@TheAlibigdeli
@TheAlibigdeli 4 жыл бұрын
nice one actually i was using ds3231 lib it self but i always had problems with ntp sync like there is a part which people need to sync their time with ntp instead of time on the device i leave the function below for those who need it: void SyncTime() { struct tm timeinfo; if (!getLocalTime(&timeinfo)) { Serial.println("Failed to obtain time"); return; } Serial.println(&timeinfo, "%A, %B %d %Y %H:%M:%S"); //rtc.adjust(DateTime(year, month, day, hour, minute, second)); rtc.adjust(DateTime(timeinfo.tm_year + 1900, timeinfo.tm_mon + 1, timeinfo.tm_mday, timeinfo.tm_hour, timeinfo.tm_min, timeinfo.tm_sec)); }
@datasith
@datasith 4 жыл бұрын
Ali to the rescue! Thanks so much for sharing!
@adabill295
@adabill295 4 жыл бұрын
I'm building a timer for a light that comes on at Dusk-60 minutes and goes off at Midnight+60 mins. I am using a DS3231 RTC and was wondering how to check the RTC's accuracy after a month or two. I live in Michigan USA and I have to constantly change the light time to account for both DST and seasonal changes to dusk (disk2dawn). I want the timer to be "hands off" but had problems setting the clock initially and adjusting the clock if it drifted. This gives me an idea on how to use the internet to set the clock initially and check it after a month or two to see how it has drifted. There is already a way to use my smart phone to enter my internet credentials, if needed to get it initially connected. An OLED on the project box to show times (current, dusk(DST Adjusted) and OFF time). only one button to Force ON/OFF if needed. Connecting to the internet will mean I don't have to depend on attaching it to my computer and having to download the new program when the time needs adjusted. THANKS to both of you for the idea and code !
@praveenraj29
@praveenraj29 3 жыл бұрын
Great Video! I believe ESP32 has an inbuilt RTC available in it. Can you we use the ESP32- RTC to get time data and will it work properly if we provide battery power without interruption for ESP32? (Anyone have tried it, please let me know as well) Thanks in advance
@SophiaCoffee_Mindest
@SophiaCoffee_Mindest 2 жыл бұрын
Can I use the rtc lib with the RV3032 rtc? I dont find any lib for that one :(
@dniellobodesousa3555
@dniellobodesousa3555 Жыл бұрын
Estou usando uma esp 8266, quais pinos se usa?
@Dvir1300
@Dvir1300 4 жыл бұрын
Nice video. Thanks! What I'm looking for - is the complete solution: To connect to the NTP server (Maybe using the NTPclient example that comes with the ESP8266 basic library, using simple UDP communication), and use its input to update the DS3231 module - so also when off-line the time will stay correct. Would you please make "Part 2" Video with this complete proccess? Many thanks!
@datasith
@datasith 4 жыл бұрын
Thanks for watching! I wanted to do exactly that, but I wanted to keep the "Getting Started" video as simple as possible. I'll add it to the (long) list of vids in the queue :)
@Dvir1300
@Dvir1300 4 жыл бұрын
Thank you for that! I think it's reletavely simple to do it as "Part 2" of this video, as the basics are already here. I'll be staying tuned to see when it comes. All The Best!
@rgmtb
@rgmtb 4 жыл бұрын
Would this board be good to trigger a wake up interrupt? If I wanted to put a device into deep sleep (like a weather sensor) and have it awake could this do it? What's the battery life on this? Thank you
@datasith
@datasith 4 жыл бұрын
Sh*t man, sorry for the super late reply! I would use the RTC board so that when the device wakes up from deep sleep, it can have an accurate sense of time. Not so much for waking up the device. Most chips these days will have the deep sleep functionality built in, which you can set by software. If you want to use an external hardware trigger, then you can build any circuitry you'd like for doing this, but there's little advantage to that, and you'd also need to power yet another device. So, I'd recommend giving the built-in one a try. Here's a good set of posts with examples: blog.voneicken.com/projects/low-power-wifi-intro/
@Dvir1300
@Dvir1300 4 жыл бұрын
AFAIK, the DS3231 module has an "alarm" option, and some extra pins that may be used to 'send a pulse' to wakeup by an interrupt. But I'm not sure, and would be glad to get smarter with that by someone that knows better.
@stevenalexander7259
@stevenalexander7259 3 жыл бұрын
can we use for display Millisecond ?
@muctop17
@muctop17 4 жыл бұрын
Phineas: "Ferb, I know what we're gonna do today!" Cisco: "Allright! Let´s do this!" Tnx! Just perfect, as allways!
@window.location
@window.location 4 жыл бұрын
Also Phineas: *where is perry*
@datasith
@datasith 4 жыл бұрын
Hahah, thanks for the kind words and the chuckle 😊
@andrasparanici5491
@andrasparanici5491 3 жыл бұрын
Nice! Thank you! What I was looking for!
@imottofeivel2479
@imottofeivel2479 4 жыл бұрын
Hey, love the vid! Can you make a tutorial on making a esp8266 remote controll for a rc projects like a rc car
@datasith
@datasith 4 жыл бұрын
Ha! Perfect timing. Funnily enough, that's going to be one of my next two videos. Stay tuned!
@imottofeivel2479
@imottofeivel2479 4 жыл бұрын
Great!! Thank you.
@dennishopper8687
@dennishopper8687 2 жыл бұрын
not a single bit of code?
@jasonmare33
@jasonmare33 Жыл бұрын
good job ! thanks
@jorgeDeveloper80
@jorgeDeveloper80 3 жыл бұрын
muy bueno el video .y la camiseta de maradona
@adilanizuly5740
@adilanizuly5740 3 жыл бұрын
Nice video. Thanks!
@scienceprojectsofdccpn3430
@scienceprojectsofdccpn3430 2 жыл бұрын
thank you ❤
Make your own Retro Nixie Clock with an RTC!
10:54
GreatScott!
Рет қаралды 1 МЛН
Sigma Kid Mistake #funny #sigma
00:17
CRAZY GREAPA
Рет қаралды 30 МЛН
Гениальное изобретение из обычного стаканчика!
00:31
Лютая физика | Олимпиадная физика
Рет қаралды 4,8 МЛН
Enceinte et en Bazard: Les Chroniques du Nettoyage ! 🚽✨
00:21
Two More French
Рет қаралды 42 МЛН
All about the DS3231
13:11
learnelectronics
Рет қаралды 26 М.
Arduino Real Time Clock - Using the Tiny RTC
31:29
DroneBot Workshop
Рет қаралды 204 М.
ESP32 Technical Tutorials: DS1307 Real Time Clock
7:57
Kolban Technical Tutorials
Рет қаралды 19 М.
#67 Exact Time without RTC Module for the ESP8266: NTP Time
9:32
Andreas Spiess
Рет қаралды 96 М.
Sigma Kid Mistake #funny #sigma
00:17
CRAZY GREAPA
Рет қаралды 30 МЛН