- Use “MATLAB function” block to evaluate the sign of the LFC signal and decide whether to charge or discharge the EV battery.
- Apply conditions like “energy < E_max”(maximum battery capacity) and “energy > E_min” (minimum battery capacity) to control the charging and discharging switches.
Can any one help? how to develop the code or logic for electric vehicle charging and discharging limits as mentioned in picture and what should be the values of threshold.
조회 수: 3 (최근 30일)
이전 댓글 표시
Can any one help? how to develop the code or logic for electric vehicle charging and discharging limits as mentioned in picture and what should be the values of threshold.
댓글 수: 0
채택된 답변
MULI
2024년 9월 13일
Hi Imran,
I understand that you are asking about the logic that controls the charging and discharging limits of electric vehicles (EVs) based on the Load Frequency Control (LFC) signal and battery energy levels.
You can follow the below steps to achieve this:
function delta_pe = ev_logic(lfc_signal, energy, E_max, E_min)
% Logic for controlling charging and discharging
if lfc_signal < 0 && energy < E_max
% Charging
delta_pe = charge_power;
elseif lfc_signal > 0 && energy > E_min
% Discharging
delta_pe = -discharge_power;
else
% No charging or discharging
delta_pe = 0;
end
end
E_max: 90% of the EV battery capacity. This prevents overcharging by stopping the charging process when the battery reaches 90% capacity.
E_min: 80% of the EV battery capacity. This prevents over-discharging by stopping discharging when the battery depletes to 80%.
These values can be adjusted based on specific EV battery characteristics or system requirements.
You can refer to this link for battery electric vehicle model in simscape
댓글 수: 0
추가 답변 (0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!