hesselonline / wallbox

MIT License
23 stars 8 forks source link

'disappearance' of swicth.py and lock.py in your Wallbox integration on Home Assistant #13

Open zuzu59 opened 2 years ago

zuzu59 commented 2 years ago

Hello @hesselonline,

I just wrote a little 'note' about the 'disappearance' of swicth.py and lock.py in your Wallbox integration on Home Assistant:

https://community.home-assistant.io/t/wallbox-pulsar-plus-integration/200339/168?u=zuzu59

I really use Home Assistant a lot for my home automation, I have more than 550 entities!

I bought the Wallbox in order to be able to charge my electric car according to consumption and/or solar production to balance the electrical consumers in my house. That's why I need to be able to pause or resume charging my electric car from Home Assistant.

Unfortunately this is not possible with the current integration of Wallbox in Home Assistant.

Could you help me to solve this problem?

Thanks again for your great work.

hesselonline commented 2 years ago

Hi, I replied in the forum. Basically this is the difference between the custom component and the out-of-the-box experience. Its a lot of work to get the component in the HASS repository so not all functionality is there yet.

yavinmaster commented 2 years ago

@hesselonline thank you for creating this integration.

I too really need the lock, start, stop functionality through Home Assistant. I will install the custom component in the coming week and give that a try, but it would be much appreciated if the "out-of-the-box" solution was complete. You say all of the functionality isn't there "yet", do you have any idea when it might be (weeks, months, years)?

One of the problems with people using the custom component is you obviously don't see the statistics of how many are using this integration.

Take care.

hesselonline commented 2 years ago

Yes, I understand. I have some code ready for the lock component, I need to do some more testing before I can submit it to the HASS Core project. There it will be reviewed by the maintainers of that project. Afterwards I still need to create the pause component (which is a bit more complex functionally; I don't really no the status of the switch its not in the data). In short, the time dimension is heavily influenced by the amount of time I have available (I do this in my spare time) and the amount of time it costs to get it approved by the HASS maintainers.

yavinmaster commented 2 years ago

Thanks @hesselonline. I fully appreciate these things can take up your life if you aren't careful. At the moment I have bigger issues of my Wallbox dropping off the network so will be trying a full reset this weekend. I have also installed the custom component version to get the additional functionality. Let us know when you have additional functionality in the core version so we can give it a try.

zuzu59 commented 2 years ago

Good morning all,

@yavinmaster, I have the same problem with my Wallbox losing network. After a lot of research I discovered that it is my Wallbox that disconnects from WIFI. Finally I discovered that she can't stand the presence of too many 'people' next to her and that she disconnects. I have around 50 IoT WIFIs in my network. A few days ago, I put her in the WIFI gest zone, where there is no one and there she no longer disconnects at all. I used Home Assistant's 'ping' integration to 'monitor' it, really handy this integration! @yavinmaster, so try to do the same with yours, isolate it to verify my discovery? Capture d’écran 2022-03-16 à 09 05 43

zuzu59 commented 2 years ago

Hello @hesselonline, I understand very well that it is not easy to validate a code for Home Assistant, it is moreover what makes that we have super quality code in the end. I can offer you my help if you want for your tests and validations.

I would happily content myself with code in Custom Component mode. But the problem is the following: we cannot use the Wallbox integration in Custom Component mode because it must be configured from the configuration.yaml file and as there is already the Wallbox integration in native mode in Home Assistant, we have an error which says that the configuration must be done from the native Wallbox integration UI on Home Assistant.

The ideal would be to clone the Wallbox Custom Component project with another name and run it in parallel with the native in order to avoid the 'configuration' conflict. This will allow us to wait for the validation of the 'pause' service and still be able to use our Wallbox. This would also allow us to better test your code.

yavinmaster commented 2 years ago

Thanks @zuzu59. I managed to get the Wallbox to connect to my network but not without some considerable efforts (it doesn't seem to like Unifi's more advanced functionality): I had to create its own 2.4GHz wifi network, disable every advanced networking feature including minimum datarate, PFM, Group Rekey Interval, BSS Transition, UAPSD, Fast Roaming, Proxy ARP and enabling IGMP Snooping. I also had to play around until I found the Wallbox would connect on channel 11 with 20MHz bandwidth. I might be able to re-enable some of these functions but as it is just the Wallbox on this network I can't be bothered at the moment to find out which one(s) are actually needed. I did report my findings to Wallbox but they didn't seem to care........not been impressed by their customer service which is a shame as I quite like the product.

I have been just monitoring the Portal status description in the integration - no need to add a ping integration. So long as this isn't "off-line" then everything is fine. I have found that it still drops out but at least it reconnects again. What is very interesting is the drop out is always around 24 minutes long.

hesselonline commented 2 years ago

OK, quick update here. I just opened a new PR for the inclusion of the lock function. You can find it here, any feedback is appreciated: https://github.com/home-assistant/core/pull/68414/ I will try to also create an updated version of the custom component (basically the ootb platform + lock + switch).