Skip to content

Instantly share code, notes, and snippets.

View D3M05's full-sized avatar

Justin D3M05

View GitHub Profile
@D3M05
D3M05 / imhome.py
Created March 24, 2014 17:20
Script that controls events for leaving home and coming back using phone pings and wemo motion sensors.
import os
import subprocess
import time
import datetime
import ephem #pyephem integration for checking if lights need to remain on
o=ephem.Observer()
o.lat='30' #change to your latitude
o.long='-98' #change to your longitude
running=1