INET Framework for OMNeT++/OMNEST
Ethernet.h File Reference
#include "INETDefs.h"

Go to the source code of this file.

Defines

#define MAX_PACKETBURST   13
#define GIGABIT_MAX_BURST_BYTES   8192 /* don't start new frame after 8192 or more bytes already transmitted */
#define MAX_ETHERNET_DATA   1500 /* including LLC, SNAP etc headers */
#define MAX_ETHERNET_FRAME   1518 /* excludes preamble and SFD */
#define MIN_ETHERNET_FRAME   64 /* excludes preamble and SFD */
#define GIGABIT_MIN_FRAME_WITH_EXT   512 /* excludes preamble and SFD, but includes 448 byte extension */
#define INTERFRAME_GAP_BITS   96
#define ETHERNET_TXRATE   10000000.0 /* 10 Mbit/sec (in bit/s) */
#define FAST_ETHERNET_TXRATE   100000000.0 /* 100 Mbit/sec (in bit/s) */
#define GIGABIT_ETHERNET_TXRATE   1000000000.0 /* 1 Gbit/sec (in bit/s) */
#define FAST_GIGABIT_ETHERNET_TXRATE   10000000000.0 /* 10 Gbit/sec (in bit/s) */
#define SLOT_TIME   (512.0/ETHERNET_TXRATE) /* for Ethernet & Fast Ethernet, in seconds */
#define GIGABIT_SLOT_TIME   (4096.0/GIGABIT_ETHERNET_TXRATE) /* seconds */
#define MAX_ATTEMPTS   16
#define BACKOFF_RANGE_LIMIT   10
#define JAM_SIGNAL_BYTES   4
#define PREAMBLE_BYTES   7
#define SFD_BYTES   1
#define PAUSE_BITTIME   512 /* pause is in 512-bit-time units */
#define ETHER_MAC_FRAME_BYTES   (6+6+2+4) /* src(6)+dest(6)+length/type(2)+FCS(4) */
#define ETHER_LLC_HEADER_LENGTH   (3) /* ssap(1)+dsap(1)+control(1) */
#define ETHER_SNAP_HEADER_LENGTH   (5) /* org(3)+local(2) */
#define ETHER_PAUSE_COMMAND_BYTES   (6) /* FIXME verify */

Define Documentation

#define BACKOFF_RANGE_LIMIT   10
#define ETHER_LLC_HEADER_LENGTH   (3) /* ssap(1)+dsap(1)+control(1) */

Definition at line 45 of file Ethernet.h.

Referenced by EtherLLC::processPacketFromHigherLayer().

#define ETHER_PAUSE_COMMAND_BYTES   (6) /* FIXME verify */
#define ETHER_SNAP_HEADER_LENGTH   (5) /* org(3)+local(2) */

Definition at line 46 of file Ethernet.h.

#define ETHERNET_TXRATE   10000000.0 /* 10 Mbit/sec (in bit/s) */
#define FAST_ETHERNET_TXRATE   100000000.0 /* 100 Mbit/sec (in bit/s) */
#define FAST_GIGABIT_ETHERNET_TXRATE   10000000000.0 /* 10 Gbit/sec (in bit/s) */
#define GIGABIT_ETHERNET_TXRATE   1000000000.0 /* 1 Gbit/sec (in bit/s) */
#define GIGABIT_MAX_BURST_BYTES   8192 /* don't start new frame after 8192 or more bytes already transmitted */

Definition at line 25 of file Ethernet.h.

Referenced by EtherMAC::handleEndTxPeriod(), and AnsaEtherMAC::handleEndTxPeriod().

#define GIGABIT_SLOT_TIME   (4096.0/GIGABIT_ETHERNET_TXRATE) /* seconds */
#define INTERFRAME_GAP_BITS   96
#define MAX_ATTEMPTS   16
#define MAX_ETHERNET_DATA   1500 /* including LLC, SNAP etc headers */
#define MAX_ETHERNET_FRAME   1518 /* excludes preamble and SFD */
#define MAX_PACKETBURST   13

Definition at line 24 of file Ethernet.h.

#define PAUSE_BITTIME   512 /* pause is in 512-bit-time units */
#define SLOT_TIME   (512.0/ETHERNET_TXRATE) /* for Ethernet & Fast Ethernet, in seconds */