SAIC-iSmart-API / saic-python-mqtt-gateway

A service that queries the data from an MG iSMART account and publishes the data over MQTT and to other sources
MIT License
71 stars 21 forks source link

Configurable interval for update after schedule charging started #143

Closed jfreves closed 6 months ago

jfreves commented 8 months ago

At the moment, Gateway is set to update the car state only 10 minutes after schedule charging start time. Can this interval be configurable instead? In my case I like to have it updated right as soon charge stars to have the correct state in my entities.

nanomad commented 8 months ago

The gateway uses the REFRESH_PERIOD_INACTIVE_GRACE which is technically configurable via MQTT inActiveGrace

The idea is that we run this task once to avoid depleting the battery in case the car is not plugged in, so waiting for the "looking for charger" timeout makes sense.

We can migrate that to a new config option (exposed in the config and MQTT I suppose) but I'd keep the default value in sync

jfreves commented 8 months ago

I just noticed an old thread in which this change was already requested. Please feel free to close this one.