From 7284f4388246c3ba5c090aa5c70985a0091bd536 Mon Sep 17 00:00:00 2001 From: Ryan Friedman <25047695+Ryanf55@users.noreply.github.com> Date: Sun, 29 Dec 2024 19:19:21 -0700 Subject: [PATCH] Add delay to fix hot loop CPU Signed-off-by: Ryan Friedman <25047695+Ryanf55@users.noreply.github.com> --- MAVProxy/mavproxy.py | 1 + 1 file changed, 1 insertion(+) diff --git a/MAVProxy/mavproxy.py b/MAVProxy/mavproxy.py index deeaac02f2..58807b0f9c 100755 --- a/MAVProxy/mavproxy.py +++ b/MAVProxy/mavproxy.py @@ -940,6 +940,7 @@ def log_writer(): if not mpstate.logqueue_raw.empty(): bytes = mpstate.logqueue_raw.get(block=False) mpstate.logfile_raw.write(bytearray(bytes)) + time.sleep(0.001) # TODO consider wait() the stop event instead timeout = time.time() + 10