cancel
Showing results for 
Search instead for 
Did you mean: 

LWIP sends an arp request for himself

HiSt
Associate

Hello,

I am trying to set up  a UPD communication with a nucleo-H755ZI-Q board.

Now I have the effect, that the lwip stack sends out an arp request for its own IP address.

I double-checked the IP address and destination address to make sure they were correct.

 

Does anyone have any idea, what could be causing this?

Thank you.

HiSt

1 ACCEPTED SOLUTION

Accepted Solutions

Hello,

i thank you all for your reply and your help!

I found the error. It was a simple transposed number.

For the LWIP_RAM_HEAP_POINTER i entered 0x30002000
instead of 0x30020000. Sorry.

The problem with the STM32H755 is that errors when setting up Ethernet are difficult to debug. You don't get an error message and
it's difficult to find the cause due to DMA usage.
There does not appear to be any official guide on how to set it up. Example projects either do not exist, are for a different MCU, do not have an .ioc file, cannot be installed, or use rtos.

Thanks again and best regards,

HiSt

View solution in original post

5 REPLIES 5
STackPointer64
ST Employee

Hello @HiSt, and welcome to ST community!

Could you please provide more details, such as a screen capture of the Wireshark-captured frame and the CubeMX configuration for LwIP? The more information you provide, the less time it will take to find a solution.

Best regards,

To improve visibility of answered topics, please click 'Accept as Solution' on the reply that resolved your issue or answered your question.
HiSt
Associate

Hello,

of course.

HiSt_0-1756799134843.png

Please excuse the resolution.

The Address of STM32H755 (M7) is "192.168.0.1". (M4 ist not working)

HiSt_1-1756799259925.png

The Destination-Address of the Pc ist "192.168.0.11".

Therefore in main.c:

IP_ADDR4(&PC_IPADDR, 192, 168, 0, 11);

...

udp_sendto(my_udp, udp_buffer, &PC_IPADDR, 55151);

Im am working with

HiSt_2-1756799418610.png

 

Best regards,

  HiSt

 

STackPointer64
ST Employee

Hello @HiSt, and welcome to ST Community!

Normally, if the gateway address is valid in the Wireshark capture, it means the device is performing an ARP probe to check whether the assigned IP address is already in use by another device. However, in this case, it appears your device fails to acquire the gateway IP address on its own, which explains the unusual 0.107.0.0 IP address. To resolve this, try setting the gateway IP manually and observe if the ARP traffic changes. Please get back to me if the issue persists so we can further analyze it.

Best regards,

To improve visibility of answered topics, please click 'Accept as Solution' on the reply that resolved your issue or answered your question.
Pavel A.
Super User

Of course it does. This is called "Gratuitous ARP" or GARP.

GAPR can be either a request (to which no response is expected) or unsolicited response (it can be sent periodically).

Hello,

i thank you all for your reply and your help!

I found the error. It was a simple transposed number.

For the LWIP_RAM_HEAP_POINTER i entered 0x30002000
instead of 0x30020000. Sorry.

The problem with the STM32H755 is that errors when setting up Ethernet are difficult to debug. You don't get an error message and
it's difficult to find the cause due to DMA usage.
There does not appear to be any official guide on how to set it up. Example projects either do not exist, are for a different MCU, do not have an .ioc file, cannot be installed, or use rtos.

Thanks again and best regards,

HiSt