lephisto / tesla-apiscraper

API Scraper for pulling Vehicle Statistics from the Tesla Owner API into an InfluxDB + Grafana Dashboards
GNU Lesser General Public License v3.0
365 stars 102 forks source link

Allow charger voltage of 0 #72

Open kurthuwig opened 5 years ago

kurthuwig commented 5 years ago

Tesla Model 3 LR AWD reports a voltage if 0 when not plugged in, so it is not an invalid value.

lephisto commented 5 years ago

I'm not sure if the reported charge value can ever be < 0, i doubt that, so that PR would not make much sense. I will dig into this later this week. Thanks for PR

kurthuwig commented 5 years ago

As the value is actually 0 with my Model 3, it really makes sense as without it, the software just does not work right. And as it is a validity check for voltage, values below 0V are invalid. Still it more looks like an example for a validator than a real check, so you might also remove the check completely.