void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
Serial.println("Hello, ESP32!");
pinMode(21, INPUT);
pinMode(33, OUTPUT);
pinMode(32, OUTPUT);
}
void loop() {
// put your main code here, to run repeatedly:
delay(10); // this speeds up the simulation
int val=digitalRead(21);
if(val=1) {
digitalWrite(33, HIGH);
}
else{
digitalWrite(32, HIGH);
}
}