From 8382975acde652b5b77586dbe51bb2dbea68c19d Mon Sep 17 00:00:00 2001 From: su530201 <olivier.kaufmann@umons.ac.be> Date: Tue, 28 Nov 2023 16:58:30 +0100 Subject: [PATCH] Tries to fix adafruit warning --- ohmpi/hardware_components/raspberry_pi.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ohmpi/hardware_components/raspberry_pi.py b/ohmpi/hardware_components/raspberry_pi.py index e9435929..8b345b5a 100644 --- a/ohmpi/hardware_components/raspberry_pi.py +++ b/ohmpi/hardware_components/raspberry_pi.py @@ -44,12 +44,12 @@ class Ctl(CtlAbstract): except RuntimeWarning: pass + warnings.resetwarnings() # Extended I2C try: self.interfaces['i2c_ext'] = ExtendedI2C(4) # 4 is defined - warnings.resetwarnings() - except RuntimeWarning: - pass + # except RuntimeWarning: + # pass except Exception as e: self.exec_logger.warning(f'Could not initialize Extended I2C:\n{e}') -- GitLab