ESPEasy with ESP_Easy_mega_20240414_collection_B_ESP32_4M316k is running fine.
i found an ARDUINO code piece and not sure how the setup in Espeasy should be:
Code: Select all
//demonstration for power sense and battery sense
//for Olimex ESP32-POE and ESP32-POE-ISO
//for other boards you might need to change pins in define
//some other boards might require hardware adjustments to
//enable power sense or/and battery sense
#define POWER_SENSE 39
#define BATTERY 35
void setup()
{
Serial.begin (115200);
pinMode (POWER_SENSE, INPUT);
pinMode (BATTERY, INPUT);
}
void loop()
{
Serial.print ("External power sense: ");
Serial.println (digitalRead (POWER_SENSE));
Serial.print ("Battery measurement: ");
Serial.print (analogReadMilliVolts (BATTERY)*2);
Serial.println (" mV");
Serial.println ();
delay (250);
}
At least for POWER_SENSE i get values >4000 when power is provided via USB. A bit wondering as in the script above it uses digitalRead for this.
For the Battery the values are always 0
Any hint how to translate the code into ESPEasy (most probably devices)?