Skip to content

Commit

Permalink
fix heatpump not updating
Browse files Browse the repository at this point in the history
  • Loading branch information
laverman committed Apr 14, 2023
1 parent fe526a6 commit b9c4cde
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 10 deletions.
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "pysolarfocus"
version = "3.6.2"
version = "3.6.3"
description = "Unofficial, local Solarfocus client"
authors = ["Jeroen Laverman <[email protected]>"]
license = "Apache-2.0"
Expand All @@ -13,7 +13,7 @@ readme = "README.md"

[tool.poetry.dependencies]
python = "^3.9"
pymodbus = "2.5.3"
pymodbus = "3.2.2"

[tool.poetry.dev-dependencies]
pytest = "^5.2"
Expand Down
12 changes: 4 additions & 8 deletions pysolarfocus/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""Python client lib for Solarfocus"""
__version__ = "3.6.2"
__version__ = "3.6.3"

from enum import Enum
from packaging import version
Expand Down Expand Up @@ -89,7 +89,7 @@ def is_connected(self)->bool:
"""Check if connection is established"""
return self.__conn.is_connected

def update(self):
def update(self) -> bool:
"""Read values from Heating System"""
if (
self.update_heating()
Expand Down Expand Up @@ -135,19 +135,15 @@ def update_fresh_water_modules(self) -> bool:

def update_heatpump(self) -> bool:
"""Read values from Heating System"""
if self._system is Systems.Vampair:
return self.heatpump.update()
return True
return self.heatpump.update()

def update_photovoltaic(self) -> bool:
"""Read values from Heating System"""
return self.photovoltaic.update()

def update_pelletsboiler(self) -> bool:
"""Read values from Pellets boiler"""
if self._system is Systems.Therminator:
return self.pelletsboiler.update()
return True
return self.pelletsboiler.update()

def update_solar(self) -> bool:
"""Read values from Solar"""
Expand Down

0 comments on commit b9c4cde

Please sign in to comment.