From 428268f4422cf187ceee1648b7766b6a828dc5a1 Mon Sep 17 00:00:00 2001 From: Rene Reimann Date: Mon, 6 Oct 2025 15:10:13 +0200 Subject: [PATCH 1/4] update to recent dripline version --- Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 27455bb..c4a291f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,6 @@ ARG img_user=ghcr.io/driplineorg ARG img_repo=dripline-python -#ARG img_tag=develop-dev -ARG img_tag=receiver-test +ARG img_tag=v5.1.0 FROM ${img_user}/${img_repo}:${img_tag} From 5e90e9fe64ec892cad08df74787e8516289ab13c Mon Sep 17 00:00:00 2001 From: Rene Reimann Date: Mon, 6 Oct 2025 15:10:51 +0200 Subject: [PATCH 2/4] separate conversion function to float in its own function --- dripline/extensions/ethernet_huber_service.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/dripline/extensions/ethernet_huber_service.py b/dripline/extensions/ethernet_huber_service.py index 68f0bdb..f77ce2b 100755 --- a/dripline/extensions/ethernet_huber_service.py +++ b/dripline/extensions/ethernet_huber_service.py @@ -133,6 +133,12 @@ def __init__(self, self.numeric = numeric Entity.__init__(self, **kwargs) + def convert_to_float(self, hex_str): + val = int(hex_str, 16) + if val > int("7FFF", 16): + val = val - int("FFFF", 16) - 1 + return val/100. + @calibrate() def on_get(self): # setup cmd here @@ -142,10 +148,9 @@ def on_get(self): logger.debug(f'raw result is: {result}') result = result[self.offset: self.offset+self.nbytes] if self.numeric: - val = int(result, 16) - if val > int("7FFF", 16): - val = val - int("FFFF", 16) - 1 - result = val / 100. + logger.debug("is numeric") + result = self.convert_to_float(result) + logger.debug(f'extracted result is: {result}') return result def on_set(self, value): From 1848063f54037fd34cbb124c2ab9a24c3858896f Mon Sep 17 00:00:00 2001 From: Rene Reimann Date: Fri, 23 Jan 2026 09:24:17 +0100 Subject: [PATCH 3/4] updating dripline version --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index c4a291f..9e9df5c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ ARG img_user=ghcr.io/driplineorg ARG img_repo=dripline-python -ARG img_tag=v5.1.0 +ARG img_tag=v5.1.2 FROM ${img_user}/${img_repo}:${img_tag} From 914aa6314ecc29437819d0f8e4896360bb8d2159 Mon Sep 17 00:00:00 2001 From: Rene Reimann Date: Thu, 5 Feb 2026 23:03:45 +0100 Subject: [PATCH 4/4] update documentation comments, nicer fromating and better variable name --- dripline/extensions/asteval_endpoint.py | 3 +-- dripline/extensions/cmd_endpoint.py | 2 +- dripline/extensions/ethernet_huber_service.py | 8 ++++---- dripline/extensions/pfeiffer_endpoint.py | 2 +- 4 files changed, 7 insertions(+), 8 deletions(-) diff --git a/dripline/extensions/asteval_endpoint.py b/dripline/extensions/asteval_endpoint.py index 68e134b..8a24f77 100644 --- a/dripline/extensions/asteval_endpoint.py +++ b/dripline/extensions/asteval_endpoint.py @@ -21,7 +21,6 @@ def __init__(self, ''' Args: asteval_format_response_string (str): function definition to format response. Default: "def f(response): return response" - *kwargs -> FormatEntity ''' FormatEntity.__init__(self, **kwargs) self.asteval_format_response_string = asteval_format_response_string # has to contain a definition "def f(response): ... return value" @@ -30,7 +29,7 @@ def __init__(self, @calibrate() def on_get(self): - result =FormatEntity.on_get(self) + result = FormatEntity.on_get(self) raw = result["value_raw"] processed_result = self.evaluator(f"f('{raw}')") logger.debug(f"processed_result: {repr(processed_result)}") diff --git a/dripline/extensions/cmd_endpoint.py b/dripline/extensions/cmd_endpoint.py index 2897f18..731b68c 100644 --- a/dripline/extensions/cmd_endpoint.py +++ b/dripline/extensions/cmd_endpoint.py @@ -24,5 +24,5 @@ def __init__(self, cmd_str=None, **kwargs): self.cmd_str = cmd_str def cmd(self): - logger.debug("Command function was successfully called") + logger.debug("in cmd function") return self.service.send_to_device([self.cmd_str]) diff --git a/dripline/extensions/ethernet_huber_service.py b/dripline/extensions/ethernet_huber_service.py index f77ce2b..952cd9e 100755 --- a/dripline/extensions/ethernet_huber_service.py +++ b/dripline/extensions/ethernet_huber_service.py @@ -27,7 +27,7 @@ def bytes_to_ints(value): class EthernetHuberService(EthernetSCPIService): ''' - A fairly specific subclass of Service for connecting to ethernet-capable thermo fisher devices. + A fairly specific subclass of Service for connecting to ethernet-capable huber devices. In particular, devices must support a half-duplex serial communication with header information, variable length data-payload and a checksum. ''' def __init__(self, **kwargs): @@ -125,9 +125,9 @@ def __init__(self, get_str: hexstring of the command, e.g. 20 ''' if get_str is None: - raise ValueError('