From b918e916b1ec6e53d141eb15e9ae2b98d446e894 Mon Sep 17 00:00:00 2001 From: mesca Date: Wed, 16 Feb 2022 13:47:19 +0100 Subject: [PATCH] Fix formatting --- timeflux_plux/helpers/transfer.py | 14 +++++++------- timeflux_plux/nodes/driver.py | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/timeflux_plux/helpers/transfer.py b/timeflux_plux/helpers/transfer.py index a4c5e79..c74e875 100644 --- a/timeflux_plux/helpers/transfer.py +++ b/timeflux_plux/helpers/transfer.py @@ -9,34 +9,34 @@ def ECG(signal): """ECG value in millivolt (𝑚𝑉)""" - return ((signal / 2 ** RESOLUTION) - 0.5) * VCC + return ((signal / 2**RESOLUTION) - 0.5) * VCC def BVP(signal): """BVP value in r.i. units""" - return signal / 2 ** RESOLUTION + return signal / 2**RESOLUTION def EDA(signal): """EDA value in microsiemens (𝜇𝑆)""" - return ((signal / 2 ** RESOLUTION) * VCC) / 0.12 + return ((signal / 2**RESOLUTION) * VCC) / 0.12 def EMG(signal): """EMG value in millivolt (𝑚𝑉)""" - return ((signal / 2 ** RESOLUTION) - 0.5) * VCC + return ((signal / 2**RESOLUTION) - 0.5) * VCC def PZT(signal): """Displacement value in percentage (%) of full scale""" - return ((signal / 2 ** RESOLUTION) - 0.5) * 100 + return ((signal / 2**RESOLUTION) - 0.5) * 100 def EEG(signal): """EEG value in microvolt (𝜇𝑉)""" - return ((((signal / 2 ** RESOLUTION) - 0.5) * VCC) / 40000) * 1e-6 + return ((((signal / 2**RESOLUTION) - 0.5) * VCC) / 40000) * 1e-6 def LUX(signal): """LUX normalized value (0-1)""" - return signal / 2 ** RESOLUTION + return signal / 2**RESOLUTION diff --git a/timeflux_plux/nodes/driver.py b/timeflux_plux/nodes/driver.py index 1a17b7d..cab3897 100644 --- a/timeflux_plux/nodes/driver.py +++ b/timeflux_plux/nodes/driver.py @@ -12,7 +12,7 @@ # Load library according to system _lib = platform.system() _lib += "ARM" if platform.machine().startswith("arm") else "" -_lib += "64" if sys.maxsize > 2 ** 32 else "32" +_lib += "64" if sys.maxsize > 2**32 else "32" if platform.system() in ("Windows", "Darwin"): _version = sys.version.split(".") _lib += f"_{''.join(sys.version.split('.')[0:2])}"