mirror of
https://github.com/espressif/esp-idf.git
synced 2026-05-19 23:45:28 +02:00
feat(network/examples): extended LwIP bridge example
Extended LwIP bridge example to support WiFi AP interface and DHCP Server https://github.com/espressif/esp-idf/issues/5697
This commit is contained in:
@@ -604,7 +604,7 @@ static void send_offer(dhcps_t *dhcps, struct dhcps_msg *m, u16_t len)
|
||||
ip_addr_t ip_temp = IPADDR4_INIT(0x0);
|
||||
ip4_addr_set(ip_2_ip4(&ip_temp), &dhcps->broadcast_dhcps);
|
||||
#if DHCPS_DEBUG
|
||||
SendOffer_err_t = udp_sendto(pcb_dhcps, p, &ip_temp, DHCPS_CLIENT_PORT);
|
||||
SendOffer_err_t = udp_sendto(dhcps->dhcps_pcb, p, &ip_temp, DHCPS_CLIENT_PORT);
|
||||
DHCPS_LOG("dhcps: send_offer>>udp_sendto result %x\n", SendOffer_err_t);
|
||||
#else
|
||||
udp_sendto(dhcps->dhcps_pcb, p, &ip_temp, DHCPS_CLIENT_PORT);
|
||||
@@ -682,7 +682,7 @@ static void send_nak(dhcps_t *dhcps, struct dhcps_msg *m, u16_t len)
|
||||
ip_addr_t ip_temp = IPADDR4_INIT(0x0);
|
||||
ip4_addr_set(ip_2_ip4(&ip_temp), &dhcps->broadcast_dhcps);
|
||||
#if DHCPS_DEBUG
|
||||
SendNak_err_t = udp_sendto(pcb_dhcps, p, &ip_temp, DHCPS_CLIENT_PORT);
|
||||
SendNak_err_t = udp_sendto(dhcps->dhcps_pcb, p, &ip_temp, DHCPS_CLIENT_PORT);
|
||||
DHCPS_LOG("dhcps: send_nak>>udp_sendto result %x\n", SendNak_err_t);
|
||||
#else
|
||||
udp_sendto(dhcps->dhcps_pcb, p, &ip_temp, DHCPS_CLIENT_PORT);
|
||||
@@ -1005,7 +1005,7 @@ POOL_CHECK:
|
||||
|
||||
#if DHCPS_DEBUG
|
||||
DHCPS_LOG("dhcps: xid changed\n");
|
||||
DHCPS_LOG("dhcps: client_address.addr = %x\n", client_address.addr);
|
||||
DHCPS_LOG("dhcps: client_address.addr = %x\n", dhcps->client_address.addr);
|
||||
#endif
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user