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

Additional sensor info from Anna/plugwise #19

Closed
AussiSG opened this issue Oct 1, 2019 · 167 comments
Closed

Additional sensor info from Anna/plugwise #19

AussiSG opened this issue Oct 1, 2019 · 167 comments

Comments

@AussiSG
Copy link

AussiSG commented Oct 1, 2019

Missing the extra info which could be read out from Anna/plugwise.

Regarding:
Actual Boiler temperature.
Actual flux rating measured by thermostat.
Actual pressure in system.

The needed to pull info is posted on following page.
https://community.home-assistant.io/t/advice-how-to-load-sensor-info-from-plugwise-anna-thermostat-web-interface-xml/87801?page=6

@bouwew
Copy link
Contributor

bouwew commented Oct 5, 2019

I've updated haanna to include getting the three requested values.

I quickly added getting the values to my private code:
image
Looks like it's working.

How to make sensors out of these values is another matter, I could use some guidance on this topic :)

@bouwew
Copy link
Contributor

bouwew commented Oct 6, 2019

Implemented and released to Pypi.

@AussiSG
Copy link
Author

AussiSG commented Oct 6, 2019

Thank you will check them later this week :D
Don't think it will be possible to really use the info to trigger your boiler/CV because Anna is already trying to do that.

I more use it to check if pressure is below 1,8 Bar and use illumination info to switch some lighting

@bouwew
Copy link
Contributor

bouwew commented Oct 6, 2019

You're welcome.
Yes, please do no test the changes today, we're still fixing some other bugs.

@bouwew
Copy link
Contributor

bouwew commented Oct 10, 2019

On Pypi, haanna is updated to version 0.12.3, the requested changes have been implemented in this version.

@AussiSG
Copy link
Author

AussiSG commented Oct 10, 2019

Hi Bouwew,
Thanks for the update. I am running the plugwise component on Home automation ( raspberry pi ).
I have tried adding you extra line of codes in the climate.py ( looks similar to your haanna) but it doesn't seem to do the trick.
Am I doing it wrong.
Kind of a python newbie ;-)

@bouwew
Copy link
Contributor

bouwew commented Oct 10, 2019

Just replace all the code in haanna.py and climate.py files. You can get the clean code via the Raw- button.

@AussiSG
Copy link
Author

AussiSG commented Oct 10, 2019

Should I be having both the haanna.py and the climate.py files in the custom_component folder? Thought only one should do that trick?
Sorry for asking ( so much )

@bouwew
Copy link
Contributor

bouwew commented Oct 10, 2019

First you will need to update haanna, this can be done by changing the number in manifest.json. to 0.12.3. Then update the contents of climate.py with the code in the anna-ha repository.

@AussiSG
Copy link
Author

AussiSG commented Oct 10, 2019

Thank you ! Clear thing will give it a go tomorrow.
Will let you know.

@bouwew
Copy link
Contributor

bouwew commented Oct 11, 2019

Some quick advice: install the Visual Studio Code add-on from the ADD-ON STORE.
With this editor it is very easy to edit your HA files.

And here you can find the clean code to put in the climate.py file: https://raw.githubusercontent.com/laetificat/anna-ha/master/custom_components/plugwise_dev/climate.py

Just copy and paste it after deleting to existing code.
Or, if you want to play it safe, make a backup of the existing file/code. Can also be done via the Visual Studio Code editor, it has some file management functions.

@AussiSG
Copy link
Author

AussiSG commented Oct 11, 2019

Have updated the climate.py code with the code you linked above.
And also changed the number inside the .json file as followed:

{
  "domain": "plugwise_dev",
  "name": "Plugwise Development Anna",
  "documentation": "https://github.com/laetificat/anna-ha",
  "dependencies": [],
  "codeowners": ["@laetificat","CoMPaTech", "@bouwew"],
  "requirements": ["haanna==0.12.3"]
}

but when I look in the develepment tools -> states part.
I dont see the extra information. Do I need to trigger something else.
Also did a restart of HASS after changing the code ;-)

@bouwew
Copy link
Contributor

bouwew commented Oct 11, 2019

That's strange, it works for me and CoMPaTech.
Try reloading the States page.
What type of HA installation are you using? Can you check in some way if haanna was updated to the required version?

@bouwew
Copy link
Contributor

bouwew commented Oct 11, 2019

Also, any information in the Development Tools - Log?

@CoMPaTech
Copy link
Collaborator

CoMPaTech commented Oct 11, 2019 via email

@AussiSG
Copy link
Author

AussiSG commented Oct 12, 2019

The only entry I can find in the log is:

2019-10-12 08:46:26 INFO (SyncWorker_16) [homeassistant.loader] Loaded plugwise from homeassistant.components.plugwise
2019-10-12 08:46:30 INFO (MainThread) [homeassistant.components.climate] Setting up climate.

I have added the following code in the config file to enable the logging but it feels wrong because of not getting any hehe

climate.plugwise: debug

To enable the logging but it feels wrong because of not getting any hehe

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

I guess you have configured the Plugwise component that is a part of HA.
You can disable that one and enable the Plugwise_dev component by making a change in configuration.yaml:
Change

climate:
  - platform: plugwise

To

climate:
  - platform: plugwise_dev

And then restart HA.

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

Also, you directory must be named: .../custom_components/plugwise_dev

@AussiSG
Copy link
Author

AussiSG commented Oct 12, 2019

Alright have made another step forward.... :D
Now get the following warning

2019-10-12 12:15:46 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for plugwise_dev which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you do experience issues with Home Assistant.

But sadly enough I dont see the extra info. I have also updated the climate.py and .json file fully by downloading and putting them in /custom_components/plugwise_dev

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

The warning is normal, so you are indeed making progress.

Can you post an image of what is shown on the States-page?
On Windows press Shift-PrintSc, open Paint, Crtl-V, then select the part of the screen you want to show here, Ctrl-C, etc.

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

Also, you have one climate.plugwise_dev entity in the States-list? And no climate.plugwise anymore?

@AussiSG
Copy link
Author

AussiSG commented Oct 12, 2019

Yeah only have the DEV one as entity.

image

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

Ok, looks like there's more missing, what is the firmware-version of your Anna?

@AussiSG
Copy link
Author

AussiSG commented Oct 12, 2019

Its running on firmware version 1.8.20

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

Ah, Ok, that's why. I'm running on 3.1.7 and the additions are written and tested for the 3.x firmware.
But, I'm happy to try and get it to work for your version.
Can you send me a complete capture of the Anna-xml-data?
Please browse to "your-anna-ip"/core/domain_objects, click with your mouse-cursor in the text that is shown, press Crtl-a, Ctrl-c and then paste (Ctrl-v) the data for instance in a pastebin.com page and send me the link.

@AussiSG
Copy link
Author

AussiSG commented Oct 12, 2019

Ah serious. I have read some stuff about that on the HA forum.... :(
Firmware version is from 2017-03-13 and HW version = 6539-1302-5002.

hope it worked. This is the link:
https://pastebin.com/510RVMTN

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

Great, thanks!

Please change the requirements-line in manifest.json from this: "haanna==0.12.3" to this: "https://github.com/bouwew/haanna/archive/master.zip#haanna==0.12.4"

Then restart HA and let me know whether the 3 new parameters are being shown.

@AussiSG
Copy link
Author

AussiSG commented Oct 12, 2019

Wauw quick progress! seems to have done the trick

image

@bouwew
Copy link
Contributor

bouwew commented Oct 12, 2019

Great!

I see some other stuff that is not working, let me make some more changes...

@bouwew
Copy link
Contributor

bouwew commented Apr 8, 2020

@AussiSG please try version 0.1.11.

@AussiSG
Copy link
Author

AussiSG commented Apr 8, 2020

Nice great job man !
That looks sorted

I haven't yet try to see if the state changes form idle to hearing when the boiler is turned on.

I will check that later on when it s a bit colder again ;-)

@CoMPaTech
Copy link
Collaborator

He said wisely on the hottest 8th of April to date :)
Tnx for the feedback

@AussiSG
Copy link
Author

AussiSG commented Apr 8, 2020

Still have this message when setting a preset mode.
Do you have any idea if that's a fault because of using the simple thermostat card or something else ?

Setting the preset mode does work but gives this messages everytime on every preset mode ( not heating or schedule mode (

Screenshot_20200408-200002

@CoMPaTech
Copy link
Collaborator

Thats weird ... ill have a look

@CoMPaTech
Copy link
Collaborator

Can you try calling it through developer tools?
i.e. https://yoururl/developer-tools/service like shown?

Schermafbeelding 2020-04-08 om 20 05 41

@CoMPaTech
Copy link
Collaborator

I have a v3 but I'd presume it should work the same (if entered both home and away to check)

@bouwew
Copy link
Contributor

bouwew commented Apr 8, 2020

@CoMPaTech see my message on Discord.

@AussiSG
Copy link
Author

AussiSG commented Apr 8, 2020

@CoMPaTech that gives the same message

@CoMPaTech
Copy link
Collaborator

Yup, @bouwew already found what went wrong. Apologies from my side, redoing legacy on the rewrite I forgot key elements, kudos to @bouwew

@CoMPaTech
Copy link
Collaborator

We know the origin of the issue, trying to wrap my head around it but it might require review from us both so hopefully you don't mind waiting for a fix tomorrow.

@AussiSG
Copy link
Author

AussiSG commented Apr 8, 2020

Updated still gives the following messages.

Kan service climate/set_preset_mode niet aanroepen 'float' object is not subscriptable

And found another small thing which got lost in transition?
Ive lost the actual pressure of the boiler.

image

Edit:
info can be found with the following data from core domain.

<point_log id="5934a3ae268f44af8d0f208509556b1a">
<updated_date>2020-04-08T18:55:50.400+02:00</updated_date>
central_heater_water_pressure
bar
<last_consecutive_log_date>2020-04-08T18:55:50.400+02:00</last_consecutive_log_date>
<pressure_gauge id="5082f6d572214c4d967b0b3212ca27b4"/>

1.80

@AussiSG
Copy link
Author

AussiSG commented Apr 8, 2020

No problem guys , you are doing great work.
Many thanks for this nice package already!!!

@CoMPaTech
Copy link
Collaborator

I'll put 0.1.12 out shortly if that doesn't work tomorrow will be a brand new shiny day

@CoMPaTech
Copy link
Collaborator

It should be available as for the list of issues per now

  • Setting prefix issue solved
  • Setting prefix tested
  • Boiler pressure issue investigation

@AussiSG
Copy link
Author

AussiSG commented Apr 9, 2020

@CoMPaTech , Very nice the warning/messages doenst appear any more on any of the preset modes presses

@bouwew
Copy link
Contributor

bouwew commented Apr 9, 2020

@AussiSG Finally fixed!
Thank you for your detailed testing and feedback, it helps us to find and fix all the bugs that are (were) still there after the complete make-over.

Do you also see the water_heater entity in our HA?

@bouwew
Copy link
Contributor

bouwew commented Apr 9, 2020

@AussiSG About the pressure sensor, please update to version 0.1.13.
After the update it should be there, but look for it, the sensor-name has probably changed.

@AussiSG
Copy link
Author

AussiSG commented Apr 9, 2020

image

Yes ! And there is also the boiler pressure sensor.
I think I have put you guys on the wrong feet with and old sensor I created myself?....

@bouwew
Copy link
Contributor

bouwew commented Apr 9, 2020

In version 0.1.12 and before the water_pressure was only available as an attribute of the water_heater.
In version 0.1.13 there is also a sensor.xyz_central_heater_water_pressure.

@AussiSG
Copy link
Author

AussiSG commented Apr 9, 2020

Yes that's awasome !
image

Sorry for the confusing part :D

Edit small remark:
Dont know if you can change the "units" in the base entity.
I think its Bar and not milibars ( mbar )

@bouwew
Copy link
Contributor

bouwew commented Apr 9, 2020

Yes, you are right. In my Adam-system and I think in the recent Anna the number is an integer (0-10), that's why I changed it. I will investigate...

@AussiSG
Copy link
Author

AussiSG commented Apr 9, 2020

Its not a real problem , you can ofcourse change the units by hand.
So I wouldnt bother changing it for legacy Anna's
As it seems there are more V3 users haha

@bouwew
Copy link
Contributor

bouwew commented Apr 9, 2020

Will be fixed in 0.1.14, sometime later today...

@AussiSG
Copy link
Author

AussiSG commented Apr 28, 2020

Hi Gents I am currently running 0.2.0 on HA on version 219.
Got everything running. But I dont get the climate entity?

I do get 2 entities called "Anna" and "Smile_Anna" but they only contain information. ( i.e. sensors )

image

@bouwew
Copy link
Contributor

bouwew commented Apr 28, 2020

Sorry, which HA version are you on?

@CoMPaTech
Copy link
Collaborator

Presumablye 109b4 (which is 219 here as well)... do you spot anything obvious in /developer-tools/logs? I guess the climate part just isn't loading, we're very keen to understand why

@bouwew
Copy link
Contributor

bouwew commented Apr 28, 2020

219 is the supervisor version, can still be 0.108.x.

@CoMPaTech
Copy link
Collaborator

Lets follow up in the above mentioned issue

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

No branches or pull requests

3 participants