daernsinstantfortress / WeConnect-Cupra-python

Cupra version of the WeConnect python library
MIT License
7 stars 5 forks source link

How to get the "total distance traveled" #12

Open Roundwolf opened 5 months ago

Roundwolf commented 5 months ago

In the app you can access the total distance and i would like to run a script that would mark down this value daily. I already did manage to make the access_status.py work. And I also found something called "OdometerMeasurement", what clearly sounded to me like the right way. But I wasn't able to change the script properly to get the value in my console feedback. My idea was to modify the access_status.py adding this in line 53:

if "measurements" in vehicle.domains and 'OdometerMeasurement' in vehicle.domains["measurements"] and vehicle.domains["measurements"]["OdometerMeasurement"].enabled: print(vehicle.domains["measurements"]["OdometerMeasurement"])

Any idea how to do better?

Zahlii commented 2 months ago

Would be interested here as well