diff --git a/relay.py b/relay.py index b703ac6..42af4b2 100644 --- a/relay.py +++ b/relay.py @@ -14,13 +14,13 @@ def main(): try: while True: # Make sure the U.R.L. is valid. - r = requests.get('http://3.9.19.84/api/readings/latest/1') + r = requests.get('http://ritherdon.abbether.net/api/readings/latest/1') # print(r.status_code) # For testing. data = r.json() # print(data) # For testing. the_reading = data.get("reading") # print(the_reading) # For testing. - if the_reading > 30: + if the_reading > 33: # Print for testing. # print(f"[INFO] Light is on -- {the_reading}.") GPIO.output(relay_pin, GPIO.HIGH) diff --git a/shutdown.sh b/shutdown.sh index aa5b6d4..7ffd1cb 100755 --- a/shutdown.sh +++ b/shutdown.sh @@ -13,7 +13,7 @@ logDate=$(date '+%Y-%m-%dT%TZ') logFile="/home/rtrp/logs/shutdown-logs.txt" -mainURL="http://3.9.19.84/api/status/update" # Make sure this is valid. +mainURL="http://ritherdon.abbether.net/api/status/update" # Make sure this is valid. getApiUrl () { case $HOSTNAME in diff --git a/startup.sh b/startup.sh index 7f80394..e53751d 100755 --- a/startup.sh +++ b/startup.sh @@ -23,7 +23,7 @@ sleep 60 logDate=$(date '+%Y-%m-%dT%TZ') logFile="/home/rtrp/logs/startup-logs.txt" -mainURL="http://3.9.19.84/api/status/update" # Make sure this is valid. +mainURL="http://ritherdon.abbether.net/api/status/update" # Make sure this is valid. getApiUrl () { case $HOSTNAME in