#define btn_act_low 2
#define btn_act_high 15
void setup() {
// put your setup code here, to run once:
pinMode(btn_act_low, INPUT);
pinMode(btn_act_high, INPUT);
Serial.begin(9600);
}
void loop() {
// put your main code here, to run repeatedly:
int btn_act_low_state = digitalRead(btn_act_low);
int btn_act_high_state = digitalRead(btn_act_high);
if(btn_act_low_state == LOW){
Serial.println("Button Active Low is pressed!");
delay(200); //avoid debounce
}
if(btn_act_high_state == HIGH){
Serial.println("Button Active High is pressed!");
delay(200); //avoid debounce
}
}