slipx06 / sunsynk-power-flow-card

⚡A customizable Home Assistant card to emulate the Sunsynk System flow that's displayed on the Inverter screen.
MIT License
207 stars 56 forks source link

Remaining battery energy #554

Open flopp999 opened 3 hours ago

flopp999 commented 3 hours ago

Is there an existing issue for this?

Current Behavior

image It says remaining is 3.6 kWh but actually I only have 0.6 kWh left because my battery will stop discharge at 10%. I have set my SoC end to 10%. I have 30000 Wh.

Expected behaviour

Showing 0 kWh remain when SoC is at 10%

Possible Solutions

I searched through the code but I couldn't find where the math is done. But remove SoC End before calculate the remaining kWh

Mode

lite

Context / Reason

So users don't think there is more kWh than there are

flopp999 commented 3 hours ago

Found it in the code, I will try to make the math as I asking for https://github.com/slipx06/sunsynk-power-flow-card/blob/706f6f14dbdee815c36edee5457148f7c081c33e/src/cards/full-card.ts#L343