Search found 4 matches

by stijnb1234
Mon Apr 22, 2024 11:37 am
Forum: ESP-IDF
Topic: UART Modbus Read response
Replies: 1
Views: 583

UART Modbus Read response

I'm trying to send a 0x03 Read holding registers request as a Modbus master to the listening slaves. What is the best way to send a request (the read request), wait for the response, and then read it? I'm stuck at waiting for the response. Could you please help me further? I tried a fixed delay, but...
by stijnb1234
Fri Mar 01, 2024 8:26 am
Forum: Hardware
Topic: GPIO4 can't be used for UART when Ethernet is enabled
Replies: 6
Views: 3189

Re: GPIO4 can't be used for UART when Ethernet is enabled

#define ETH_PHY_ADDR 0 #define ETH_PHY_RST_GPIO GPIO_NUM_17 #define ETH_PHY_POWER_GPIO GPIO_NUM_2 #define ETH_PHY_MDIO_GPIO GPIO_NUM_18 #define ETH_PHY_MDC_GPIO GPIO_NUM_23 esp_err_t Ethernet::init() { esp_err_t err; // Turn on LAN8720 gpio_set_direction(ETH_PHY_POWER_GPIO, GPIO_MODE_OUTPUT); gpio_...
by stijnb1234
Wed Feb 28, 2024 12:47 pm
Forum: Hardware
Topic: GPIO4 can't be used for UART when Ethernet is enabled
Replies: 6
Views: 3189

Re: GPIO4 can't be used for UART when Ethernet is enabled

I'm using an LAN8720 chip connected by a custom PCB, which works fine when I'm not using GPIO4 for UART.

TX EN: IO21
TX D0: IO19
TX D1: IO22
RX D0: IO25
RX D1: IO26
CRS DV: IO27
MDIO: IO18
MDC: IO23
REF CLK: IO0
RESET: IO17
LAN8720 ON: IO2
by stijnb1234
Tue Feb 27, 2024 12:17 pm
Forum: Hardware
Topic: GPIO4 can't be used for UART when Ethernet is enabled
Replies: 6
Views: 3189

GPIO4 can't be used for UART when Ethernet is enabled

I'm using an ESP32-WROOM-U. When I try to use GPIO4 for UART when I have Ethernet enabled, it can't get an IP. Why is this? How can I fix this?