public HotWater(IStateService stateService, ISerialCommunicationService serialCommunicationService, OilBurner oilBurner) { StateService = stateService; SerialCommunicationService = serialCommunicationService; OilBurner = oilBurner; InitFsm(); }
public HeatingCircuit(IStateService stateService, ISerialCommunicationService serialCommunicationService, OilBurner oilBurner) { SerialCommunicationService = serialCommunicationService; OilBurner = oilBurner; StateService = stateService; InitFsm(); }
private bool IsBoilerToHeatByBurner() { if (!OilBurner.IsReady()) { return(false); } return(StateService.GetSensor(ItemEnum.BoilerTop).Value <= BOILER_COLD); }
private (bool, string) IsntBoilerToHeatByBurner() { if (OilBurner.IsHeatedToReady().Item1) { return(false, "OilBurner is ready"); } return(true, "Oilburner is too cold"); }
private (bool, string) IsAllResidualHeatUsed() { if (OilBurner.IsBurnerNeededByHotWater) { return(true, "No use of residual heat, because burner is used by HotWater"); } var(isOilBurnerCooled, message) = OilBurner.IsCooledToReady(); var temperature = StateService.GetSensor(SensorName.HmoLivingroomFirstFloor).Value; return(isOilBurnerCooled, $"IsAllResidualHeatUsed: LivingRoom: {temperature}, {message}"); }
private (bool, string) IsBoilerToHeatByBurner() { if (!OilBurner.IsHeatedToReady().Item1) { return(false, "OilBurner isn't ready"); } var temperature = StateService.GetSensor(SensorName.BoilerTop).Value; if (temperature <= BOILER_COLD) { return(true, $"Boiler is to heat by burner: {temperature}"); } return(false, ""); }
public bool IsCooledDown() => OilBurner.IsCooledDown();
private bool IsBurnerTooHot() => OilBurner.IsTooHot();
public bool IsBurnerCold() => OilBurner.IsCold();
private bool IsBurnerReady() => OilBurner.IsReady();
public bool IsntBurnerToCool() => OilBurner.IsCooledDown();
private (bool, string) IsBurnerReady() => OilBurner.IsHeatedToReady();
public (bool, string) IsCooledDown() => OilBurner.IsCooledToHot();
private (bool, string) IsBurnerTooHot() => OilBurner.IsHeatedToTooHot();
public (bool, string) IsBurnerCold() => OilBurner.IsCooledToCold();
public (bool, string) IsntBurnerToCool() => OilBurner.IsCooledToHot();