CharlesGillanders / homeassistant-alphaESS

Monitor your energy generation, storage, and usage data using the official API from Alpha ESS.
MIT License
101 stars 22 forks source link

Setting Discharge Times doesn't seem to work any more (since switching API?) #91

Closed ffrog8 closed 11 months ago

ffrog8 commented 11 months ago

Calling the service

service: alphaess.setbatterycharge
data:
  serial: XXX
  enabled: true
  cp1start: "01:00"
  cp1end: "04:00"
  cp2start: "01:00"
  cp2end: "04:00"
  chargestopsoc: 100

Shows a green tick and no error reports. However nothing is updated in the alpha app/web page.

Adding some debug:

async def async_battery_charge_handler(call):
        response = await client.updateChargeConfigInfo(call.data.get('serial'), call.data.get('chargestopsoc'), int(call.data.get('enabled') == True), call.data.get('cp1end'), call.data.get('cp2end'), call.data.get('cp1start'),  call.data.get('cp2start'))
        _LOGGER.debug(f"UpdateChargeConfigInfo response: {response}")

Gives the output

DEBUG (MainThread) [custom_components.alphaess] UpdateChargeConfigInfo response: None

Not sure what the problem could be?

ffrog8 commented 11 months ago

Nope it works fine - its a validation problem on my end.