The library that’s being used here states in Support Nucleo-H743 · Issue #21 · stm32duino/STM32Ethernet · GitHub that STM32H7 support does not work.
Same is repeated in Use Async Web Server with Nucleo-H743 or H745 · Issue #3 · khoih-prog/AsyncWebServer_STM32 · GitHub.
And again in this issue mqtt_STM32Ethernet.ino doesn't compile with Nucleo H743ZI2 · Issue #28 · stm32duino/STM32Examples · GitHub
I’m afraid you’ll have to use a diffrent library or framework for this, or ping the developers of the library above.
Note that just the Wifi101 library example from WiFi101/examples/WiFiWebClient at master · arduino-libraries/WiFi101 · GitHub compiles when applying the code fix in attachInterrupt() on wifi101 unidentified - #4 by maxgerhardt. It’s the ethernet part that’s giving you problems.
PS: I’ve also checked the latest git version which differs from the latest released version but it does still not compile. The way the STM32H7 HAL layer is accessed with the structures and macros is wrong.
[env:nucleo_h743zi]
platform = ststm32
board = nucleo_h743zi
framework = arduino
lib_deps =
arduino-libraries/WiFi101@^0.16.1
stm32duino/STM32duino LwIP @ ^2.1.2
https://github.com/stm32duino/STM32Ethernet.git
→
.pio\libdeps\nucleo_h743zi\STM32Ethernet@src-d06a072c7077098d2d1f015983f255fd\src\utility\stm32_eth.cpp:67:4: warning: #warning "Default timer used to call ethernet scheduler at regular interval: TIM14" [-Wcpp]
67 | #warning "Default timer used to call ethernet scheduler at regular interval: TIM14"
| ^~~~~~~
Compiling .pio\build\nucleo_h743zi\libf01\WiFi101\WiFiUdp.cpp.o
.pio\libdeps\nucleo_h743zi\STM32Ethernet@src-d06a072c7077098d2d1f015983f255fd\src\utility\ethernetif.cpp:80:48: error: 'ETH_RXBUFNB' was not declared in this scope
80 | __ALIGN_BEGIN ETH_DMADescTypeDef DMARxDscrTab[ETH_RXBUFNB] __ALIGN_END;/* Ethernet Rx MA Descriptor */
| ^~~~~~~~~~~
.pio\libdeps\nucleo_h743zi\STM32Ethernet@src-d06a072c7077098d2d1f015983f255fd\src\utility\ethernetif.cpp:85:48: error: 'ETH_TXBUFNB' was not declared in this scope
85 | __ALIGN_BEGIN ETH_DMADescTypeDef DMATxDscrTab[ETH_TXBUFNB] __ALIGN_END;/* Ethernet Tx DMA Descriptor */
| ^~~~~~~~~~~
.pio\libdeps\nucleo_h743zi\STM32Ethernet@src-d06a072c7077098d2d1f015983f255fd\src\utility\ethernetif.cpp:90:31: error: 'ETH_RXBUFNB' was not declared in this scope
90 | __ALIGN_BEGIN uint8_t Rx_Buff[ETH_RXBUFNB][ETH_RX_BUF_SIZE] __ALIGN_END; /* Ethernet Receive Buffer */
| ^~~~~~~~~~~
.pio\libdeps\nucleo_h743zi\STM32Ethernet@src-d06a072c7077098d2d1f015983f255fd\src\utility\ethernetif.cpp:90:44: error: 'ETH_RX_BUF_SIZE' was not declared in this scope
Compiling .pio\build\nucleo_h743zi\libf01\WiFi101\bsp\source\nm_bsp_arduino.c.o
...
.pio\libdeps\nucleo_h743zi\STM32Ethernet@src-d06a072c7077098d2d1f015983f255fd\src\utility\ethernetif.cpp:184:18: error: 'struct ETH_InitTypeDef' has no member named 'PhyAddress'
184 | EthHandle.Init.PhyAddress = LAN8742A_PHY_ADDRESS;
..