home_assistant_solarman icon indicating copy to clipboard operation
home_assistant_solarman copied to clipboard

added megarevo inverter definations

Open wolfmon opened this issue 1 year ago • 1 comments

Added Megarevo Inverter Defination

(Mostly via solarman app pcap, so might not be 100% accurate)

Confirmed most registers in this commit working on 15KW 3 phase hybrid model (R15k3H) with Solarman V5 Wifi Logger, more fields to be added and validated. image

Sidenote: A potential interesting V2G/V2H/V2L feature this can enable:

Still a PoC, but I am able to get the inverter to relatively safely? to connect and disconnect an EV to be used as energy storage battery, EV HV battery can both be charged and discharged via inverter, tested with GB/T 20234 connector (maybe this will work with ChaDeMo too? yet to be tested), inverter has issue detecting disconnected battery: when battery is disconnected, inverter still tries to energize battery bus with lethal DC voltage (tires to charge battery), this can be addressed by enabling BMS communication on the inverter to inject a fault so the inverter will stop putting voltage on battery bus, this can be done with the following so that the connector and cable can be removed safely: image image

USE PROPER PPE, THIS SETUP IS NOT 100% SAFE YET, DO NOT TRY THIS AT HOME

`modbus.send_raw_modbus_frame_parsed(b"\x01\x10\x34\x0f\x00\x01\x02\x00\x02\x52\xad")`
# DEBUG:pysolarmanv5.pysolarmanv5:SENT: a5 1a 00 10 45 FF FF FF FF FF FF 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 10 34 0f 00 01 02 00 02 52 ad f6 15 (changed a few random bits to redact my SN, checksum will not match)
# DEBUG:pysolarmanv5.pysolarmanv5:RECD: a5 16 00 10 15 FF FF FF FF FF FF 02 01 07 2b 06 00 ff 17 00 00 f7 08 91 66 01 10 34 0f 00 01 3f fa d3 15  (changed a few random bits to redact my SN, checksum will not match)

Inverter mode can also be changed to force charge the car HV battery via grid (storm watch mode) or only via PV (like Tesla's drive on sunshine), but was not able to write with the current HA_solarman service call, any help would be appreciated (maybe create an separate issue for this?).

wolfmon avatar Aug 05 '24 00:08 wolfmon