Skip to content
Discussion options

You must be logged in to vote

FWIW I wrote this:

    powerwall = tesla.battery_list()
    data = powerwall[0].get_battery_data
    energy_left = round(data()['energy_left'],2)
    total_pack_energy = data()['total_pack_energy']

    print(round(energy_left / total_pack_energy * 100,2))

Which results (52.1) in a true representation of what the Tesla application displays (52) . Weird that it's no just part of the API. Though if someone has a cleaner way to do this I'm all ears.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by nwhobart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant