June 23, 2024, 07:38:12 AM

Doubts ESP32-POE

Started by Cesarpuig, March 02, 2024, 06:09:49 PM

Previous topic - Next topic

Cesarpuig

Hello.

I want to use ESP32-POE boards and I have some doubts.

1st. I am going to supply the power through the +5 and GND terminals, I am not going to use the USB connector or the Ethernet cable to power, but I am going to use the Ethernet connector to communicate the board. Is the ISO version of the board or the conventional one recommended?


2nd. I want to make a set of digital inputs through pc817c optocouplers, as seen in the image and I have a question as to whether to polarize the optocouplers it is advisable to use the internal pullup resistors of the ESP32 or instead it is advisable to place external resistances?


For example, GPIO35 and GPIO36, I do use external resistors for Pullup because the ESP32 does not have internal resistors for these GPIOs, but for the rest, external or internal?

And what value? For GPIO35 and 36 I am using 10K.

By the way, on a board that I have for testing I think I have damaged the GPIO0, and it no longer works as an input, neither through the opto-aclapper nor by manually exciting it from the ground of the ESP32-POE Sorry, this is not true. What happens is that the ESP that I use for testing is a WROVER, and in this case if you use the Ethernet port, that GPIO is in use. Also, I think this GPIO is used during boot. So another question arises, in the case of the ESP WROOM version, and if I wanted to use this GPIO as input, can I install an external pullup resistor?

A greeting and thanks in advance

LubOlimex

#1
ESP32-POE-ISO is always the better choice. You can have voltage from the potential difference between grounds between board's power supply and Ethernet cable if the network equipment is not good enough (cheaper switch with no transformer in power plug). We've investigated few such cases and it is possible to have more than 30V DC between grounds which might damage ESP32-POE, but will not damage ESP32-POE-ISO. ESP32-POE is good for evaluation of the design but for implementing in own product, especially one that would reach end customers - ESP32-POE-ISO is the better and safer choice.

Your schematic looks alright but specifics would depend on the optocoupler chosen. Just few notes:

GPIO36 is not GPIO. It is just GPI, it can't be output. Same for GPI34, GPI35, GPI39. The naming in our schematics is not a typo, it is according to the datasheet of the ESP32 chip and module.

WROOM and WROVER have two pin difference. If you don't need PSRAM better use WROOM - it has two more GPIOs available (WROVER uses these two pins for the PSRAM). The pin difference can be seen in the schematic in the top right corner of the Ethernet section. In ESP32-POE - when using WROVER module GPIO17 becomes GPIO0 and GPIO16 becomes GPIO33 (since GPIO17 and GPIO16 are used for the PSRAM).

Try with the internal resistors empirically (for the GPIOs that have it), it should be alright in most cases.

The resistors values would depend on the current going trough the LEDs of the optocouplers.
Technical support and documentation manager at Olimex

Cesarpuig

Hello.

The idea of using ESP32-POE instead of the ISO version was to optimize space. The use to which it is intended is domestic and private.

Quote from: LubOlimex on March 04, 2024, 08:29:39 AMTry with the internal resistors empirically (for the GPIOs that have it), it should be alright in most cases.

I have tested the optocouplers with the internal resistors and they work. Is there any downside to placing them externally anyway?

Quote from: LubOlimex on March 04, 2024, 08:29:39 AMThe resistors values would depend on the current going trough the LEDs of the optocouplers.

The intensity that I am circulating through the optoaclocator LEDS is 10ma

Thank you.

Cesarpuig

Sorry

Quote from: LubOlimex on March 04, 2024, 08:29:39 AMESP32-POE-ISO is always the better choice. You can have voltage from the potential difference between grounds between board's power supply and Ethernet cable if the network equipment is not good enough (cheaper switch with no transformer in power plug). We've investigated few such cases and it is possible to have more than 30V DC between grounds which might damage ESP32-POE...

Another question that arises for me. If I am not going to use POE power, would it be enough to wire tx+, tx-, rx+, rx- in the Ethernet conductor? And would this solve the problem of the voltage difference between grounds?

Thank you

LubOlimex

That's the thing parasitic influence can occur via the data wires too.
Technical support and documentation manager at Olimex

KeviNH

For my application, when deployed the ESP32-POE will be in a case which only exposes the Ethernet port, and will always be powered only by PoE in the field.   I use the USB-ISO for initial programming (loading my code which includes OTA updating).

Quote from: Cesarpuig on March 04, 2024, 12:25:01 PMIf I am not going to use POE power, would it be enough to wire tx+, tx-, rx+, rx- in the Ethernet conductor? And would this solve the problem of the voltage difference between grounds?
Yes, and no.

Communications using 10/100BASE-TX uses the two pairs on pins 1–2, 3–6 for data.

Even with just two pairs wired up, you still have a ground path because the ESP32-POE supports both PoE Mode A (power over data pairs) and Mode B (power over spare pairs).

LubOlimex

Yes, what Kevin wrote - it is highly recommended to have USB-ISO or similar product between ESP32-POE boards and your computer or power supply, this would reduce changes of influence between LAN and the USB. We also use USB-ISOs in our tests setups for ESP32-POE (each ESP32-POE is tested here).
Technical support and documentation manager at Olimex

Cesarpuig

Hello @KeviNH @LubOlimex and thanks to both of you.

Decided, I will mount ESP32-POE-ISO WROOM. There are quite a few plates I have to make and it's not worth the risk.

What current is necessary to activate an ESP32 input? In order to calculate the resistance on the transistor side of the optocoupler.

I am not going to use GPIO0 at first, but I want to leave it ready in case it is necessary. It is used during the board's startup. Could it be a problem to install an external pullup resistor? Could it affect startup?

Thank you.

LubOlimex

10kOhm is alright. Current 50nA at least that info can be seen in the user manual for the ESP32 chip in "DC Characteristics" table.

GPIO0 should NOT be pulled-down during power-up or reboot or your code won't execute, you will set the board in different mode. This is visible in the bootable in the schematic.
Technical support and documentation manager at Olimex

Cesarpuig

Quote from: LubOlimex on March 05, 2024, 12:53:07 PMGPIO0 should NOT be pulled-down during power-up or reboot or your code won't execute, you will set the board in different mode. This is visible in the bootable in the schematic.

My intention is not to do a pulldown, but quite the opposite, a pullup. But anyway I will do previous tests.

Thank you very much for the time dedicated and the support provided.

Cesarpuig

Sorry, one more question, the EA version of the board incorporates an external antenna, is this antenna for Wi-Fi, for Bluetooth, or both? All the best.

LubOlimex

Yes, the WIFI and Bluetooth use the same antenna (no matter if it is the on-board PCB antenna or an external antenna).
Technical support and documentation manager at Olimex