Skip to content

Automation Pomodoro based on your timetable with Google smart device using pychromecast (Google Nest时间提醒小程序)

Notifications You must be signed in to change notification settings

xihajun/NestTimeManager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Pomodoro Reminder (on Nest Hub or Nest mini)

Automated time management system based on your timetable with Google Smart Device using pychromecast

How it works

image

default.mov

Key points:

Quick start

python code/run.py

Test Nest Hub

If you have your Google Nest Hub in your room with the same wifi network, let's try this see if it works.

import time
import pychromecast

from icalevents.icalevents import events
es  = events("webcal://p50-caldav.icloud.com/published/2/token", fix_apple=True)
url = 'https://api.oick.cn/txt/apiz.php?text=省去我开始要提醒你了,滴滴滴,' + es[0].summary + '&spd=1'
url = 'https://tts.youdao.com/fanyivoice?word=我开始要提醒你了,滴滴滴,' + es[0].summary + '&le=zh&keyfrom=speaker-target'
# Discover and connect to chromecasts named Living Room
# use pychromecast.get_chromecasts() to check the name
chromecasts, browser = pychromecast.get_listed_chromecasts(friendly_names=["Bedroom display"])
cast = chromecasts[0]
cast.wait()
# play media with message embedding
mc = cast.media_controller
mc.play_media(url,'video/mp4')
mc.block_until_active()

# quit app about 20 sec
time.sleep(20)
cast.quit_app()

TODO

  • Timetable project - previous python icalendar
  • customise your timetable using previous project
  • monite your mac project - based on github resource
  • Merge projects - done ✅

MP3 API

About

Automation Pomodoro based on your timetable with Google smart device using pychromecast (Google Nest时间提醒小程序)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published