@BrettS is correct - custom code and it behaves exactly as he says. It's been on the backlog forever now to interface with a solar prediction site to augment the runtime estimates but oddly haven't found spare time to get around to it... Now that the pack energy numbers are exposed in the API I'm going to look to update the plugin to read from there rather than estimate what's remaining, right now you have to manually set your total pack energy.
@MrVivekB the best Powerwall API documentation I've found (and contributed to) is here: GitHub - vloschiavo/powerwall2: Tesla Powerwall 2 - Local Gateway API documentation
@MrVivekB the best Powerwall API documentation I've found (and contributed to) is here: GitHub - vloschiavo/powerwall2: Tesla Powerwall 2 - Local Gateway API documentation