diff --git a/src/main.cpp b/src/main.cpp index bd237e1..b458e5b 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -342,8 +342,8 @@ void loop() } if (buttonLeft.isJustPressed()) { - // decrease steeping time for next brew - state = State::WAIT_FOR_RFID_SCAN; + // decrease steeping time for next brew // TODO: this should be smarter + currentTea.m_steepingSeconds -= 10; String payload = teaNet.bundleSteepingTimeChange(currentTea.m_steepingSeconds); Serial.println(payload); @@ -356,13 +356,15 @@ void loop() delay(1000); break; } + state = State::WAIT_FOR_RFID_SCAN; smartDisplay.playTeaAnimationPartTwo(32, "", "Done!", "", ""); smartStrip.reset(); } if (buttonRight.isJustPressed()) { - // increase steeping time for next brew - state = State::WAIT_FOR_RFID_SCAN; + // increase steeping time for next brew // TODO: this should be smarter + currentTea.m_steepingSeconds += 10; + String payload = teaNet.bundleSteepingTimeChange(currentTea.m_steepingSeconds); Serial.println(payload); @@ -375,6 +377,7 @@ void loop() delay(1000); break; } + state = State::WAIT_FOR_RFID_SCAN; smartDisplay.playTeaAnimationPartTwo(32, "", "Done!", "", ""); smartStrip.reset(); }