It is an alarm clock made in c++ using ctime library
References:
https://stackoverflow.com/questions/22901901/what-does-fflushstdin-do-in-c-programing
https://www.tutorialspoint.com/cplusplus/cpp_date_time.htm
https://www.geeksforgeeks.org/sprintf-in-c/
https://stackoverflow.com/questions/2566073/how-to-make-c-program-wait-on-linux
https://stackoverflow.com/questions/7469139/what-is-equivalent-to-getch-getche-in-linux
https://stackoverflow.com/questions/11169392/c-alarm-clock-loop-issue
https://gist.github.com/Codeplaza/7326881
https://stackoverflow.com/questions/31589464/difference-between-delay-and-sleep-in-c
https://www.unix.com/programming/143352-playing-sound-file-sdl-c.html
Issues :
1)I could'nt find an equivalent of \a or \7 to make a bell sound in linux.
2)I got to know a little about threading and so,an alternate and a more better version of the same program could have been made if the same had been used. It could have freed the terminal space and it would have notified the user whenever the alarm time coincides with the given time, giving space for additional features, like adding date.
STEPS TO RUN THE PROGRAM :
- Download makefile, alarm_new.cpp and circle.png and save them in a folder.
- Compile the program in the terminal using the command "make alarm_new".
- Run the program by typing "./alarm_new" in the terminal after compilation.
- Also, please install ncurses library if not present already by typing "sudo apt-get install libncurses-dev" in the terminal.
SOME RELATED IMAGES :