“In this the second part you’ll learn how to implement the timer and function to program the hour to activate the device.
In the first part of this article, we presenting how to create all process to implement this project. You can access the first part in the link (Access the first part of the Article)
Now, through this second part, we’ll present all process to create the functions to program the clock and date and program the hour of device activation.
Therefore, through this functions, we’ll can learn several principles of application and uses of Real Time Clock (RTC) DS1307.
Proposed Functions for the Project
According to explain in part I, the project has an aim to activate and deactivate the device in a programmed hour by the user.
Therefore, based in the problematic, is need use the CHIP Real Time Clock. The CHIP is used to count 7 variables: second, minute, hour, day of wee, date of month, month and year. So, for this, is need implement a system of hour for user adjust the hour, the date, the activation and deactivation hour.
For this, several functions will be implemented to solve this problem according to the diagram shown in the Part I. So, we’ll develop the functions to configure the actual time and the date of the Real Time Clock and hour to activate the device connected in the relay.”