Update IDF to 9274814 (#767)

* Update IDF to 9274814

* Fix error in i2c and Arduino
This commit is contained in:
Me No Dev
2017-10-24 00:21:00 +02:00
committed by GitHub
parent 95123681d5
commit 55289a45af
99 changed files with 1011 additions and 1302 deletions

View File

@ -15,8 +15,6 @@
#define __DHCPS_H__
#include "lwip/ip_addr.h"
//#include "esp_common.h"
#define USE_DNS
typedef struct dhcps_state{
s16_t state;
@ -46,6 +44,7 @@ typedef struct {
enum dhcps_offer_option{
OFFER_START = 0x00,
OFFER_ROUTER = 0x01,
OFFER_DNS = 0x02,
OFFER_END
};
@ -63,17 +62,29 @@ typedef u32_t dhcps_time_t;
typedef u8_t dhcps_offer_t;
typedef struct {
dhcps_offer_t dhcps_offer;
dhcps_time_t dhcps_time;
dhcps_lease_t dhcps_poll;
dhcps_offer_t dhcps_offer;
dhcps_offer_t dhcps_dns;
dhcps_time_t dhcps_time;
dhcps_lease_t dhcps_poll;
} dhcps_options_t;
#define dhcps_router_enabled(offer) ((offer & OFFER_ROUTER) != 0)
static inline bool dhcps_router_enabled (dhcps_offer_t offer)
{
return (offer & OFFER_ROUTER) != 0;
}
static inline bool dhcps_dns_enabled (dhcps_offer_t offer)
{
return (offer & OFFER_DNS) != 0;
}
void dhcps_start(struct netif *netif, ip4_addr_t ip);
void dhcps_stop(struct netif *netif);
void *dhcps_option_info(u8_t op_id, u32_t opt_len);
void dhcps_set_option_info(u8_t op_id, void *opt_info, u32_t opt_len);
bool dhcp_search_ip_on_mac(u8_t *mac, ip4_addr_t *ip);
void dhcps_dns_setserver(const ip_addr_t *dnsserver);
ip4_addr_t dhcps_dns_getserver();
#endif