Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kaifa crashing on entity generation unique_id #12

Closed
TheDiverM opened this issue Mar 21, 2020 · 8 comments · Fixed by #15
Closed

Kaifa crashing on entity generation unique_id #12

TheDiverM opened this issue Mar 21, 2020 · 8 comments · Fixed by #15

Comments

@TheDiverM
Copy link

Hi
I have just installed your nice little software, but on my kaifa 3 phase meter it say 0 volts on ams_voltage_l2, is this something in you module or is it something wrong in my meter?

im using this mbus module:
https://www.aliexpress.com/item/32719562958.html?spm=a2g0s.9042311.0.0.c8314c4dpbv1pv

@turbokongen
Copy link
Owner

Thanks for using my software.
Your issue is not a problem. It's how the meter is programmed. I do not know the reasons to why it is so.
It's noted here in this document on page 3: https://www.nek.no/wp-content/uploads/2018/11/Kaifa-KFM_001.pdf

@turbokongen turbokongen added the wontfix This will not be worked on label Mar 22, 2020
@TheDiverM
Copy link
Author

another issue, migth be that I use a pi3, but the software runs for about 1 hour, then stops, while measurement comes in it is a load of 1.4 to 1.9, when it stops measure, load drops to 0.1

is the pi 3 just to small or is there something else.

the pi that has the mbus adapter only runs the norwegian han sensor, nothing else.
last log entry

from log on rpi:

2020-03-21 15:21:26 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for ams which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant.
2020-03-21 15:22:01 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 425, in _async_add_entity
raise HomeAssistantError(msg)
homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.ams_active_power_import_none. Platform ams does not generate unique IDs
2020-03-21 15:43:30 WARNING (MainThread) [asyncio] socket.send() raised exception.
2020-03-21 15:43:31 WARNING (MainThread) [asyncio] socket.send() raised exception.
2020-03-21 15:43:31 WARNING (MainThread) [asyncio] socket.send() raised exception.
2020-03-21 15:43:31 WARNING (MainThread) [asyncio] socket.send() raised exception.
2020-03-21 15:43:31 WARNING (MainThread) [asyncio] socket.send() raised exception.
2020-03-21 15:43:31 WARNING (MainThread) [asyncio] socket.send() raised exception.`

@turbokongen
Copy link
Owner

The unique_id error is known, but it will not stop homeassistant from working.
The socket.send() error might though.
I have the software running on a pi3 as well, without problems. (I also get the entity id error on the hourly package)

@TheDiverM
Copy link
Author

for me this halts the entire homeassistant collection of data from the meter, only way to get it running again is to restart the PI.

im open to suggestions for how to fix this issue

@TheDiverM
Copy link
Author

TheDiverM commented Mar 22, 2020

I found this line:

homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.ams_active_power_import_none. Platform ams does not generate unique IDs

seems like system try to create the ID:
sensor.ams_active_power_import_none
but it already exists

another question, do you use 32bit or 64 bit version?

@turbokongen
Copy link
Owner

I am running:
/bin/bash: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, for GNU/Linux 3.2.0, BuildID[sha1]=3e5e2847bbc51da2ab313bc53d4bdcff0faf2462, stripped
Please try the unique_id branch and see if that will fix it for you.

@turbokongen
Copy link
Owner

Make sure you use the latest code. Just published another fix for this.
https://github.com/turbokongen/hass-AMS/tree/unique_id

@turbokongen turbokongen removed the wontfix This will not be worked on label Mar 22, 2020
@turbokongen turbokongen changed the title little question about the kaifa meter Kaifa crashing on entity generation unique_id Mar 22, 2020
@TheDiverM
Copy link
Author

TheDiverM commented Mar 22, 2020

now Im running on 32 bit hassio for rpi3 (was running on 64 bit when errors occured)
and now it seems like all runs fine, and no errors in the logs.
so maybe put something in readme about error in 64bit version..., ill give another feedback tomorrow if test runs fine all nigth

edit: still running stable, so I guess, 32 bit was the trick

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants