I am completely new to Arduino and am having an issue with my code, which I couldn’t find a solution to in the forums. I was making a program that would trigger an alarm for a set time of that starts at 5 seconds when a motion sensor is triggered. To stop it from going for the whole time something is moving I set a delay of 5 minutes. (as a side note any help with how to delay the alarm without delaying the whole loop would be greatly appreciated) This is all working fine but I also want to be able to change the times with buttons. I have it post to the serial monitor, however when I pressed the buttons nothing happened to the variables, they just stayed constant. Please let me know if I am missing something or should explain something better. Thanks in advance for the help.
Buzzer4.ino (2.5 KB)