This Pomodoro timer feautures different modes with varying amounts of timer which is counted down in seconds. You can also pause the timer and resume it whenever you want to. Pomodoro technique.
- A timer that displays how many seconds you have left.
- Study timer: 25 mins
- Short break timer: 5 mins
- Long break timer: 10 mins
- After each timer has passed it goes to the next mode.
- You can also pause the timer and then resume it with the same button.
what i learned
- How to take input using a push button.
- How to display and wire an LCD module.
- How to make a rudimentary timer using delay().
- How to receive input while the program is running.
I had to figure out a way to make a timer that didn’t keep the program stalled at delay(). I had to use a for loop that would delay for 1 sec each loop. The problem with this was that you would have to hold down the button for 1-2 seconds for it to actually receive the input and there was a chance for it to keep recieving the input afterwards. I added a two second delay between each input beind received to prevent unwanted inputs. The former issue could be solved by counting milliseconds instead of seconds.
The contrast can be adjusted by adding a potentiometer to the contrast pin of the LCD