summaryrefslogtreecommitdiff
path: root/ports/stm32/powerctrlboot.c
diff options
context:
space:
mode:
authorDamien George <damien@micropython.org>2025-07-26 16:22:36 +1000
committerDamien George <damien@micropython.org>2025-11-20 13:01:35 +1100
commit5a69d4756751b92e13a6ea9a0c7b755dd3b43f7c (patch)
tree9857858d5a81757641a4858e948be419d145c212 /ports/stm32/powerctrlboot.c
parent2ad1d29747df1f35c638b32477684c6e141d0f81 (diff)
stm32/eth: Add support for Ethernet on N6 MCUs.
This adds working support for 100MBit Ethernet on N6 MCUs. Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'ports/stm32/powerctrlboot.c')
-rw-r--r--ports/stm32/powerctrlboot.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/ports/stm32/powerctrlboot.c b/ports/stm32/powerctrlboot.c
index a8ef8c34a..7baaa6773 100644
--- a/ports/stm32/powerctrlboot.c
+++ b/ports/stm32/powerctrlboot.c
@@ -482,6 +482,11 @@ void SystemClock_Config(void) {
LL_RCC_IC11_SetDivider(1);
LL_RCC_IC11_Enable();
+ // Configure IC12 at 100MHz for ETH1CLKSEL.
+ LL_RCC_IC12_SetSource(LL_RCC_ICCLKSOURCE_PLL1);
+ LL_RCC_IC12_SetDivider(8);
+ LL_RCC_IC12_Enable();
+
// Configure IC14 at 100MHz for slower peripherals.
LL_RCC_IC14_SetSource(LL_RCC_ICCLKSOURCE_PLL1);
LL_RCC_IC14_SetDivider(8);