Module Eth

module Eth: sig .. end
Ethernet protocol implementation.

TODO: (r)STP, optional padding


val debug : bool

Private Types



Ethernet addresses


module Addr: sig .. end
Ethernet addresses are implemented as bitstring internally but the abstract type Eth.Addr.t has a batter printer (which support such thing as vendor decoding).

Gateway specifications


type gw_addr = 
| Mac of Addr.t
| IPv4 of Ip.Addr.t
The address of a gateway, which can be given either as an Ethernet address of as an IP address.
val string_of_gw_addr : gw_addr -> string
Converts a Eth.gw_addr to a string.
val gw_addr_of_string : string -> gw_addr
Converts the other way around.

Ethernet frames


module Pdu: sig .. end
Pack/Unpack an Ethernet frame.

Transceiver


module TRX: sig .. end
An Ethernet TRX will convert from payload to Ethernet frames (resolving destinations using ARP), for a single Arp.HwProto.t.
val limited : Clock.Interval.t ->
float -> (Bitstring.bitstring -> unit) -> Bitstring.bitstring -> unit