Giter VIP home page Giter VIP logo

hass-amphiro-ble's Introduction

hass-amphiro-ble's People

Contributors

bipsendk avatar chkuendig avatar ctso avatar eifinger avatar eseglem avatar github-actions[bot] avatar iantrich avatar jcgoette avatar ludeeus avatar matthewflamm avatar mattrayner avatar mjmeli avatar oncleben31 avatar raman325 avatar rianoc avatar rodpayne avatar rroller avatar salem84 avatar swartjean avatar tefinger avatar tetienne avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

hass-amphiro-ble's Issues

Deprecated constants which will be removed in HA Core 2025.1

HA logs have the following mention that some of the constants used will be deprecated in a year. Thanks already beforehand if you have the time to fix this in the near future @chkuendig!

Logger: homeassistant.const
Source: helpers/deprecation.py:205
First occurred: 18:46:47 (8 occurrences)
Last logged: 18:46:51

TEMP_CELSIUS was used from amphiro_ble, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTemperature.CELSIUS instead, please report it to the author of the 'amphiro_ble' custom integration
TIME_SECONDS was used from amphiro_ble, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfTime.SECONDS instead, please report it to the author of the 'amphiro_ble' custom integration

Unclear how to add/configure integration

Hey there!

From the Readme it is unfortunately not clear to me how to install this integration. I have added the page as custom repository to HACS and installed the integration. When I attempt to add the integration afterwards, I only get the following screen:

Bildschirmfoto vom 2023-06-03 22-10-10

I am using HA 2023.5.4. Bluetooth is enabled via an ESPHome bluetooth proxy, which works quite well with the Xiaomi BLE integration.

What am I missing? Does the integration still work with the latest version of Home Assistant?

Setting up / error

So I copied the custom_components folder to my installation custom_components folder and restarted Home Assistant. Did Add integration and chose amphiro BLE. Nothing appears on the setup dialog and in log I found:

2023-02-16 15:15:25.114 ERROR (MainThread) [custom_components.amphiro_ble.models] Amphiro data format not supported: b'\x00\x06\xf5\x00\x00\x00\x00\x00\x00\x00F\x18\x00\x00\x16O\x00\x00\x00'

The shower head is an Oras branded Amphiro.

[Issue] The integration only receives data the first 2 seconds

Hi @chkuendig and thank you for this integration.
I have the Hansa version of the Amphiro DHS.
The device is properly detected but it is receiving data only for the first 2 seconds after opening the tap. If I close the tap after another let's say 10 seconds and open the tap again, the values get updated with the missing quantities, and get updated for another 2 seconds and stop updating again.
Any idea what could be the reason?

I don't see any errors in the HA logs.

Thanks in advance for your help.

Sensors become Unavailable after 15 minutes

Hi @chkuendig,

The sensors become Unavailable after 15 minutes of not receiving data from the shower head. HA shows a notification that the integration amphiro_ble doesn't provide these entities anymore.
Is this expected behaviour? Is there any way to have the sensors keep their values?
Thanks in advance.

image

Errors in log using HA 2024.6.0b2

With the new beta release, exceptions appear in the log/. Seems like ble apis changed:

Logger: homeassistant.config_entries
Bron: config_entries.py:594
Eerst voorgekomen: 18:45:45 (1 gebeurtenissen)
Laatst gelogd: 18:45:45

Error setting up entry Douche for amphiro_ble
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/loader.py", line 1249, in _load_platform
cache[full_name] = self._import_platform(platform_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/loader.py", line 1281, in _import_platform
return importlib.import_module(f"{self.pkg_path}.{platform_name}")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/util/loop.py", line 128, in protected_loop_func
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/importlib/init.py", line 90, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1387, in _gcd_import
File "", line 1360, in _find_and_load
File "", line 1331, in _find_and_load_unlocked
File "", line 935, in _load_unlocked
File "", line 995, in exec_module
File "", line 488, in _call_with_frames_removed
File "/config/custom_components/amphiro_ble/sensor.py", line 132, in
PassiveBluetoothDataProcessor[Optional[Union[float, int]]]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/typing.py", line 384, in inner
return func(*args, **kwds)
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/typing.py", line 1066, in _generic_class_getitem
_check_generic(cls, params, len(cls.parameters))
File "/usr/local/lib/python3.12/site-packages/typing_extensions.py", line 2941, in _check_generic
raise TypeError(f"Too {'many' if alen > elen else 'few'} arguments"
TypeError: Too few arguments for <class 'homeassistant.components.bluetooth.passive_update_processor.PassiveBluetoothDataProcessor'>; actual 1, expected at least 2

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 594, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/amphiro_ble/init.py", line 37, in async_setup_entry
await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 2031, in async_forward_entry_setups
await integration.async_get_platforms(platforms)
File "/usr/src/homeassistant/homeassistant/loader.py", line 1162, in async_get_platforms
import_future.result()
File "/usr/src/homeassistant/homeassistant/loader.py", line 1150, in async_get_platforms
platforms.update(self._load_platforms(platform_names))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/loader.py", line 1075, in _load_platforms
platform_name: self._load_platform(platform_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/loader.py", line 1269, in _load_platform
raise ImportError(
ImportError: Exception importing custom_components.amphiro_ble.sensor

And:

Logger: homeassistant.loader
Bron: loader.py:1249
Eerst voorgekomen: 18:45:42 (2 gebeurtenissen)
Laatst gelogd: 18:45:45

Unexpected exception importing platform custom_components.amphiro_ble.sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/loader.py", line 1249, in _load_platform
cache[full_name] = self._import_platform(platform_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/loader.py", line 1281, in _import_platform
return importlib.import_module(f"{self.pkg_path}.{platform_name}")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/util/loop.py", line 128, in protected_loop_func
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/importlib/init.py", line 90, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1387, in _gcd_import
File "", line 1360, in _find_and_load
File "", line 1331, in _find_and_load_unlocked
File "", line 935, in _load_unlocked
File "", line 995, in exec_module
File "", line 488, in _call_with_frames_removed
File "/config/custom_components/amphiro_ble/sensor.py", line 132, in
PassiveBluetoothDataProcessor[Optional[Union[float, int]]]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/typing.py", line 384, in inner
return func(*args, **kwds)
^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/typing.py", line 1066, in _generic_class_getitem
_check_generic(cls, params, len(cls.parameters))
File "/usr/local/lib/python3.12/site-packages/typing_extensions.py", line 2941, in _check_generic
raise TypeError(f"Too {'many' if alen > elen else 'few'} arguments"
TypeError: Too few arguments for <class 'homeassistant.components.bluetooth.passive_update_processor.PassiveBluetoothDataProcessor'>; actual 1, expected at least 2

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.