cancel
Showing results for 
Search instead for 
Did you mean: 

LWIP with STM32F769

Rick MC
Associate III
Posted on May 21, 2018 at 17:07

I want to use the ETH port to communicate with other devices. I started by creating a project in CubeMX for the STM2F769I-Disc board. 

I simply added the LWIP and the ETH port (as RMII) and set a specific IP address (which was not already taken by any other device, my pc included). 

I'm using IAR to comile the project and everything is fine: I also added in the while(1) the function MX_LWIP_Process();

My problem is that I don't reach the board at its specific address when I ping it.

Where am I going wrong?

Thank you!

#stm32f7 #lwip #eth
1 ACCEPTED SOLUTION

Accepted Solutions
john doe
Lead
Posted on May 23, 2018 at 01:59

Make sure you set the PHY address to 0.  STM32CubeMX application STILL wants to set it to 1.  Come on, ST,  how many years do we have to wait?

View solution in original post

8 REPLIES 8
Rick MC
Associate III
Posted on May 22, 2018 at 08:58

In particular the code returns an error in function HAL_ETH_GetReceivedFrame since the following if statement is not verified:

/* Check if segment is not owned by DMA */

if(((heth->RxDesc->Status & ETH_DMARXDESC_OWN) == (uint32_t)RESET))

What is this statement doing? When is its condition true?

john doe
Lead
Posted on May 23, 2018 at 01:59

Make sure you set the PHY address to 0.  STM32CubeMX application STILL wants to set it to 1.  Come on, ST,  how many years do we have to wait?

Rick MC
Associate III
Posted on May 23, 2018 at 13:39

Thanks for your advice about the PHY parameter! It must have been that. Now it works well!

Posted on May 23, 2018 at 12:45

Hello,

The

PHY 

address name issue is already fixed in the

STM32CubeMx 

4.19 release: You can change the PHY address value in ETH configuration, then go to the 'Parameter Settings' tab.

With Regards,

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen
Posted on May 23, 2018 at 13:37

It is NOT fixed in 4.25.1. PHY defaults to 1 - see attached images

0690X0000060KtXQAU.png0690X0000060KthQAE.png
Posted on May 23, 2018 at 14:06

Hello

doe.john.016

,

B

y default,

the PHY address value in ETH configuration is setted to 1, and you can change it to 0.

With Regards,

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen

As far I can see, initially CubeMX starts with the correct PHY address of 0... but then if you (for example) disable and re-enable the ETH device, it changes the PHY address from 0 to 1

We are spending so much time on this stupid CubeMX behaviours...

I can't set PHY to 0 because there is no such setting for this card.