diff --git a/pio-tools/metrics-firmware.py b/pio-tools/metrics-firmware.py index 0ecdb3f36..623256245 100644 --- a/pio-tools/metrics-firmware.py +++ b/pio-tools/metrics-firmware.py @@ -7,7 +7,7 @@ from os.path import join def firm_metrics(source, target, env): if env["PIOPLATFORM"] == "espressif32": import tasmota_metrics - env.Execute("$PYTHONEXE -m tasmota_metrics " + str(tasmotapiolib.get_source_map_path(env).resolve())) + env.Execute("$PYTHONEXE -m tasmota_metrics \"" + str(tasmotapiolib.get_source_map_path(env).resolve()) + "\"") elif env["PIOPLATFORM"] == "espressif8266": map_file = join(env.subst("$BUILD_DIR")) + os.sep + "firmware.map" with open(map_file,'r') as f: @@ -22,4 +22,4 @@ def firm_metrics(source, target, env): print("Used static IRAM:",used_bytes,"bytes (",remaining_bytes,"remain,",percentage,"% used)") -env.AddPostAction("$BUILD_DIR/${PROGNAME}.bin",firm_metrics) \ No newline at end of file +env.AddPostAction("$BUILD_DIR/${PROGNAME}.bin",firm_metrics)