ble - fixing dict in summarize test run

This commit is contained in:
matt committed 2026-10-20 23:53:56 -07:00
1 parent 90cb977b35
commit 1dff4d71b6
2 files changed
+5 -3

No files matched your search

+3 -2
View File
@@ -337,7 +337,8 @@ def test_driver(test_count = 0, bt_usb_id = None):
# helper function for summarizing test run results
def summarize_test_run(sensors):
log.info(f" {sensors['name']} - Temp: {temp_ctof(sensors['name'])} | Humidity: {sensors['humidity']}")
for sensor in sensors:
log.info(f" {sensor['name']} - Temp: {temp_ctof(sensor['temp'])} | Humidity: {sensor['humidity']}")
result = {
"found_macs": found_macs,
"sensor_results": sensors
@@ -362,7 +363,7 @@ def print_sensor_data(sensors):
# yes i am an insufferable american that doesn't think in celcius, sue me
def temp_ctof(c_temp):
f_temp = (c_temp * 1.80) + 32.0
return f_temp
return round(f_temp, 1)
# This resets the BT adapter when things go caca
def reset_adapter():