reading out registers corrected
This commit is contained in:
6
main.py
6
main.py
@@ -1,13 +1,12 @@
|
||||
import time
|
||||
from datetime import datetime
|
||||
from data_base_csv import DataBaseCsv
|
||||
from data_base_influx import DataBaseInflux
|
||||
from heat_pump import HeatPump
|
||||
from pv_inverter import PvInverter
|
||||
from shelly_pro_3m import ShellyPro3m
|
||||
|
||||
# For dev-System run in terminal: ssh -N -L 127.0.0.1:8111:10.0.0.10:502 pi@192.168.1.146
|
||||
# For productive-System change port in heatpump to 502
|
||||
# For productive-System change IP-adress in heatpump to '10.0.0.10' and port to 502
|
||||
|
||||
interval_seconds = 10
|
||||
|
||||
@@ -18,7 +17,7 @@ db = DataBaseInflux(
|
||||
bucket="allmende_db"
|
||||
)
|
||||
|
||||
hp = HeatPump(device_name='hp_master', ip_address='localhost', port=8111)
|
||||
hp = HeatPump(device_name='hp_master', ip_address='10.0.0.10', port=502)
|
||||
shelly = ShellyPro3m(device_name='wohnung_2_6', ip_address='192.168.1.121')
|
||||
wr = PvInverter(device_name='wr_master', ip_address='192.168.1.112')
|
||||
|
||||
@@ -31,5 +30,6 @@ while True:
|
||||
db.store_data(shelly.device_name, shelly.get_state())
|
||||
db.store_data(wr.device_name, wr.get_state())
|
||||
#controller.perform_action()
|
||||
|
||||
time.sleep(0.1)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user