Electronic – Crystal Oscillator for STM32F407 with LAN8720

ethernetlan8720phyrmiistm32

I'm planning to build a custom board with STM32F407 chip for a system where I also need Ethernet connectivity.

I'm planning to connect this board to a LAN8720 with breakout board from Smart Electronics to have Ethernet connectivity (two independent boards connected via PHY interface).

Smart Electronics LAN8720 Ethernet Module

But I'm a bit in doubt regarding which Oscillator to couple with STM32F407.
I read that for RMII we need a 25MHz oscillator to achieve the 50MHz required for RMII circuit. But I also notice that breakout board already its own 50MHz crystal oscillator.

I also notice that some of these boards do not include this extra crystal oscillator, not the case with the board I have.

In this case I still need the use a 25MHz crystal oscillator with STM32F407 or can I use the "standard" 16MHz crystal that also comes with a lot of available boards (DevEBox, DiyMoore, etc).

Thanks in advance!

Cheers,
Leandro

Best Answer

STM32 has a complex clock system that allows to generate specific clock speed for the peripherals. It means many different oscillator can work, but it has to be able to generate the correct final frequency.

You should start by looking at the STM32 stack. You can create a project with the STM32CubeMX software and configure the ethernet module.

STM32CubeMX has a visual representation of the clock and peripherals, so you can use that to get the final correct frequency and then you can see what oscillator frequency you can use as an input.