pub struct Eui48Addr {
pub octets: [u8; 6],
}
Expand description
EUI-48 MAC address struct.
Can be instantiated with Eui48Addr::new
.
This is an EUI-48 MAC address (previously called MAC-48).
Fields§
§octets: [u8; 6]
Octets of the MAC address.
Implementations§
source§impl Eui48Addr
impl Eui48Addr
sourcepub const fn new(a: u8, b: u8, c: u8, d: u8, e: u8, f: u8) -> Eui48Addr
pub const fn new(a: u8, b: u8, c: u8, d: u8, e: u8, f: u8) -> Eui48Addr
Creates a new EUI-48 MAC address from six eight-bit octets.
The result will represent the EUI-48 MAC address
a
:b
:c
:d
:e
:f
.
Examples
use w5500_ll::net::Eui48Addr;
let addr = Eui48Addr::new(0x00, 0x00, 0x5E, 0x00, 0x00, 0x00);
sourcepub const UNSPECIFIED: Eui48Addr = _
pub const UNSPECIFIED: Eui48Addr = _
An EUI-48 MAC address representing an unspecified address: 00:00:00:00:00:00
Examples
use w5500_ll::net::Eui48Addr;
let addr = Eui48Addr::UNSPECIFIED;
assert_eq!(addr, Eui48Addr::new(0x00, 0x00, 0x00, 0x00, 0x00, 0x00));
Trait Implementations§
source§impl Ord for Eui48Addr
impl Ord for Eui48Addr
source§impl PartialEq for Eui48Addr
impl PartialEq for Eui48Addr
source§impl PartialOrd for Eui48Addr
impl PartialOrd for Eui48Addr
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for Eui48Addr
impl Eq for Eui48Addr
impl StructuralEq for Eui48Addr
impl StructuralPartialEq for Eui48Addr
Auto Trait Implementations§
impl RefUnwindSafe for Eui48Addr
impl Send for Eui48Addr
impl Sync for Eui48Addr
impl Unpin for Eui48Addr
impl UnwindSafe for Eui48Addr
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more