diff --git a/iotDashboard/mqtt.py b/iotDashboard/mqtt.py new file mode 100644 index 0000000..9c13a8f --- /dev/null +++ b/iotDashboard/mqtt.py @@ -0,0 +1,4 @@ +import paho.mqtt.subscribe as subscribe + +msg = subscribe.simple("esptest-01/sensor/tempreature/state", hostname="localhost") +print("%s %s" % (msg.topic, msg.payload)) diff --git a/iotDashboard/templates/chart.html b/iotDashboard/templates/chart.html index 7791ef9..09b3707 100644 --- a/iotDashboard/templates/chart.html +++ b/iotDashboard/templates/chart.html @@ -23,11 +23,31 @@ width: 100% !important; height: 100% !important; } + + .current-conditions { + text-align: center; + padding: 20px; + margin-bottom: 20px; + background-color: #ffffff; + border-radius: 10px; + box-shadow: 0px 0px 15px rgba(0, 0, 0, 0.1); + } + + .current-conditions h2 { + font-size: 36px; + margin: 10px 0; + } + + .current-conditions .value { + font-size: 48px; + font-weight: bold; + margin-bottom: 10px; + } -