# HG changeset patch # User Daniel O'Connor # Date 1656902369 -34200 # Node ID 8990981c60a05827e0d8b564225a41309b4924c1 # Parent ec3c8b63d8e766ac7e0244b4e0a9d734c8ea9c5b Catch up with tesla_powerwall API changes. diff -r ec3c8b63d8e7 -r 8990981c60a0 pw2.ini --- a/pw2.ini Tue Feb 09 22:10:25 2021 +1030 +++ b/pw2.ini Mon Jul 04 12:09:29 2022 +0930 @@ -7,5 +7,8 @@ logtime=30 [pw] -ip=10.0.2.64 +#ip=10.0.2.64 +ip=1118431-01-H--TG1180640005H1 +username=darius@dons.net.au +password=Fnordish diff -r ec3c8b63d8e7 -r 8990981c60a0 pw2log.py --- a/pw2log.py Tue Feb 09 22:10:25 2021 +1030 +++ b/pw2log.py Mon Jul 04 12:09:29 2022 +0930 @@ -111,17 +111,16 @@ if not pw: first = True pw = Powerwall(pwip) - pw.login(username, password) - pw.detect_and_pin_version() + pw.login(password, username) meters = pw.get_meters() - grid_volts = meters.site.avarage_voltage + grid_volts = meters.site.average_voltage grid_freq = meters.site.frequency grid_power = meters.site.instant_power load_power = meters.load.instant_power battery_power = meters.battery.instant_power solar_power = meters.solar.instant_power charge = pw.get_charge() - except APIError as e: + except Exception as e: pw = None logger.error('Error communicating with Powerwall: ' + str(e)) time.sleep(300)