Skip to main content
Version: FILS English

πŸ’§ Water Spitting Alarm

A creative and effective alarm clock that guarantees you'll wake up β€” by spraying water on your face when the alarm goes off.

info

Author: Rizescu Razvan-Alexandru
GitHub Project Link:https://github.com/UPB-PMRust-Students/project-RazvanRZR

Description

Built around a Raspberry Pi Pico microcontroller and a DS3231 real-time clock module, the system uses a relay-controlled water pump and a buzzer to deliver both audio and physical alerts when the alarm time is reached. The alarm time is easily configurable through a simple frontend web interface. This project combines embedded hardware design with Rust-based software development to create a reliable, fun, and slightly mischievous alarm system. With a modular architecture, clear schematics, and robust software design, it’s a perfect example of how creative engineering can solve everyday problems in unexpected ways.


🎯 Motivation​

Since I was 14 years old, I struggled to wake up to traditional alarms. Most mornings, I would snooze or sleep through them. This project solves that by introducing an unavoidable physical stimulus β€” a blast of water β€” triggered by a reliable, time-based microcontroller system.


🧱 Architecture​

Main Components:​

  • Raspberry Pi Pico
  • DS3231 RTC
  • Relay Module
  • Buzzer
  • Water Pump
  • USB Power
  • Frontend App (for time setting)

System Architecture


πŸ—‚ Architecture Diagram​

The diagram above shows:

  • USB powering the Raspberry Pi Pico
  • Pico connections:
    • I2C to RTC
    • GPIO to Buzzer and Relay
  • Relay powering the water pump
  • Frontend app interface via serial or USB input

πŸ“† Weekly Development Log​

Week 6-12 May​

-In the first week after deciding on my project, I ordered the necessary components and worked on schematics, architecture and documentation, planning everything that i want to do in my head, first important features, possible future features.


πŸ›  Hardware​

  • Raspberry Pi Pico reads time and controls outputs.
  • Relay safely drives the water pump.
  • All powered via USB.
  • RTC provides persistent and accurate timekeeping.
  • When the current time matches the alarm:
    • Triggers a buzzer for audio alert.
    • Activates a water pump to spray water on the user.
  • Both components run until manually stopped.
  • Alarm time is set via a simple frontend web app.

πŸ“ Schematics​

Schematic Diagram

Describes the physical circuit:

  • RTC (I2C) to Pico
  • Relay and Buzzer via GPIO
  • Water pump through relay
  • Powered through USB

πŸ”„ Functional Flow Diagram​

Functional Flow Diagram

Diagram:

  • Start β†’ Init RTC
  • Set time via frontend
  • Loop: Compare time
  • If match β†’ Activate buzzer + pump
  • Wait/Reset

πŸ“‹ Bill of Materials​

ItemQuantityPurposeEstimated Price (RON)
Raspberry Pi Pico1Controller$46.99
DS3231 RTC Module1Timekeeping$15.98
Relay Module1Switches water pump$04.99
Water Pump1Sprays water$15.99
Buzzer1Audio alarm$05.78
Breadboard1Prototyping circuit$12.10
Jumper Wires10+Connections$15.90
USB Power Adapter1Power supply$10.49

πŸ’Ύ Software​

Component / LibraryDescriptionUsage in Project
rp-picoRust support crate for Raspberry Pi PicoProvides low-level access to Pico-specific peripherals and pins
embedded-halHardware Abstraction Layer (HAL) for embedded RustOffers standardized traits for GPIO, I2C, timers, etc.
ds323-xDriver for DS3231 RTC moduleCommunicates with RTC over I2C to get/set current time
embedded-timeTime handling library for embedded systemsManages durations, clocks, and time comparisons
chronoDate and time libraryParses and formats time values; aids alarm comparison logic
defmtDebug logging framework for embedded RustProvides efficient, low-overhead logging over serial
Frontend App (Web UI)Simple web interface for setting alarm timeAllows user to configure the alarm time over serial/USB

  1. No links just yet,