Skip to content

Commit 15f859c

Browse files
authored
Add support for VMB8PB (#64)
* Add support for VMB8PB * Black code formatting
1 parent ebfc853 commit 15f859c

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

velbus/modules/vmbpbn.py

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,21 @@ def number_of_channels(self):
169169
return 8
170170

171171

172+
class VMB8PBModule(VMB2PBNModule):
173+
"""
174+
Velbus input module with 8 channels
175+
"""
176+
177+
def __init__(self, module_type, module_name, module_address, controller):
178+
super().__init__(module_type, module_name, module_address, controller)
179+
for channel in list(range(1, self.number_of_channels() + 1)):
180+
self._is_enabled[channel] = True
181+
182+
def number_of_channels(self):
183+
return 8
184+
185+
172186
register_module("VMB2PBN", VMB2PBNModule)
173187
register_module("VMB6PBN", VMB6PBNModule)
174188
register_module("VMB8PBU", VMB8PBUModule)
189+
register_module("VMB8PB", VMB8PBModule)

0 commit comments

Comments
 (0)