Hello,
First of all I only had programming in School and that's been a few years ago now.
Anyway I mostly undestand the code other people have written, but i have a hard time doing things on my own, so let's get to the problem:
I tried to fill an array with the input of the keypad:
for ( int v=0; v<4;v++){
int key = keypad.getKey();
if (key != NO_KEY)
{
xyz[v] = key -48;
Serial.println(xyz[v]);
delay(2000);
}
}
the array is [0, 0, 0, 0] before the loop starts. I've put in a Serial.println(v); before the if statement. It shows that the for loop doesn't wait for the if and just keeps on repeating. I don't know how to solve this. Can anyone give me a hint what I'm doing wrong?
Thanks