dan-r/HomeAssistant-Ohme

Would it be possible to inform Ohme of car charge level via this integration?

x00r opened this issue · 4 comments

x00r commented

Loving this integration so far, but I have a request if at all possible!

Is your feature request related to a problem? Please describe.
I'm one of the many currently affected by Jaguar nerfing their API for 3rd parties, such that the Ohme charger can't directly query the car for charge level. This completely screws up the smart charging capability and means in order to have a "charge to 80%" kind of behaviour, I have to use Home Assistant (which can still talk to the jag) to work out the charge % required whenever the car is plugged in, then configure the charger via your integration.

Describe the solution you'd like
Ideally, I could just directly push the car's current charge level to the charger whenever it changes.

Additional context
I'm half certain this isn't possible, alas... Ohme were getting that info from pestering Jaguar's API, not the other way around, so I guess their API may not offer this capability? Thought I'd ask just in case!

So my car (Nissan) has Ohme API support but I never found it to be particularly reliable, so my solution is (using Node-RED):

  1. Ohme says car is plugged in, does car say its plugged in?
  2. Set charge target to 80% - cars current charge.
  3. Approve charge

Its not ideal but it does the job...

I hadn't thought about the idea of telling Ohme the current charge percentage, but thats a very interesting idea... I'll have a play around with the API and see if it'll accept anything like that.

x00r commented

Thanks for your thoughts on the matter, I appreciate it!

Alas Jaguar doesn't seem to support charge limits on the car-side (you can sort of fake it with 3rd party apps like Wattcat, or indeed, Home Assistant telling it to stop at a set percentage) but this wouldn't fix my problem of the charger needing to know the current charge level to correctly strategize for electricity pricing (I'm on Octopus Agile tariff, so my prices are changing every 30mins, sometimes by a lot - since the charger doesn't know how full the car is, it always assumes it's charging from 0%, and thus makes stupid assumptions about when it should start charging, e.g. starting during expensive hours instead of waiting because it thinks it needs more time on charge).

The only solution I've got so far is to calculate the percentage required when the car is detected as plugged in; this is vaguely close enough for the charger to pick the best charging times but just a major pain in the bum, haha.

Frankly it's a bit weird they don't just query the car directly through the cable, like public chargers do, you know?? Surely that's easier? Or is there something about AC charging that does not support such advanced communication, I wonder? Like can they only do that PWM-signal thing, maybe?

AFAIK there is only very basic communication when AC charging (effectively just current capability and state), so we are stuck with flaky API comms for now.

Informing Ohme of the charge level would be technically very simple, but would require some cooperation with Ohme, and I don't have any direct contact with them to do that sadly.
I also expect they would be quite reluctant to open that sort of thing up, as it would open up another route to 'gaming' Intelligent Octopus to get more cheap energy.

Closing for now - I'll reopen if we ever get an opportunity to work with Ohme.