diff --git a/changes.md b/changes.md index 816cad4..938af52 100644 --- a/changes.md +++ b/changes.md @@ -1,5 +1,10 @@ # Change Log +## v0.1.29 Added FGD14 and FD2G14 Support +* Added FGD14 and FD2G14 Support +* Fixed missing dependency for FSR14M-2x support. +* Fixed configuration generation and sender id validation. + ## v0.1.28 added EEP F6-01-01 ## v0.1.27 Added Support for FSR14M-2x diff --git a/eo_man/data/data_helper.py b/eo_man/data/data_helper.py index 6aeba64..1d52be8 100644 --- a/eo_man/data/data_helper.py +++ b/eo_man/data/data_helper.py @@ -33,7 +33,8 @@ {'hw-type': 'FUD14', CONF_EEP: 'A5-38-08', 'sender_eep': 'A5-38-08', CONF_TYPE: Platform.LIGHT, 'PCT14-function-group': 3, 'PCT14-key-function': 32, 'description': 'Central command - gateway', 'address_count': 1}, {'hw-type': 'FUD14_800W', CONF_EEP: 'A5-38-08', 'sender_eep': 'A5-38-08', CONF_TYPE: Platform.LIGHT, 'PCT14-function-group': 3, 'PCT14-key-function': 32, 'description': 'Central command - gateway', 'address_count': 1}, - {'hw-type': 'FDG14', CONF_EEP: 'A5-38-08', CONF_TYPE: Platform.LIGHT, 'PCT14-function-group': 1, 'PCT14-key-function': 32, 'description': 'Central command - gateway', 'address_count': 16}, + {'hw-type': 'FDG14', CONF_EEP: 'A5-38-08', 'sender_eep': 'A5-38-08', CONF_TYPE: Platform.LIGHT, 'PCT14-function-group': 1, 'PCT14-key-function': 32, 'description': 'Central command - gateway', 'address_count': 16}, + {'hw-type': 'FD2G14', CONF_EEP: 'A5-38-08', 'sender_eep': 'A5-38-08', CONF_TYPE: Platform.LIGHT, 'PCT14-function-group': 1, 'PCT14-key-function': 32, 'description': 'Central command - gateway', 'address_count': 16}, {'hw-type': 'FMZ14', CONF_EEP: 'M5-38-08', 'sender_eep': 'A5-38-08', CONF_TYPE: Platform.LIGHT, 'PCT14-function-group': 1, 'description': 'Eltako relay', 'address_count': 1}, {'hw-type': 'FSR14', CONF_EEP: 'M5-38-08', 'sender_eep': 'A5-38-08', CONF_TYPE: Platform.LIGHT, 'PCT14-function-group': 2, 'PCT14-key-function': 51, 'description': 'Eltako relay', 'address_count': 1}, diff --git a/eo_man/data/ha_config_generator.py b/eo_man/data/ha_config_generator.py index ff571c7..622f124 100644 --- a/eo_man/data/ha_config_generator.py +++ b/eo_man/data/ha_config_generator.py @@ -41,7 +41,7 @@ def get_gateway_by(self, gw_d:Device) -> GatewayDeviceType: return None def perform_tests(self): - device_list = self.data_manager.devices.values() + device_list = [d for d in self.data_manager.devices.values() if d.use_in_ha] self.test_unique_sender_ids(device_list) @@ -50,10 +50,10 @@ def test_unique_sender_ids(self, device_list:list[Device]): for d in device_list: if 'sender' in d.additional_fields and 'id' in d.additional_fields['sender']: sender_id = d.additional_fields['sender']['id'] - if not sender_id.isnumeric() or int(sender_id) < 1 or int(sender_id) > 127: + if int(sender_id, 16) < 1 or int(sender_id, 16) > 127: raise Exception(f"sender id '{sender_id}' of device '{d.external_id}' is no valid number between 1 and 127.") if sender_id in sender_ids: - raise Exception(f"sender id '{sender_id}' is assinged more than once for at least device '{sender_ids[sender_id].external_id}' and '{d.external_id}'.") + raise Exception(f"sender id '{sender_id}' is assigned more than once for at least device '{sender_ids[sender_id].external_id}' and '{d.external_id}'.") sender_ids[sender_id] = d diff --git a/requirements.txt b/requirements.txt index f823163..e2cb27c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,5 @@ aiocoap==0.4.7 -eltako14bus==0.0.61 +eltako14bus==0.0.62 numpy==1.26.3 pillow==10.2.0 pyserial==3.5 diff --git a/setup.py b/setup.py index 29c9ed0..2e83234 100644 --- a/setup.py +++ b/setup.py @@ -14,7 +14,7 @@ with open('LICENSE', encoding="utf-8") as f: license = f.read() -required = ['eltako14bus==0.0.61', 'requests==2.31.0', 'enocean==0.60.1', 'pyserial', 'pyserial-asyncio', 'aiocoap', +required = ['eltako14bus==0.0.62', 'requests==2.31.0', 'enocean==0.60.1', 'pyserial', 'pyserial-asyncio', 'aiocoap', 'esp2_gateway_adapter==0.2.9', # 'homeassistant', 'zeroconf==0.132.2', @@ -27,7 +27,7 @@ setup( name='eo_man', - version='0.1.28', + version='0.1.29', package_dir={'eo_man':"eo_man"}, # packages=find_packages("./eo-man"), #package_data={'': ['*.png']},