Compare commits

..

2 Commits

Author SHA1 Message Date
e214e5b59d gradual profile 2024-09-02 23:17:26 +07:00
d3ab0202fa output power fixed 2024-09-02 00:39:39 +07:00

View File

@ -47,6 +47,7 @@ struct Profile {
Profile profiles[] = {
{"Chickpeas", 3, {{47, 120}, {53, 120}, {65, 180}, {72, 90}, {90, 90}}, 5},
{"Lentils", 3, {{47, 120}, {53, 120}, {65, 180}, {72, 90}, {90, 15}}, 5},
{"Lentils: Gradual", 10, {{48, 120}, {80, 60}}, 2},
{"Wheat", 3, {{47, 60}, {53, 60}, {65, 20}, {72, 20}, {85, 20}}, 5},
{"Veggies Sous Vide", 2, {{55, 30}, {85, 120}}, 2},
{"Test", 1, {{49, 1}, {51, 1}}, 2},
@ -85,11 +86,13 @@ char timeBuffer[10];
void setup() {
pinMode(ssrPin, OUTPUT);
Serial.begin(9600);
oled.init(); // Initialize the OLED
oled.clear(); // Clear the display
readEEPROM();
myPID.SetMode(AUTOMATIC);
myPID.SetOutputLimits(0, 1);
}
void loop() {
@ -274,7 +277,7 @@ void printPhases() {
formatTime((currentTime - finishTime) / 1000, timeBuffer); // Time since completion
oled.print(timeBuffer);
oled.print(" ");
oled.print(Input,1);
oled.print(Input,0);
oled.print("c");
oled.print("->");
oled.print((int)Setpoint);
@ -296,7 +299,6 @@ void printPhases() {
oled.print(timeBuffer);
oled.print(" ");
for (int i = 0; i < activeProfile.numPhases; i++) {
if (i == currentPhase) {
oled.invertText(true); // Invert text for the current phase
@ -335,8 +337,8 @@ void printPhases() {
oled.invertText(false); // Ensure text inversion is off after the loop
oled.setCursor(110,7);
oled.print(Output*100,0);
oled.print(" ");
sprintf(timeBuffer, "%3d", (int)(Output*100));
oled.print(timeBuffer);
oled.update();
}