I have a board which have stm32f405 and LAN8720 PHY,it use the mcu mac, i want to use it in mpy,but when i import network module,the module has no 'LAN' method(only a router method),i download a pyboard network DFU , it has no 'LAN' method either.
Does any one test pyboard using its own mac with a PHY like LAN8720?
I think it maybe run faster with this PHY although it need eight PIN to connect to PHY with RMMI interface,because the mac is inside the mcu.
if anyone test pyboard with it,please share your DFU.
any help would be appreciated
pyboard with LAN8720
Re: pyboard with LAN8720
Hi,
The "network" builds have network drivers for CC3000 and WIZ820io included. This does not include the RMII/MII on-chip MAC driver.
I have not tried this myself but I understand it is possible on the pyboard v11 (with the F405).
You will need to build your own firmware and enable the RMII ethernet interface by adding the following to ports/stm32/boards/PYBV11/mpconfigboard.h
Then follow the build instructions (ports/stm32/README.md) and build using
make BOARD=PYBV11
(You might want to double-check those pin assignments from the manual, but I assume you've already figured this out for wiring up your LAN8720)
(I copied this with some small pin modifications from the NUCLEO_F429ZI board definition)
The "network" builds have network drivers for CC3000 and WIZ820io included. This does not include the RMII/MII on-chip MAC driver.
I have not tried this myself but I understand it is possible on the pyboard v11 (with the F405).
You will need to build your own firmware and enable the RMII ethernet interface by adding the following to ports/stm32/boards/PYBV11/mpconfigboard.h
Then follow the build instructions (ports/stm32/README.md) and build using
make BOARD=PYBV11
Code: Select all
// Ethernet via RMII
#define MICROPY_HW_ETH_MDC (pin_C1)
#define MICROPY_HW_ETH_MDIO (pin_A2)
#define MICROPY_HW_ETH_RMII_REF_CLK (pin_A1)
#define MICROPY_HW_ETH_RMII_CRS_DV (pin_A7)
#define MICROPY_HW_ETH_RMII_RXD0 (pin_C4)
#define MICROPY_HW_ETH_RMII_RXD1 (pin_C5)
#define MICROPY_HW_ETH_RMII_TX_EN (pin_B11)
#define MICROPY_HW_ETH_RMII_TXD0 (pin_B12)
#define MICROPY_HW_ETH_RMII_TXD1 (pin_B13)
(I copied this with some small pin modifications from the NUCLEO_F429ZI board definition)
Re: pyboard with LAN8720
Hi, Antonio!
Did this method help you? I'm going to try it myself, so I'm curious if this is the right way.
Did this method help you? I'm going to try it myself, so I'm curious if this is the right way.
Re: pyboard with LAN8720
Interest on it.
Can we refer ESP32 network.LAN() implement, it works fine, it initialize with:
Relate link:
https://github.com/micropython/micropyt ... work_lan.c
https://github.com/micropython/micropyt ... issues/172
And can you share your STM32F405 -> LAN8720 hardware wiring?
Can we refer ESP32 network.LAN() implement, it works fine, it initialize with:
Code: Select all
lan = network.LAN(mdc = machine.Pin(23), mdio = machine.Pin(18), power = machine.Pin(17), phy_type = network.PHY_LAN8720, phy_addr = 1)
https://github.com/micropython/micropyt ... work_lan.c
https://github.com/micropython/micropyt ... issues/172
And can you share your STM32F405 -> LAN8720 hardware wiring?