Skip to content

Commit

Permalink
fix surplus charging for pv charging - submode instant charging (open…
Browse files Browse the repository at this point in the history
…WB#1950)

* fix surplus charging for pv charging - submode instant charging

* amend
  • Loading branch information
LKuemmel authored Oct 14, 2024
1 parent f4ec86b commit 8cdbe88
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/control/algorithm/surplus_controlled.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,13 @@ def phase_switch_necessary() -> bool:
control_parameter.required_currents = [0]*3

def check_switch_on(self) -> None:
for cp in get_chargepoints_by_chargemodes(CONSIDERED_CHARGE_MODES_SURPLUS):
for cp in get_chargepoints_by_chargemodes(CONSIDERED_CHARGE_MODES_PV_ONLY):
if (cp.data.control_parameter.state == ChargepointState.NO_CHARGING_ALLOWED or
cp.data.control_parameter.state == ChargepointState.SWITCH_ON_DELAY):
data.data.counter_all_data.get_evu_counter().switch_on_threshold_reached(cp)

def set_required_current_to_max(self) -> None:
for cp in get_chargepoints_by_chargemodes(CONSIDERED_CHARGE_MODES_PV_ONLY):
for cp in get_chargepoints_by_chargemodes(CONSIDERED_CHARGE_MODES_SURPLUS):
charging_ev_data = cp.data.set.charging_ev_data
required_currents = cp.data.control_parameter.required_currents
control_parameter = cp.data.control_parameter
Expand Down

0 comments on commit 8cdbe88

Please sign in to comment.