jmccrohan / pysolarmanv5

A python module to interact with Solarman Data Logging Sticks
MIT License
123 stars 25 forks source link

Some values don't appear to be signed #10

Closed LucidityCrash closed 2 years ago

LucidityCrash commented 2 years ago

Sorry I know you have the same inverter as I do and I'd like to confirm with you that the battery current 33134 and the battery power 33149-33150 don't actually go negative when discharging as you would expect based off the closest doc I found or the graphs when looking at soliscloud

Eg

Battery power
SENT: a5 17 00 10 45 00 00 71 19 8e f3 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 04 81 7d 00 02 c9 ef 36 15
RECD: a5 17 00 10 15 00 20 71 19 8e f3 02 01 21 16 1e 00 a7 19 00 00 d4 39 96 62 01 04 04 00 00 00 0a 7b 83 95 15
b'\xa5\x17\x00\x10\x15\x00 q\x19\x8e\xf3\x02\x01!\x16\x1e\x00\xa7\x19\x00\x00\xd49\x96b\x01\x04\x04\x00\x00\x00\n{\x83\x95\x15'
10

Battery current
SENT: a5 17 00 10 45 00 00 71 19 8e f3 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 04 81 6e 00 01 78 2b 11 15
RECD: a5 15 00 10 15 00 21 71 19 8e f3 02 01 21 16 1e 00 a7 19 00 00 d4 39 96 62 01 04 02 00 02 38 f1 b5 15
b'\xa5\x15\x00\x10\x15\x00!q\x19\x8e\xf3\x02\x01!\x16\x1e\x00\xa7\x19\x00\x00\xd49\x96b\x01\x04\x02\x00\x028\xf1\xb5\x15'
0.2

Battery Current Direction
SENT: a5 17 00 10 45 00 00 71 19 8e f3 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 04 81 6f 00 01 29 eb 83 15
RECD: a5 15 00 10 15 00 22 71 19 8e f3 02 01 21 16 1e 00 a7 19 00 00 d4 39 96 62 01 04 02 00 01 78 f0 f4 15
b'\xa5\x15\x00\x10\x15\x00"q\x19\x8e\xf3\x02\x01!\x16\x1e\x00\xa7\x19\x00\x00\xd49\x96b\x01\x04\x02\x00\x01x\xf0\xf4\x15'
1

Current Direction is 1 so discharging ... both Battery Power and Battery Current show negative in SolisCloud, but positive here.

jmccrohan commented 2 years ago

Yeah, 33134 and 33149-33150 are unsigned. If you need a signed version, you'll need to combined with the current direction in 33135.

From memory, I think the battery BMS current (33142) is signed, but I found the BMS registers to be a little slow to update (presumably because the battery is polled relatively infrequently).