0
I have a question about building a menu with buttons. Initially, I have to wait for a button to be pressed. When someone leaves, I have to open the button option pressed. I tried the following, but I was unsuccessful. Anyone have any suggestions?
void loop()
{
int button1 = digitalRead(but1);
int button2 = digitalRead(but2);
while(button1 == LOW && button2 ==LOW){};
while(button1 == HIGH || button2 ==HIGH){
if(button1 == HIGH){
Serial.print("RFID")
rfid_menu();
}
if(button2 == HIGH){
Serial.print("FingerPrint")
fingerprint_menu();
}
};
}