示例#1
0
        /// <summary> Get a Recipe from the BrewTroller </summary>
        /// <param name="recipeSlot">Recipe Slot Number</param>
        public BTRecipe GetRecipe(int recipeSlot)
        {
            if (recipeSlot < 0 || recipeSlot >= BTConfig.NumberOfRecipes)
                throw new ArgumentOutOfRangeException("recipeSlot");

            var btRecipe = new BTRecipe(Version.Units);
            ProcessBTCommand(BTCommand.GetRecipe, btRecipe, new List<int> { recipeSlot });
            return btRecipe;
        }
示例#2
0
        /// <summary> Send a recipe to the BrewTroller </summary>
        /// 
        public void SetRecipe(BTRecipe btRecipe)
        {
            if (btRecipe.Slot < 0 || btRecipe.Slot >= BTConfig.NumberOfRecipes)
                throw new ArgumentOutOfRangeException("recipeSlot");

            ProcessBTCommand(BTCommand.SetRecipe, btRecipe, null);
        }
示例#3
0
        private BTRecipe CreateTestRecipe(int slot, BTUnits units)
        {
            var recipe = new BTRecipe(units);
            recipe.Name = "NUnit Test Recipe";

            recipe.PreHeat.step_time.Value = 10;
            recipe.PreHeat.step_temperature.Value = 120;
            recipe.DoughIn.step_time.Value = 11;
            recipe.DoughIn.step_temperature.Value = 130;
            recipe.AcidRest.step_time.Value = 12;
            recipe.AcidRest.step_temperature.Value = 140;
            recipe.ProteinRest.step_time.Value = 13;
            recipe.ProteinRest.step_temperature.Value = 150;
            recipe.Sacch1Rest.step_time.Value = 14;
            recipe.Sacch1Rest.step_temperature.Value = 160;
            recipe.Sacch2Rest.step_time.Value = 15;
            recipe.Sacch2Rest.step_temperature.Value = 170;
            recipe.MashOut.step_time.Value = 16;
            recipe.MashOut.step_temperature.Value = 180;

            recipe.SpargeTemp.Value = 150;
            recipe.HLTSetpoint.Value = 121;
            recipe.MashHeatSource = BTVesselID.HLT;
            recipe.MashRatio = 1.05m;
            recipe.BatchVolume.Value = 65.5m;
            recipe.GrainWeight.Value = 2.34m;
            recipe.BoilTime.Value = 63;
            recipe.PitchTemp.Value = 144;
            recipe.Additions = 0x55;

            return recipe;
        }