Showing results for 
Search instead for 
Did you mean: 

Ethernet - RMII vs MII

Associate II

I'm working on an application that requires Ethernet on an STM32F765 chip and there are two options to attach an Ethernet PHY to the MCU: RMII and MII. Deciding on which interface to use has led me to a post that mentioned RMII having issues on STM32 MCUs. Granted, the post is old and refers to the F4 (I'm using the F7), but I'd like to take a poll of what others have experienced with using either RMII or MII. Which one would you recommend and why? What issues have you experienced?

My preference would be to use RMII due to the lower pin count, but it requires a higher clock frequency.

Thanks in advance for your feedback!


RMII works fine.

The ethernet/lwip bugs in HAL are due to software issues, not hardware.

If you feel a post has answered your question, please click "Accept as Solution".
Associate II

Thanks for the reply. I figured that the issue was not related to hardware, but unless one aspires to write their own Ethernet driver, you're stuck with the HAL. In that case, would it be advisable to use MII?

Or have the bugs been fixed? The post I referenced is 6 years old. Not sure if ST addressed these issues.

Associate III

ST has a lot of errors in lwip. This is terrible.

On stm32f407vgt6 I even have "tcp echo server" not working in stm32cubemx 6.0.1+lib 1.25, although in stm32cubemx 4.27+gb 1.21 it worked.

All linked post says, that with RMII you should design hardware appropriately to the 50MHz signalling, starting with a decent clock.


Chief II

I have RMII working flawlessly on a two layer 1,6 mm board. If the board is designed properly, 50 MHz is not very high frequency.

For a clock typically you either put a separate crystal for PHY chip, feed HSE through MCO pin or feed HSE and PHY from other source. Take a note that, when using MCO pin, you cannot source it from PLL because that clock has a significant amount of jitter.

There is a minor errata issue for RMII, but that is easy to work around and is only present on revision A chips, which most likely by now are gone from warehouses anyway.

Regarding HAL/CubeMX bloatware - using MII will not change anything.

> 50 MHz is not very high frequency..

That does not mean it can't be spoiled on a 6- or 8-layer board, with a bit of effort....