icanos / hassio-plejd

Hass.io add-on for Plejd home automation devices
Apache License 2.0
126 stars 37 forks source link

Anyone care to update this addon? #307

Open MHultman opened 1 month ago

MHultman commented 1 month ago

Hi,

Doesn't seem that we got the attention to get a new release of the addon over the last couple of months. What is going on?

I would love to see PR#297 in 0.12.0.

SweVictor commented 1 month ago

Hi, I'm interested in that as well (as the author). Have you tested the PR?

As I write in the PR I'd like more people testing it before merging.

An in general it's an open source initiative, so please contribute!

/Victor

tomoqv commented 1 month ago

How do I try this out? I have massive problems getting plejd to work on my Intel NUC with built-in BT.

 Add-on version: 0.11.0
 You are running the latest version of this add-on.
parse error: Expected string key before ':' at line 1, column 4
[18:03:03] ERROR: Unknown HTTP error occured
 System:   (amd64 / generic-x86-64)
 Home Assistant Core: 2024.8.1
 Home Assistant Supervisor: 2024.08.0
SweVictor commented 1 month ago

How do I try this out? I have massive problems getting plejd to work on my Intel NUC with built-in BT.

 Add-on version: 0.11.0
 You are running the latest version of this add-on.
parse error: Expected string key before ':' at line 1, column 4
[18:03:03] ERROR: Unknown HTTP error occured
 System:   (amd64 / generic-x86-64)
 Home Assistant Core: 2024.8.1
 Home Assistant Supervisor: 2024.08.0

The l first rows of logs posted are known but do not affect anything.

The http error might be an issue but error need to turn on verbose or debug logging to be able to get help here.

To install a PR, use the manual install method but download the code from the PR branch instead of the latest master

tomoqv commented 1 month ago

Sorry for being a bit of a noob with Github, by I fail to find the code download link on this page: https://github.com/icanos/hassio-plejd/pull/297

MHultman commented 1 month ago

The PR says it’s merged to develop branch so should work with that one. https://github.com/icanos/hassio-plejd/tree/develop

tomoqv commented 1 month ago

Now running 12.0-beta, but can't get it to work at all with my plejd devices. plejd-12.0-beta.log

tomoqv commented 1 month ago

Also, plejd devices show as switches instead of, as before, lamps in the HA gui. image

SweVictor commented 3 weeks ago

Also, plejd devices show as switches instead of, as before, lamps in the HA gui.

How do they look in Plejd? What's the device type for the devices that are "wrong"?

From memory I think we follow the device type more correctly now and that you can use HA functionality (helpers?) to change device type in HA.

tomoqv commented 3 weeks ago

I have used HA helpers to turn them into lamps, but now they show as only switches in HA. Problem is, I haven't got the Plejd integration to work since the update to the beta version. The stable version I used before that, was nothing but stable, but worked sometimes. I haven't tried to roll back to the latest stable version, but I may do that as it at least worked occasionally. Sadly, the newer beta version seems to not work at all.

Please tell me which logs I need to provide, and I'll be glad to help out and test.

SweVictor commented 3 weeks ago

Well... As a first step, what do the logs say in the addon? Have you tried restarting the computer running HA?

If you can't figure out what's wrong them I would increase log level to verbose, pinpoint when things go wrong and post here.

Look in the readme how to get full logs if what you see in the plugin window is not enough

tomoqv commented 3 weeks ago

I have power cycled my Intel NUC HASS machine and turned on verbose logging. Log file attached. plejd-12.0-beta.log Hope this helps! I am starting to suspect there is something wrong with the bluetooth adapter, but running bluetoothctl doesn't cleary indicate that for me. The fact that I previously has got Plejd working in HA by power cycling the NUC makes me wonder though... What do you think?

MHultman commented 3 weeks ago

From what I can see in your logs, the add-on is failing to start Bluetooth discovery and keeps throwing the error:

Failed to start discovery. Operation already in progress
DBusError: Operation already in progress

This is likely why you're stuck in a loop of failed reconnect attempts. It appears that the system can't begin discovery because another process might already be using the Bluetooth adapter.

The log itself suggests a possible solution:

Access the root console. Run the following commands:

After that, restart the Plejd add-on.

tomoqv commented 3 weeks ago

Yes, I tried that, but didn't look closely enough. This is what happens when I issue "power off": bild It is turning the controller on again! I really don't know what's going on.

MHultman commented 3 weeks ago

It looks like your Bluetooth controller is automatically powering back on after you issue the power off command. This behavior could be caused by an automatic process or service that re-enables Bluetooth after it’s turned off.

Try some of this (Yes, I got if from GPT, but seems legit):

sudo systemctl stop bluetooth After that, try running bluetoothctl again and power off the controller to see if it remains off.

Try stopping the Bluetooth service as mentioned above and manually power it off again to see if the issue persists. Let us know if this changes anything!

tomoqv commented 3 weeks ago

I am also using this integration: https://www.home-assistant.io/integrations/bluetooth But I have tried to disable it and repeat the above, and I am getting the same log errors and warnings.

Wilbers007 commented 1 week ago

Hi all, I have managed to get the MQTT Mosquitto broker installed and also got the MQTT installed through HACS but when I try to add the Hassio-Plejd repository add on, it appears in the repositories but not in the add-ons page. What am I doing wrong? Thank you!

Screenshot 2024-09-04 at 11 21 21 Screenshot 2024-09-04 at 11 21 04