From 0ba8772d1b56a8da994c5e1ae2dc1b99f094d973 Mon Sep 17 00:00:00 2001 From: Sven Sager Date: Wed, 18 Sep 2024 10:55:31 +0200 Subject: [PATCH] fix: Raise error on connect 4 when using wd_toggle function On the Connect 4, the hardware watchdog was removed from the process image by KUNBUS. To use the hardware watchdog, other functions must now be used that are not implemented by RevPiModIO. --- src/revpimodio2/device.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/revpimodio2/device.py b/src/revpimodio2/device.py index 8798752..b2f92d4 100644 --- a/src/revpimodio2/device.py +++ b/src/revpimodio2/device.py @@ -1423,6 +1423,13 @@ class Connect4(ModularBase): else: raise ValueError("led status must be between 0 and 7") + def wd_toggle(self): + """Toggle watchdog bit to prevent a timeout.""" + raise NotImplementedError( + "On the Connect 4, the hardware watchdog was removed from the process image by " + "KUNBUS. This function is no longer available on Connect 4 devices." + ) + A1 = property(_get_leda1, _set_leda1) A2 = property(_get_leda2, _set_leda2) A3 = property(_get_leda3, _set_leda3)