Olimex Support Forum

Microcontrollers => ESP32 => Topic started by: moe.szyslak on July 06, 2021, 06:52:20 PM

Title: ESP-POE using ESPHome not working via POE
Post by: moe.szyslak on July 06, 2021, 06:52:20 PM
Hi,

I am using an ESP-POE controller to read two ultrasonic sensors. The code is generated using ESPHome (so basically platform.io). The two sensors are both connected to 5V and GND and then each to two GPIO pins (GPIO2 & GPIO3 and GPIO4 & GPIO5) for ECHO and TRIGGER. The setup works fine when powered via USB but it only reads one sensor when powered by POE. Do I need to configure something or am I using the wrong GPIOs or something?

Thanks for your help and best regards,

Moe
Title: Re: ESP-POE using ESPHome not working via POE
Post by: LubOlimex on July 07, 2021, 09:22:47 AM
GPIO4 and GPIO5 are used by the Ethernet, when you plug something in the Ethernet port they will become unavailable. Use other free pins for it. Make sure to check the schematics and the pinout here:

https://www.olimex.com/Products/IoT/ESP32/ESP32-POE/open-source-hardware

Edit: GPIO4 and GPIO5 seem free for ESP32-POE, can't say the same for GPIO2 and GPIO3.
Title: Re: ESP-POE using ESPHome not working via POE
Post by: moe.szyslak on July 07, 2021, 06:10:38 PM
Thanks for your quick reply.

I switched GPIOs from 4 & 5 to 13 & 14, but it's actually the sensor on 2 & 3 that is not working. So I switched that to 15 & 16 and now it works.

So 4 & 5 actually worked when using ethernet + USB power and PoE, while 2 & 3 just didn't work using PoE.
Title: Re: ESP-POE using ESPHome not working via POE
Post by: BMOD on August 06, 2021, 11:12:31 AM
Quote from: LubOlimex on July 07, 2021, 09:22:47 AMGPIO4 and GPIO5 are used by the Ethernet, when you plug something in the Ethernet port they will become unavailable.

Hi LubOlimex,

I am wondering about GPIO4 and GPIO5. I am also accidentally using this pins and it seems to work with PoE.
I have also checked the schematic (https://raw.githubusercontent.com/OLIMEX/ESP32-POE-ISO/master/HARDWARE/ESP32-PoE-ISO-Rev.D/ESP32-PoE-ISO_Rev_D.pdf) and I cannot see that this GPIOs are connected to the ethernet controller. Or am I missing something?
Title: Re: ESP-POE using ESPHome not working via POE
Post by: LubOlimex on August 25, 2021, 09:40:41 AM
You wrote that you have ESP32-POE in the title and the first post of this thread, but you are linking the schematic of ESP32-POE-ISO.These are different designs with different schematics.

Do you have ESP32-POE or ESP32-POE-ISO?
Title: Re: ESP-POE using ESPHome not working via POE
Post by: BMOD on September 02, 2021, 04:20:07 PM
Sorry it was my fault... I am not the thread opener, I am just an interested reader.
Title: Re: ESP-POE using ESPHome not working via POE
Post by: stif on November 26, 2021, 01:38:41 PM
Hi LubOlimex,

i stumbled on this Thread and also wondering about using Pin 4 & 5 and Ethernet on the ESP32-PoE.

i checked the schematics (https://raw.githubusercontent.com/OLIMEX/ESP32-POE/master/HARDWARE/ESP32-PoE-hardware-revision-G1/ESP32-PoE_Rev_G1.pdf) and did not find any hints, that pin 4 & 5 are used for ethernet. i can only see GPIO 12,17,18,19,21,22,23,25,26 and 27 are used for ehternet (and they are not available via pinheader anyway).

also in the GPIO  Picture File (https://www.olimex.com/Products/IoT/ESP32/ESP32-POE/resources/ESP32-POE-GPIO.png) there is no mention to not use pin 4&5..

in fact i have some projects where i am sucessfully using pin 4 & 5 and poe ethernet with the ESP32-PoE..

so i am expected to see some issues from time to time, or is it ok to use these pins?
Title: Re: ESP-POE using ESPHome not working via POE
Post by: LubOlimex on November 26, 2021, 01:55:02 PM
Nah, GPIO4 and GPIO5 should be fine and free. I made a mistake there, it was GPIO2 and GPIO3 that were used for SD card and UART debug. Will strike trough my previous post.
Title: Re: ESP-POE using ESPHome not working via POE
Post by: stif on November 26, 2021, 02:12:59 PM
ok, thanks for clarification