STM32H7 Ethernet
Hi,
Likely this is a feature request - but is it feasible to get ethernet working for the H7 series of STM32 chips? I know the registers are different compared to the other chips, but I wasn't sure if anyone was looking in to this.
Thanks,
Rob
stm32: Add support for ETH RMII peripheral (version 2)
This is an improved version of #3808, to add full Ethernet support to the stm32 port. It is actually a complete rewrite from scratch of the Ethernet driver.
Features of this version are:
- no use of the ST HAL, ETH driver is completely self contained
- MPU is used to interface correctly with the ETH DMA system, but no definitions are needed in the linker script
- improvements made to modlwip to protect against concurrency issues with the ETH driver
- addition of Ethernet frame tracing, enabled via
lan.config(trace=7) - enabled on NUCLEO_F767ZI, STM32F7DISC and STM32F769DISC
Tested on a NUCLEO_F767ZI and STM32F769DISC board. The following code will get it connected:
import network
lan = network.LAN()
lan.active(1)
DHCP is automatically enabled. IP can be statically assigned via lan.ifconfig(...). The API is the same as WLAN and LAN on other ports.
The following network performance was obtained with the STM32F769DISC board on a 100Mbit full-duplex LAN:
- TCP send: 82 Mbit/sec
- TCP recv: 89 Mbit/sec
- UDP send: 85 Mbit/sec (no lost packets)
- UDP recv: 30 Mbit/sec (1% packet loss)
I think the UDP receive rate can be improved by some minor improvements to extmod/modlwip.c, since the TCP receive is much higher (and close to the theoretical maximum).