From 66549a85d9a52423eb62a418c61ceb0aa9703572 Mon Sep 17 00:00:00 2001 From: Norbert Date: Wed, 12 Jul 2023 07:13:37 +0200 Subject: [PATCH] fixed Mode upgrade --- solax.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/solax.py b/solax.py index 1e2e706..1313a9b 100644 --- a/solax.py +++ b/solax.py @@ -124,11 +124,16 @@ if s.connect(): act_item.state=float(energy_to_grid) act_item=items.get("Solax_feed_in_today") act_item.state=float(feed_in_today) + act_item=items.get("Solax_runMode") + act_item.state=int(run_mode) + act_item=items.get("Solax_time_count_down") + act_item.state=float(time_count_down) data += ["Solax_SUM_DC"+" value="+str(total_power)] data += ["Solax_eToGridToday"+" value="+str(etoday_togrid)] data += ["Solax_feed_in_today"+" value="+str(feed_in_today)] - data += ["Solax_runMode"+" value="+str(run_mode)] - data += ["Solax_time_count_down"+" value="+str(time_count_down)] + data += ["Solax_runMode"+" value="+str(int(run_mode))] +# print("RunMode: "+ str(int(run_mode))) + data += ["Solax_time_count_down"+" value="+str(int(time_count_down))] write_api = client.write_api(write_options=SYNCHRONOUS) write_api.write(bucket, org, data)