Compare commits

...
1 Commits
Author SHA1 Message Date
Patrick762 9ef9d38a6e renamed ep700 to ep760 2024-02-04 12:05:53 +01:00
5 changed files with 12 additions and 12 deletions

No files matched your search

+1 -1
View File
@@ -27,7 +27,7 @@ After the installation, you can use this button to install the integration:
- EP500
- EP500P
- EP600 (tested)
- EP700 (beta, untested)
- EP760 (beta, untested)
### Available sensors:
All sensors which are available in bluetti_mqtt (Based on [this file](https://github.com/warhammerkid/bluetti_mqtt/blob/main/bluetti_mqtt/mqtt_client.py)).
+5 -5
View File
@@ -28,7 +28,7 @@ from .const import (
)
from .coordinator import PollingCoordinator
from .devices.ep600 import EP600
from .devices.ep700 import EP700
from .devices.ep760 import EP760
PLATFORMS: [Platform] = [Platform.BINARY_SENSOR, Platform.SENSOR]
_LOGGER = logging.getLogger(__name__)
@@ -107,14 +107,14 @@ def get_type_by_bt_name(bt_name: str):
dev_type = "EP500"
elif bt_name.startswith("EP600"):
dev_type = "EP600"
elif bt_name.startswith("EP700"):
dev_type = "EP700"
elif bt_name.startswith("EP760"):
dev_type = "EP760"
return dev_type
def build_device(address: str, name: str):
match = DEVICE_NAME_RE.match(name)
if match[1] == 'EP700':
return EP700(address, match[2])
if match[1] == 'EP760':
return EP760(address, match[2])
elif match[1] == 'EP600':
return EP600(address, match[2])
else:
+1 -1
View File
@@ -17,7 +17,7 @@ CONF_MAX_RETRIES = "max_retries"
DATA_COORDINATOR = "coordinator"
DATA_POLLING_RUNNING = "polling_running"
DEVICE_NAME_RE = re.compile(r'^(AC200M|AC300|AC500|AC60|EP500P|EP500|EP600|EP700|EB3A)(\d+)$')
DEVICE_NAME_RE = re.compile(r'^(AC200M|AC300|AC500|AC60|EP500P|EP500|EP600|EP760|EB3A)(\d+)$')
CONTROL_FIELDS = [
"ac_output_on",
@@ -1,4 +1,4 @@
"""EP700 Field definitions.
"""EP760 Field definitions.
Changes made here are only temporary and should also be
contributed to https://github.com/warhammerkid/bluetti_mqtt
@@ -10,7 +10,7 @@ from bluetti_mqtt.core.devices.bluetti_device import BluettiDevice
from bluetti_mqtt.core.devices.struct import DeviceStruct
from bluetti_mqtt.core.commands import ReadHoldingRegisters
class EP700(BluettiDevice):
class EP760(BluettiDevice):
def __init__(self, address: str, sn: str):
self.struct = DeviceStruct()
@@ -36,7 +36,7 @@ class EP700(BluettiDevice):
self.struct.add_version_field('safety_module_version', 6181)
self.struct.add_version_field('high_voltage_module_version', 6184)
super().__init__(address, 'EP700', sn)
super().__init__(address, 'EP760', sn)
@property
def polling_commands(self) -> List[ReadHoldingRegisters]:
+2 -2
View File
@@ -9,7 +9,7 @@
{ "local_name": "EB3A*" },
{ "local_name": "EP500*" },
{ "local_name": "EP600*" },
{ "local_name": "EP700*" }
{ "local_name": "EP760*" }
],
"codeowners": ["@Patrick762"],
"config_flow": true,
@@ -19,5 +19,5 @@
"iot_class": "local_polling",
"issue_tracker": "https://github.com/Patrick762/hassio-bluetti-bt/issues",
"requirements": ["bluetti_mqtt==0.15.0"],
"version": "0.0.12"
"version": "0.0.13"
}