720 if (recipe.MashStep[i].Resttime) |
720 if (recipe.MashStep[i].Resttime) |
721 mashsteps++; |
721 mashsteps++; |
722 } |
722 } |
723 EditInt((char *)"Maisch stappen", &mashsteps, 1, 6); |
723 EditInt((char *)"Maisch stappen", &mashsteps, 1, 6); |
724 EditFloat((char *)"Inmaisch temperatuur", &recipe.MashStep[0].Temperature, 38, 74, 2); |
724 EditFloat((char *)"Inmaisch temperatuur", &recipe.MashStep[0].Temperature, 38, 74, 2); |
725 // Round to 0.25 values |
725 // Round to 0.0625 values |
726 recipe.MashStep[0].Temperature = ((int)(recipe.MashStep[0].Temperature * 4)) / 4.0; |
726 recipe.MashStep[0].Temperature = ((int)(recipe.MashStep[0].Temperature * 16)) / 16.0; |
727 for (int i = 1; i <= mashsteps; i++) { |
727 for (int i = 1; i <= mashsteps; i++) { |
728 sprintf(tmp, "Maisch stap %d naam", i); |
728 sprintf(tmp, "Maisch stap %d naam", i); |
729 EditText(tmp, recipe.MashStep[i].Name, 31); |
729 EditText(tmp, recipe.MashStep[i].Name, 31); |
730 EditMashType(&recipe.MashStep[i].Type); |
730 EditMashType(&recipe.MashStep[i].Type); |
731 sprintf(tmp, "Maisch stap %d temperatuur", i); |
731 sprintf(tmp, "Maisch stap %d temperatuur", i); |
732 if (i == 1) |
732 if (i == 1) |
733 mintemp = recipe.MashStep[0].Temperature - 5; |
733 mintemp = recipe.MashStep[0].Temperature - 5; |
734 else |
734 else |
735 mintemp = recipe.MashStep[i - 1].Temperature; |
735 mintemp = recipe.MashStep[i - 1].Temperature; |
736 EditFloat(tmp, &recipe.MashStep[i].Temperature, mintemp, 74, 2); |
736 EditFloat(tmp, &recipe.MashStep[i].Temperature, mintemp, 74, 2); |
|
737 // Round to 0.25 values |
737 recipe.MashStep[i].Temperature = ((int)(recipe.MashStep[i].Temperature * 4)) / 4.0; |
738 recipe.MashStep[i].Temperature = ((int)(recipe.MashStep[i].Temperature * 4)) / 4.0; |
738 sprintf(tmp, "Maisch stap %d rusttijd in minuten", i); |
739 sprintf(tmp, "Maisch stap %d rusttijd in minuten", i); |
739 EditUint16(tmp, &recipe.MashStep[i].Resttime, 1, 480); |
740 EditUint16(tmp, &recipe.MashStep[i].Resttime, 1, 480); |
740 if (i == 1) { |
741 if (i == 1) { |
741 recipe.MashStep[i].Ramptime = 1; |
742 recipe.MashStep[i].Ramptime = 1; |