return netif;
}
-typedef int (*netif_addr_change_cb_t)(struct netif *netif);
-static netif_addr_change_cb_t g_netif_addr_change_cb = NULL;
-
-void netif_reg_addr_change_cb(void *cb)
-{
- g_netif_addr_change_cb = (netif_addr_change_cb_t)cb;
-}
-
#if LWIP_IPV4
/**
* Change IP address configuration for a network interface (including netmask
netif_set_gw(netif, gw);
/* set ipaddr last to ensure netmask/gw have been set when status callback is called */
netif_set_ipaddr(netif, ipaddr);
- if (g_netif_addr_change_cb){
- g_netif_addr_change_cb(netif);
- }
}
#endif /* LWIP_IPV4*/
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
+
#include <stdio.h>
#include <string.h>
IP4_ADDR(&esp_ip[TCPIP_ADAPTER_IF_AP].gw, 192, 168 , 4, 1);
IP4_ADDR(&esp_ip[TCPIP_ADAPTER_IF_AP].netmask, 255, 255 , 255, 0);
}
-
- netif_reg_addr_change_cb(tcpip_adapter_addr_change_cb);
}
esp_err_t tcpip_adapter_start(tcpip_adapter_if_t tcpip_if, uint8_t *mac, struct ip_info *info)