Commit graph

40 commits

Author SHA1 Message Date
Christopher Fenner
ec647677e9
Update initial translation for ViCare water heater entity (#104696) 2023-11-30 01:38:33 +01:00
Christopher Fenner
c4e3ae84f4
Optimize async executor use in ViCare integration (#104645)
* use one async executor

* use list comprehension

* simplify

* simplify

* simplify

* simplify

* simplify

* simplify

* simplify

* simplify

* add type

* Apply suggestions from code review

* fix ruff findings
2023-11-29 09:28:56 +01:00
Christopher Fenner
ad17acc6ca
Fix async issue in ViCare integration (#104541)
* use async executor for get_circuits

* use async executor for get_burners and get_compressors
2023-11-26 15:28:58 +01:00
Christopher Fenner
48f8cec84b
Add reuse functions to access circuits, burners and compressors in ViCare integration (#104371) 2023-11-25 15:47:45 +01:00
Christopher Fenner
17cef8940f
Add translation keys to ViCare integration (#104425)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2023-11-25 13:11:29 +01:00
Christopher Fenner
5805601a83
Set unique_id by base entity in ViCare integration (#104277)
* set unique_id in ViCareEntity

* remove individual unique_id functions

* remove description

* remove individual _attr_unique_id

* fix return types
2023-11-21 09:53:02 +01:00
Christopher Fenner
ae7bb60677
Fix types in ViCare integration (#101926)
* fix type

* fix return type

* fix type

* fix type

* Apply suggestions from code review

* Update climate.py

* Apply suggestions from code review

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update __init__.py

* Update climate.py

* Update __init__.py

* Apply suggestions from code review

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

* Update binary_sensor.py

* Update button.py

* Update sensor.py

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2023-10-13 23:13:39 +02:00
Christopher Fenner
6d2fbeb556
Migrate ViCare to has_entity_name (#101895)
* set has_entity_name

* remove sensor prefix

* Apply suggestions from code review

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>

---------

Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
2023-10-12 21:06:09 +02:00
Christopher Fenner
5c52a15df7
Fix type issue in vicare integration (#101872)
* fix type issue

* fix type issue

* fix type issue

* extract from constructor

* Revert "extract from constructor"

This reverts commit a33de7ca8e.
2023-10-12 15:01:23 +02:00
Christopher Fenner
6e1c23906c
Add base entity class in vicare integration (#101870)
* add entity base class

* depend on base class

* add device info to base class

* remove individual DeviceInfo

* move class

* fix imports

* add file comment

* use super()

* fix formatting

* add vicare/entity.py
2023-10-12 14:54:16 +02:00
Joost Lekkerkerker
eeaca8ae3c
Use shorthand attributes in Vicare (#99915) 2023-09-09 23:18:41 +02:00
Erik Montnemery
045c327928
Move DeviceInfo from entity to device registry (#98149)
* Move DeviceInfo from entity to device registry

* Update integrations
2023-08-10 22:04:26 -04:00
Hans Oischinger
c354868270
water_heater: Add unsupported states (#84720) 2022-12-28 21:45:24 +01:00
epenet
63e8dd58ef
Use UnitOfTemperature in water_heater entities (#83132) 2022-12-05 11:42:15 +01:00
epenet
050cb275ff
Improve entity type hints [v] (#77885) 2022-09-06 13:59:05 +02:00
epenet
e19e65908a
Use _attr_precision in entities (#77477) 2022-08-29 22:02:29 +02:00
epenet
b9c135870a
Fix model in vicare device_info (#74135) 2022-06-28 17:54:07 +02:00
epenet
f194f7809b
Use EntityFeature enum in components (v**) (#69465)
* Use EntityFeature enum in vallox

* Use EntityFeature enum in velbus

* Use EntityFeature enum in velux

* Use EntityFeature enum in venstar

* Use EntityFeature enum in vera

* Use EntityFeature enum in verisure

* Use EntityFeature enum in vesync

* Use EntityFeature enum in vicare

* Use EntityFeature enum in vivotek

* Use EntityFeature enum in vizio

* Use EntityFeature enum in vlc

* Use EntityFeature enum in vlc_telnet

* Use EntityFeature enum in volumio
2022-04-07 08:42:18 +02:00
Hans Oischinger
2c8bf006eb
Fix precision of vicare target & current temperature (#66456) 2022-03-16 13:14:11 +01:00
Hans Oischinger
94a0f1c7b3
Add service configuration URL for vicare (#66927) 2022-02-20 11:47:05 +01:00
Hans Oischinger
99fd16d675
Clean up vicare code (#65774)
* Clean up vicare code

Remove constants that were only used once
Remove _build_entity and use constructor directly

* Fix copy/paste issue
2022-02-05 14:26:44 +01:00
Hans Oischinger
a9cc35d6b6
Handle vicare I/O in executor (#65105)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-01-28 12:06:05 +01:00
Hans Oischinger
8d6880ab85
Support systems w/o circuits (#64779) 2022-01-24 11:18:54 +01:00
Hans Oischinger
2969a7ab4f
Address late review of vicare config flow (#63343)
* Review comments from #56691

* Adapt to review suggestions

* Update homeassistant/components/vicare/strings.json

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-01-05 22:49:42 +01:00
epenet
3fe527422d
Add setup type hints to select, vacuum and water_heater (#63300)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-01-03 16:26:14 +01:00
Hans Oischinger
38b976e6d6
Add vicare config flow (#56691)
* Configuration via UI

Config flow / YAML deprecation
- Support discovery via MAC address
- Support import of YAML config
- Switch to ConfigEntry, get rid of platform setup

* Fix review comments

* More tests for vicare yaml import
2021-11-22 15:06:42 +01:00
Hans Oischinger
8e8ccb7ce4
Fix Vicare unique_ids (#58531) 2021-10-27 14:19:26 +02:00
Hans Oischinger
66ae116023
Update PyVicare to 2.13.0 (#57700)
* Update PyVicare to 2.x

With PyViCare 2.8.1 a breaking change was introduced which required changes on sensor and binary_sensor platforms:
- Circuit, Burner and Compressor have been separated out from the "main" device
- Multiple circuits and burners allow "duplicate sensors". We add the circuit or burner number as suffix now

At the same time the sensors are now created only when available:
During entity creation we can check if the value is provided for the user's device.

Sensors are not created by heating type anymore but instead the new API structure is reflected, providing device, burner or circuit sensors.

For details of breaking changes from PyViCare 1.x to 2.x please see https://github.com/somm15/PyViCare#breaking-changes-in-version-2x

* Integrate review comments

* variables cleanup

* Update unique ids

The unique ids shall not depend on the name but on the entity
description key (which should not change) and the id of the circuit,
burner or device.
2021-10-25 13:43:43 +02:00
Marc Mueller
ff853b2d53
Use assignment expressions 19 (#57968) 2021-10-18 15:54:38 +02:00
Hans Oischinger
84dc6af760
Update to PyVicare 1.0 (#53281) 2021-07-22 21:56:38 +02:00
Martin
0bbb56dd05
Add sensor platform for vicare integration (heatpump) (#34385)
* Add sensor platform for vicare (heatpump)

* Formatting and fixes

* Formatting and fixes 2

* Fixes and formatting 3

* Fixes and formatting 4

* Add binary_sensor and more sensors

This moves some more climate attributes to sensors and adds
binary_sensors

* Move ActiveError back to climate component

The data returned by ActiveError is more complex.
It takes further investigation on how to interpret it a s a binary sensor.
Therefore it is moved back as an attribute of the climate component

* Update PyViCare library

* PR changes

* PR changes 2

Co-authored-by: Hans Oischinger <hans.oischinger@gmail.com>
2020-06-13 21:53:42 +02:00
Erik Montnemery
f3d79104a7
Rename WaterHeaterDevice to WaterHeaterEntity (#34675)
* Rename WaterHeaterDevice to WaterHeaterEntity

* Fix stale name

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-05-01 16:29:14 +02:00
Hans Oischinger
4a2236fe85
:vicare: Improve scan_interval (#33294)
This upgrades to PyVicare 0.1.10 which allows to combine multiple
requests into a single HTTP GET. This in turn allows us to increase
the scan_interval to 60 seconds by default.
Additionally scan_interval has been introduced as a config parameter.
2020-03-28 12:12:27 +01:00
Hans Oischinger
cd79720a14
Introduce safe scan_interval for vicare (#32915) 2020-03-17 13:19:57 -07:00
Hans Oischinger
7e0560c7dc
Vicare water_heater set_temperature fix and bump PyVicare to 0.1.7 (#31672)
* Fix ViCare water_heater set_temperature

This fixes a obvious but undiscovered bug in the water heater component:
Instead of the commanded value the prvious value was set on the API

* Bump PyVicare to 0.1.7
2020-02-10 21:23:02 +01:00
Bas Nijholt
f281069c8c Sort imports according to PEP8 for vicare (#29754) 2019-12-09 13:13:33 +01:00
rappenze
1c73ac5df8 Fix Vicare imports (#29071)
* fix import

* Update water_heater.py

* use ValueError

* use ValueError
2019-11-26 10:46:53 -08:00
Hans Oischinger
3d2ff841d3 Handle exceptions from PyViCare library (#28536)
* ViCare: Handle exceptions from PyViCare library (#28072)

Sometimes Viessmann server failures or other connection problems may
lead to exceptions thrown when updating data.

This commit handles those exceptions with some error logging and
makes sure that the component does not break completely in that case.

* Remove unneeded returns

* Remove unneeded returns
2019-11-06 22:46:18 +01:00
Martin
06c26f3ffc Add heating_type for ViCare integration (#27296)
* Add heating_type for ViCare

* Add additional gas heating properties

* Update requirements_all

* Add hvac action

* Remove measurements

* Remove unused property
2019-11-04 20:12:43 +01:00
Hans Oischinger
a72d9da9f4 Add Viessmann ViCare Climate platform (#26151)
* Add Viessmann ViCare Climate platform

* Add water_heater and fix review comments
Update to latest PyVicare (0.1.0)

* Move PyVicare API creation to component

* More review fixes

* Return false if api creation fails

* Fix logging format

* Update PyVicare 0.1.1 to fix json issues

* Formatting fixes
2019-09-06 22:09:03 +02:00