taim
New Member
Posts: 32
|
Post by taim on Jun 17, 2021 3:11:35 GMT -8
Hi,
instead of channel 1-8, would it be possible to assign sensible names (such as living room, kitchen etc.) to the internal temperature sensors?
In addition, in the blynk app, would it be possible to somehow trigger an alarm/notification when external temperature exceeds the internal temperature(s)? My use case is that I'd like to close the windows of my flat once the temperature outside is too high.
Besides, I am puzzled on what basis the bylnk app chooses the internal temperature. Sometimes the temp value switches from one internal sensor to the other (without any predictable pattern, at least from my understanding).
Best greetings, Timo
|
|
|
Post by doxidad on Jun 17, 2021 5:31:24 GMT -8
You can modify the code in indoorth.py to put room name or whatever on each channel.
Add a line in the functions buildTemperatureGraph and buildHumidityGraph similar to below - (BR=Bedroom,LR=Livingroom, FR=Familyroom) or whatever. You should probably keep them all short and maybe the same length.
colors = ['red', 'blue', 'green', 'violet', 'brown', 'black', 'magenta', 'pink'] room = ['BR', 'LR', 'FR', ' ', ' ', ' ', ' ', ' ']
In buildTemperatureGraph change this line
go.Scatter(x=Time, y=Temperature, name="CHAN "+str(i), to go.Scatter(x=Time, y=Temperature, name=room[i-1],
And in BuildHumidityGraph change this line go.Scatter(x=Time, y=Humidity, name="CHAN "+str(i), to go.Scatter(x=Time, y=Humidity, name=room[i-1],
The module updateBlynk.py uses the the last sent temperature/humidity. The last sensor that sends data to SkyWeather2 is the one that is reported to Blynk during an update. Ex: sensor 1 sends then 4 sends and a blynk update happens -4 is the data reported. Next time 2 sends then 1 and a blynk update happens 1 will be reported. This could be fixed to report only a specific sensor but a lot of code would have to added/changed.
|
|