Skip to content
Snippets Groups Projects
Commit 857e7ce9 authored by Martin Teichmann's avatar Martin Teichmann
Browse files

support inherited channels for terminals

parent 121c1a13
Branches master
No related tags found
No related merge requests found
Pipeline #142974 failed
...@@ -684,11 +684,12 @@ class Terminal: ...@@ -684,11 +684,12 @@ class Terminal:
elif isinstance(v, StructDesc): elif isinstance(v, StructDesc):
struct = getattr(self, k) struct = getattr(self, k)
offset = struct.position_offset[None] offset = struct.position_offset[None]
for kk, vv in struct.__class__.__dict__.items(): for ccls in struct.__class__.__mro__:
if isinstance(vv, ServiceDesc): for kk, vv in ccls.__dict__.items():
setattr(struct, kk, if isinstance(vv, ServiceDesc):
await self.read_object_entry( setattr(struct, kk,
vv.index + offset, vv.subidx)) await self.read_object_entry(
vv.index + offset, vv.subidx))
async def set_state(self, state): async def set_state(self, state):
"""try to set the state, and return the new state""" """try to set the state, and return the new state"""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment