What’s the exact problem?
If I understand it correctly:
- you are setting channel values on component
ess0
. - State-of-Charge (
SOC
) is coming from JSON as"BtSoc":51
and result in51 %
foress0/Soc
- Active Power (
ACTIVE_POWER
) is coming from JSON as"GridPw":0.04
; you convertkW
toW
by multiplying with1000
, resulting in40 W
foress0/ActivePower
- You configured only
ess0
, there is no meter.
Consumption is calculated using this formula: (-> https://github.com/OpenEMS/openems/blob/develop/io.openems.edge.core/src/io/openems/edge/core/sum/SumImpl.java#L359-L360)
this._setConsumptionActivePower(TypeUtils.sum(essActivePowerSum, gridActivePowerSum, productionAcActivePowerSum));
essActivePowerSum
is40
gridActivePowerSum
isnull
(because there is no grid meter configured)productionAcActivePowerSum
isnull
(because there is no production meter configured)
TypeUtils.sum()
calculates 40 + null + null
as 40
As a result 40
is then set as _sum/ConsumptionActivePower
.
Ok?
Regards,
Stefan