bimmer_connected icon indicating copy to clipboard operation
bimmer_connected copied to clipboard

A suggestion: add the 'state_class' property for the fuel and mileage entities to use the 'statistic' function in HA

Open muxiachuixue opened this issue 4 years ago • 4 comments

Describe the issue

The question: The historical data of the car in HA only applies to the past 10 days for default. If you want to analyse the fuel consumption for past several months, you can only set the parameter keep_days in recorder to a larger value which will impact all the entities in HA and increase the size of the database file.

The solution: According to the official instruction of HA, if a sensor entity contains the state_class property and the value is measurement, the statistic function will be available. So it will be useful if the state_class property is added to the mileage/fuel_percent/remaining_range entities.

Looking forward to see the update. Many thanks for your great work!

Expected behavior

Add the state_class property for the fuel and mileage entities to use the 'statistic' function in HA

Which Home Assistant version are you using?

core-2021.12.7

What was the last working version of Home Assistant Core?

No response

What is your region?

China

ConnectedDrive website

  • [X] I can still successfully login to the BMW ConnectedDrive website and the car status is available there.
  • [X] I have ConnectedDrive enabled for my vehicle.

Number of cars

  • [ ] I have 2 or more cars linked to the ConnectedDrive account.
  • [ ] I have a Mini vehicle linked to my account.

Output of bimmer_connected fingerprint

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

muxiachuixue avatar Jan 06 '22 02:01 muxiachuixue

Thanks, good idea! I'll have a look into this.

rikroe avatar Jan 09 '22 14:01 rikroe

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Apr 10 '22 03:04 github-actions[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jul 10 '22 03:07 github-actions[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Oct 09 '22 04:10 github-actions[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jan 08 '23 03:01 github-actions[bot]