githubDante / deye-controller

DEYE Hybrid inverters library
MIT License
31 stars 5 forks source link

not able to get the JSON file #6

Closed chinezbrun closed 10 months ago

chinezbrun commented 10 months ago

installed last version 0.1.3

running command:

deye-read 192.168.0.151 [serial] --json

i get:

Traceback (most recent call last):
  File "c:\program files\python38\lib\runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "c:\program files\python38\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\Program Files\Python38\Scripts\deye-read.exe\__main__.py", line 7, in <module>
  File "c:\program files\python38\lib\site-packages\deye_controller\deye_reader.py", line 95, in read_from_inverter
    read_inverter(opts.address, opts.serial, batt_only=opts.battery, power_only=opts.power, combo=opts.combo,
  File "c:\program files\python38\lib\site-packages\deye_controller\deye_reader.py", line 32, in read_inverter
    res = inv.read_holding_registers(group.start_address, group.len)
  File "c:\program files\python38\lib\site-packages\pysolarmanv5\pysolarmanv5.py", line 508, in read_holding_registers
    modbus_values = self._get_modbus_response(mb_request_frame)
  File "c:\program files\python38\lib\site-packages\pysolarmanv5\pysolarmanv5.py", line 385, in _get_modbus_response
    mb_response_frame = self._send_receive_modbus_frame(mb_request_frame)
  File "c:\program files\python38\lib\site-packages\pysolarmanv5\pysolarmanv5.py", line 373, in _send_receive_modbus_frame
    mb_response_frame = self._v5_frame_decoder(v5_response_frame)
  File "c:\program files\python38\lib\site-packages\pysolarmanv5\pysolarmanv5.py", line 249, in _v5_frame_decoder
    raise V5FrameError("V5 frame contains invalid sequence number")
pysolarmanv5.pysolarmanv5.V5FrameError: V5 frame contains invalid sequence number

with out --json switch all is good

githubDante commented 10 months ago

The error is caused by someone/something reading from the datalogger at the same time. Try again and should be OK.