From b6a40f2c9371db4afcd890e4aa0787a3c4a66eec Mon Sep 17 00:00:00 2001 From: CPD Date: Mon, 17 Mar 2025 15:30:29 +0100 Subject: [PATCH] Add live metadata updates --- cpdctrl/measurement.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cpdctrl/measurement.py b/cpdctrl/measurement.py index 00a5d66..c528145 100644 --- a/cpdctrl/measurement.py +++ b/cpdctrl/measurement.py @@ -141,6 +141,10 @@ def measure( elif type(recv) == tuple and recv[0] == "led_script": log.info(f"Received 'led_script', replacing script") led_script = recv[1] + elif type(recv) == tuple and recv[0] == "metadata": + log.info(f"Received 'metadata', updating metadata") + data.metadata |= recv[1] + data.write_metadata() else: log.error(f"Received invalid message: '{recv}'")