Olimex STM32-E407

Discussion and questions about boards that can run MicroPython but don't have a dedicated forum.
Target audience: Everyone interested in running MicroPython on other hardware.
BrendanSimon
Posts: 33
Joined: Wed Sep 07, 2016 10:46 am

Re: Olimex STM32-E407

Post by BrendanSimon » Fri Dec 09, 2016 11:21 am

What is a "PR". Problem Report?

I had a quick look at `drivers/wiznet5k/`, which provides and ethernet interface via the SPI interface. I think it is accessed via the `socket` interface in the `ethernet` directory. I'm assuming it uses the onboard tcp/ip interface on the the W5500 chip, rather than a uPy tcp/ip library and a low level Net IF (but I'm not 100% certain).

The E407 would need to provide a Net IF, presumably to something like `lwip` library (which is in `lib/lwip`).

I think I will ask for some advice on this from the list to see which is the best way to approach this.

BrendanSimon
Posts: 33
Joined: Wed Sep 07, 2016 10:46 am

Re: Olimex STM32-E407

Post by BrendanSimon » Fri Dec 09, 2016 11:49 am

There is a skeleton file `lib/lwip/src/netif/ethernetif.c` which looks like it should be copied somewhere, renamed to something relevant to the stmhal or 407. e.g. stmethif.c or stmf4ethif.c or stmf407ethif.c

Then modifiy it to call the low level functions which should be in the F4 STM32Cube libraries. From memory I think saw lwip in the Cube so it probably already has a lot of this done ??

BrendanSimon
Posts: 33
Joined: Wed Sep 07, 2016 10:46 am

Re: Olimex STM32-E407

Post by BrendanSimon » Fri Dec 09, 2016 12:20 pm

In the F4 Cube directory `STM32Cube_FW_F4_V1.13.0`, there are lots of `ethernetif.c` files.

Example:

`./Projects/STM32469I_EVAL/Applications/LwIP/LwIP_UDP_Echo_Client/Src/ethernetif.c`

Looks like they'd make a great basis for porting to the 407.

Post Reply