summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2022-04-29 19:20:08 +0200
committerDaniel Friesel <derf@finalrewind.org>2022-04-29 19:20:08 +0200
commit06b57082d6e2f172994c7b2802e4c23237eca69a (patch)
tree3225490cbc134cb659556301643f714115ec4f69
parent4120267bcafaad6ca8b99dc449de6123a0d5e840 (diff)
fix json data keys
-rw-r--r--init.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index a1cca04..1d2db17 100644
--- a/init.lua
+++ b/init.lua
@@ -59,7 +59,7 @@ function uart_callback(data)
print("Invalid PM1006 frame")
return
else
- local json_str = string.format('{"pm25_ugm3": %d, "rssi_dbm": %d}', pm2_5, wifi.sta.getrssi())
+ local json_str = string.format('{"pm2_5_ugm3": %d, "rssi_dbm": %d}', pm2_5, wifi.sta.getrssi())
if not publishing then
publishing = true
gpio.write(ledpin, 0)