34 #include "contiki-net.h"
36 #include "net/wpcap.h"
38 #include "net/wpcap-drv.h"
40 #define BUF ((struct uip_eth_hdr *)&uip_buf[0])
41 #define IPBUF ((struct uip_tcpip_hdr *)&uip_buf[UIP_LLH_LEN])
43 PROCESS(wpcap_process,
"WinPcap driver");
65 if(BUF->type ==
uip_htons(UIP_ETHTYPE_IPV6)) {
69 if(BUF->type ==
uip_htons(UIP_ETHTYPE_IP)) {
73 }
else if(BUF->type ==
uip_htons(UIP_ETHTYPE_ARP)) {
87 #ifdef UIP_FALLBACK_INTERFACE
94 if(BUF->type ==
uip_htons(UIP_ETHTYPE_IPV6)) {
99 if(BUF->type ==
uip_htons(UIP_ETHTYPE_IP)) {
103 }
else if(BUF->type ==
uip_htons(UIP_ETHTYPE_ARP)) {
130 tcpip_set_outputfunc(wpcap_output);
132 tcpip_set_outputfunc(wpcap_send);