You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
latest_sensor_data = latest_data["Humidity"] # Retrieve the raw sensor data
latest_sensor_value = float(latest_sensor_data) # Convert to float
threshold = 80 # Replace with your average value
if latest_sensor_value > threshold:
msgbody = '<p>The current humidity ' + f'{latest_sensor_value:.2f}' + '% is above threshold, the reading is more than ' + str(threshold) + '%' + '.</p><br>'