Skip to content

Commit

Permalink
Fix ActivePower-bug for ProPvMeter
Browse files Browse the repository at this point in the history
This bug caused the monitoring to not show anymore data for pv production. The problem is caused by the lower case naming "activePower" introduced in commit 46b0cc0
  • Loading branch information
sfeilmeier committed Aug 10, 2017
1 parent 7492bdf commit 704c4bb
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions edge/src/io/openems/impl/device/pro/FeneconProPvMeter.java
Original file line number Diff line number Diff line change
Expand Up @@ -200,23 +200,23 @@ protected ModbusProtocol defineModbusProtocol() throws ConfigException {
activeEnergyL1 = new ModbusReadLongChannel("ActiveEnergyL1", this)
.unit("Wh").multiplier(2)),
new DummyElement(2037, 2065), new UnsignedWordElement(2066, //
orginalActivePowerL1 = new ModbusReadLongChannel("ActivePowerL1", this).unit("W")
.delta(10000L))),
orginalActivePowerL1 = new ModbusReadLongChannel("OriginalActivePowerL1", this)
.unit("W").delta(10000L))),
new ModbusRegisterRange(2135, //
new UnsignedDoublewordElement(2135, //
activeEnergyL2 = new ModbusReadLongChannel("ActiveEnergyL2", this).unit(
"Wh").multiplier(2)),
activeEnergyL2 = new ModbusReadLongChannel("ActiveEnergyL2", this)
.unit("Wh").multiplier(2)),
new DummyElement(2137, 2165), new UnsignedWordElement(2166, //
orginalActivePowerL2 = new ModbusReadLongChannel("ActivePowerL2", this).unit("W")
.delta(10000L))),
orginalActivePowerL2 = new ModbusReadLongChannel("OriginalActivePowerL2", this)
.unit("W").delta(10000L))),
new ModbusRegisterRange(2235, //
new UnsignedDoublewordElement(2235, //
activeEnergyL3 = new ModbusReadLongChannel("ActiveEnergyL3", this)
.unit("Wh").multiplier(2)),
new DummyElement(2237, 2265), new UnsignedWordElement(2266, //
orginalActivePowerL3 = new ModbusReadLongChannel("ActivePowerL3", this).unit("W")
.delta(10000L))));
activePowerL1 = new FunctionalReadChannel<Long>("activePowerL1", this, (channels) -> {
orginalActivePowerL3 = new ModbusReadLongChannel("OriginalActivePowerL3", this)
.unit("W").delta(10000L))));
activePowerL1 = new FunctionalReadChannel<Long>("ActivePowerL1", this, (channels) -> {
ReadChannel<Long> power = channels[0];
try {
if (power.value() >= 0) {
Expand All @@ -228,7 +228,7 @@ protected ModbusProtocol defineModbusProtocol() throws ConfigException {
return null;
}
}, orginalActivePowerL1);
activePowerL2 = new FunctionalReadChannel<Long>("activePowerL2", this, (channels) -> {
activePowerL2 = new FunctionalReadChannel<Long>("ActivePowerL2", this, (channels) -> {
ReadChannel<Long> power = channels[0];
try {
if (power.value() >= 0) {
Expand All @@ -240,7 +240,7 @@ protected ModbusProtocol defineModbusProtocol() throws ConfigException {
return null;
}
}, orginalActivePowerL2);
activePowerL3 = new FunctionalReadChannel<Long>("activePowerL3", this, (channels) -> {
activePowerL3 = new FunctionalReadChannel<Long>("ActivePowerL3", this, (channels) -> {
ReadChannel<Long> power = channels[0];
try {
if (power.value() >= 0) {
Expand All @@ -252,7 +252,7 @@ protected ModbusProtocol defineModbusProtocol() throws ConfigException {
return null;
}
}, orginalActivePowerL3);
activePower = new FunctionalReadChannel<Long>("activePower", this, (channels) -> {
activePower = new FunctionalReadChannel<Long>("ActivePower", this, (channels) -> {
ReadChannel<Long> L1 = channels[0];
ReadChannel<Long> L2 = channels[1];
ReadChannel<Long> L3 = channels[2];
Expand All @@ -262,7 +262,7 @@ protected ModbusProtocol defineModbusProtocol() throws ConfigException {
return null;
}
}, activePowerL1, activePowerL2, activePowerL3);
reactivePower = new FunctionalReadChannel<Long>("reactivePower", this, (channels) -> {
reactivePower = new FunctionalReadChannel<Long>("ReactivePower", this, (channels) -> {
ReadChannel<Long> L1 = channels[0];
ReadChannel<Long> L2 = channels[1];
ReadChannel<Long> L3 = channels[2];
Expand Down

0 comments on commit 704c4bb

Please sign in to comment.