diff --git a/scripts/ota_update.py b/scripts/ota_update.py index 35438bb..200731f 100755 --- a/scripts/ota_update.py +++ b/scripts/ota_update.py @@ -66,6 +66,8 @@ if not success: print("Failed.") exit(1) +print() # for proper progress display + with open(filename, "rb") as binfile: filesize = os.stat(filename).st_size @@ -80,11 +82,11 @@ with open(filename, "rb") as binfile: s.send(data) sent_bytes += len(data) - print(f"Sent {sent_bytes} of {filesize} bytes.") + print(f"\rSent {sent_bytes} of {filesize} bytes.") success, message = readMessage(s) print(f"Server message: {message}") if not success: print("Failed.") - exit(1) \ No newline at end of file + exit(1)