This is the whole coding for the simon game. I am curious about how the code flow since each function do not return anything. And I am curious about this part:
void input()
{
for (int x=0; x <= turn;)
{
input1 = digitalRead(SWITCHROOT);
input2 = digitalRead(SWITCHROOT+1);
input3 = digitalRead(SWITCHROOT+2);
input4 = digitalRead(SWITCHROOT+3);
counter++;
if (counter > RESPONSETIME)
{
Serial.println("TIMEOUT!");
fail(randomArray[x]);
counter = 0;
x++;
}
Does that means that we need to respond faster as the counter increases ?
Thanks