diff --git a/wash/src/wash/control/ControllerSpin.java b/wash/src/wash/control/ControllerSpin.java index 5396334..1ad3e14 100644 --- a/wash/src/wash/control/ControllerSpin.java +++ b/wash/src/wash/control/ControllerSpin.java @@ -28,7 +28,8 @@ public final class ControllerSpin extends ActorThread { while (true) { try { temp = receiveWithTimeout(10000 / Settings.SPEEDUP); - elapsed = ((System.currentTimeMillis() - start) * (Settings.SPEEDUP) / 1000 * 60); + elapsed = ((System.currentTimeMillis() - start) * Settings.SPEEDUP) / (1000 * 60); + System.out.println(elapsed); // If there is a new message, swap if (temp != null) { diff --git a/wash/src/wash/program/WashingProgram3.java b/wash/src/wash/program/WashingProgram3.java index 79ee344..40ffd91 100644 --- a/wash/src/wash/program/WashingProgram3.java +++ b/wash/src/wash/program/WashingProgram3.java @@ -52,6 +52,9 @@ public final class WashingProgram3 extends ActorThread { water.send(new WashingMessage(this, WATER_DRAIN)); receive(); + water.send(new WashingMessage(this, WATER_IDLE)); + receive(); + // Unlock hatch io.lock(false);