ether.h
来自「在ARM7和UC/OSII的平台上实现了GPS自动报站的功能,涉及GPS模块LE」· C头文件 代码 · 共 67 行
H
67 行
/*
* FILENAME: ether.h
*
* Copyright 2000 By InterNiche Technologies Inc. All rights reserved
*
* information common to all ethernet drivers
*
* MODULE: INET
*
*
* PORTABLE: yes
*/
/* Additional Copyrights: */
/* Portions Copyright 1990, 1993 by NetPort Software. */
/* Portions Copyright 1986 by Carnegie Mellon */
/* Portions Copyright 1983, 1985 by the Massachusetts Institute of Technology */
#ifndef _ETHER_H_
#define _ETHER_H_ 1
/* initialization modes: 0 = rcv normal + broadcast packets */
#define LOOPBACK 0x01 /* send packets in loopback mode */
#define ALLPACK 0x02 /* receive all packets: promiscuous */
#define MULTI 0x04 /* receive multicast packets */
/* ethernet packet header */
START_PACKED_STRUCT(ethhdr)
u_char e_dst[6];
u_char e_src[6];
unshort e_type;
END_PACKED_STRUCT(ethhdr)
/* ETHHDR_SIZE - size of packet header structure for allocation
* purposes Note this is a default -- it should be overridden in
* ipport.h if the need arises.
*/
#ifndef ETHHDR_SIZE
#define ETHHDR_SIZE (sizeof(struct ethhdr))
#endif /* ETHHDR_SIZE */
/* ETHHDR_BIAS - where to locate the struct ethhdr within the
* allocated space, as an offset from the start in bytes Note this is
* a default -- it should be overridden in ipport.h if the need
* arises.
*/
#ifndef ETHHDR_BIAS
#define ETHHDR_BIAS 0
#endif /* ETHHDR_BIAS */
/* minimum & maximun length legal ethernet packet sizes */
#define ET_MINLEN 60
#define ET_MAXLEN 1514
#define MINTU 60
#define MTU 1514
extern unsigned char ETBROADCAST[];
#endif /* _ETHER_H_ */
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?