dan-r / HomeAssistant-Ohme

Unofficial Home Assistant integration for interacting with Ohme EV chargers (EVSE) 🚗⚡️
MIT License
35 stars 10 forks source link

Battery SoC and Energy sensor values incorrect values #79

Open coathook opened 1 month ago

coathook commented 1 month ago

Firstly, congratulations on this integration - this is great work and really useful!

Issues below are minor for my use case but wanted to share in aid of future improvements

I have an Ohme Home Pro FW v2.5, and a Tesla Model Y using Octopus Intelligent, controlling the Ohme Home Pro

The _sensor.ohme_batterysoc is constantly at 100% value in Home Assistant, whether car is connected or not. In the Ohme app it is reporting the battery SoC correctly (same as the car)

The _sensor.ohme_sessionenergy also appears to have the wrong value, on first charge session it was 77kWh and second charge session shows 60kWh (but charge is from 60%-80%)

Home Assistant Version Core: 2024.4.2 Operating System: 11.5

Integration Version v0.82

Thanks!

dan-r commented 1 month ago

Thanks for getting in touch!

So I don't have my car (Leaf) API connected as its a bit unreliable, so some of the logic causing that constant 100% could be related to that. If you restart Home Assistant (or reload the integration), does the SOC show correctly? If that doesn't help, the next port of call is that the API returns two 'battery' fields and we could be looking at the wrong one.

The energy sensor is a bit more complicated. The only way to read the 'live' energy usage is to effectively read the graph points from the Ohme app home screen. These often don't tally up exactly with Ohme's own statistics screen, but I'm working on getting this a bit closer...

coathook commented 1 month ago

Thanks for the fast response

I have restarted Home Assistant, now sensor.ohme_battery_soc value is 74%, however car and Ohme app show 80% (Car charging is stopped, car still plugged in) sensor.ohme_session_energy still shows 80kWh

coathook commented 1 month ago

Stop press.. Left the car connected this morning after the charge had finished and from 11am sensor.ohme_battery_soc value is now correct at 80% will keep you posted if it’s working now

yanikdude commented 1 month ago

I have an Ohme Home Pro (V2.62) and a Volvo C40 Recharge. The Ohme has never reported the correct battery charge state. This is rubbish as the basic fundamental function of an EV charger is to talk to the EV through the 2 communication wires and share status. Ohme has got some serious bugs so would say it's an issue with this Add-On.

dan-r commented 1 month ago

@coathook could you please try v0.8.3-beta.2 and see if it helps? I've removed some of the logic I think is being problematic (beta instructions)

dan-r commented 1 month ago

@yanikdude the J1772 protocol used by Type1/2 charging cables does not support reporting battery state of charge, details here. Hence the Ohme talks to the car through the APIs of car manufacturers to get these details. I personally don't use this functionality because I find it flaky and unneccesary.

This add-on is not developed nor endorsed by Ohme and is completely reliant with data returned by undocumented APIs. If the integration is returning the same data as the Ohme app, there is nothing I can do to correct that. If the integration is reporting different data, that is most likely an integration issue (as reported by @coathook).

yanikdude commented 1 month ago

Hey dan-r, thank you so much for the feedback.

We are having a lot of issues with the Ohme Home Pro, crashing, miss-reporting etc and we have connected our car via the API to Ohme bit have been advised to disconnect until they resolve the API issue.

Our friends use our charger from time to time and have no issue with any status in the Ohme stats and they are not even connected via the API just the charging cable. Theirs is a Tesla. So it can only use the communication pins. Will keep badgering away at Ohme and see what they come back with.

As for the Add-On, fully understand that somethings are not truly supported but it is amazing what has been done. A huge applause for the development team. Now, if one of you could get job at Ohme and fix the numerous bugs, that would be amazing.

andyvee69 commented 1 month ago

Our friends use our charger from time to time and have no issue with any status in the Ohme stats and they are not even connected via the API just the charging cable. Theirs is a Tesla. So it can only use the communication pins. Will keep badgering away at Ohme and see what they come back with.

There is no SoC communication via the cable for Type 2 charging. So your friends Tesla is NOT communicating any SoC info via the cable to Ohme.

dan-r commented 1 month ago

@yanikdude my recommendation would be to just not bother with the API connection if its unreliable. You can set a percent charge to add with no API connection, and thats what I do. My Home Pro has been very reliable using it like this.

In terms of a development team, I'm afraid its just me and this is one of several side projects alongside a full-time job! 😄 (Although I have had some excellent help from the community with testing and where certain data comes back on the API)

Last I heard was that all the dev teams at Ohme were pretty busy working on a new app, but I haven't seen anything on it for a while...

andyvee69 commented 1 month ago

Last I heard was that all the dev teams at Ohme were pretty busy working on a new app, but I haven't seen anything on it for a while...

The new app has been in a limited closed public beta test for quite a few weeks now.

It doesn't have all functionality yet though for a wider test, but more testers have recently been invited

coathook commented 1 month ago

hi dan-r just trying v0.8.3-beta.2 so far looks good, sensor.ohme_battery_soc value is reporting correctly, however update rate is quite slow, maybe one every 45 mins or so during the charge, is that to be expected?

dan-r commented 1 month ago

The integration fetches data from Ohme every minute, so the SOC update rate is on Ohmes side.

Does it update quicker if you look on the Ohme app, or only if you manually press the update button on there?

coathook commented 1 month ago

Will check the Ohme app on next charge but think it has a faster update rate than showing in HA Here’s the history to highlight the slow update rate image

dan-r commented 1 month ago

That seems like Ohme only polling that often to stay in the good books of car manufactuers... But if it updates quicker in the Ohme app I can look into triggering an update more often. Its possible that by being on the app it updates more frequently anyway

yanikdude commented 1 month ago

@yanikdude my recommendation would be to just not bother with the API connection if its unreliable. You can set a percent charge to add with no API connection, and thats what I do. My Home Pro has been very reliable using it like this.

In terms of a development team, I'm afraid its just me and this is one of several side projects alongside a full-time job! 😄 (Although I have had some excellent help from the community with testing and where certain data comes back on the API)

Last I heard was that all the dev teams at Ohme were pretty busy working on a new app, but I haven't seen anything on it for a while...

The issue I have is that the Ohme has no way of seeing the charge percentage of the EV and, even now we have set it to "Price cap", you see a spike usage in electricity just to see if the vehicle needs more charge even though it's at 100%.

These changes are just making the Ohme a dumb charger and would have just installed a commando socket instead if it wasn't for Octopus Intelligent Go tariff.

I do know our bills are higher because of the miss management of charging percentages.

Your HACS is amazing to help with this insight. Shall be reaching out to my old boss, now Director at Ohme to see what can be done and even any beta programs.

Thanks again.

dan-r commented 2 weeks ago

@yanikdude did you have any luck with this?

yanikdude commented 2 weeks ago

Hey Dan-r,

Just to update, Our OhMe has always had issues with connectivity and regularly goes "Off Line" Ohme support put this down to high voltage in our area, and tbh, it was sitting between 247v & 254v for long while (it has been blowing a lot of caps ion things).

Ohme have apparently sent a software update to cater for the high voltage but has made it even more unstable. This has been feedback.

Nation Grid have placed monitoring equipment to see what is happening which was removed this morning and awaiting feedback.

Octopus also have a ticket open for wrong charging and getting the car to charge outside of peak hours but also out of cheap charging. Octopus have advised to only use 'off peak' charging due to communication issues. Ohme have said to not use the Volvo sign in to link into their app because of API issues.

The good. thing is, if we trick Ohme into thinking our car needs more charge than it needs, Octopus send a lot of intelligent time slots and put the whole house on a cheap tariff for that duration, which means we use those slots for cooking / washing etc.

In short, your app is amazing at letting me know a lot of data I am now using to feedback to Ohme & Octopus.

Thank you!

yanikdude commented 1 week ago

Just to update:

Ohme has stated that we have mobile coverage issues and they have changed a few things of which provider connects first. This doesn't look like it has resolved anything, This is a draw back when units don't have local ethernet or wifi connection.

Have offered the use of my home femtocell to help resole this.