Automate your Pomodoro Routine with Amazon Alexa, Google Assistant, or Home Assistant.
This post may contain affiliate links that the author will receive compensation if a purchase is made through the links.
Working from home was supposed to be a short term event. Since that ship has sailed, we need to find a way to focus at home. Focusing at home can be hard, where there are housemates, TVs, and Video Games. To keep me on task, I follow a four-step process, to make sure that I remain on task:
- List my goals and activities at the beginning of the week (I use a Trello Board or some other Kanban Board)
- Break down those goals and activities into small manageable tasks. I then transcribe those tasks and track them in Todoist.
- Schedule those tasks over the week, focusing on never over-burdening a day.
- Work on the tasks in front of me in short bursts.
The Pomodoro technique is a great way to maintain your focus and combat distractions. To prevent yourself from being overwhelmed, you try to focus for only twenty-five minutes at a time. These small work sessions are coupled with short breaks.
By achieving small bursts of concertation, the idea is that you aren’t overwhelmed with everything that you have to do, you are just focusing on “putting one foot in front of the other” for twenty-five minutes, i.e. Getting Stuff Done.
The benefits and theory are explained really well in the article below:
Pomodoro Technique, version 4.u (Medium)
This technique does require tools to manage our flow. Namely a timer and a way to manage it. When I first started out, I started using the below timer. It’s easy to use and relatively cheap.
I wanted to reduce the friction between managing the work sessions and break times so that I could actually focus on my work. So I looked at automation opportunities.
Regardless of what Home Automation Hub you have, there is a solution to this problem, feel free to skip to the platform that you want to use:
Amazon Alexa Routines
The Amazon Alexa is a very low cost “digitial assistant”. Out of the box you can create timers, but that’s just a voice solution to the timer block.
Amazon provides the ability to automate workflows via Routines. You can access this by hitting the “More Button” on your Alexa app and choosing “Routines”
Steps to Create The Routine
- Give Alexa a Phrase to Listen for: “Alexa, I need to work”
- Provide a Confirmation Response that Alexa Heard You — you can use a Light Change or an Audible Notification
- Wait (or Play Music) for 25 minutes (your focus time)
- At the end of the 25 minutes say a notification to let you know its time to rest
- Wait for 5 minutes (your break time)
- Say a notification that your break is over
You can use either Alexa to announce your notifications or use your integrated smart lights.
You’ll notice that I use my Office Lights to change colors in various phases of my Pomodoro sessions. This allows me to see at a glance when I should be focusing vs resting.
NOTE: You will have to tell Alexa to repeat the loop when you are ready for your next Pomodoro session.
Google Assistant Routines
Google Assistant’s automated workflows are also called routines. To get started, open the Google Home App, Navigate to Routines, and Hit the (+) button to create a new routine.
Steps to Create The Routine
- Give a Phrase (or group of phrases!) that will start your Automated Pomodoro Work Phrase
- Change the Color of your Office Light
- Start a timer called “Rest” for 30 minutes. This way you will know when its time to end your rest phrase.
- Start a timer called “Work” for 25 minutes. This way you will know when it’s time to stop your rest phase.
- (Optional) Use music to help set the mood for optimal productivity.
Notice that we defined all our action definitions in “Plain English”. Anything that you can do with your Google Assistant can be a step in your routine. When you know what you want to happen, type the command exactly as you would say it. I would test the commands to make sure that it works as expected before committing it to the routine.
The main difference between Alexa and Google Routines is the manner in how you have to think about setting up the routines. Alexa Routines are like steps in a cookbook, do this and then that. Google Routines happen at once, so you have to think a little harder about what will happen and when and plan accordingly.
Most “smart” lights work for both the Amazon and Google Ecosystem. Make sure that when you make your purchase, that you check for compatability. Here are two of the most popular lights (Phillips Hue and Lifx):
Home Assistant Technique
If you want more control and to integrate other functionality into your Pomodoro flow, Home Assistant has what you want.
In my case, I’m going to use Home Assistant (on a Raspberry Pi), an Amazon Alexa, and the Phillips Hue ecosystem to create my timer and track my progress.
Now that we have the hardware, it is time to look at the actual automation.
We are going to use three different components in Home Assistant to make our Pomodoro flow (these can all be accessed from the Home Assistant “Configuration”):
- Helpers — These are counters and toggles that we are going to use to keep track of our automations
- Scripts — These are the equivalent to the routines in Google Assistant and Amazon Alexa
- Automations — Our Stimuli (in this case pushing buttons on our Phillips Hue Remote) that kick off our Scripts.
We are going to use a Phillips Hue Smart Dimmer to make our automation tactile.
Create the Helpers
Home Assistant recently added “Helpers” to their automation stable. Think of these Helpers as Variables in a typical programming environment.
We are going to create two Helpers:
- An Input Boolean — This allows us to indicate when we are in our “Work Flow”
- An Input Number — This allows us to count our completed Pomodoro Work Flows
Create our Scripts
Home Assistant can create scripts either in the GUI or as shown below in the YAML syntax. I’ve added it here for you to easily copy into your own /scripts.yaml file or you can create it in the GUI (as shown below).
pomoscript:
alias: PomoScript
sequence:
- service: light.turn_on
data:
rgb_color:
- 86
- 177
- 179
entity_id: light.main_office
- service: input_boolean.turn_on
data: {}
entity_id: input_boolean.pomoflow
- wait_template: ''
timeout: 00:25:00
continue_on_timeout: true
- service: light.turn_on
data:
rgb_color:
- 103
- 179
- 86
entity_id: light.main_office
- service: input_number.increment
data: {}
entity_id: input_number.pomocomplete
- service: input_boolean.turn_off
data: {}
entity_id: input_boolean.pomoflow
- wait_template: ''
timeout: 00:05:00
continue_on_timeout: true
- service: notify.alexa_media
data_template:
target: media_player.office
message: You have completed {{ states('input_number.pomocomplete') }} cycles
data:
type: announce
method: all
- service: input_number.decrement
data: {}
entity_id: input_number.pomothissession
mode: single
- Once the cycle is kicked off via the automation, we change our office light to a light blue via a Call Service and set our toggle (input_boolean.pomoflow) to on
- We then have the system WAIT for 25 minutes (Remember to set the continue_on_timeout: true option)
- The light then changes to green for 5 minutes via a Call Service
- We increment our counter (input_number.pomocomplete) and set our toggle (input_boolean.pomoflow) to off
- At the end of the five minutes, we use Amazon Alexa to announce the number of cycles we have completed
Note: I’m using the add-on component Alexa Media Player to do the final step and added another helper (input_number.pomothissession) in case I want to track how many Pomo Cycles I have left.
Here are all the Configurations in the GUI Editor:
We also need to create a script to reset our counter to zero. So create another Script called Weekly Pomodoro Reset and use it to set the input_number helper to 0.
By creating a script, you can call it via multiple automations! Modularity is important.
Create the Automation
Now for the magic. We are going to call these scripts via pushing a button.
Create a new Automation and choose a trigger from you Phillips Hue Dimmer Switch.
Then you can use the simple repeat loop available in Home Assistant to repeat it however many times you want. You can also use an additional input_boolean and pass the field as a parameter to the count option so that you can dynamically set your sessions. See the Home Assistant documentation for more information.
Using the same format you can also do things like:
- Use one of the buttons to increment the tasks completed, so you can track your productivity during the week.
- Create a Lovelace dashboard to visually show how productive you’ve been!
Focus is within your grasp! Taking the time to automate your Pomodoro timer will help reduce the friction between work and distractions. Use these recipes as a template to get started, but make sure that they work for you!.
How will you be able to integrate this automation into your other automation needs?
For example:
- You can continue to iterate over these automations to let your housemates that you are working
- Call third-party web services like IFTTT to perform additional tasks based on stimuli from other programs
- Integrating your Trello or Todoist into the workflow by keeping track of what tasks to perform in your Pomodoro Sessions.
5 thoughts on “Automate your Pomodoro Process Today”
Comments are closed.