Open GoogleCodeExporter opened 9 years ago
i have added the %DATA_BYTES= under
foreach $inverter (keys(%inverters)) {
simply checking against my serial numbers to decide which config to use.
cheers.
foreach $inverter (keys(%inverters)) {
$response = send_request($inverter, $CTRL_FUNC_CODES{"READ"}{"QUERY_NORMAL_INFO"});
if($response) {
# good response - reset response_timeout_count
$inverters{$inverter}{"response_timeout_count"} = 0;
$serial = ($inverters{$inverter}{"serial"});
if($serial == "8891500A40B05707"){
print "Serial: $serial\n";
%DATA_BYTES = (
"TEMP" => 0,
"E_TODAY" => 1,
"VPV" => 2,
"IPV" => 3,
"IAC" => 4,
"VAC" => 5,
"FREQUENCY" => 6,
"PAC" => 7,
"IMPEDANCE" => 8,
"NA_1" => 9,
"E_TOTAL" => 10,
"NA_2" => 11,
"HOURS_UP" => 12,
"OP_MODE" => 13
);
}
if($serial == "A984300A128P0066"){
print "Serial: $serial\n";
%DATA_BYTES = (
"TEMP" => 0,
"E_TODAY" => 1,
"VPV" => 2,
"VPV2" => 3,
"IPV" => 4,
"IPV2" => 5,
"IAC" => 6,
"VAC" => 7,
"FREQUENCY" => 8,
"PAC" => 9,
"NA_0" => 10,
"NA_1" => 11,
"E_TOTAL" => 12,
"NA_2" => 13,
"HOURS_UP" => 14,
"OP_MODE" => 15
);
}
Original comment by m...@baywind.com.au
on 22 Aug 2013 at 1:19
Well spotted, I'll see if I can come up with a more sturdy solution for mixing
single string inverters with multiple string inverters in the next iteration
Original comment by henrik.m...@gmail.com
on 9 Sep 2013 at 7:20
Original comment by henrik.m...@gmail.com
on 9 Sep 2013 at 7:21
I will be needing this enhancement soon as I put up my third array. Thanks
I doubt I'll find time to look at this for you, but I can assist if you attempt to change the code
ok I will see how I go. My languages are c++ and c# so perl is a bit foreign. will be next week before I get my new panels and I have to build a pergola for them too but after that I will definitely be looking into this. I was also wondering about a 3rd or 4th inverter but again I will have to try it for myself.
Original issue reported on code.google.com by
baywindc...@gmail.com
on 20 Aug 2013 at 8:29