I am working on a project and I need some LEDs to turn on and off in a cycle. I am currently using delays to do this task, but I also need to be able to read button presses while the LEDs are going through the cycle so I need to use millis instead. Can anyone help me with what the equivalent code for this would, using millis() (no delays)? Please explain the logic behind it as well! I've already looked at the "Blink Without Delay" tutorial and it didn't really help me out much.
digitalWrite(bluePin1, LOW);
digitalWrite(yellowPin1, HIGH);
delay(7000);
digitalWrite(yellowPin1, LOW);
digitalWrite(greenPin1, HIGH);
delay(2000);
digitalWrite(greenPin1, LOW);
digitalWrite(bluePin1, HIGH);
delay(3000);