Optimizer: allow plan goal to exceed pv limit (#25348)
This commit is contained in:
parent
4f5a8899e9
commit
633f39f3a3
1 changed files with 1 additions and 0 deletions
|
|
@ -222,6 +222,7 @@ func (site *Site) optimizerUpdate(battery []measurement) error {
|
|||
if slot := int(time.Until(ts) / tariff.SlotDuration); slot < minLen && slot >= 0 {
|
||||
bat.SGoal = lo.RepeatBy(minLen, func(_ int) float32 { return 0 })
|
||||
bat.SGoal[slot] = float32(goal)
|
||||
bat.SMax = max(bat.SMax, float32(goal))
|
||||
} else {
|
||||
site.log.DEBUG.Printf("plan beyond forecast range or overrun: %.1f at %v slot %d", goal, ts.Round(time.Minute), slot)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue