Skip to content

Commit

Permalink
Implement heated mixing state
Browse files Browse the repository at this point in the history
  • Loading branch information
acodili-jg committed May 11, 2024
1 parent d8082a6 commit 3c0ed80
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/duration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@ macro_rules! constants {
constants! {
DEFAULT_LONG = Millis(5000);
DEFAULT = Millis(2000);
DEFAULT_SHORT = Millis(250);
DEFAULT_SHORT = Millis(500);

DRAINING = DEFAULT_LONG;
HEATED_MIXING = DEFAULT;
HEATING = DEFAULT_LONG;
LOCKING = DEFAULT_SHORT;
SEPARATOR_TRANSITION = DEFAULT;
Expand Down
12 changes: 12 additions & 0 deletions src/sketch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,18 @@ impl Sketch {
self.mixer.set_high();
}

State::SoakWaterHeatedMixing if stop => {
transition_to!(SoakWaterDraining);
self.heater.set_low();
self.mixer.set_low();
self.upper_drain_pump.set_high();
}
State::SoakWaterHeatedMixing if delta_ms < duration::HEATED_MIXING => {}
State::SoakWaterHeatedMixing => {
transition_to!(SoakWaterMixing);
self.heater.set_low();
}

_ => { /* TODO */ }
}
}
Expand Down

0 comments on commit 3c0ed80

Please sign in to comment.