I'm using RT1021 lwip stack and need to account for the IP info could be changed dynamically. This info is needed when initialize LWIP stack, below:
netifapi_netif_add(&g_netif, &netif_ipaddr, &netif_netmask, &netif_gw, &enet_config, EXAMPLE_NETIF_INIT_FN,tcpip_input);
netifapi_netif_set_default(&g_netif);
netifapi_netif_set_up(&g_netif);
My questions are:
1. Is there such API de_init_lwip to properly delete/remove previously lwip stack setup with old IP info to repeat the re-initialization with new IP info? (I tried to re-init anyways this without the non existing de_init API and ran into a ASSERT code halt "Function called without core lock").
2. How do I handle properly when getting the new IP info to re-initialize lwip stack to effect the new IP?
thanks.