This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # roughly based on https://gist.github.com/sbyx/6d8344d3575c9865657ac51915684696 | |
| mode: single | |
| max_exceeded: silent | |
| blueprint: | |
| name: Appliance has finished | |
| description: Do something when an appliance (like a washing machine or dishwasher) has finished as detected by a power sensor. | |
| domain: automation | |
| input: | |
| power_sensor: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import json | |
| import twitter | |
| import subprocess | |
| import datetime | |
| import csv | |
| class SpeedTest(object): | |
| SPEEDTEST = '/tmp/speedtest.csv' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import twitter | |
| import datetime | |
| import csv | |
| import requests | |
| class OfflineTimer(object): | |
| DATETIME_FORMAT = '%Y-%m-%d %H:%M:%S' | |
| OFFLINE_SINCE = '/tmp/offline_since.txt' |