cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F407IG Ethernet (UDP)

younginpark
Associate II

Is there an example or link where I can see the code for STM32F407IG Ethernet (UDP) communication?

https://www.st.com/en/embedded-software/stm32cubef4.html

The link here doesn't have the code I want

- UPD Ethernet connection
- Code for Ethernet Receive and Send

4 REPLIES 4
Issamos
Lead II

Hello @younginpark 

I can't find direct exemples using STM32F407 but, I suggest you to take a look at this tutorial and try to adapt it to your F407IG (that's not going to be so hard). For advice, I suggest you to migrate to use a H7 or F7 MCU.

Best regards.

II

LCE
Lead III

The bad news: it's not that simple...

UDP: do you want to use lwIP ?

Ethernet Rx / Tx: do you want to use the HAL drivers ? (I don't like these)

CubeMX is a good starting point for that. But IMO only for starting, concerning the HAL ethernet drivers.

I tried LWIP (UDP) communication by looking at the example in the link, but can you tell me why it doesn't connect?
Error : lwip.c -> ethernetif_set_link(&gnetif);  
An error occurs in this part. Could you please tell me a function or method that can be used instead?

LCE
Lead III

As I said, it's not that simple...

So my advice: debug!