Copy of Python_Microproject Format_2024-25
Copy of Python_Microproject Format_2024-25
Academic year
2024-25
Alarm Clock
Certificate
This is to certify that Mr. /Ms. Hemant Bhatia, Gaurav Punjabi, Pooja Makhija Roll No.37,38,39
(Code: 0004) has completed the Micro Project satisfactorily in Subject – Programming with
Python (22616) for the academic year 2024- 2025. as prescribed in the curriculum.
Seal of
Institution
INDEX
1 Project Proposal 01
2 Action plan 02
3 Resource required 02
03
4 Introduction
5 Actual Procedure 04
6 Output
7 Skill developed
8 Evaluation sheet
Annexure – I
Micro-Project Proposal
Alarm Clock
An alarm clock is a device designed to help individuals wake up at a set time, ensuring
punctuality and effective time management. It plays a key role in establishing a consistent
routine, promoting better sleep habits, and improving productivity by providing a reliable wake-
up mechanism. With customizable features like adjustable sounds or vibrations, alarm clocks
cater to individual preferences, making them a versatile tool for maintaining daily schedules. By
reducing the stress of oversleeping, alarm clocks contribute to a more organized and timely
lifestyle, ultimately supporting physical and mental well-being.
● Planning: Establish project objectives and requirements for the Python project, outlining
the
goals and functionalities of the application.
● Tech Stack: Opt for Python and relevant libraries/frameworks suitable for the project
requirements, ensuring a cohesive and efficient development environment.
● Environment: Configure development tools and dependencies to create a robust and
conducive programming environment for Python application development.
● UI Design: Develop a user-friendly interface using Python frameworks like Tkinter or
Django, focusing on intuitive input methods and clear result displays.
● Logic Implementation: Implement the core logic and functionalities of the Python
application, ensuring accurate and efficient processing of data based on the project’s
1
objectives.
● Result Presentation: Display results appropriately within the user interface, providing
relevant information and feedback for the user in the Python project.
● Testing and Debugging: Thoroughly test the Python application to verify correct
functionality, addressing and resolving any issues or bugs encountered during the testing
phase.
1 Hp Laptop – Windows 11
2
Name of Team Members with Roll Nos.
1. Hemant Bhatia 37
2. Gaurav Pujabi 38
3. Pooja Makhija 39
Annexure – II
Micro-Project Report
Alarm Clock
1.0 Rationale
The report elucidates the central aim and objectives of the Alarm Clock System. It provides
insight into the project's origin and the specific aims it sought to fulfill, such as developing a
reliable and customizable tool for time management and waking up. The report outlines the key
features and functionalities intended to enhance user convenience, such as setting alarm times,
snooze options, and a user-friendly interface for easy time adjustments. It highlights the
importance of leveraging technology to cater to individual preferences and needs, ensuring
punctuality and improving daily routine efficiency. The system emphasizes reliability, accuracy,
and simplicity, ensuring that users can manage their time effectively and meet their daily
commitments.
3
• Develop a python program to demonstrate use of Operators.
• Perform operations on data structure in Python
• Develop function for given problem
• Design classes for given problem
• Handle exception
An Alarm Clock System is a software solution designed to efficiently manage and streamline the
process of waking up and setting alarms. In the context of your console application, it serves as a
digital tool that empowers users to manage their time effectively and ensure punctuality. This
system typically includes features such as alarm time setting, snooze options, and displaying the
current time, providing users with a simple and accessible way to interact with their daily
schedule. The primary goal is to automate the process of waking up, enhance the user’s time
management, and improve their overall daily routine by leveraging technology.
Within the console application, users can initiate the alarm-setting process, allowing them to set
a specific time for the alarm to trigger. This includes entering the desired time for the alarm,
along with optional customization such as selecting alarm tones or volume levels. The system
also provides a snooze functionality, allowing users to temporarily delay the alarm for a few
minutes, offering a more flexible wake-up experience. Additionally, the application displays the
current time, ensuring users are always aware of the time and can make adjustments to the alarm
settings if necessary.
The Alarm Clock System, being a console application, offers a straightforward and text-based
interface for users to set and manage their alarms. It aligns with the growing trend of digital time
management tools, providing a convenient and efficient way for users to manage their wake-up
times without the need for physical devices. The simplicity of the console interface hides the
complexity of the underlying operations, making it accessible to individuals with varying levels
of technical expertise.
Overall, the Alarm Clock System encapsulates the essence of modern time management
solutions, combining functionality, convenience, and ease of use within a digital framework. The
system’s ability to allow users to set alarms, use snooze features, and display the current time
ensures a reliable and effective means of managing daily schedules, ultimately enhancing user
punctuality and time management skills.
4
The Alarm Clock System also incorporates essential features such as the ability to set multiple
alarms, providing flexibility for users with varying schedules. For example, users can configure
different alarms for specific days of the week or even set recurring alarms, ensuring that they are
reminded at the appropriate times. In addition to the alarm functionality, the system may offer
features like customizing alarm sounds, allowing users to select tones or even upload their
preferred audio. This added personalization enhances the user experience, ensuring the system
adapts to different preferences and making it a more enjoyable and effective tool for managing
time.
Furthermore, the Alarm Clock System emphasizes the importance of reliability and accuracy in
its operations. The system ensures that alarms are triggered precisely at the set time, minimizing
the chances of errors or delays. Security measures, such as password protection or PIN code
access, can be implemented to prevent unauthorized modifications to alarm settings, especially
for shared or public devices. The ability to track alarm history or usage can also be integrated
into the system, providing users with insights into their wake-up habits and enabling them to
refine their time management strategies.
Algorithm
5
the event loop.
Step 10: Handle errors and exceptions in alarm sound playback using try-except blocks.
Step 11: Ensure the program terminates gracefully when the user exits by stopping background
processes.
Step 12: Execute the main function using if __name__ == "__main__": to run the application.
Flow Diagram
6
Code
import tkinter as tk
from tkinter import ttk, messagebox
import time
import datetime
import threading
import pygame
class AlarmClock:
def __init__(self, root):
self.root = root
self.root.title("Alarm Clock")
self.root.geometry("400x500")
self.root.resizable(False, False)
self.root.configure(bg="#282C34")
# Alarm variables
self.alarm_time = None
self.alarm_set = False
self.snooze_time = 5 # Minutes
# UI Setup
self.create_widgets()
def create_widgets(self):
"""Create UI elements for alarm clock"""
ttk.Label(self.root, text="ALARM CLOCK", font=("Helvetica", 16,
"bold"), foreground="white", background="#282C34").pack(pady=10)
7
# Display live time
self.time_label = tk.Label(self.root, font=("Helvetica", 48),
bg="#282C34", fg="cyan")
self.time_label.pack()
ttk.Separator(self.root, orient='horizontal').pack(fill='x',
pady=10)
# Buttons
button_frame = tk.Frame(self.root, bg="#282C34")
button_frame.pack(pady=20)
8
self.cancel_btn = tk.Button(button_frame, text="Cancel",
command=self.cancel_alarm, width=10, bg="red", fg="white",
font=("Helvetica", 10, "bold"), state=tk.DISABLED)
self.cancel_btn.grid(row=0, column=1, padx=10)
def update_clock(self):
"""Updates the displayed clock and checks for alarm
activation."""
now = datetime.datetime.now()
self.time_label.config(text=now.strftime("%I:%M:%S %p"))
self.date_label.config(text=now.strftime("%A, %B %d, %Y"))
self.root.after(1000, self.update_clock)
def set_alarm(self):
"""Sets the alarm with the selected time"""
hour = self.hour_var.get()
minute = self.min_var.get()
period = self.period_var.get()
self.set_btn.config(state=tk.DISABLED)
self.cancel_btn.config(state=tk.NORMAL)
self.snooze_btn.config(state=tk.DISABLED)
def cancel_alarm(self):
"""Cancels the alarm"""
9
self.alarm_set = False
self.set_btn.config(state=tk.NORMAL)
self.cancel_btn.config(state=tk.DISABLED)
self.snooze_btn.config(state=tk.DISABLED)
self.status_label.config(text="No alarm set")
pygame.mixer.music.stop()
def snooze_alarm(self):
"""Snoozes the alarm for 5 minutes"""
self.alarm_set = True
snooze_time = datetime.datetime.now() +
datetime.timedelta(minutes=self.snooze_time)
self.alarm_time = snooze_time.strftime("%I:%M %p")
pygame.mixer.music.stop()
self.snooze_btn.config(state=tk.DISABLED)
self.status_label.config(text=f"Alarm snoozed until
{self.alarm_time}")
def trigger_alarm(self):
"""Triggers the alarm"""
self.alarm_set = False # Reset alarm
try:
pygame.mixer.music.load("alarm.wav") # Load sound
pygame.mixer.music.play(-1) # Loop indefinitely
except:
print("\a") # Fallback beep sound
print("ALARM! WAKE UP!")
self.snooze_btn.config(state=tk.NORMAL)
self.cancel_btn.config(state=tk.NORMAL)
1 Desktop pc – Windows 7
11
12
13
14
8.0 Skill Developed / learning out of this Micro-Project \
The following skills were developed while performing and developing this micro-project:-
1. Designing: Designing of micro project with minimum required resources and at low
cost.
2. Teamwork: Learned to work in a team and boost individual confidence.
3. Time Management: Timely completion of micro project as scheduled.
4. Data Analysis: Interpretation of data
5. Problem-solving: Develop good problem-solving habits.
6. Technical writing: Preparing a report of the proposed plan and final report.
1. Alarm Management: The system allows users to set, modify, and manage their alarms.
This includes creating new alarms, adjusting alarm times, and enabling or disabling
alarms as needed. Users can customize their alarm settings to suit their preferences, such
as selecting alarm sounds or snooze durations.
2. Alarm History Tracking: Users can view a detailed history of triggered alarms. This
feature is useful for monitoring previous alarm settings and times, giving users insight
into their wake-up habits and allowing them to track alarm performance.
3. Secure User Authentication: The system ensures secure user authentication through a
PIN or password, protecting alarm settings and preventing unauthorized access to alarm
configurations. This feature ensures that users' alarm preferences remain private and
secure.
15
Annexure – III
Relevance to the Relate to very Related to Take care of at-least Take care of more
1
course few LOs some LOs one CO than one CO
Completion of the
Completed Completed 50 Completed 60 to Completed more
3 Target as per
less than 50% to 60% 80% than 80 %
project proposal
Sufficient and
Data neither appropriate Sufficient and
Enough data
organized nor enough data appropriate enough
Analysis of Data collected and
4 presented well generated but data generated
and representation sufficient and
not organized which is organized
presenting data.
and not and but not used.
presented well.
Well assembled
Just assembled Well assembled and
Quality of with proper
Incomplete and some functioning parts.
Prototype/Model functioning parts..
5 Programming codeis not But no creativity in
Creativity in
code functioning design and use of
design and use of
well. graphics function
graphics function
Nearly
Very short, Detailed, correct and
sufficient and
Details about clear description of Very detailed,
correct details
methods, and methods and correct, clear
Report about methods,
6 conclusions description of
Preparation and conclusion. Conclusions.
omitted, some methods, and
but clarity is Sufficient Graphic
details are conclusions.
not there in Description.
wrong
presentation.
Replied to
Could not
considerable
reply to Replied properly to Replied most of
number of
8 Defense considerable considerable number the questions
questions but
number of of question. properly
not very
question.
properly
Annexure – IV
Poor
Sr. Characteristic to be Average Good Excellent
( Marks1-
Sub Total
No assessed (Marks 4-5 ) (Marks 6-8) ( Marks9-10)
3)
(A) Process and Product Assessment (Convert Above Total marks out of 6 Marks)
17
Literature review/
2
Information Collection
Quality of
5
Prototype/Model
6 Report Preparation
(B) Individual Presentation / Viva (Convert above total marks out of 4 marks)
7 Presentation
8 Defense/Viva
Total Marks
Process and Product Assessment Individual Presentation / Viva
Roll No.
(6 Marks) (4 Marks) 10
37
38
39
18
19