A USB timer powered by Digispark ATtiny85 according to pomodoro time management technique

Overview

ES Timer

ES Timer

Powered by Digispark ATtiny85 and it works based on 🍅 pomodoro time management technique a special timer for all those that work a lot with computer and have difficulty managing time. Features of ES Timer in compare to existing softwares:

  • forcing to follow the simple law of this technique
  • it is simple and cheap to make less than 10$
  • it can store in memory awake and sleep time and count of pomodoros and show them

Contents

  1. How it works
  2. Requirements
  3. Assemble monitor version (Optional)
  4. Initialization arduino ide for Digispark ATtiny85
  5. Upload code
  6. Configurations
  7. Demos
  8. Donations
  9. License

How it works

As mentioned, this timer works according to the Pomodoro technique, which you can refer to this link for more information about the technique. it works in such a way that when the user connects it to the port of her/his computer, it starts countdown according to the time specified by the user, and the user should to do his task during that time. when counter reach to zero, it using the HID protocol goes the computer to sleep mode and it starts counting again for user rest. From this moment, it is not possible to use the computer by user and it cannot wake up the computer until the counting is over.

Requirements

  • Arduino IDE
  • Digispark ATtiny85
  • For monitor version (Optional)
    • Female and male pin header standard
    • LED
    • PCB 10x10 pin
    • Soldering iron and wire
    • SSD1306 I2C OLED
    • Wire

Assemble monitor version

Step 1 Step 2 Step 3
Step 1 Step 2 Step 3
Step 4 Step 5 Step 6
Step 4 Step 5 Step 6
  1. Cut your PCB into square shape (10x10 holes) with cutter.
  2. Break female pin header into two pins 2 and 4 and put them on pcb like top photo then soldering them legs.
  3. The same work do on male pin header with the difference that, you have to break it into 3 and 6 pins, look to related picture.
  4. In this step putting digispark attiny85 on male pin headers and soldering their top legs related to 5V, GND, P0, P1, P2.
  5. According to the picture of the fifth step, do wiring and solder on the back of pcb.
  6. In the end, put OLED and LED on pin headers, in this moment your ES Timer is ready for next step.

Initialization arduino ide for Digispark ATtiny85

If this is the first time you have used Digispark ATtiny85 in Arduino IDE, you need to follow these steps to see click here please.

Upload code

After opening the file EsTimer.ino in Arduino IDE In order to be able to upload the code on the device, you must add the zip files in the lib folder to IDE To do this, follow the path:

Arduino IDE Toolbar -> Sketch -> Include Library -> Add .ZIP Library...

If you have assembled the monitor version, you need to change the value of INCLUDE_OLED to true. Now to upload the code in ES Timer click on the arrow button or use shortcut Ctrl + U. Wait for the code to be compiled. After you see the Please plug in the device ... message. Connect the device to the computer. After a maximum of 5 seconds, the code will be uploaded. Congratulations 🎉 , your ES Timer is ready to use.

Configurations

You can customize the awake and sleep system. All you have to do is change the definition values of AWAKE_TIME and SLEEP_TIME also, if you want you can change the brightness OLED by changing BRIGHTNESS_OLED defines in range of 0..1 and if you have connected your ES Timer to right side of computer should change FLIP_CONTENT to true and you can also change the value of BE_SAVE_TIMER_STATUS to false in order to disable timer mode saving (sleep & rest).

Note 📝 : According to the code, the maximum definition time for AWAKE_TIME is 99 minutes and for SLEEP_TIME is a quarter AWAKE_TIME.

Demos

Monitor version Only digispark
Monitor version Only digispark

Donations

This is free, open-source software. If you'd like to support the development of future projects, or say thanks for this one, you can donate:

RIAL at 6037701527276452

BTC at bc1q0l8rn8y5rlka278ypq6u4dvapyue7d64uvhgct

BTC qrcode

License

Copyright (C) 2021  Erfan Sn

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see https://www.gnu.org/licenses/.
You might also like...
Anotter USB temperature logger that can record up to four channels with thermocouple or NTCs connected via CDC directly or SCPI to USB.
Anotter USB temperature logger that can record up to four channels with thermocouple or NTCs connected via CDC directly or SCPI to USB.

temperature-logger Anotter USB temperature logger that can record up to four channels with thermocouple or NTCs connected via CDC directly or SCPI to

Simple lights effects driven by an ATTiny85

halloween-lights Simple light effects driven by an ATTiny85 assembled with three gadgets grabbed from Thingiverse Halloween Tree Stump LED Candle [thi

My own version of a PCB Christmas Tree, using an ATtiny85 / ATtiny13A.
My own version of a PCB Christmas Tree, using an ATtiny85 / ATtiny13A.

PCB_ChristmasTree My own version of a PCB Christmas tree, using an ATtiny85 / ATtiny13/13A. Some of the ideas are my own, others are borrowed from var

Simple ATTiny85 based PS/2 to Amiga keyboard protocol converter that fits inside the keyboard.
Simple ATTiny85 based PS/2 to Amiga keyboard protocol converter that fits inside the keyboard.

Simple ATTiny85 based PS/2 to Amiga keyboard protocol converter that fits inside the keyboard.

Simple min heap timer

KTimer simple useable heap timer . Samples #include "ktimer.h" ktimer::KTimerstd::chrono::seconds, std::mutex myTimer ; //default ktimer::KTimer

A software serial driver package by using the hardware timer capture / comparison functionality.

Soft serial 1.简介 Soft serial 是利用硬件定时器捕获/比较功能实现软件模拟串口的软件包。 1.1目录结构 Soft serial 软件包目录结构如下所示: soft_serial ├───inc // 头文件目录 │

Timer for advanced LED blinking for Arduino

TimerLED Timer for advanced LED blinking for Arduino (millis()-based) Compatibility Compatible with all Arduino platforms Dependencies TimerMs Install

Software for the best kitchen timer.
Software for the best kitchen timer.

kitchen timer The summer of 2021 I finally got fed up with my crappy ikea kitchen timer and decided to build my own. You can find a build log in this

Simple timer with splits, useful for speedrunning
Simple timer with splits, useful for speedrunning

SeedSplit Simple timer with splits, useful for speedrunning Installation (building) You need to have Birb2D library installed (version 0.1.0). make -j

Comments
  • Newbie Problem

    Newbie Problem

    Hi! I'm trying to build your OLED version. The EEPROM part seems working: the PC go to standby mode after a minute (i set that so) But the problem is the OLED that have no signs of working.

    • I added the .h files and putted "true" in the code
    • wiring and soldering is correct (the OLED work with other projects)
    • libraries added

    Am i missing something? Thank you and compliments for you awesome project!

    FC from ITA

    opened by LeatherElectron 4
  • Starts in sleep mode, no sequence reset

    Starts in sleep mode, no sequence reset

    I love this design and have made it according to your instructions. Thank you for posting them here. It's working for me but I have a couple of issues. Apologies for not being able to fix it myself - I'm a novice programmer and some of your code is beyond my abilities.

    My issue is that on first use the timer puts my PC to sleep immediately. I have tried changing bits of the code but to no avail. Reuploading the code with different values doesn't take effect until the first round is complete as the timer remembers where it was in the sequence before the key is removed.

    Changing awake and sleep times works, but again the timer picks up from where in the sequence it was previously and therefore the new values don't take effect immediately. Is there something I'm missing or is this how the code is expected to work?

    opened by chuffstix 4
  • Doc for keystroke values

    Doc for keystroke values

    I tried ES-Timer on a Linux based system. The flash seemed to work. The lights seem to match, but the keystroke did not lock. My issue might have to do with my udev rules.

    Can you explain these values found in ./lib/ESTimer.zip ESTimer/ESTimer.h?

    #if SYSTEM_OS == WINDOWS
    #   define LOCK_SHORTCUT 0x08, 0x0F
    #elif SYSTEM_OS == LINUX
    #   define LOCK_SHORTCUT 0x01 | 0x04, 0x0F
    #else
    #   define LOCK_SHORTCUT 0x01 | 0x08, 0x14
    #endif
    

    I assume it correlates to these values:

    • 0x08 = Windows or super key
    • 0x0F = l
    • 0x01 = Control
    • 0x04 = Alt
    • 0x14 = q

    I read hut1_3_0.pdf pages 88-94 and hid1_11.pdf pages 59 and 60, but I am still having trouble understanding the Super, Control, and Alt portion. What differentiates between 0x08 being a modifier and being the letter e?

    opened by TechnologyClassroom 2
  • Lock instead of sleep?

    Lock instead of sleep?

    Cool project!

    I am interested in modifying ES-Timer to lock the machine instead of sending it to sleep as sleep breaks the WiFi connection and I work with remote servers frequently. I could just use tmux or screen after I remote in, but locking the screen would be simple. Locking instead of sleeping also has a security benefit of ensuring someone else cannot press the power button to access the machine while away on a break.

    With DigiKeyboard.h, the method to send the CTRL+ALT+l keystroke would be like this:

    DigiKeyboard.sendKeyStroke(KEY_L, MOD_ALT_LEFT | MOD_CONTROL_LEFT);
    

    Can you help me understand which line of code is doing the sleep key? Is it this line in ESTimer.h within ESTimer.zip?

    #define SLEEP           0x82
    

    If that is correct, do you know how to send multiple keys to build a keystroke in this way without using DigiKeyboard.h?

    opened by TechnologyClassroom 2
Releases(v2.1.0)
  • v2.1.0(Mar 9, 2022)

  • v2.0.1(Jan 20, 2022)

    A Big update! 🥳

    • Replacement of sleep mode with lock screen on break phase
    • Showing the current Pomodoro with a semicircle
    • Changed save mode to a counter of work phase of timer
    • Notified the start of the break phase with 15 seconds before starting by turning on the led
    • Determining the amount of long break
    • Specify address of ssd1306 if different
    • Increasing the life of ES timer memory to a maximum of 9 years! (with max 8 Pomodoro in day)
    • Refactoring all code and optimizing it
    Source code(tar.gz)
    Source code(zip)
  • v1.2.1(Nov 14, 2021)

    • Changing how save timer from counter to status (may changed in future)
    • Added configuration of save the timer status
    • Fixing not change immediately the time of sleep and awake system
    Source code(tar.gz)
    Source code(zip)
  • v1.1.1(Oct 30, 2021)

  • v1.1.0(Oct 23, 2021)

  • v1.0.0(Oct 23, 2021)

Owner
Android and etc. dev and crazy programming to exprience current technologies
null
Digispark attiny85 code to smack the big button!

dave-o-rec The big button what records the trucks! Requires the DigiKeyboard.h library, which is included in the Arduino IDE's DigiStump package. Setu

Dave Regan 1 Dec 25, 2021
A 555 timer simulator running on the ATTiny85 :)

ATTiny555 A 555 timer simulator running on the ATTiny85 :) For a more detailed description (and build instructions), check me out on Hackaday! Overvie

null 60 Dec 5, 2022
Multiple payloads for the digispark digistump AVR boards.

Multiple payloads for the digispark digistump AVR boards. Some are translated from RubberDucky and some are original..

null 6 Dec 14, 2022
This is the repo for the microcontroller part of project Cleanurge - a scalable IoT powered waste management system, our solution towards a greener world.

Cleanurge A scalable waste management system powered by IoT. There are 3 repositories for the entire cleanurge system in total cleanurge-mcu: Containi

Developer Student Clubs KGEC 6 Oct 11, 2021
A basic system that waters a plant according to the heat index of the environment.

Basic-Plant-Watering-System ?? This is a basic plant watering system created on Arduino Uno using DHT11 Temperature and Humidity sensor. DHT Sensor Li

Aydanur Akça 5 Apr 11, 2021
C Program to input a string and adjust memory allocation according to the length of the string.

C-String C Program to input a string and adjust memory allocation according to the length of the string. With the help of this program, we have replic

Kunal Kumar Sahoo 1 Jan 20, 2022
ESP32 software USB host through general IO pins. We can connect up to 4 USB-LS HID (keyboard mouse joystick) devices simultaneously.

esp32_usb_soft_host esp32 USB-LS pure software host thru general IO pins. Up to 4 HID devices simultaneously. board ~$3 :https://www.aliexpress.com/pr

Samsonov Dima 313 Jan 1, 2023
ESP8266 software USB host through general IO pins. We can connect up to 2 USB-LS HID (keyboard mouse joystick) devices simultaneously.

esp8266_usb_soft_host Test for esp8266 usb host . Works with ESP-IDF v3.4 80MHz and 160MHz. WorkInProgress Test run with mouse & combined mouse & keyb

Samsonov Dima 28 Sep 1, 2022
Tiny and portable usb host and device stack for mcu with usb ip

Tiny and portable usb host and device stack for mcu with usb ip

sakumisu 545 Jan 2, 2023
USB-C_PCB_experiments - USB-C ports made from a flex PCB and an ATtiny84A

USB-C PCB Experiments This is part of an ongoing series of projects involving creative interpretations of the USB mechanical standards. You've probabl

Sam Ettinger 23 Sep 5, 2022