How to create TM1637 Digital Clock with setup Time and setup Alarm functionality

  Переглядів 13,270

Mario's Ideas

Mario's Ideas

3 роки тому

This is a prototype of the time and alarm setup mechanism which I am planning to use in my next digital clock projects.
I hope you find it useful.
If you think of any improvements please let me know. I would be more then glad to look into them and potentially incorporate in my code.
Here is the link to the project details including the code:
create.arduino.cc/projecthub/...
List of components:
- Arduino Nano
pl.aliexpress.com/item/328440...
- TM1637 Display
pl.aliexpress.com/item/328678...
- DS1302 RTC module
pl.aliexpress.com/item/149823...
- Buzzer
- Lilypad LED
- 220OHM resistors
- 3 pushbuttons
If you like this content and you want to support me in creating similar videos go to my Patreon webpage
/ mariosideas
Or
www.paypal.com/cgi-bin/webscr...
Music Credits
------------------------------
Track: 24 Happy Hours a Day - Igor Khainskyi [Audio Library Release]
Music provided by Audio Library Plus
Watch: • 24 Happy Hours a Day -...
Free Download / Stream: alplus.io/24-happy-hours-day
------------------------------

КОМЕНТАРІ: 51
@mandrasaptakmandal636
@mandrasaptakmandal636 2 роки тому
your code explanations are magnificent
@marios_ideas
@marios_ideas 2 роки тому
Thanks:)
@magnetservicecenter
@magnetservicecenter 2 роки тому
From India thanks for your inspiration I am 45 not an engineer or computer expect ,I am an ordinary technical person doing microwave and television repair. But i love arduino projects by you 👍👍
@marios_ideas
@marios_ideas 2 роки тому
Thanks:)
@kentruperthambil5754
@kentruperthambil5754 Рік тому
Hi great project sir! if may I ask sir do you have additional code for also setting automatic time off in this project? thanks in advance
@Witsenburg
@Witsenburg 2 місяці тому
Hi, thanks for sharing. My son and I will build it as his next Arduino project and we will try to add automatic brightness adjust, so the display is bright when there is light, and dim when it's dark.
@CrazyCoupleDIY
@CrazyCoupleDIY Рік тому
Thanks Mate Very helpful I am going to use this in my upcoming project tutorial Thanks for sharing.
@marios_ideas
@marios_ideas Рік тому
Cool:)
@Sekhar_Home
@Sekhar_Home 3 роки тому
Can u program tm1637 without library in arduino
@ABID5
@ABID5 2 роки тому
Thank you for the effort. I wonder if it is possible to make it 12hour format. Can you help?
@marios_ideas
@marios_ideas 2 роки тому
Few people asked about this. I might do a short video on this. Give video thumb up if you liked it
@erment55
@erment55 2 роки тому
I watched the related video with interest, I appreciate your effort and wish for the continuation of such educational videos. I uploaded the relevant code to Arduino and ran it, I did not encounter any problems. In this context, I have a question. What kind of code should I write to skech with the screen brightness setting of TM16237? ,I'm waiting for your help
@marios_ideas
@marios_ideas 2 роки тому
You aztually see that in the code for that video. In the setup function you see command clock.setBrightness(0x0f); You have to play with the hex value passed to that function. I prsume the lower the value the lower is the brightness
@erment55
@erment55 2 роки тому
@@marios_ideas Thank you for the quick and useful information.
@marios_ideas
@marios_ideas 2 роки тому
@@erment55 Give the video a like if you found it usefull:)
@erment55
@erment55 2 роки тому
@@marios_ideas I did and also subscribed to the channel
@pablonaranjo9426
@pablonaranjo9426 3 роки тому
hello, great project, how to make the two points blink, greetings and thanks
@marios_ideas
@marios_ideas 3 роки тому
You need to change this loop. Output time when seconds change and not minutes. if (myRTC.minutes!=minutes){ clock.showNumberDecEx((int)myRTC.hours/10*1000+(myRTC.hours-((int)myRTC.hours/10)*10)*100+ (int)myRTC.minutes/10*10+myRTC.minutes-((int)myRTC.minutes/10)*10, (0x80 >> 1), true); minutes=myRTC.minutes; hours=myRTC.hours; } And then check if the number of seconds is even. So bild an if statement When it is use different command to display time clock.showNumberDec((int)myRTC.hours/10*1000+(myRTC.hours-((int)myRTC.hours/10)*10)*100+ (int)myRTC.minutes/10*10+myRTC.minutes-((int)myRTC.minutes/10)*10, true,4,0); Dont have this connected but you will have look at my tutorial ukposts.info/have/v-deo/f3iHgZicna6L1Ww.html basically shownumnerdec dows not display the colon and it displays 4 digit number which is what you want. So we want to do it every other second
@fahmipras5846
@fahmipras5846 3 роки тому
can I use ds1307 instead ?. If I can, what should I change in the code ?
@marios_ideas
@marios_ideas 3 роки тому
I can see that there is dedicated library for ds1307 github.com/PaulStoffregen/DS1307RTC So download it , install it and check examples that come with it to see if there are any differences in declaring the RTC module. Since the author of this library is the same I would imagine that there might only be a difference in declaration and the rest of the code should be ok
@fahmipras5846
@fahmipras5846 3 роки тому
@@marios_ideas thank you !
@avcimustafa7052
@avcimustafa7052 Рік тому
thanks
@marios_ideas
@marios_ideas Рік тому
Like the video if you enjoyed it
@erment55
@erment55 2 роки тому
Hi again, how to activate colon blinking every second?
@marios_ideas
@marios_ideas 2 роки тому
So currently you have this piece of code if (myRTC.minutes!=minutes){ clock.showNumberDecEx((int)myRTC.hours/10*1000+(myRTC.hours-((int)myRTC.hours/10)*10)*100+ (int)myRTC.minutes/10*10+myRTC.minutes-((int)myRTC.minutes/10)*10, (0x80 >> 1), true); minutes=myRTC.minutes; hours=myRTC.hours; } } Where whenever minutes change you redisplay the clock. (0x80 >> 1) is responsible for displaying the colon. What you need to do is to redisplay time whenever second change and for even seconds display colon and for odd seconds display clock.showNumberDecEx((int)myRTC.hours/10*1000+(myRTC.hours-((int)myRTC.hours/10)*10)*100+ (int)myRTC.minutes/10*10+myRTC.minutes-((int)myRTC.minutes/10)*10, true); so without the colon
@erment55
@erment55 2 роки тому
@@marios_ideas I will try and let you know the result, thank you again for your quick and helpful feedback as always.
@janradlinski3787
@janradlinski3787 2 роки тому
hello i just wanted to display real time on this 4 digit display with DS1302 RTC module so i copied your code from 2:44, set the time and brightness but it is not working :/ any ideas what is the problem?
@marios_ideas
@marios_ideas 2 роки тому
After connecting RTC run I2C scanner code to see if Arduino sees RTC device playground.arduino.cc/Main/I2cScanner/ Also output the Time to serial monitor to see if time is read , if this does that would indicate the problem with 4 digit display
@janradlinski3787
@janradlinski3787 2 роки тому
it works, thanks for the help
@marios_ideas
@marios_ideas 2 роки тому
Jan Radliński silly me. I did not read your initial question carefully enough. Ds1302 is not I2c device. I assumed you were using ds3231:( so was the problem linked to 4 digit display?
@janradlinski3787
@janradlinski3787 2 роки тому
@@marios_ideas it seems that i had to mess something up with the code because i just simply restarted the arduino and rewrite the code and it worked. Still great video and good explanation.
@ndolomusau8414
@ndolomusau8414 2 роки тому
hello sir,can i use an LCD 16 by 2 module for this project,am doing it as part of my project.
@marios_ideas
@marios_ideas 2 роки тому
Sure you can. It is just a different type of display. Of course you would have to adjust code to exit the RTC read time to a different display
@ndolomusau8414
@ndolomusau8414 2 роки тому
@@marios_ideas can you help me out with the codes setting,am having some difficulties in figuring out.
@ndolomusau8414
@ndolomusau8414 2 роки тому
@@marios_ideas am using the following port in my lcd; D4,D5,D6,D7,A,K,RS,RW,E.
@marios_ideas
@marios_ideas 2 роки тому
​@@ndolomusau8414 I am receiving too many requests like this . I do not have time to respond to all nor I should really be doing the project for you.
@marios_ideas
@marios_ideas 2 роки тому
@@ndolomusau8414 I have a video on LCD displays ukposts.info/have/v-deo/n49ng4B7sIuokqs.html. In the code you have to replace following lines with the lines that would display the time to LCD display. (all lines where clock.showNumberDec is used)
@MdFiroz-qk3vz
@MdFiroz-qk3vz Місяць тому
please give me program
@drelectronics13
@drelectronics13 6 місяців тому
Can we add multiple alarms
@marios_ideas
@marios_ideas 6 місяців тому
You can program anything you want. Obviously having functionality to set multiple alarm would make code a bit more complex:)
@drelectronics13
@drelectronics13 6 місяців тому
@@marios_ideas thanks for replying brother
@ndolomusau8414
@ndolomusau8414 2 роки тому
am doing this as my project where can i get the pdf of the codes used?????
@marios_ideas
@marios_ideas 2 роки тому
there is a link in video description
@ndolomusau8414
@ndolomusau8414 2 роки тому
@@marios_ideas got it,thanks sir.
@Dancopymus
@Dancopymus 2 роки тому
Cool but, it is much better to use the Buttons without resistors, that is, use with PULLUP in the code; it gets cleaner and less work!
@marios_ideas
@marios_ideas 2 роки тому
Check my recent video. It is like you were reading my mind:)
@suriptods9177
@suriptods9177 21 день тому
permission to copy the file,thanks sir
@marios_ideas
@marios_ideas 21 день тому
Copy file where?:) Either way permission granted
Voloshyn - ЗУСИЛЛЯ (прем'єра треку 2024)
06:17
VOLOSHYN
Переглядів 876 тис.
Історія загиблого Назара Небожинського
00:54
Суспільне Рівне
Переглядів 958 тис.
Real-Time Clock using TM1637 & DS3231
4:21
Anas Kuzechie
Переглядів 13 тис.
Is Adam Savage Still an Atheist?
8:16
Adam Savage’s Tested
Переглядів 231 тис.
Cheap DIY digital alarm clock, with temperature and light sensor
10:54
I'm just DIYer
Переглядів 17 тис.
Homemade Easy Digital Clock with RTC | 12Hr/24Hr
3:22
Tech Ideas
Переглядів 125 тис.
Using multiple TM1637 4 digits LED Display with Arduino
7:54
Robojax
Переглядів 28 тис.
Best OS for programming? Mac vs Windows vs Linux debate settled
8:40
8x8x8 LED CUBE WITH ARDUINO UNO
6:46
HARRY LE
Переглядів 15 млн
Samsung UE40D5520RU перезагружается, замена nand памяти
0:46
Слава 100пудово!
Переглядів 3,7 млн
iPhone 17 Slim - НЕ ОНОВЛЮЙ iPhone в 2024 | Новини Тижня
31:12
Канал Лучкова
Переглядів 34 тис.
Як знімати з музикою на iPhone #apple #icoola #айфон #айкула #tradein #відновлений #iphone #ремонт
0:18