audiconnect / audi_connect_ha

Adds an audi connect integration to home assistant
MIT License
224 stars 98 forks source link

fix: Remove Charge Time Display for Gas Vehicles #408

Closed coreywillwhat closed 4 months ago

coreywillwhat commented 4 months ago

As discussed in #402 we need to check if remaining_charging_time is supported using a different method. Since the value only appears in the API output when a vehicle is actually charging, we need to check against car type first. If in a supported car type [hybrid,electric], then we want to return the value, if the value isn't available, then we want to return 0.

Tested and working as expected with my 2021 Q5 plug-in hybrid. Hasn't been tested on a gas only vehicle to see if the respective sensors are removed.