What pins to use for a Wiegand card reader on an ESP32-EVB ?

Started by GeorgeFlorian, February 13, 2023, 01:26:23 PM

Previous topic - Next topic

GeorgeFlorian

I am using https://github.com/me-no-dev/ESPAsyncWebServer on an ESP32-EVB in a project that also uses the following library to read Wiegand Cards https://github.com/paulo-raca/YetAnotherArduinoWiegandLibrary.

I investigated and found that after accessing/refreshing the web interface or navigating to another page the first card reading is also an error.
Whenever I comment the Server Routine, so basically running the project without an HTTP server, the Wiegand cards are read perfectly.

So I came to the conclusion that after each Server "initialization " the first card reading is always an error.

The input pins that I've tried are GPIO 13,14,15 and 17, because others are, well, unavailable.

But looking at the ESP32 docs: https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-reference/peripherals/gpio.html these pins have other uses:

GPIO13 - ADC2_CH4
GPIO14 - ADC2_CH6
GPIO15 - ADC2_CH3
GPIO17 - SPI0/1

SPI0/1: GPIO6-11 and GPIO16-17 are usually connected to the SPI flash and PSRAM integrated on the module and therefore should not be used for other purposes.
ADC2: ADC2 pins cannot be used when Wi-Fi is used.

And this got me thinking that I get an error when there is network communications and that maybe this is a GPIO related issue.

The problem is that I only have ESP32-EVB available to me right now and I can't test with something else.

I will get my hands on a "simpler" ESP32 board with more free GPIOs and test this, but in the meantime I would like some confirmation or some thoughts on this matter.

What about GPI pins like GPI 34, 35, 36, 37, 38 and 39 ?
GPI 34 - BTN1
GPI 35 - CAN-RX
GPI 36 - SENSOR_VP/ADC_H/ADC1_CH0/RTC_GPIO/U1RXD
GPI 37 - Couldn't find it in the schematics
GPI 38 - Couldn't find it in the schematics
GPI 39 - SENSOR_VN/ADC1_CH3/ADC_H/RTC_GPIO3/IR_RECEIVE

Also, what about the ESP32-POE ? Does it really have more free pins, because it doesn't look like that. Also if you power the ESP32-POE using POE, what voltage will the GPIO have ? 3.3V or 5V ?

LubOlimex

ESP32-GATEWAY, ESP32-POE, ESP32-POE-ISO have more free pins compared to ESP32-EVB. The point of ESP32-EVB was to leave as little free pins as possible to demonstrate more of the ESP32 chip capabilities. It was our first ESP32 release.
Technical support and documentation manager at Olimex