86 |
PACK_STRUCT_FIELD(u8_t file[DHCP_FILE_LEN]); |
PACK_STRUCT_FIELD(u8_t file[DHCP_FILE_LEN]); |
87 |
PACK_STRUCT_FIELD(u32_t cookie); |
PACK_STRUCT_FIELD(u32_t cookie); |
88 |
#define DHCP_MIN_OPTIONS_LEN 68U |
#define DHCP_MIN_OPTIONS_LEN 68U |
89 |
|
/** make sure user does not configure this too small */ |
90 |
|
#if ((defined(DHCP_OPTIONS_LEN)) && (DHCP_OPTIONS_LEN < DHCP_MIN_OPTIONS_LEN)) |
91 |
|
# undef DHCP_OPTIONS_LEN |
92 |
|
#endif |
93 |
/** allow this to be configured in lwipopts.h, but not too small */ |
/** allow this to be configured in lwipopts.h, but not too small */ |
94 |
#if ((!defined(DHCP_OPTIONS_LEN)) || (DHCP_OPTIONS_LEN < DHCP_MIN_OPTIONS_LEN)) |
#if (!defined(DHCP_OPTIONS_LEN)) |
95 |
/** set this to be sufficient for your options in outgoing DHCP msgs */ |
/** set this to be sufficient for your options in outgoing DHCP msgs */ |
96 |
# define DHCP_OPTIONS_LEN DHCP_MIN_OPTIONS_LEN |
# define DHCP_OPTIONS_LEN DHCP_MIN_OPTIONS_LEN |
97 |
#endif |
#endif |
104 |
|
|
105 |
/** start DHCP configuration */ |
/** start DHCP configuration */ |
106 |
err_t dhcp_start(struct netif *netif); |
err_t dhcp_start(struct netif *netif); |
107 |
|
/** enforce early lease renewal (not needed normally)*/ |
108 |
|
err_t dhcp_renew(struct netif *netif); |
109 |
|
/** release the DHCP lease, usually called before dhcp_stop()*/ |
110 |
|
err_t dhcp_release(struct netif *netif); |
111 |
/** stop DHCP configuration */ |
/** stop DHCP configuration */ |
112 |
void dhcp_stop(struct netif *netif); |
void dhcp_stop(struct netif *netif); |
113 |
/** enforce lease renewal */ |
/** inform server of our manual IP address */ |
|
err_t dhcp_renew(struct netif *netif); |
|
|
/** inform server of our IP address */ |
|
114 |
void dhcp_inform(struct netif *netif); |
void dhcp_inform(struct netif *netif); |
115 |
|
|
116 |
/** if enabled, check whether the offered IP address is not in use, using ARP */ |
/** if enabled, check whether the offered IP address is not in use, using ARP */ |