I am currently working with STM32F779 and i'm trying to obtain an IP address using the LwIP Middleware unsuccessfully.
Here are the configurations:
1. Change some jumpers according to the user manual page 23.
2. Using the STM32CubeMX, i've made the following configurations
3. In the header file lwip.h i have extern the following variables (used in lwip.c file) because they will also be used at freertos.c file :
extern struct netif gnetif;
extern ip4_addr_t ipaddr;
extern ip4_addr_t netmask;
extern ip4_addr_t gw;
4. In the source file freertos.c, inside the defaultThread, i have the following:
while (gnetif.ip_addr.addr == 0)
mscnt += DHCP_FINE_TIMER_MSECS;
if (mscnt >= DHCP_COARSE_TIMER_SECS * 1000)
mscnt = 0;
Unfotunately, the gnetif.ip_addr.addr is not changing as it should be after obtaining an IP address.
Is there something that i am missing?
Please help me to find the right solution.