Skip to content

Commit

Permalink
Connection only opened once
Browse files Browse the repository at this point in the history
  • Loading branch information
OStrama authored Oct 26, 2024
1 parent 005f869 commit d03bb77
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion custom_components/weishaupt_modbus/modbusobject.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ async def connect(self):
return self._modbus_client.connected
else:
await asyncio.sleep(1)
# warnings.warn("Connection to heatpump succeeded")
warnings.warn("Connection to heatpump succeeded")

except ModbusException:
warnings.warn("Connection to heatpump failed")
Expand All @@ -69,6 +69,7 @@ def close(self):
except ModbusException:
warnings.warn("Closing connection to heatpump failed")
return False
warnings.warn("Connection to heatpump closed")
return True

def get_device(self):
Expand Down

0 comments on commit d03bb77

Please sign in to comment.