One ESP32's 3v3 is connected to GPIO 26 of another ESP32. The program is uploaded. The built-in LED lights for two seconds as expected. Then, it turns off. No matter what GPIO pin the 3v3 is connected to (besides 2), the LED remains off.
/*
* ON Board LED GPIO 2
*/
#define LED 2
#define inPin 26
void setup()
{
Serial.begin(9600);
// Pins 34, 35, 36, 39 are input only
pinMode(LED, OUTPUT);
// Sanity check LED works
digitalWrite(LED, HIGH);
delay(2000);
}
void loop()
{
Serial.println(digitalRead(inPin));
digitalWrite(LED, digitalRead(inPin));
}
Any reason this is happening? Grounds are connected. Simply trying to turn LED on/off if external voltage occurs at any GPIO pin (e.g., 26).