Time is always passing, and it can not be irreversible. That is why we have to spend our time very carefully. People live and spend their time in the past, the present, and the future. Therefore, the clock that tells us the current time has become a necessity, and I am going to introduce you how to get to know a more accurate time.
STEP 1. <Introducing Project and Technology>
In order to know the exact time, there are several ways to find the correct time through the Internet Network. NTP(Network Time Protocol) is a method to receive network time. The Internet Network has an NTP server, and we can get the current time by requesting the information from the NTP server. Smartphones and smartwatches that we use all the time also request the time information from the NTP server to find out the exact time and display it on them.
This project is to maintain the current time continuously using NTP and RTC(Real Time Clock) and display it through 7-segment.
STEP 2. <Introducing Materials>
- WIZwiki-W7500 x 1ea(For details: https://wizwiki.net/wiki/doku.php?id=products:wizwiki_w7500:start
- Purchasing place: https://www.wiznet.io/product-item/WIZwiki-w7500/ )
- 7 segmentsx4(Common-Anode Type, Array 7-Segment) x 2
- BC547 x 8ea
- Tact SW x 1ea
- 220 ohm resistor x 16ea
- 1k ohm resistor x 8ea
- 10k ohm resistor x 1ea
- 1uF x 1ea
- Jumper Wire
STEP 3. <Hardware Configuration>
- MBED Subscription, Driver Installation, and Configuration
- Access the MBED site(https://os.mbed.com/) and register.
- Download “Arm Mbed Windows serial port driver” and install it.
- Make sure that it pops up as a removable disk as shown below if you connect the WIZwiki-W7500 and PC with a USB cable.
- Circuit Configuration
- The circuit is composed as follows.
- Code Compilation and Firmware Writing
- Connect to the code URL of “STEP4″ below and click “Import into Compiler”.
- The web browser connects to the MBED Online Compiler, and the corresponding code is imported.
- When you click the “Compile” button at the top, the code Compiles and when it is finished, the file “SNTP_7SEG_WIZwiki_W7500.WIZWIKI_W7500.bin” is downloaded.
- Copy the file and paste it into your removable disk. This is how the firmware Writes.
STEP 4. <Source Code links and Key Code descriptions>
The source code can be found at the following URL.
STEP 5. <Project Result>
Please follow the link for the complete result.
In operation video, it connects to NTP server and receives time information when WIZwiki-W7500 board is reset. Time information is receiving from the NTP server when the red LED on the board is turned on. The current time is registered in the RTC when the time information is received and the RTC operates. The current time of the RTC is output in 7 segments.
It displayed on the 7 segments will alternate between time and date information each time you press SW. And every day at 10 a.m., it connects to the NTP server and receive the new time and update it.
Curator: Scott Jeong