diff --git a/hems/semp/semp.go b/hems/semp/semp.go index 9f43ae655..1632d0153 100644 --- a/hems/semp/semp.go +++ b/hems/semp/semp.go @@ -366,9 +366,14 @@ func (s *SEMP) deviceStatus(id int, lp core.LoadPointAPI) DeviceStatus { } } + var hasVehicle bool + if hasVehicleP, err := s.cache.GetChecked(id, "hasVehicle"); err == nil { + hasVehicle = hasVehicleP.Val.(bool) + } + res := DeviceStatus{ DeviceID: s.deviceID(id), - EMSignalsAccepted: s.controllable && isPV, + EMSignalsAccepted: s.controllable && isPV && hasVehicle, PowerInfo: PowerInfo{ AveragePower: int(chargePower), AveragingInterval: 60, @@ -433,7 +438,7 @@ func (s *SEMP) planningRequest(id int, lp core.LoadPointAPI) (res PlanningReques if mode == api.ModeNow { minPowerConsumption = maxPowerConsumption } - + if connected && maxEnergy > 0 { res = PlanningRequest{ Timeframe: []Timeframe{{