diff --git a/csharp/App/SaliMax/src/Program.cs b/csharp/App/SaliMax/src/Program.cs index 52554cb11..8a857c7db 100644 --- a/csharp/App/SaliMax/src/Program.cs +++ b/csharp/App/SaliMax/src/Program.cs @@ -223,6 +223,8 @@ internal static class Program dcDevices.ForEach(d => d.Control.CurrentControl.MaxBatteryChargingCurrent = configFile.MaxBatteryChargingCurrent); dcDevices.ForEach(d => d.Control.CurrentControl.MaxBatteryDischargingCurrent = configFile.MaxBatteryDischargingCurrent); + dcDevices.ForEach(d => d.Control.MaxDcPower = configFile.MaxDcPower); + dcDevices.ForEach(d => d.Control.VoltageLimits.MaxBatteryVoltage = configFile.MaxChargeBatteryVoltage); dcDevices.ForEach(d => d.Control.VoltageLimits.MinBatteryVoltage = configFile.MinDischargeBatteryVoltage); dcDevices.ForEach(d => d.Control.ControlMode = DcControlMode.VoltageDroop); diff --git a/csharp/App/SaliMax/src/SystemConfig/Config.cs b/csharp/App/SaliMax/src/SystemConfig/Config.cs index d6c7be511..e57a3d5dd 100644 --- a/csharp/App/SaliMax/src/SystemConfig/Config.cs +++ b/csharp/App/SaliMax/src/SystemConfig/Config.cs @@ -22,8 +22,11 @@ public class Config //TODO: let IE choose from config files (Json) and connect t public required Double HoldSocZone { get; set; } public required DevicesConfig IslandMode { get; set; } public required DevicesConfig GridTie { get; set; } + public required Double MaxBatteryChargingCurrent { get; set; } public required Double MaxBatteryDischargingCurrent { get; set; } + public required Double MaxDcPower { get; set; } + public required Double MaxChargeBatteryVoltage { get; set; } public required Double MinDischargeBatteryVoltage { get; set; } @@ -76,10 +79,12 @@ public class Config //TODO: let IE choose from config files (Json) and connect t }, }, - MaxBatteryChargingCurrent = 210, - MaxBatteryDischargingCurrent = 210, - MaxChargeBatteryVoltage = 57, - MinDischargeBatteryVoltage = 0, + MaxBatteryChargingCurrent = 210, + MaxBatteryDischargingCurrent = 210, + MaxDcPower = 10000, + + MaxChargeBatteryVoltage = 57, + MinDischargeBatteryVoltage = 0, Devices = new () { TruConvertAcIp = new() { Host = "localhost", Port = 5001}, @@ -139,6 +144,8 @@ public class Config //TODO: let IE choose from config files (Json) and connect t MaxBatteryChargingCurrent = 210, MaxBatteryDischargingCurrent = 210, + MaxDcPower = 10000, + MaxChargeBatteryVoltage = 57, MinDischargeBatteryVoltage = 0, S3 = new()