fix(io): Do not read/wirte process image while device is in self-update
Signed-off-by: Sven Sager <s.sager@kunbus.com>
This commit is contained in:
@@ -110,6 +110,9 @@ class InterfaceInput:
|
||||
|
||||
@property
|
||||
def value(self) -> Variant:
|
||||
if not self.io._parentdevice._selfupdate:
|
||||
self.io._parentdevice.readprocimg()
|
||||
|
||||
return Variant(
|
||||
self.variant_type,
|
||||
self.io.get_value() if self._raw else self.io.value,
|
||||
@@ -145,7 +148,8 @@ class InterfaceOutput(InterfaceInput):
|
||||
self.io.set_value(value)
|
||||
else:
|
||||
self.io.value = value
|
||||
self.io._parentdevice._modio.writeprocimg()
|
||||
if not self.io._parentdevice._selfupdate:
|
||||
self.io._parentdevice.writeprocimg()
|
||||
|
||||
|
||||
class InterfaceIoManager:
|
||||
|
||||
Reference in New Issue
Block a user