services: Fix power total_kwh
This commit is contained in:
parent
381a0e2c2e
commit
fa31ab8590
2 changed files with 3 additions and 2 deletions
|
@ -21,7 +21,7 @@ while True:
|
|||
sleep(10)
|
||||
try:
|
||||
data = requests.get(f'http://{sdm630_host}/api/v1/data').json()
|
||||
client.publish('bitlair/power/total_kwh', data['total_power_import_kwh'])
|
||||
client.publish(f'bitlair/power/{net}/total_kwh', data['total_power_import_kwh'])
|
||||
client.publish(f'bitlair/power/{net}/All/now_w', data['active_power_w'])
|
||||
client.publish(f'bitlair/power/{net}/L1/now_w', data['active_power_l1_w'])
|
||||
client.publish(f'bitlair/power/{net}/L2/now_w', data['active_power_l2_w'])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue