diff --git a/thermostat.py b/thermostat.py index 61c0e66..17fc8d2 100644 --- a/thermostat.py +++ b/thermostat.py @@ -212,12 +212,14 @@ migrate = Migrate(app, db, compare_type=True) # print(row) #sys.stdout.flush() +target_name = default_target + def thermostat_loop(): start_time = time.time() last_control_time = None new_forced_mode = None - target_name = default_target first_loop = True + global target_name while True: # if stop.is_set():