From 30c221efaf2f315a7fc58ed1b453f5762abbc168 Mon Sep 17 00:00:00 2001
From: awatlet <arnaud.watlet@umons.ac.be>
Date: Tue, 14 Nov 2023 12:25:24 +0100
Subject: [PATCH] Fixes rs_check

---
 ohmpi/ohmpi.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ohmpi/ohmpi.py b/ohmpi/ohmpi.py
index c25164ea..0b05ec73 100644
--- a/ohmpi/ohmpi.py
+++ b/ohmpi/ohmpi.py
@@ -857,14 +857,14 @@ class OhmPi(object):
                 'rsdata': {
                     'A': int(quad[0]),
                     'B': int(quad[1]),
-                    'rs': rab,  # in kOhm
+                    'rs': np.round(rab,2),  # in kOhm
                 }
             }
             self.data_logger.info(json.dumps(msg))
 
             # if contact resistance = 0 -> we have a short circuit!!
             if rab < 1e-5:
-                msg = f'!!!SHORT CIRCUIT!!! {str(quad):s}: {rab:.3f} kOhm'
+                msg = f'!!!SHORT CIRCUIT!!! {str(quad):s}: {rab:.2f} kOhm'
                 self.exec_logger.warning(msg)
 
             # save data in a text file
-- 
GitLab