ayasystems / dbus-fronius-smart-meter

Integrate Fronius Smart meter into Victron Energies Venus OS
GNU General Public License v3.0
6 stars 2 forks source link

No connection issue #2

Open valdeira888 opened 1 year ago

valdeira888 commented 1 year ago

Hi, I'm having trouble connecting to the meter. Here is the error msg: root@raspberrypi2:/data/dbus-fronius-smart-meter# python dbus-fronius-smart-meter.py 2023-09-18 17:01:30,775 root ERROR com.victronenergy.grid 2023-09-18 17:01:30,786 root CRITICAL Error at main Traceback (most recent call last): File "dbus-fronius-smart-meter.py", line 248, in main pvac_output = DbusFroniusMeterService( File "dbus-fronius-smart-meter.py", line 28, in init self.dbusservice = VeDbusService("{}.http{:02d}".format(servicename, deviceinstance)) File "/opt/victronenergy/dbus-systemcalc-py/ext/velib_python/vedbus.py", line 78, in init self._dbusname = dbus.service.BusName(servicename, self._dbusconn, do_not_queue=True) File "/usr/lib/python3.8/site-packages/dbus/service.py", line 144, in new raise NameExistsException(name) dbus.exceptions.NameExistsException: Bus name already exists: com.victronenergy.grid.http_40 root@raspberrypi2:/data/dbus-fronius-smart-meter# /data/dbus-fronius-smart-meter/restart.sh root@raspberrypi2:/data/dbus-fronius-smart-meter# python dbus-fronius-smart-meter.py 2023-09-18 17:03:07,726 root ERROR com.victronenergy.grid 2023-09-18 17:03:08,621 root CRITICAL Error at main Traceback (most recent call last): File "dbus-fronius-smart-meter.py", line 248, in main pvac_output = DbusFroniusMeterService( File "dbus-fronius-smart-meter.py", line 52, in init self._dbusservice.add_path('/Serial', self._getFronisSerial()) File "dbus-fronius-smart-meter.py", line 71, in _getFronisSerial if not meter_data['Body']['Data']['Details']['Serial']: KeyError: 'Details' root@raspberrypi2:/data/dbus-fronius-smart-meter#

The host ip, is the Fronius Inverter IP?

config.ini [DEFAULT] AccessType = OnPremise SignOfLifeLog = 1

[ONPREMISE] Host=192.168.1.105 MeterID = 1 intervalMs = 800 CustomName = VIR1 Fronius Smart Meter Role = grid

Role = acload

Role = genset

Role = pvinverter

Thanks for the help

driest commented 4 months ago

In case anyone else stumbles onto this like I just did:

Stopping the service doesn't seem to unregister it from dbus, so if you try to start it again you get this error: Bus name already exists: com.victronenergy.grid.http_40

There are probably easier ways to do this, but just restarting the cerbo allows the service to start again.