ConOpSys V2970
P004.07
ANVILEX control operating system
|
Go to the source code of this file.
Classes | |
struct | eth_addr |
struct | eth_hdr |
struct | eth_vlan_hdr |
Macros | |
#define | ETH_HWADDR_LEN 6 |
#define | ETH_ADDR(b0, b1, b2, b3, b4, b5) {{b0, b1, b2, b3, b4, b5}} |
#define | SIZEOF_ETH_HDR (14 + ETH_PAD_SIZE) |
#define | SIZEOF_VLAN_HDR 4 |
#define | VLAN_ID(vlan_hdr) (lwip_htons((vlan_hdr)->prio_vid) & 0xFFF) |
#define | LL_IP4_MULTICAST_ADDR_0 0x01 |
#define | LL_IP4_MULTICAST_ADDR_1 0x00 |
#define | LL_IP4_MULTICAST_ADDR_2 0x5e |
#define | LL_IP6_MULTICAST_ADDR_0 0x33 |
#define | LL_IP6_MULTICAST_ADDR_1 0x33 |
#define | eth_addr_cmp(addr1, addr2) (memcmp((addr1)->addr, (addr2)->addr, ETH_HWADDR_LEN) == 0) |
Variables | |
PACK_STRUCT_BEGIN struct eth_addr | PACK_STRUCT_STRUCT |
Ethernet protocol definitions
#define ETH_ADDR | ( | b0, | |
b1, | |||
b2, | |||
b3, | |||
b4, | |||
b5 | |||
) | {{b0, b1, b2, b3, b4, b5}} |
initialise a struct eth_addr with its 6 bytes (takes care of correct braces)
#define eth_addr_cmp | ( | addr1, | |
addr2 | |||
) | (memcmp((addr1)->addr, (addr2)->addr, ETH_HWADDR_LEN) == 0) |
#define ETH_HWADDR_LEN 6 |
#define LL_IP4_MULTICAST_ADDR_0 0x01 |
The 24-bit IANA IPv4-multicast OUI is 01-00-5e:
#define LL_IP4_MULTICAST_ADDR_1 0x00 |
#define LL_IP4_MULTICAST_ADDR_2 0x5e |
#define LL_IP6_MULTICAST_ADDR_0 0x33 |
IPv6 multicast uses this prefix
#define LL_IP6_MULTICAST_ADDR_1 0x33 |
#define SIZEOF_ETH_HDR (14 + ETH_PAD_SIZE) |
#define SIZEOF_VLAN_HDR 4 |
#define VLAN_ID | ( | vlan_hdr | ) | (lwip_htons((vlan_hdr)->prio_vid) & 0xFFF) |
PACK_STRUCT_BEGIN struct eth_vlan_hdr PACK_STRUCT_STRUCT |