กลับไปหน้ารวมไฟล์
starter-kit-hourglass-personal-mod-03f25b-en.md

This project may be thought as a Pommodoro-technique variant of the project n. 8 of the starter kit. Both the circuit and the code are quite straightforward, and since I am still experimenting with the basics I wanted to propose a slightly more challenging variant of the original project.

Technical Implementation

The system uses a Tilt Switch to detect when the hourglass is flipped and 6 LEDs to indicate the passing time. When the hourglass is tilted, the LEDs turn on one by one at regular intervals.

Hardware Infrastructure

  • Arduino Uno: The primary controller for the hourglass's logic and sensors.
  • 6 LEDs: Provide the visual indicators of the passing time.
  • Tilt Switch: Detects when the hourglass is flipped or tilted.
  • 220-ohm Resistors: Used to protect the LEDs and the Arduino's output pins. The tilt sensor is going in series with a 10k Ohm resistor in order to force the current towards the 8th pin.
  • Micro-USB Cable: Connects the Arduino to your computer for power and code.
  • Jumper Wires: Connect all the components together.
Design realized on Tinkercad

Timing and Logic

This has a similar result to the original starter project, with the difference that this is going to count both minutes and seconds (ten by ten). The end of the 5 minutes is going to be signaled by a Christmas-light kind of LED choreography, which is going to end triggering the tilt sensor and start from the beginning (for the purpose of making a video that would last less than 5 minutes I made the code wait 100x less).

The Arduino code uses timing functions to manage the sequence.

  1. Initialize: The Arduino initializes the tilt switch and sets its measurement pin to INPUT.
  2. Polling: The Arduino constantly polls the tilt switch for any orientation change.
  3. Sequential Activation: Any orientation change triggers the sequential activation of the LEDs.
  4. Time Delay: Each LED is turned on at regular intervals, providing a visual representation of the passing time.

Software Execution

The code is designed to update the LEDs after each tilt or orientation change and keep them synchronized with the digital hourglass's overall status. This provides a highly responsive and engaging user interface.

Future Expansion

  • Custom Time Settings: Add a push button or a potentiometer to allow you to customize the timing of the hourglass.
  • Audio Feedback Integration: Add a buzzer to provide audible feedback when the digital hourglass finishes its cycle.
  • OLED Display Integration: Add a small OLED display to show the exact time remaining.
  • Wireless Notification: Add a Bluetooth module to send a notification to your smartphone when the hourglass is finished.

Starter Kit - Hourglass (personal mod) is a perfect project for any electronics enthusiast looking for a more interactive and engaging educational tool!

ข้อมูล Frontmatter ดั้งเดิม

apps:
  - "1x Arduino IDE"
author: "shassandanish1"
category: "Photography"
components:
  - "5x 5 mm LED: Red"
  - "5x 5 mm LED: Green"
  - "10x Resistor 220 ohm"
  - "1x Resistor 10k ohm"
  - "1x Tilt Switch, SPST"
  - "1x Arduino UNO"
description: "Mod of the Starter Kit project n. 8 5 minutes counter with different lights for seconds and minutes"
difficulty: "Intermediate"
documentationLinks: []
downloadableFiles:
  - "https://github.com/pnuts93/arduino_hourglass"
  - "https://github.com/pnuts93/arduino_hourglass"
encryptedPayload: "U2FsdGVkX1/MSdPTHRgKT1EprYdozdAylItVNXNAox+ZmwEn0JXDjyA2URtqWe5Ufxq8INkyoWcWThZkRV1Jyf0rzIAaOapELBJ28YuJedY="
heroImage: "https://cdn.jsdelivr.net/gh/bigboxthailand/arduino-assets@main/images/projects/starter-kit-hourglass-personal-mod-03f25b_cover.jpg"
lang: "en"
likes: 0
passwordHash: "b9f9657af9e1b0289e7c528e5091b23a0f7b7597d3d94adf056521f80d9edde2"
price: 1499
seoDescription: "A custom mod of Starter Kit project 8 featuring a 5-minute counter with separate lights for seconds and minutes."
tags:
  - "hourglass"
  - "arduino"
  - "mod"
  - "beginners"
title: "Starter Kit - Hourglass (personal mod)"
tools: []
videoLinks:
  - "https://www.youtube.com/embed/dUTxZdzroL8"
views: 1071